Returns all configured YouTube trigger nodes for an agent.
Each agent can have multiple YouTube trigger nodes, and each trigger node can monitor multiple channels. The GET endpoint returns all triggers configured for the agent.
Request
curl -X GET "https://api.mosaic.so/agent/[agent_id]/triggers" \
-H "Authorization: Bearer mk_your_api_key"
Response
[
{
"id": "8f7d6c5b-4a3e-2b1f-9d8c-1a2b3c4d5e6f",
"type": "youtube",
"youtube_channels": [
"UCxxxxxxxxxxxxxx",
"UCyyyyyyyyyyyyyy"
],
"youtube_channel_details": [
{
"channel_id": "UCxxxxxxxxxxxxxx",
"channel_name": "Marques Brownlee",
"channel_handle": "@mkbhd",
"thumbnail_url": "https://yt3.googleusercontent.com/...",
"subscriber_count": 19200000
},
{
"channel_id": "UCyyyyyyyyyyyyyy",
"channel_name": "Cinematic Clips",
"channel_handle": "@cinematicclips",
"thumbnail_url": null,
"subscriber_count": null
}
],
"callback_url": "https://your-app.com/webhooks/trigger"
}
]
Returns an empty array [] if no triggers are configured. Each trigger represents a trigger node with its associated YouTube channels.
youtube_channel_details includes channel_name, channel_handle, thumbnail_url, and subscriber_count. Some fields may be null if Mosaic has not yet refreshed metadata for a channel. Always fall back to youtube_channels when details are unavailable.