Topics
Create a new topic
Introduction
Organization APIs
- Users
- Invitations
- Workspaces
Workspace APIs
- Syncs
- Sync Management Links
- Sync Runs
- Destination Types
- Destinations
- Destination Connect Links
- Source Types
- Sources
- Source Connect Links
- Segment Management Links
- Webhooks
Topics
Create a new topic
POST
/
sources
/
{source_id}
/
topics
curl --request POST \
--url https://app.getcensus.com/api/v1/sources/{source_id}/topics \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '{
"name": "NewAppUsers",
"sample_message": {
"name": "Jill",
"id": "1",
"email": "Jill@foo.com"
},
"description": "Users that have signed up for our product in the last week."
}'
{
"status": "created",
"data": {
"id": 18,
"name": "NewAppUsers",
"description": "Users that have signed up for our product in the last week.",
"created_at": "2021-10-20T02:43:07.120Z",
"updated_at": "2021-10-20T02:50:35.477Z",
"schema": {
"name": "string",
"id": "number",
"email": "string"
}
}
}
Authorizations
Bearer token for the current workspace. Can be retrieved from the Workspace's settings page.
Path Parameters
ID of the source
Body
application/json
Response
201
application/json
Topic created successfully
The response is of type object
.
Was this page helpful?
curl --request POST \
--url https://app.getcensus.com/api/v1/sources/{source_id}/topics \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '{
"name": "NewAppUsers",
"sample_message": {
"name": "Jill",
"id": "1",
"email": "Jill@foo.com"
},
"description": "Users that have signed up for our product in the last week."
}'
{
"status": "created",
"data": {
"id": 18,
"name": "NewAppUsers",
"description": "Users that have signed up for our product in the last week.",
"created_at": "2021-10-20T02:43:07.120Z",
"updated_at": "2021-10-20T02:50:35.477Z",
"schema": {
"name": "string",
"id": "number",
"email": "string"
}
}
}