OpenIsle Docs

List Comments

GET
/api/posts/{postId}/comments
AuthorizationBearer <token>

In: header

Path Parameters

postIdinteger
Formatint64

Query Parameters

sort?string
Default"OLDEST"
Value in"NEWEST" | "OLDEST" | "MOST_INTERACTIONS"

Response Body

curl -X GET "https://www.staging.open-isle.com/api/posts/0/comments?sort=NEWEST"
[
  {
    "id": 0,
    "content": "string",
    "createdAt": "2019-08-24T14:15:22Z",
    "pinnedAt": "2019-08-24T14:15:22Z",
    "author": {
      "id": 0,
      "username": "string",
      "avatar": "string",
      "displayMedal": "COMMENT"
    },
    "reactions": [
      {
        "id": 0,
        "type": "LIKE",
        "user": "string",
        "postId": 0,
        "commentId": 0,
        "messageId": 0,
        "reward": 0
      }
    ],
    "reward": 0,
    "pointReward": 0
  }
]