Create a new webhook subscription or update an existing one (if id is provided).
cURL
curl --request POST \ --url https://api.useproxy.ai/v1/webhooks \ --header 'Authorization: Bearer <token>' \ --header 'Content-Type: application/json' \ --data ' { "id": "<string>", "url": "<string>", "events": [ "<string>" ], "enabled": true, "secret": "<string>", "metadata": {} } '
{ "id": "<string>", "url": "<string>", "events": [ "<string>" ], "enabled": true, "secret": "<string>", "createdAt": "2023-11-07T05:31:56Z", "updatedAt": "2023-11-07T05:31:56Z" }
API key authentication. Include your API key in the Authorization header as Bearer <api_key>.
Bearer <api_key>
Unique key for idempotent requests (24-hour cache)
Existing webhook ID to update
Webhook endpoint URL (required for new webhooks)
Event types to subscribe to
Custom signing secret (auto-generated if not provided)
Webhook updated
Webhook endpoint URL
Webhook signing secret