Carousel Templates
List and retrieve carousel templates approved on Meta. Template registration is done in the ChatYug portal — the External API is read-only for templates.
List templates
GET /api/external/templates/carousel
Auth: Authorization: Bearer ck_<api_key> (required)
Query parameters
| Field | Required | Type | Description |
|---|---|---|---|
status | No | string | Filter by review status. Default APPROVED. Also: PENDING, REJECTED. |
Response example
{
"success": true,
"templates": [
{
"templateId": 501,
"templateName": "summer_sale_carousel",
"status": "APPROVED",
"languageCode": "en_US",
"carouselConfig": { "category": "MARKETING" },
"carouselCardCount": 3,
"category": "MARKETING",
"reviewStatus": "APPROVED",
"metaTemplateId": "800000000000001",
"createdAt": "2026-06-01T10:00:00.000Z"
}
]
}Get template
GET /api/external/templates/carousel/:templateId
Auth: Authorization: Bearer ck_<api_key> (required)
Path parameters
| Field | Required | Type | Description |
|---|---|---|---|
templateId | Yes | number | Internal ChatYug template ID (positive integer) |
Response example
{
"success": true,
"template": {
"templateId": 501,
"templateName": "summer_sale_carousel",
"status": "APPROVED",
"languageCode": "en_US",
"carouselConfig": {
"category": "MARKETING",
"cards": [
{
"bodyText": "Summer collection item 1",
"buttons": [{ "type": "quick_reply", "text": "Buy" }]
}
]
},
"carouselCardCount": 3,
"bodyText": "Check out our summer sale!",
"reviewStatus": "APPROVED",
"metaTemplateId": "800000000000001",
"rejectionReason": null,
"createdAt": "2026-06-01T10:00:00.000Z"
}
}404 response when not found:
{
"success": false,
"message": "Carousel template not found",
"code": "TEMPLATE_NOT_FOUND"
}Code samples — list templates
curl -s "https://chatyug.com/api/external/templates/carousel?status=APPROVED" \ -H "Authorization: Bearer ck_your_api_key_here"
const axios = require('axios');
const { data } = await axios.get('https://chatyug.com/api/external/templates/carousel', {
params: { status: 'APPROVED' },
headers: { Authorization: 'Bearer ck_your_api_key_here' }
});import requests
requests.get('https://chatyug.com/api/external/templates/carousel', params={
'status': 'APPROVED'
}, headers={'Authorization': 'Bearer ck_your_api_key_here'})$client = new GuzzleHttp\Client();
$client->get('https://chatyug.com/api/external/templates/carousel', [
'headers' => ['Authorization' => 'Bearer ck_your_api_key_here'],
'query' => ['status' => 'APPROVED']
]);