Audience

Create a topic

Create a topic. The default_subscription field is set at creation and cannot be changed later. Requires the audience:write scope and is blocked for sandbox API keys.

post/audience/topics

Request

  • Base URL: https://app.lettr.com/api
  • URL: https://app.lettr.com/api/audience/topics
  • Auth: HTTP bearer

Request body

namestring required
descriptionstring nullable
default_subscription'opt_in' | 'opt_out'

Default subscription state for newly-created contacts. opt_in means the contact must subscribe themselves (not auto-attached). opt_out means the contact is subscribed by default and must opt out to leave (auto-attached on creation).

visibility'private' | 'public'

Whether the topic is visible to public subscription pages

Example request

{
  "name": "Product updates",
  "default_subscription": "opt_in",
  "visibility": "public"
}

Response

Topic created

messagestring required

Example response

{
  "message": "Topic retrieved successfully.",
  "data": {
    "name": "Product updates",
    "description": "Monthly product updates",
    "default_subscription": "opt_in",
    "visibility": "public",
    "contacts_count": 12
  }
}

Changes

No recorded changes to this operation across all 1 revision of this API.