유저의 좋아요 게시물 조회하기

해당 id의 유저가 좋아요를 누른 게시물을 조회하는 API입니다.

METHOD

GET

URL

/users/:id/likes
  • id: 유저 고유 id

Url Example

users/1/likes?page=0&size=2&sort=post.likeCount,desc

Query String

name

type

require

description

page

number

선택, 기본값 = 0

불러올 페이지, 0부터 시작

size

number

선택, 기본값 = 20

불러올 게시물 개수

sort

string

선택

정렬 기준, 유저가 좋아요한 최신 순: sort=id,desc 게시물 최신 순: sort:post.id,desc 정렬 기준 한개 이상 가능 sort=post.likeCount,desc&sort=post.viewCount,desc

RESPONSE

  • totalNum: 좋아요 한 post 객체의 개수 (number)

  • postList: 좋아요 한 post 리스트 (post List)

    • post: 게시물 정보

      • id: 게시물 고유 id (number)

      • category: 게시물 카테고리 정보 (object)

        • id: 카테고리 id (number)

        • name: 카테고리 이름 (string)

        • level: 카레고리 level, 항상 2

        • postNum: 카테고리가 가지고 있는 게시물 수 (number)

        • parentCategoryId: 상위 카테고리 id, 항상 1

      • user: 작성자 정보 (object)

        • email: 이메일 (string)

        • name: 이름 (string)

        • nickname: 별명 (string)

        • profileImage: 작성자 프로필 사진 (이미지 링크 string or base64 encoded string / BLOB)

      • title: 게시물 제목 (string)

      • content: 게시물 내용 (string)

      • likeCount: 좋아요 수 (number)

      • viewCount: 조회수 (number)

RESPONSE EXAMPLE

success

HTTP Status code : 200 OK

fail

HTTP Status code : 400 Bad Request

name

type

description

status

string

HTTP status

message

string

에러 메시지

Last updated

Was this helpful?