Topics API
Subscription topics shown on the preference center.
5 operations. Guide: Manage contacts and consent, Let recipients unsubscribe. Requests and responses are JSON with snake_case fields; authenticate with Authorization: Bearer <api key>. The examples assume a client built as in SDKs and the command line.
Create a topic
POST /v1/topics
default_subscription is what contacts without a choice of their own receive; it is fixed at creation.
Request body
| Field | Type | Required | Description |
|---|---|---|---|
name | string | yes | 1 to 100 characters. |
description | string or null | no | At most 500 characters. |
default_subscription | one of "opt_in", "opt_out" | yes | |
public_name | string or null | no | At most 100 characters. |
Response
201 Created: Topic.
| Field | Type | Required | Description |
|---|---|---|---|
id | string | yes | A UUID. |
object | "topic" | yes | |
project_id | string | yes | A UUID. |
name | string | yes | |
description | string or null | yes | |
default_subscription | one of "opt_in", "opt_out" | yes | |
public_name | string or null | yes | |
created_at | string (date-time) | yes | An ISO 8601 timestamp with timezone, for example 2026-10-24T18:00:00.000Z. |
Errors: 400, 401, 403, 404, 409, 422, 429, 500, with the error body.
Examples
curl -X POST https://api.minket.com/v1/topics \
-H "Authorization: Bearer $MINKET_API_KEY" \
-H "Content-Type: application/json" \
-d '{"name":"Product updates","default_subscription":"opt_out","public_name":"Product updates, monthly"}'const result = await minket.topics.create({
name: "Product updates",
default_subscription: "opt_out",
public_name: "Product updates, monthly"
});minket api createTopic --body '{"name":"Product updates","default_subscription":"opt_out","public_name":"Product updates, monthly"}'from minket.api.topics import create_topic
from minket.models import CreateTopicBody
result = create_topic.sync(client=client, body=CreateTopicBody.from_dict({"name":"Product updates","default_subscription":"opt_out","public_name":"Product updates, monthly"}))var body minket.CreateTopicJSONRequestBody
res, err := client.CreateTopicWithResponse(ctx, body)List topics
GET /v1/topics
Response
200 Success: object.
| Field | Type | Required | Description |
|---|---|---|---|
object | "list" | yes | |
data | array of Topic | yes | |
data[]. | string | yes | A UUID. |
data[]. | "topic" | yes | |
data[]. | string | yes | A UUID. |
data[]. | string | yes | |
data[]. | string or null | yes | |
data[]. | one of "opt_in", "opt_out" | yes | |
data[]. | string or null | yes | |
data[]. | string (date-time) | yes | An ISO 8601 timestamp with timezone, for example 2026-10-24T18:00:00.000Z. |
has_more | boolean | yes |
Errors: 400, 401, 403, 404, 409, 422, 429, 500, with the error body.
Examples
curl https://api.minket.com/v1/topics \
-H "Authorization: Bearer $MINKET_API_KEY"const result = await minket.topics.list();minket api listTopicsfrom minket.api.topics import list_topics
result = list_topics.sync(client=client)res, err := client.ListTopicsWithResponse(ctx)Get a topic
GET /v1/topics/{id}
Parameters
| Name | In | Type | Required | Description |
|---|---|---|---|---|
id | path | string | yes | A UUID. |
Response
200 Success: Topic.
| Field | Type | Required | Description |
|---|---|---|---|
id | string | yes | A UUID. |
object | "topic" | yes | |
project_id | string | yes | A UUID. |
name | string | yes | |
description | string or null | yes | |
default_subscription | one of "opt_in", "opt_out" | yes | |
public_name | string or null | yes | |
created_at | string (date-time) | yes | An ISO 8601 timestamp with timezone, for example 2026-10-24T18:00:00.000Z. |
Errors: 400, 401, 403, 404, 409, 422, 429, 500, with the error body.
Examples
curl https://api.minket.com/v1/topics/019a2b3c-4d5e-7f60-8a9b-0c1d2e3f4a5b \
-H "Authorization: Bearer $MINKET_API_KEY"const result = await minket.topics.get("019a2b3c-4d5e-7f60-8a9b-0c1d2e3f4a5b");minket api getTopic 019a2b3c-4d5e-7f60-8a9b-0c1d2e3f4a5bfrom minket.api.topics import get_topic
result = get_topic.sync("019a2b3c-4d5e-7f60-8a9b-0c1d2e3f4a5b", client=client)res, err := client.GetTopicWithResponse(ctx, "019a2b3c-4d5e-7f60-8a9b-0c1d2e3f4a5b")Update a topic
PATCH /v1/topics/{id}
Parameters
| Name | In | Type | Required | Description |
|---|---|---|---|---|
id | path | string | yes | A UUID. |
Request body
| Field | Type | Required | Description |
|---|---|---|---|
name | string | no | 1 to 100 characters. |
description | string or null | no | At most 500 characters. |
default_subscription | one of "opt_in", "opt_out" | no | |
public_name | string or null | no | At most 100 characters. |
Response
200 Success: Topic.
| Field | Type | Required | Description |
|---|---|---|---|
id | string | yes | A UUID. |
object | "topic" | yes | |
project_id | string | yes | A UUID. |
name | string | yes | |
description | string or null | yes | |
default_subscription | one of "opt_in", "opt_out" | yes | |
public_name | string or null | yes | |
created_at | string (date-time) | yes | An ISO 8601 timestamp with timezone, for example 2026-10-24T18:00:00.000Z. |
Errors: 400, 401, 403, 404, 409, 422, 429, 500, with the error body.
Examples
curl -X PATCH https://api.minket.com/v1/topics/019a2b3c-4d5e-7f60-8a9b-0c1d2e3f4a5b \
-H "Authorization: Bearer $MINKET_API_KEY" \
-H "Content-Type: application/json" \
-d '{"description":"What changed this month."}'const result = await minket.topics.update("019a2b3c-4d5e-7f60-8a9b-0c1d2e3f4a5b", {
description: "What changed this month."
});minket api updateTopic 019a2b3c-4d5e-7f60-8a9b-0c1d2e3f4a5b --body '{"description":"What changed this month."}'from minket.api.topics import update_topic
from minket.models import UpdateTopicBody
result = update_topic.sync("019a2b3c-4d5e-7f60-8a9b-0c1d2e3f4a5b", client=client, body=UpdateTopicBody.from_dict({"description":"What changed this month."}))var body minket.UpdateTopicJSONRequestBody
res, err := client.UpdateTopicWithResponse(ctx, "019a2b3c-4d5e-7f60-8a9b-0c1d2e3f4a5b", body)Delete a topic
DELETE /v1/topics/{id}
Parameters
| Name | In | Type | Required | Description |
|---|---|---|---|---|
id | path | string | yes | A UUID. |
Response
200 Success: object.
| Field | Type | Required | Description |
|---|---|---|---|
object | "topic" | yes | |
id | string | yes | |
deleted | true | yes |
Errors: 400, 401, 403, 404, 409, 422, 429, 500, with the error body.
Examples
curl -X DELETE https://api.minket.com/v1/topics/019a2b3c-4d5e-7f60-8a9b-0c1d2e3f4a5b \
-H "Authorization: Bearer $MINKET_API_KEY"const result = await minket.topics.delete("019a2b3c-4d5e-7f60-8a9b-0c1d2e3f4a5b");minket api deleteTopic 019a2b3c-4d5e-7f60-8a9b-0c1d2e3f4a5bfrom minket.api.topics import delete_topic
result = delete_topic.sync("019a2b3c-4d5e-7f60-8a9b-0c1d2e3f4a5b", client=client)res, err := client.DeleteTopicWithResponse(ctx, "019a2b3c-4d5e-7f60-8a9b-0c1d2e3f4a5b")