getPostLikes query.
The following arguments can be used in the query:
| Argument | Type | Description | Default |
|---|---|---|---|
postId | Int | Required. The post ID to get the related comments. | — |
after | Cursor | Returns results that come after the specified cursor. Should be used together with first parameter. Cannot be used if before is set. | — |
before | Cursor | Returns results that come before the specified cursor. Should be used together with last parameter. Cannot be used if after is set. | — |
first | Integer | Returns up to the first N elements from the list. Required if after parameter is set. Cannot be used together with last. | — |
last | Integer | Returns up to the first N elements from the list. Required if before parameter is set. Cannot be used together with first. | — |
reverse | Boolean | Allows to change the order of the sorting to DESC. | false |
sortKey | LikeSortKey | Allows to change the sorting key of the query. Available options: CREATED or USER_NAME (allows to sort by the user context name). | CREATED |
query getPostLikes {
getPostLikes(postId: 169, first: 2) {
edges {
node {
userContext {
id
uuid
}
}
}
pageInfo {
hasNextPage
startCursor
endCursor
}
}
}
{
"data": {
"getPostLikes": {
"edges": [
{
"node": {
"userContext": {
"id": "915",
"uuid": "5acfc440-88e0-4286-b089-c0f03575ed91"
}
}
},
{
"node": {
"userContext": {
"id": "3302",
"uuid": "fddab9cc-9379-4e39-b058-5709f0915ac1"
}
}
}
],
"pageInfo": {
"hasNextPage": false,
"startCursor": "TzozMzoiRHJ1cGFsXG9waWdub19hcGlcV3JhcHBlcnNcQ3Vyc29yIjo0OntzOjE0OiIAKgBiYWNraW5nVHlwZSI7czoxMToib3BpZ25vX2xpa2UiO3M6MTI6IgAqAGJhY2tpbmdJZCI7aTozNztzOjEwOiIAKgBzb3J0S2V5IjtzOjc6IkNSRUFURUQiO3M6MTI6IgAqAHNvcnRWYWx1ZSI7aToxNzUxNTU2MzM2O30=",
"endCursor": "TzozMzoiRHJ1cGFsXG9waWdub19hcGlcV3JhcHBlcnNcQ3Vyc29yIjo0OntzOjE0OiIAKgBiYWNraW5nVHlwZSI7czoxMToib3BpZ25vX2xpa2UiO3M6MTI6IgAqAGJhY2tpbmdJZCI7aTozOTtzOjEwOiIAKgBzb3J0S2V5IjtzOjc6IkNSRUFURUQiO3M6MTI6IgAqAHNvcnRWYWx1ZSI7aToxNzUxNTU2NzI0O30="
}
}
}
}