Skip to content
Start here

Destinations

DestinationsEligible

Get delivery mechanism eligibility
client.Alerting.Destinations.Eligible.Get(ctx, query) (*DestinationEligibleGetResponse, error)
GET/accounts/{account_id}/alerting/v3/destinations/eligible

DestinationsPagerduty

List PagerDuty services
client.Alerting.Destinations.Pagerduty.Get(ctx, query) (*SinglePage[Pagerduty], error)
GET/accounts/{account_id}/alerting/v3/destinations/pagerduty
Create PagerDuty integration token
client.Alerting.Destinations.Pagerduty.New(ctx, body) (*DestinationPagerdutyNewResponse, error)
POST/accounts/{account_id}/alerting/v3/destinations/pagerduty/connect
Delete PagerDuty Services
client.Alerting.Destinations.Pagerduty.Delete(ctx, body) (*DestinationPagerdutyDeleteResponse, error)
DELETE/accounts/{account_id}/alerting/v3/destinations/pagerduty
Connect PagerDuty
client.Alerting.Destinations.Pagerduty.Link(ctx, tokenID, query) (*DestinationPagerdutyLinkResponse, error)
GET/accounts/{account_id}/alerting/v3/destinations/pagerduty/connect/{token_id}
ModelsExpand Collapse
type Pagerduty struct{…}
ID stringoptional

UUID

maxLength32
Name stringoptional

The name of the pagerduty service.

DestinationsWebhooks

List webhooks
client.Alerting.Destinations.Webhooks.List(ctx, query) (*SinglePage[Webhooks], error)
GET/accounts/{account_id}/alerting/v3/destinations/webhooks
Get a webhook
client.Alerting.Destinations.Webhooks.Get(ctx, webhookID, query) (*Webhooks, error)
GET/accounts/{account_id}/alerting/v3/destinations/webhooks/{webhook_id}
Create a webhook
client.Alerting.Destinations.Webhooks.New(ctx, params) (*DestinationWebhookNewResponse, error)
POST/accounts/{account_id}/alerting/v3/destinations/webhooks
Update a webhook
client.Alerting.Destinations.Webhooks.Update(ctx, webhookID, params) (*DestinationWebhookUpdateResponse, error)
PUT/accounts/{account_id}/alerting/v3/destinations/webhooks/{webhook_id}
Delete a webhook
client.Alerting.Destinations.Webhooks.Delete(ctx, webhookID, body) (*DestinationWebhookDeleteResponse, error)
DELETE/accounts/{account_id}/alerting/v3/destinations/webhooks/{webhook_id}
ModelsExpand Collapse
type Webhooks struct{…}
ID stringoptional

The unique identifier of a webhook

maxLength32
CreatedAt Timeoptional

Timestamp of when the webhook destination was created.

formatdate-time
LastFailure Timeoptional

Timestamp of the last time an attempt to dispatch a notification to this webhook failed.

formatdate-time
LastSuccess Timeoptional

Timestamp of the last time Cloudflare was able to successfully dispatch a notification using this webhook.

formatdate-time
Name stringoptional

The name of the webhook destination. This will be included in the request body when you receive a webhook notification.

Secret stringoptional

Optional secret that will be passed in the cf-webhook-auth header when dispatching generic webhook notifications or formatted for supported destinations. Secrets are not returned in any API response body.

Type WebhooksTypeoptional

Type of webhook endpoint.

One of the following:
const WebhooksTypeDatadog WebhooksType = "datadog"
const WebhooksTypeDiscord WebhooksType = "discord"
const WebhooksTypeFeishu WebhooksType = "feishu"
const WebhooksTypeGchat WebhooksType = "gchat"
const WebhooksTypeGeneric WebhooksType = "generic"
const WebhooksTypeOpsgenie WebhooksType = "opsgenie"
const WebhooksTypeSlack WebhooksType = "slack"
const WebhooksTypeSplunk WebhooksType = "splunk"
URL stringoptional

The POST endpoint to call when dispatching a notification.