HomeAboutMeBlogGuest
© 2025 Sejin Cha. All rights reserved.
Built with Next.js, deployed on Vercel
🧚
[1기]최종 프로젝트 데브코스
/
🏄‍♂️
[팀8] 어푸(Ah puh) - Surf
/
🏷️
API 설계
/
API 설계

API 설계

API 설계
도메인
기능
HTTP method
Path
Request / Response
응답 코드
진행상황
담당자
메모
완료
USER
로그인
POST
/users/login
200
완료
완료
USER
로그인
POST
/users/login
200
완료
완료
USER
회원가입
POST
/users
201
완료
완료
USER
개인 정보 수정
PUT
/users
200
완료
완료
USER
회원 정보 조회
GET
/users/{userId}
200
완료
완료
USER
회원 탈퇴
DELETE
/users
204
완료
완료
POST
게시글 등록
POST
/posts
201
완료
완료
POST
게시글 수정
PUT
/posts/{postId}
200
완료
완료
POST
게시글 삭제
DELETE
/posts/{postId}
204
완료
완료
POST
게시글 상세 조회
GET
/posts/{postId}
200
완료
완료
POST
즐겨찾기
POST
/posts/{postId}/favorite
200
완료
완료
POST
즐겨찾기 취소
DELETE
/posts/{postId}/favorite
200
완료
완료
POST
해당년도 게시글 개수 정보 조회
GET
/posts/calendarGraph?year={year}&userId={userId}
200
완료
1. 카드 페이지 버튼 누를 때 - 1년치 한 번에 보냄 2. surfing stat(잔디밭) 🔆조회하려는 userId를 request param으로 추가(잔디밭에서 필요)
완료
POST
일년치 게시글 점수 조회
GET
/posts/score?userId={userId}
200
완료
- 메인페이지 그래프 (카테고리 미 선택시) 타회원 그래프 조회 가능 (userId) 카테고리 선택하면 categoryId로 필터링 1. category id 2. post의 select date 순으로 정렬 🔆응답에서 selectedDate, score → x, y로 수정
완료
POST
한달 전체 게시글 조회
GET
/posts/month?year={year}&month={month}
200
완료
- 카드 페이지에서 카드를 눌렀을 때 ex> URL?year=2016&month=8 - userId는 토큰
완료
POST
전체 게시글 조회
GET
/posts/all?userId={userId}&cursorId={cursorId}
200
완료
- 10개씩 무한 스크롤(커서 페이징)
완료
POST
카테고리별 게시글 전체 조회
GET
/posts?userId={userId}&categoryId={categoryId}&cursorId={cursorId}
200
완료
- 10개씩 무한 스크롤(커서 페이징)
완료
POST
카테고리별 최근 게시글 점수 조회
GET
/recentscore?categoryId={categoryId}
200
완료
기능 분리 - post 생성 위해 (+) 누를 때
완료
POST
최신 전체 게시글 둘러보기
GET
/posts/recent?cursorId={cursorId}
200
완료
- 최신 전체 게시글 10개씩 둘러보기
완료
POST
팔로우 한 사용자 게시글 둘러보기
GET
/follow/posts?cursorId={cursorId}
200
완료
- 팔로우한 사용자 게시글 둘러보기
완료
CATEGORY
카테고리 등록
POST
/categories
201
완료
완료
CATEGORY
카테고리 수정
PUT
/categories/{categoryId}
200
완료
완료
CATEGORY
카테고리 삭제
DELETE
/categories/{categoryId}
204
완료
완료
CATEGORY
카테고리 전체 조회
GET
/categories
200
완료
categoryId, catagoryName 확인 가능
완료
CATEGORY
해당 사용자의 대시보드 정보
GET
/categories/dashboard?userId={userId}
200
완료
완료
완료
FOLLOW
팔로우
POST
/follow
201
완료
완료
FOLLOW
언팔로우
DELETE
/follow/{userId}
204
완료
완료
FOLLOW
특정 사용자의 팔로워 전체 조회
GET
/users/{userId}/followers
200
완료
완료
FOLLOW
특정 사용자가 팔로잉 한 사람 전체 조회
GET
/users/{userId}/following
200
완료
완료
LIKE
게시글 좋아요
POST
/posts/{postId}/like
200
완료
완료
LIKE
게시글 좋아요 취소
DELETE
/posts/{postId}/unlike/{likeId}
204
완료
완료