Parameters
audience
dictionary
name
string
RequiredDescription
Name of the audience segment.
description
string
Description
Optional description for internal reference.
audience_type
string
RequiredDescription
Audience type: `user` or `account`.
status
string
Description
Status of the audience: `draft` (default), `active`, or `inactive`.
filters
array | object
RequiredDescription
Filter definitions (flat array or nested grouped object with `AND`/`OR` logic).
POST/v1/audiences
bash
curl https://api.tradly.app/v1/audiences \
-H "Authorization: Bearer YOUR_PUBLISHABLE_OR_SECRET_KEY" \
-H "Content-Type: application/json" \
-X POST \
-d '{
"audience": {
"name": "High-Value Buyers",
"description": "Buyers with active purchase history",
"audience_type": "user",
"status": "draft",
"filters": [
{
"dimension": "user_type",
"operator": "includes",
"value": "buyer"
}
]
}
}'RESPONSE
json
{
"status": true,
"data": {
"audience": {
"id": 1
}
}
}