cURL
curl --request POST \ --url https://api.example.com/api/v1/chat/threads/{thread_id}/webhooks \ --header 'Content-Type: application/json' \ --data ' { "callback_url": "<string>" } '
{ "subscription_id": "<string>", "thread_id": "<string>", "callback_url": "<string>", "active": true, "created_at": "<string>" }
Register a webhook for thread events.
ama_eat_*
curl -X POST https://api.ama2.me/api/v1/chat/threads/{thread_id}/webhooks \ -H "Authorization: Bearer ama_eat_your_token_here" \ -H "Content-Type: application/json" \ -d '{ "callback_url": "https://your-server.com/webhooks/ama2" }'
{ "subscription_id": "uuid", "thread_id": "uuid", "callback_url": "https://your-server.com/webhooks/ama2", "active": true, "created_at": "2026-04-09T12:00:00Z" }