HomeAboutMeBlogGuest
© 2025 Sejin Cha. All rights reserved.
Built with Next.js, deployed on Vercel
♥️
2기 최종 프로젝트 팀별 공간
/
[팀 08] 사이코
[팀 08] 사이코
/
📶
API 설계
/
📃
채팅방 목록 조회
📃

채팅방 목록 조회

Method
GET
URL Patterns
api/v1/chatRooms
인증 필요 여부
O
요청
Get api/v1/chatRooms?offset=&limit=

QueryParam

  • offset (필수)
    • 상품 번호(index)
    • 0부터 시작
  • limit (필수)
    • 한번에 받아오는 상품 개수
    • 1부터 시작
응답
// 채팅 목록 페이지 진입시 (만약 API로 목록을 불러온다면) response [ { "chatRoomId": 2, "productInfo": { "productId": 2, "thumbnailImage": "https://user-images.githubusercontent.com/61923768/182771448-d2eefc50-7f3a-4582-8eb7-e91ebb9e94d0.png" }, "opponentUserInfo": { "username": "유재희", "profileImage": "https://lh3.googleusercontent.com/a/AItbvmmujg3pE4C3iRbHWRZCd-BtvUykZ2BaaIAuSoo7=s96-c" }, "lastMessage": "마지막 메세지", "lastMessageDate": "2022-08-10T13:13:54" } ]
  • 응답에 데이터가 없을 경우 빈배열을 반환합니다