Get Notification Channel
GET /notification_channels/{channel_id}
GET /notification_channels/{channel_id}Interactive request editor loads with JavaScript.
Authorization
BearerAdminToken Organization-scoped admin token. Read operations require a valid token, and write operations require a token with write permission.
In: header
Path Parameters
Notification channel ID.
uuidResponse Body
application/json
application/json
application/json
application/json
curl -X GET "$AISIX_CP/notification_channels/$CHANNEL_ID" \ -H "Authorization: Bearer $AISIX_TOKEN"OK
{
"notification_channel": {
"id": "497f6eca-6276-4993-bfeb-53cbbbba6f08",
"org_id": "a40f5d1f-d889-42e9-94ea-b9b33585fc6b",
"name": "string",
"type": "webhook",
"url": "string",
"enabled": true,
"created_at": "2019-08-24T14:15:22Z",
"updated_at": "2019-08-24T14:15:22Z"
}
}Request body or parameters failed validation.
{
"error": {
"code": "string",
"message": "string"
}
}Missing or invalid bearer.
{
"error": {
"code": "UNAUTHENTICATED",
"message": "no org context"
}
}Resource not found.
{
"error": {
"code": "NOT_FOUND",
"message": "provider key not found"
}
}Complete operation details and schema variants
GET /notification_channels/{channel_id}
Get Notification Channel
Return one notification channel in the authenticated organization. The destination URL is masked in the response.
Parameters
channel_id(path, string, required): Notification channel ID.
Responses
-
200: OK -
notification_channel(object, required): An outbound alert destination. Enabled channels receive every alert raised in the organization. -
notification_channel.id(string, required): Notification channel ID. -
notification_channel.org_id(string, required): Organization that owns this channel. -
notification_channel.name(string, required): Human-readable channel name, unique per organization. -
notification_channel.type(string, required): Delivery mechanism.webhookposts alert events as JSON;slackposts a rendered text message to a Slack incoming-webhook URL. -
notification_channel.url(string, required): Masked destination URL (scheme://host/***). The full URL — which for Slack incoming webhooks IS the credential — is write-only.
This masked value may be sent straight back on update, so a read-modify-write round-trip works unchanged: it is accepted as an echo and keeps the stored URL. It never writes anything — a masked value naming a different host is rejected with 400 rather than stored, since storing it would replace the credential with the redaction. The mask carries only the scheme and host, so it does not identify one channel: a mask read from another channel on the same host is accepted here too, and likewise changes nothing.
-
notification_channel.enabled(boolean, required): Whether new alerts are delivered to this channel. -
notification_channel.created_at(string, required): Time when the channel was created. -
notification_channel.updated_at(string, required): Time when the channel was last updated. -
400: Request body or parameters failed validation. -
error(object, required): Error details. -
error.code(string, required): Machine-readable identifier. Examples:UNAUTHENTICATED,INVALID_REQUEST,MASTER_KEY_UNSET,INTERNAL. -
error.message(string, required): Human-readable explanation; safe to surface to operators. -
401: Missing or invalid bearer. Response fields (application/json): identical toGET /notification_channels/{channel_id}, response 400 above. -
404: Resource not found. Response fields (application/json): identical toGET /notification_channels/{channel_id}, response 400 above.
cURL
curl -X GET '$AISIX_CP/notification_channels/{channel_id}' -H 'Authorization: Bearer $AISIX_TOKEN'