The default notification route, set by `YAGRA_WEBHOOK_URL` and `YAGRA_SMTP_*` on the core.
const url = 'https://example.com/api/v1/notification-default-route';const options = {method: 'GET', headers: {Authorization: 'Bearer <token>'}};
try { const response = await fetch(url, options); const data = await response.json(); console.log(data);} catch (error) { console.error(error);}curl --request GET \ --url https://example.com/api/v1/notification-default-route \ --header 'Authorization: Bearer <token>'It is sent every alert, whatever the routing rules say, so it is not a fallback for alerts no rule matches. The answer is the environment of the core that answers: with two cores, each reads its own, and only the leader delivers.
Authorizations
Section titled “Authorizations”Responses
Section titled “Responses”Whether the default route is configured and which kinds of channel it sends to
The env-configured default notification route (ADR-200 Inc.28): whether it exists, and which kinds of channel it is made of.
Kinds only, by design — the webhook URL, the mail server and the addresses are never returned, for the same reason a channel’s sealed config is not.
object
Whether this core has a default route at all.
The kinds of channel it sends to, in the order they are configured. Empty when not configured.
Example
{ "kinds": [ "webhook" ]}No valid bearer token
The ADR-019 envelope every failure renders as. pub(crate) and schema-bearing so the OpenAPI
document can name one error shape for every endpoint (ADR-035) instead of leaving 4xx/5xx bodies
undescribed — a client that has to guess the failure shape ends up parsing the success shape and
reading undefined.
object
object
Stable machine-readable code. Clients branch on this, never on the message.
Operator-facing sentence. Safe to display; never carries an internal error’s own text.
Examplegenerated
{ "error": { "code": "example", "message": "example" }}Role lacks ManageSystem
The ADR-019 envelope every failure renders as. pub(crate) and schema-bearing so the OpenAPI
document can name one error shape for every endpoint (ADR-035) instead of leaving 4xx/5xx bodies
undescribed — a client that has to guess the failure shape ends up parsing the success shape and
reading undefined.
object
object
Stable machine-readable code. Clients branch on this, never on the message.
Operator-facing sentence. Safe to display; never carries an internal error’s own text.
Examplegenerated
{ "error": { "code": "example", "message": "example" }}This core has no write side (skeleton mode)
The ADR-019 envelope every failure renders as. pub(crate) and schema-bearing so the OpenAPI
document can name one error shape for every endpoint (ADR-035) instead of leaving 4xx/5xx bodies
undescribed — a client that has to guess the failure shape ends up parsing the success shape and
reading undefined.
object
object
Stable machine-readable code. Clients branch on this, never on the message.
Operator-facing sentence. Safe to display; never carries an internal error’s own text.
Examplegenerated
{ "error": { "code": "example", "message": "example" }}