POST ?action=update_bouquets

Updates the bouquet assignments for an existing activation. The request format differs depending on whether an editor is configured on the line.

Editor Mode

Use this format when the line has an editor configured. Bouquets are specified per category. Passing an empty array for a category activates all bouquets in that category, including any added in the future.

activation_id — integer — Required. Activation ID.

bouquets — object — Required. Keys: live, vod, series. Each value is an array of bouquet IDs, or an empty array for all.

No-Editor Mode

Use this format when the line does not have an editor configured.

activation_id — integer — Required. Activation ID.

bouquet_ids — array — Required. Flat array of bouquet IDs to assign.

Response

{
"success": true,
"data": {
"activation_id": 321,
"bouquet_ids": [101, 102],
"sync": "editor"
},
"error": null
}

The "sync" field indicates how the bouquets were applied: editor, plugin, or local.

Examples

cURL (editor mode):

curl -X POST "https://YOUR_DOMAIN/api/api.php?action=update_bouquets" \
-H "X-Panelr-API-Key: YOUR_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"activation_id": 321,
"bouquets": { "live": [101, 102], "vod": [], "series": [] }
}'

cURL (no editor):

curl -X POST "https://YOUR_DOMAIN/api/api.php?action=update_bouquets" \
-H "X-Panelr-API-Key: YOUR_API_KEY" \
-H "Content-Type: application/json" \
-d '{"activation_id": 321, "bouquet_ids": [101, 102, 103]}'