Overview
GET
/communities/{id}/topicscommunityList a community’s live topics (filter by category, sort, paged; private instance: members only → 404)
Fetch a record from topics by id.
Auth: bearerAuth — calls run as the authenticated user.
Parameters
- idpathstring
- categoryquery · optionalstring
- sortquery · optional"recent" | "popular" | "trending"
- pagequery · optionalstring
- pageSizequery · optionalstring
Responses
200
The community’s live topics + a total count
- itemsDiscussionTopic[]
- totalinteger
Example
{
"items": [
{
"id": "string",
"communityId": "string",
"customerId": "string",
"title": "string",
"categoryId": "string",
"isPinned": true,
"isLocked": true,
"isPublic": true,
"replyCount": 0,
"answeredPostId": "string",
"lastActivityAt": "string",
"createdAt": "string",
"updatedAt": "string",
"excerpt": "string",
"authorName": "string",
"authorSlug": "string",
"authorAvatarUrl": "string"
}
],
"total": 0
}401
Error
- erroroptionalobject
Example
{
"error": {
"message": "string",
"code": "string"
}
}404
Error
- erroroptionalobject
Example
{
"error": {
"message": "string",
"code": "string"
}
}Code examples
cURL
curl -X GET "https://api.agenticdeveloperhub.com/communities/{id}/topics" \
-H "Authorization: Bearer YOUR_TOKEN"JavaScript
const res = await fetch("https://api.agenticdeveloperhub.com/communities/{id}/topics", {
method: "GET",
headers: {
"Authorization": "Bearer YOUR_TOKEN"
},
});
const data = await res.json();