List topics
Lists visible topics, default first then by name. The organization holds at most 200 topics, so the list is bounded and unpaged.
GET
Lists visible topics, default first then by name. The organization holds at most 200 topics, so the list is bounded and unpaged.
apiKeyheader
x-api-key<token>namespaceId?stringMatch
^ns_[0-9a-hjkmnp-tv-z]{16,24}$TopicList
application/json- response
items*array<>Items
items <= 200import { createClient } from "samva";
const samva = createClient({ apiKey: process.env.SAMVA_API_KEY! });
const result = await samva.topics.list({});Example Response
{
"items": [
{
"id": "string",
"namespaceId": "string",
"name": "string",
"description": "string",
"default": "opt_out",
"isDefault": true,
"defaultSenderId": "string",
"replyMailboxId": "string",
"templateId": "string",
"subscriptions": {
"sms": {
"subscribed": 0,
"unsubscribed": 0
},
"whatsapp": {
"subscribed": 0,
"unsubscribed": 0
},
"email": {
"subscribed": 0,
"unsubscribed": 0
}
},
"createdAt": "string",
"updatedAt": "string"
}
]
}