Create an AI-generated campaign
Changed onQueues generation for a multi-post AI campaign and returns immediately with GENERATING status. Campaign posts are generated asynchronously in the background.
Request
- Base URLhttps://www.app.ocoya.com/api/_public/v1
- AuthAPI key in header X-API-Key
Query parameters
Ocoya brand ID. Get one from GET /brands.
Request body
Example request
{
"prompt": "Summer launch campaign for our ecommerce analytics dashboard.",
"goal": "launch",
"duration": 10,
"startDate": "2026-11-02",
"count": 6,
"postLength": "medium",
"channelIds": [
"clh49poxf008x8kov4ncbjty9"
],
"generateMedia": true,
"imageCount": 3,
"referenceUrls": [
"https://example.com/reference.png"
],
"referenceDesignIds": [
"design_123"
],
"studioDesignId": "design_123",
"studioDesignFields": {
"pixy-cmte3datf00f435708hleujti": "https://example.com/logo.png"
}
}Response
Campaign generation queued
Example response
{
"campaignId": "cmayxcmpn00087aps2m7hjs9z",
"status": "GENERATING",
"queued": true,
"generation": {}
}Changes
- warning
removed the request property
- warning
removed the request property
- info
added the new optional request property
- info
added the new optional request property
- info
added the new optional request property
- warning
- info
api operation id
createCampaignwas added - info
api tag
Campaignsadded - info
added the new optional request property
- info
added the new optional request property
- info
the
request property's max was increased from30.00to90.00 - info
the
request property's max was increased from30.00to90.00 - info
added the media type
application/jsonfor the response with the status - info
added the media type
application/jsonfor the response with the status - info
added the non-success response with the status
- info
added the non-success response with the status
- info
the response property
became required for the status - info
the response property
became required for the status - info
the response property
became required for the status - info
the response property
became required for the status - info
added 'propertyNames' constraint to the
response property for the status
- info