Destinations

Update a destination

Changed on

Update a destination's parameters

patch/v1/notifications/destinations/{destinationId}

Request

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

Path parameters

destinationId, string uuid required

ID of the destination, a UUID v7.

Request body

DestinationUpdatePayload required
type, 'http'

Destination type. This value must match the type set when the destination was created. You cannot change the destination type.

name, string nullable

Name of the destination.

url, string nullable

Full URL of the endpoint that receives notifications.

custom_headers, object nullable

Custom headers to add or change. Headers that you do not include keep their current values. Set a header to null to remove it. An empty object changes nothing.

state, 'enabled' | 'disabled'

Set to enabled to allow notifications to be sent, or disabled to pause them. Setting a destination that was automatically disabled back to enabled restarts delivery attempts.

Example request

{
  "type": "http",
  "name": "Production webhooks",
  "custom_headers": {
    "X-Environment": "staging"
  },
  "state": "enabled"
}

Response

A single destination.

Destination required
id, string required

UUID v7 identifier of the destination.

name, string required

Name of the destination.

type, 'http' required
state, 'pending_verification' | 'enabled' | 'disabled' | 'disabled_system' required

Destination status. pending_verification means the destination is waiting for verification; enabled means it can receive notifications; disabled means it is paused; disabled_system means it was disabled automatically.

url, string nullable

Endpoint URL of the destination.

url_host, string nullable

Host part of the target URL.

custom_header_names, string[] nullable

Names of the configured custom headers. Header values are not returned.

last_success_at, string date-time nullable

Time of the most recent successful notification delivery, if any.

last_failure_at, string date-time nullable

Time of the most recent failed notification delivery, if any.

last_failure_reason, string nullable

Reason for the most recent failed notification delivery, if any.

created_at, string date-time required

An ISO-8601 timestamp representation of entity creation date.

updated_at, string date-time required

An ISO-8601 timestamp representation of entity update date.

Example response

{
  "created_at": "2022-11-04T20:10:06.927Z",
  "updated_at": "2022-11-04T20:10:06.927Z"
}

Changes