Update Topic
Update a topic's name, description, or visibility.
PATCH
/topics/{topic_id}Requires a full_access API key.
Path Parameters
topic_idstringrequiredThe topic ID (UUID).
Body Parameters
namestringThe new topic name. Max 50 characters.
descriptionstringThe new description. Max 200 characters.
visibilitystringThe new visibility: "public" or "private".
Response Fields
objectstringAlways "topic".
idstringThe topic ID.
curl -X PATCH 'https://api.postflare.app/topics/b2c3d4e5-f6a7-8901-bcde-f12345678901' \
-H 'Authorization: Bearer re_xxxxxxxxx' \
-H 'Content-Type: application/json' \
-d '{
"name": "Latest Product News",
"visibility": "public"
}'const response = await fetch(
'https://api.postflare.app/topics/b2c3d4e5-f6a7-8901-bcde-f12345678901',
{
method: 'PATCH',
headers: {
'Authorization': 'Bearer re_xxxxxxxxx',
'Content-Type': 'application/json',
},
body: JSON.stringify({
name: 'Latest Product News',
visibility: 'public',
}),
}
);
const data = await response.json();Response
{
"object": "topic",
"id": "b2c3d4e5-f6a7-8901-bcde-f12345678901"
}