> ## Documentation Index
> Fetch the complete documentation index at: https://docs.mailofly.com/llms.txt
> Use this file to discover all available pages before exploring further.

# Create Topic

> Create a subscription topic or category for user communication preferences.

Create an email topic (such as "Newsletter", "Product Updates", or "Security Alerts") to allow contacts to granularly manage what emails they receive.

### Body Parameters

<ParamField body="name" type="string" required>
  The name of the topic.
</ParamField>

<ParamField body="description" type="string">
  A public or internal description of what emails are sent under this topic.
</ParamField>

<ParamField body="defaultStatus" type="string" default="opt_in">
  Default subscription state for contacts: `opt_in` or `opt_out`.
</ParamField>

### Response

<ResponseField name="data" type="object">
  <ResponseField name="id" type="string">Unique identifier for the topic.</ResponseField>
  <ResponseField name="name" type="string">Topic name.</ResponseField>
  <ResponseField name="description" type="string">Topic description.</ResponseField>
  <ResponseField name="defaultStatus" type="string">Default subscription status.</ResponseField>
  <ResponseField name="createdAt" type="string">ISO 8601 timestamp.</ResponseField>
</ResponseField>

<RequestExample>
  ```bash cURL theme={null}
  curl -X POST https://api.mailofly.com/api/v1/topics \
    -H "Authorization: Bearer mf_live_your_api_key" \
    -H "Content-Type: application/json" \
    -d '{
      "name": "Product Updates",
      "description": "Weekly digests on new features and product improvements",
      "defaultStatus": "opt_in"
    }'
  ```
</RequestExample>

<ResponseExample>
  ```json 201 Created theme={null}
  {
    "data": {
      "id": "top_123",
      "name": "Product Updates",
      "description": "Weekly digests on new features and product improvements",
      "defaultStatus": "opt_in",
      "createdAt": "2026-09-11T13:40:00Z"
    }
  }
  ```
</ResponseExample>


## Related topics

- [Topics](/audience/topics.md)
- [Delete Topic](/api/topics/delete-topic.md)
- [Retrieve Topic](/api/topics/retrieve-topic.md)
- [Update Topic](/api/topics/update-topic.md)
- [List Topics](/api/topics/list-topics.md)
