Create a webhook endpoint
POST/v1/webhook-endpointsPortal sign-in
Registers an HTTPS URL to receive deliveries, and returns its signing secret once, in secret. The URL must use https, name a host (not an IP address) and resolve to public addresses only. Needs a plan with webhooks (403 forbidden otherwise). Your plan sets how many endpoints your account can have (entitlements.limits.webhook_endpoints on GET /v1/account): at the limit, 409 conflict. The endpoint gets events detected from now on: subscribe it to them with POST /v1/webhook-subscriptions. Each delivery is signed: Model-Atlas-Signature: t=<unix seconds>,v1=<hex HMAC-SHA256 of "<t>.<body>">.
Authorization
Portal sign-in Authorization: Bearer $MA_ACCESS_TOKEN
Sign in to the portal and send its access token. Portal sign-in isn't available yet, so you can read this endpoint but not call it.
Request body
Required, application/json.
urlstringrequiredWhere to POST deliveries: an
httpsURL naming a public host (not an IP address), with no user name, password or#fragment. Its host must resolve to public addresses only. It can’t be changed later.- Range
- up to 2048 characters
- Example
https://hooks.acme.example/model-atlas
descriptionstringA label for you, up to 200 characters, with no control characters.
- Range
- up to 200 characters
- Example
Production alerts
{ "url": "https://hooks.acme.example/model-atlas", "description": "Production alerts"}Responses
The new endpoint, with its signing secret in secret.
application/json · WebhookEndpointCreated
idstring (uuid)requiredThe endpoint’s ID. Subscriptions and deliveries refer to it as
endpoint_id.- Example
2a7f9c4d-8e1b-4f6a-93d5-c0b8e2f17a46
urlstringrequiredWhere deliveries are POSTed.
- Example
https://hooks.acme.example/model-atlas
descriptionstringrequiredYour label for it. Empty when you didn’t give one.
- Example
Production alerts
enabledbooleanrequiredWhether it gets deliveries. A disabled endpoint’s pending deliveries wait, and events detected while it’s disabled aren’t delivered.
- Example
true
disabled_reasonstringrequirednullablefailing: we disabled it after 3 days of failed deliveries.customer: you did.- Allowed
failing,customer- Example
null
failing_sincestring (date-time)requirednullableThe first failed attempt since the last success. Null when the last attempt succeeded.
- Example
null
created_atstring (date-time)requiredWhen the endpoint was created. It gets events detected after this.
- Example
2026-11-26T15:20:00Z
secretstringrequiredThe signing secret. Shown once.
- Example
whsec_Zx3c9vT1mQ8kR2pL5nW7yB4dF6hJ0sA1uE3gI5oK7qM
{ "id": "2a7f9c4d-8e1b-4f6a-93d5-c0b8e2f17a46", "url": "https://hooks.acme.example/model-atlas", "description": "Production alerts", "enabled": true, "disabled_reason": null, "failing_since": null, "created_at": "2026-11-26T15:20:00Z", "secret": "whsec_Zx3c9vT1mQ8kR2pL5nW7yB4dF6hJ0sA1uE3gI5oK7qM"}400 Bad Request, code: invalid_parameter. A parameter or the request body is invalid.
application/problem+json · Problem
typestringrequiredAlways about:blank for now. Use
code.titlestringrequiredThe HTTP status’s standard name.
statusintegerrequiredThe HTTP status code, the same as the response’s.
detailstringWhat went wrong with this request, in plain language: which parameter, which slug. Absent when there’s nothing to add (an internal error).
codestringrequiredThe error, for your code to act on. Branch on this, not on
titleordetail.- Allowed
not_found,invalid_parameter,unauthorized,forbidden,conflict,rate_limited,not_implemented,internal
401 Unauthorized. No valid portal access token. API Gateway checks it before the API runs, so this body is API Gateway’s, not a Problem.
403 Forbidden, code: forbidden. You can’t do this on this account (see the description).
application/problem+json · Problem
typestringrequiredAlways about:blank for now. Use
code.titlestringrequiredThe HTTP status’s standard name.
statusintegerrequiredThe HTTP status code, the same as the response’s.
detailstringWhat went wrong with this request, in plain language: which parameter, which slug. Absent when there’s nothing to add (an internal error).
codestringrequiredThe error, for your code to act on. Branch on this, not on
titleordetail.- Allowed
not_found,invalid_parameter,unauthorized,forbidden,conflict,rate_limited,not_implemented,internal
409 Conflict, code: conflict. It conflicts with what’s there (see the description).
application/problem+json · Problem
typestringrequiredAlways about:blank for now. Use
code.titlestringrequiredThe HTTP status’s standard name.
statusintegerrequiredThe HTTP status code, the same as the response’s.
detailstringWhat went wrong with this request, in plain language: which parameter, which slug. Absent when there’s nothing to add (an internal error).
codestringrequiredThe error, for your code to act on. Branch on this, not on
titleordetail.- Allowed
not_found,invalid_parameter,unauthorized,forbidden,conflict,rate_limited,not_implemented,internal
Over a rate limit: your account’s per-minute limit from its plan (entitlements.requests_per_minute on GET /v1/account), shared by its keys, or the API-wide throttle every caller shares. Wait Retry-After seconds, then retry with backoff.
application/problem+json · Problem
typestringrequiredAlways about:blank for now. Use
code.- Example
about:blank
titlestringrequiredThe HTTP status’s standard name.
- Example
Not Found
statusintegerrequiredThe HTTP status code, the same as the response’s.
- Example
404
detailstringWhat went wrong with this request, in plain language: which parameter, which slug. Absent when there’s nothing to add (an internal error).
- Example
No version claude-sonnet-9.
codestringrequiredThe error, for your code to act on. Branch on this, not on
titleordetail.- Allowed
not_found,invalid_parameter,unauthorized,forbidden,conflict,rate_limited,not_implemented,internal- Example
not_found
{ "type": "about:blank", "title": "Too Many Requests", "status": 429, "detail": "Your plan allows 60 requests a minute, across your account's keys. Retry after 12 s.", "code": "rate_limited"}{ "type": "about:blank", "title": "Too Many Requests", "status": 429, "detail": "The API is busy. Retry after 1 s, with backoff.", "code": "rate_limited"}