Retrieve Posts
Retrieve Information about a Post
post
query is used to retrieve information about a post.
It takes id
as an input.
{
post(id: "NHzqSd4upYWuSkb") {
title
shortContent
}
}
List of Posts
posts
query is used to get a list of posts.
It returns a paginated list of posts. It takes pagination parameters as inputs.
You can also filter the list using filterBy
, postTypeIds
, spaceIds
, and orderBy
inputs.
{
posts(limit: 10) {
nodes {
id
title
shortContent
}
}
}
Feed
feed
query is similar to posts query and is optimized
for showing the posts in the feed.
It returns a paginated list of posts. It takes pagination parameters as inputs.
You can also filter the list using postTypeIds
, onlyMemberSpace
, and orderBy
inputs.
{
feed(limit: 10, ) {
nodes {
id
title
shortContent
reactions {
count
reaction
}
}
}
}