notification-channels

Replace a notification channel

Changed on

Replaces a notification channel's name, labels, and settings, and returns the result. The channel keeps its identifier and type.

  • The request carries the full channel, so an omitted labels or managed_by clears it.
  • A Slack channel keeps its stored webhook URL when the request omits slack.webhook_url. This is the only exception to full replacement, because reads never return the full URL.
  • If type differs from the stored type, the request fails with 400, and invalid_parameters names type.
  • If the organization has no notification channel with this identifier, or the identifier isn't a valid UUID, the request fails with 404. The request never creates a channel.
put/v1/ai-cost-management/notification-channels/{channelId}

Request

  • Base URL
    https://global.api.konghq.com
  • Auth
    • HTTP bearer
    • or HTTP bearer
    • or HTTP bearer
    • or HTTP bearer

Path parameters

channelId, string uuid required

The id of the notification channel.

Request body

union required
AICostEmailNotificationChannelInput required

The body of a request that creates or replaces an email channel.

OR
AICostSlackNotificationChannelReplaceInput required

The body of a request that replaces a Slack channel.

Example request

{
  "labels": {
    "env": "test"
  },
  "managed_by": {
    "owner": "terraform"
  }
}

Response

The notification channel after the replacement.

union required

A notification channel is a destination for budget alerts: a list of email addresses or a Slack incoming webhook. A budget's notification rule sends its alerts to the channels it lists, and one channel can serve many rules.

type tells the two kinds apart. An email channel carries its settings in email, and a Slack channel carries them in slack.

AICostEmailNotificationChannel required

A notification channel that emails each message to its recipients through Konnect's email service.

OR
AICostSlackNotificationChannel required

A notification channel that posts each message to a Slack incoming webhook the organization created in its own workspace.

Example response

{
  "id": "5f9fd312-a987-4628-b4c5-bb4f4fddd5f7",
  "labels": {
    "env": "test"
  },
  "managed_by": {
    "owner": "terraform"
  },
  "created_at": "2022-11-04T20:10:06.927Z",
  "updated_at": "2022-11-04T20:10:06.927Z"
}

Changes

    • info

      added the new optional request property oneOf[#/components/schemas/AICostEmailNotificationChannelInput]/managed_by

    • info

      added the new optional request property oneOf[#/components/schemas/AICostSlackNotificationChannelReplaceInput]/managed_by

    • info

      added the optional property oneOf[#/components/schemas/AICostEmailNotificationChannel]/managed_by to the response with the status

    1 more change in this revision