alerting

package
v2.0.0-beta.5 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Mar 13, 2024 License: Apache-2.0 Imports: 14 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type AaaHistory

type AaaHistory struct {
	// UUID
	ID string `json:"id"`
	// Message body included in the notification sent.
	AlertBody string `json:"alert_body"`
	// Type of notification that has been dispatched.
	AlertType string `json:"alert_type"`
	// Description of the notification policy (if present).
	Description string `json:"description"`
	// The mechanism to which the notification has been dispatched.
	Mechanism string `json:"mechanism"`
	// The type of mechanism to which the notification has been dispatched. This can be
	// email/pagerduty/webhook based on the mechanism configured.
	MechanismType AaaHistoryMechanismType `json:"mechanism_type"`
	// Name of the policy.
	Name string `json:"name"`
	// The unique identifier of a notification policy
	PolicyID string `json:"policy_id"`
	// Timestamp of when the notification was dispatched in ISO 8601 format.
	Sent time.Time      `json:"sent" format:"date-time"`
	JSON aaaHistoryJSON `json:"-"`
}

func (*AaaHistory) UnmarshalJSON

func (r *AaaHistory) UnmarshalJSON(data []byte) (err error)

type AaaHistoryMechanismType

type AaaHistoryMechanismType string

The type of mechanism to which the notification has been dispatched. This can be email/pagerduty/webhook based on the mechanism configured.

const (
	AaaHistoryMechanismTypeEmail     AaaHistoryMechanismType = "email"
	AaaHistoryMechanismTypePagerduty AaaHistoryMechanismType = "pagerduty"
	AaaHistoryMechanismTypeWebhook   AaaHistoryMechanismType = "webhook"
)

type AaaPagerduty

type AaaPagerduty struct {
	// UUID
	ID string `json:"id"`
	// The name of the pagerduty service.
	Name string           `json:"name"`
	JSON aaaPagerdutyJSON `json:"-"`
}

func (*AaaPagerduty) UnmarshalJSON

func (r *AaaPagerduty) UnmarshalJSON(data []byte) (err error)

type AaaPolicies

type AaaPolicies struct {
	// The unique identifier of a notification policy
	ID string `json:"id"`
	// Refers to which event will trigger a Notification dispatch. You can use the
	// endpoint to get available alert types which then will give you a list of
	// possible values.
	AlertType AaaPoliciesAlertType `json:"alert_type"`
	Created   time.Time            `json:"created" format:"date-time"`
	// Optional description for the Notification policy.
	Description string `json:"description"`
	// Whether or not the Notification policy is enabled.
	Enabled bool `json:"enabled"`
	// Optional filters that allow you to be alerted only on a subset of events for
	// that alert type based on some criteria. This is only available for select alert
	// types. See alert type documentation for more details.
	Filters AaaPoliciesFilters `json:"filters"`
	// List of IDs that will be used when dispatching a notification. IDs for email
	// type will be the email address.
	Mechanisms map[string][]AaaPoliciesMechanisms `json:"mechanisms"`
	Modified   time.Time                          `json:"modified" format:"date-time"`
	// Name of the policy.
	Name string          `json:"name"`
	JSON aaaPoliciesJSON `json:"-"`
}

func (*AaaPolicies) UnmarshalJSON

func (r *AaaPolicies) UnmarshalJSON(data []byte) (err error)

type AaaPoliciesAlertType

type AaaPoliciesAlertType string

Refers to which event will trigger a Notification dispatch. You can use the endpoint to get available alert types which then will give you a list of possible values.

const (
	AaaPoliciesAlertTypeAccessCustomCertificateExpirationType         AaaPoliciesAlertType = "access_custom_certificate_expiration_type"
	AaaPoliciesAlertTypeAdvancedDDOSAttackL4Alert                     AaaPoliciesAlertType = "advanced_ddos_attack_l4_alert"
	AaaPoliciesAlertTypeAdvancedDDOSAttackL7Alert                     AaaPoliciesAlertType = "advanced_ddos_attack_l7_alert"
	AaaPoliciesAlertTypeAdvancedHTTPAlertError                        AaaPoliciesAlertType = "advanced_http_alert_error"
	AaaPoliciesAlertTypeBGPHijackNotification                         AaaPoliciesAlertType = "bgp_hijack_notification"
	AaaPoliciesAlertTypeBillingUsageAlert                             AaaPoliciesAlertType = "billing_usage_alert"
	AaaPoliciesAlertTypeBlockNotificationBlockRemoved                 AaaPoliciesAlertType = "block_notification_block_removed"
	AaaPoliciesAlertTypeBlockNotificationNewBlock                     AaaPoliciesAlertType = "block_notification_new_block"
	AaaPoliciesAlertTypeBlockNotificationReviewRejected               AaaPoliciesAlertType = "block_notification_review_rejected"
	AaaPoliciesAlertTypeBrandProtectionAlert                          AaaPoliciesAlertType = "brand_protection_alert"
	AaaPoliciesAlertTypeBrandProtectionDigest                         AaaPoliciesAlertType = "brand_protection_digest"
	AaaPoliciesAlertTypeClickhouseAlertFwAnomaly                      AaaPoliciesAlertType = "clickhouse_alert_fw_anomaly"
	AaaPoliciesAlertTypeClickhouseAlertFwEntAnomaly                   AaaPoliciesAlertType = "clickhouse_alert_fw_ent_anomaly"
	AaaPoliciesAlertTypeCustomSSLCertificateEventType                 AaaPoliciesAlertType = "custom_ssl_certificate_event_type"
	AaaPoliciesAlertTypeDedicatedSSLCertificateEventType              AaaPoliciesAlertType = "dedicated_ssl_certificate_event_type"
	AaaPoliciesAlertTypeDosAttackL4                                   AaaPoliciesAlertType = "dos_attack_l4"
	AaaPoliciesAlertTypeDosAttackL7                                   AaaPoliciesAlertType = "dos_attack_l7"
	AaaPoliciesAlertTypeExpiringServiceTokenAlert                     AaaPoliciesAlertType = "expiring_service_token_alert"
	AaaPoliciesAlertTypeFailingLogpushJobDisabledAlert                AaaPoliciesAlertType = "failing_logpush_job_disabled_alert"
	AaaPoliciesAlertTypeFbmAutoAdvertisement                          AaaPoliciesAlertType = "fbm_auto_advertisement"
	AaaPoliciesAlertTypeFbmDosdAttack                                 AaaPoliciesAlertType = "fbm_dosd_attack"
	AaaPoliciesAlertTypeFbmVolumetricAttack                           AaaPoliciesAlertType = "fbm_volumetric_attack"
	AaaPoliciesAlertTypeHealthCheckStatusNotification                 AaaPoliciesAlertType = "health_check_status_notification"
	AaaPoliciesAlertTypeHostnameAopCustomCertificateExpirationType    AaaPoliciesAlertType = "hostname_aop_custom_certificate_expiration_type"
	AaaPoliciesAlertTypeHTTPAlertEdgeError                            AaaPoliciesAlertType = "http_alert_edge_error"
	AaaPoliciesAlertTypeHTTPAlertOriginError                          AaaPoliciesAlertType = "http_alert_origin_error"
	AaaPoliciesAlertTypeIncidentAlert                                 AaaPoliciesAlertType = "incident_alert"
	AaaPoliciesAlertTypeLoadBalancingHealthAlert                      AaaPoliciesAlertType = "load_balancing_health_alert"
	AaaPoliciesAlertTypeLoadBalancingPoolEnablementAlert              AaaPoliciesAlertType = "load_balancing_pool_enablement_alert"
	AaaPoliciesAlertTypeLogoMatchAlert                                AaaPoliciesAlertType = "logo_match_alert"
	AaaPoliciesAlertTypeMagicTunnelHealthCheckEvent                   AaaPoliciesAlertType = "magic_tunnel_health_check_event"
	AaaPoliciesAlertTypeMaintenanceEventNotification                  AaaPoliciesAlertType = "maintenance_event_notification"
	AaaPoliciesAlertTypeMTLSCertificateStoreCertificateExpirationType AaaPoliciesAlertType = "mtls_certificate_store_certificate_expiration_type"
	AaaPoliciesAlertTypePagesEventAlert                               AaaPoliciesAlertType = "pages_event_alert"
	AaaPoliciesAlertTypeRadarNotification                             AaaPoliciesAlertType = "radar_notification"
	AaaPoliciesAlertTypeRealOriginMonitoring                          AaaPoliciesAlertType = "real_origin_monitoring"
	AaaPoliciesAlertTypeScriptmonitorAlertNewCodeChangeDetections     AaaPoliciesAlertType = "scriptmonitor_alert_new_code_change_detections"
	AaaPoliciesAlertTypeScriptmonitorAlertNewHosts                    AaaPoliciesAlertType = "scriptmonitor_alert_new_hosts"
	AaaPoliciesAlertTypeScriptmonitorAlertNewMaliciousHosts           AaaPoliciesAlertType = "scriptmonitor_alert_new_malicious_hosts"
	AaaPoliciesAlertTypeScriptmonitorAlertNewMaliciousScripts         AaaPoliciesAlertType = "scriptmonitor_alert_new_malicious_scripts"
	AaaPoliciesAlertTypeScriptmonitorAlertNewMaliciousURL             AaaPoliciesAlertType = "scriptmonitor_alert_new_malicious_url"
	AaaPoliciesAlertTypeScriptmonitorAlertNewMaxLengthResourceURL     AaaPoliciesAlertType = "scriptmonitor_alert_new_max_length_resource_url"
	AaaPoliciesAlertTypeScriptmonitorAlertNewResources                AaaPoliciesAlertType = "scriptmonitor_alert_new_resources"
	AaaPoliciesAlertTypeSecondaryDNSAllPrimariesFailing               AaaPoliciesAlertType = "secondary_dns_all_primaries_failing"
	AaaPoliciesAlertTypeSecondaryDNSPrimariesFailing                  AaaPoliciesAlertType = "secondary_dns_primaries_failing"
	AaaPoliciesAlertTypeSecondaryDNSZoneSuccessfullyUpdated           AaaPoliciesAlertType = "secondary_dns_zone_successfully_updated"
	AaaPoliciesAlertTypeSecondaryDNSZoneValidationWarning             AaaPoliciesAlertType = "secondary_dns_zone_validation_warning"
	AaaPoliciesAlertTypeSentinelAlert                                 AaaPoliciesAlertType = "sentinel_alert"
	AaaPoliciesAlertTypeStreamLiveNotifications                       AaaPoliciesAlertType = "stream_live_notifications"
	AaaPoliciesAlertTypeTrafficAnomaliesAlert                         AaaPoliciesAlertType = "traffic_anomalies_alert"
	AaaPoliciesAlertTypeTunnelHealthEvent                             AaaPoliciesAlertType = "tunnel_health_event"
	AaaPoliciesAlertTypeTunnelUpdateEvent                             AaaPoliciesAlertType = "tunnel_update_event"
	AaaPoliciesAlertTypeUniversalSSLEventType                         AaaPoliciesAlertType = "universal_ssl_event_type"
	AaaPoliciesAlertTypeWebAnalyticsMetricsUpdate                     AaaPoliciesAlertType = "web_analytics_metrics_update"
	AaaPoliciesAlertTypeZoneAopCustomCertificateExpirationType        AaaPoliciesAlertType = "zone_aop_custom_certificate_expiration_type"
)

type AaaPoliciesFilters

type AaaPoliciesFilters struct {
	// Usage depends on specific alert type
	Actions []string `json:"actions"`
	// Used for configuring radar_notification
	AffectedASNs []string `json:"affected_asns"`
	// Used for configuring incident_alert. A list of identifiers for each component to
	// monitor.
	AffectedComponents []string `json:"affected_components"`
	// Used for configuring radar_notification
	AffectedLocations []string `json:"affected_locations"`
	// Used for configuring maintenance_event_notification
	AirportCode []string `json:"airport_code"`
	// Usage depends on specific alert type
	AlertTriggerPreferences []string `json:"alert_trigger_preferences"`
	// Used for configuring magic_tunnel_health_check_event
	AlertTriggerPreferencesValue []AaaPoliciesFiltersAlertTriggerPreferencesValue `json:"alert_trigger_preferences_value"`
	// Used for configuring load_balancing_pool_enablement_alert
	Enabled []string `json:"enabled"`
	// Used for configuring pages_event_alert
	Environment []string `json:"environment"`
	// Used for configuring pages_event_alert
	Event []string `json:"event"`
	// Used for configuring load_balancing_health_alert
	EventSource []string `json:"event_source"`
	// Usage depends on specific alert type
	EventType []string `json:"event_type"`
	// Usage depends on specific alert type
	GroupBy []string `json:"group_by"`
	// Used for configuring health_check_status_notification
	HealthCheckID []string `json:"health_check_id"`
	// Used for configuring incident_alert
	IncidentImpact []AaaPoliciesFiltersIncidentImpact `json:"incident_impact"`
	// Used for configuring stream_live_notifications
	InputID []string `json:"input_id"`
	// Used for configuring billing_usage_alert
	Limit []string `json:"limit"`
	// Used for configuring logo_match_alert
	LogoTag []string `json:"logo_tag"`
	// Used for configuring advanced_ddos_attack_l4_alert
	MegabitsPerSecond []string `json:"megabits_per_second"`
	// Used for configuring load_balancing_health_alert
	NewHealth []string `json:"new_health"`
	// Used for configuring tunnel_health_event
	NewStatus []string `json:"new_status"`
	// Used for configuring advanced_ddos_attack_l4_alert
	PacketsPerSecond []string `json:"packets_per_second"`
	// Usage depends on specific alert type
	PoolID []string `json:"pool_id"`
	// Used for configuring billing_usage_alert
	Product []string `json:"product"`
	// Used for configuring pages_event_alert
	ProjectID []string `json:"project_id"`
	// Used for configuring advanced_ddos_attack_l4_alert
	Protocol []string `json:"protocol"`
	// Usage depends on specific alert type
	QueryTag []string `json:"query_tag"`
	// Used for configuring advanced_ddos_attack_l7_alert
	RequestsPerSecond []string `json:"requests_per_second"`
	// Usage depends on specific alert type
	Selectors []string `json:"selectors"`
	// Used for configuring clickhouse_alert_fw_ent_anomaly
	Services []string `json:"services"`
	// Usage depends on specific alert type
	Slo []string `json:"slo"`
	// Used for configuring health_check_status_notification
	Status []string `json:"status"`
	// Used for configuring advanced_ddos_attack_l7_alert
	TargetHostname []string `json:"target_hostname"`
	// Used for configuring advanced_ddos_attack_l4_alert
	TargetIP []string `json:"target_ip"`
	// Used for configuring advanced_ddos_attack_l7_alert
	TargetZoneName []string `json:"target_zone_name"`
	// Used for configuring traffic_anomalies_alert
	TrafficExclusions []AaaPoliciesFiltersTrafficExclusion `json:"traffic_exclusions"`
	// Used for configuring tunnel_health_event
	TunnelID []string `json:"tunnel_id"`
	// Used for configuring magic_tunnel_health_check_event
	TunnelName []string `json:"tunnel_name"`
	// Usage depends on specific alert type
	Where []string `json:"where"`
	// Usage depends on specific alert type
	Zones []string               `json:"zones"`
	JSON  aaaPoliciesFiltersJSON `json:"-"`
}

Optional filters that allow you to be alerted only on a subset of events for that alert type based on some criteria. This is only available for select alert types. See alert type documentation for more details.

func (*AaaPoliciesFilters) UnmarshalJSON

func (r *AaaPoliciesFilters) UnmarshalJSON(data []byte) (err error)

type AaaPoliciesFiltersAlertTriggerPreferencesValue

type AaaPoliciesFiltersAlertTriggerPreferencesValue string
const (
	AaaPoliciesFiltersAlertTriggerPreferencesValue99_0 AaaPoliciesFiltersAlertTriggerPreferencesValue = "99.0"
	AaaPoliciesFiltersAlertTriggerPreferencesValue98_0 AaaPoliciesFiltersAlertTriggerPreferencesValue = "98.0"
	AaaPoliciesFiltersAlertTriggerPreferencesValue97_0 AaaPoliciesFiltersAlertTriggerPreferencesValue = "97.0"
)

type AaaPoliciesFiltersIncidentImpact

type AaaPoliciesFiltersIncidentImpact string
const (
	AaaPoliciesFiltersIncidentImpactIncidentImpactNone     AaaPoliciesFiltersIncidentImpact = "INCIDENT_IMPACT_NONE"
	AaaPoliciesFiltersIncidentImpactIncidentImpactMinor    AaaPoliciesFiltersIncidentImpact = "INCIDENT_IMPACT_MINOR"
	AaaPoliciesFiltersIncidentImpactIncidentImpactMajor    AaaPoliciesFiltersIncidentImpact = "INCIDENT_IMPACT_MAJOR"
	AaaPoliciesFiltersIncidentImpactIncidentImpactCritical AaaPoliciesFiltersIncidentImpact = "INCIDENT_IMPACT_CRITICAL"
)

type AaaPoliciesFiltersTrafficExclusion

type AaaPoliciesFiltersTrafficExclusion string
const (
	AaaPoliciesFiltersTrafficExclusionSecurityEvents AaaPoliciesFiltersTrafficExclusion = "security_events"
)

type AaaPoliciesMechanisms

type AaaPoliciesMechanisms struct {
	// UUID
	ID   AaaPoliciesMechanismsID   `json:"id"`
	JSON aaaPoliciesMechanismsJSON `json:"-"`
}

func (*AaaPoliciesMechanisms) UnmarshalJSON

func (r *AaaPoliciesMechanisms) UnmarshalJSON(data []byte) (err error)

type AaaPoliciesMechanismsID

type AaaPoliciesMechanismsID interface {
	ImplementsAlertingAaaPoliciesMechanismsID()
}

UUID

Union satisfied by shared.UnionString or shared.UnionString.

type AaaWebhooks

type AaaWebhooks struct {
	// The unique identifier of a webhook
	ID string `json:"id"`
	// Timestamp of when the webhook destination was created.
	CreatedAt time.Time `json:"created_at" format:"date-time"`
	// Timestamp of the last time an attempt to dispatch a notification to this webhook
	// failed.
	LastFailure time.Time `json:"last_failure" format:"date-time"`
	// Timestamp of the last time Cloudflare was able to successfully dispatch a
	// notification using this webhook.
	LastSuccess time.Time `json:"last_success" format:"date-time"`
	// The name of the webhook destination. This will be included in the request body
	// when you receive a webhook notification.
	Name string `json:"name"`
	// 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.
	Secret string `json:"secret"`
	// Type of webhook endpoint.
	Type AaaWebhooksType `json:"type"`
	// The POST endpoint to call when dispatching a notification.
	URL  string          `json:"url"`
	JSON aaaWebhooksJSON `json:"-"`
}

func (*AaaWebhooks) UnmarshalJSON

func (r *AaaWebhooks) UnmarshalJSON(data []byte) (err error)

type AaaWebhooksType

type AaaWebhooksType string

Type of webhook endpoint.

const (
	AaaWebhooksTypeSlack   AaaWebhooksType = "slack"
	AaaWebhooksTypeGeneric AaaWebhooksType = "generic"
	AaaWebhooksTypeGchat   AaaWebhooksType = "gchat"
)

type AlertingService

type AlertingService struct {
	Options []option.RequestOption
	V3      *V3Service
}

AlertingService contains methods and other services that help with interacting with the cloudflare API. Note, unlike clients, this service does not read variables from the environment automatically. You should not instantiate this service directly, and instead use the NewAlertingService method instead.

func NewAlertingService

func NewAlertingService(opts ...option.RequestOption) (r *AlertingService)

NewAlertingService generates a new service that applies the given options to each request. These options are applied after the parent client's options (if there is one), and before any request-specific options.

type Error

type Error = apierror.Error

type V3DestinationEligibleGetParams

type V3DestinationEligibleGetParams struct {
	// The account id
	AccountID param.Field[string] `path:"account_id,required"`
}

type V3DestinationEligibleGetResponse

type V3DestinationEligibleGetResponse interface {
	ImplementsAlertingV3DestinationEligibleGetResponse()
}

Union satisfied by alerting.V3DestinationEligibleGetResponseUnknown, alerting.V3DestinationEligibleGetResponseArray or shared.UnionString.

type V3DestinationEligibleGetResponseArray

type V3DestinationEligibleGetResponseArray []interface{}

func (V3DestinationEligibleGetResponseArray) ImplementsAlertingV3DestinationEligibleGetResponse

func (r V3DestinationEligibleGetResponseArray) ImplementsAlertingV3DestinationEligibleGetResponse()

type V3DestinationEligibleGetResponseEnvelope

type V3DestinationEligibleGetResponseEnvelope struct {
	Errors   []V3DestinationEligibleGetResponseEnvelopeErrors   `json:"errors,required"`
	Messages []V3DestinationEligibleGetResponseEnvelopeMessages `json:"messages,required"`
	Result   V3DestinationEligibleGetResponse                   `json:"result,required,nullable"`
	// Whether the API call was successful
	Success    V3DestinationEligibleGetResponseEnvelopeSuccess    `json:"success,required"`
	ResultInfo V3DestinationEligibleGetResponseEnvelopeResultInfo `json:"result_info"`
	JSON       v3DestinationEligibleGetResponseEnvelopeJSON       `json:"-"`
}

func (*V3DestinationEligibleGetResponseEnvelope) UnmarshalJSON

func (r *V3DestinationEligibleGetResponseEnvelope) UnmarshalJSON(data []byte) (err error)

type V3DestinationEligibleGetResponseEnvelopeErrors

type V3DestinationEligibleGetResponseEnvelopeErrors struct {
	Code    int64                                              `json:"code,required"`
	Message string                                             `json:"message,required"`
	JSON    v3DestinationEligibleGetResponseEnvelopeErrorsJSON `json:"-"`
}

func (*V3DestinationEligibleGetResponseEnvelopeErrors) UnmarshalJSON

func (r *V3DestinationEligibleGetResponseEnvelopeErrors) UnmarshalJSON(data []byte) (err error)

type V3DestinationEligibleGetResponseEnvelopeMessages

type V3DestinationEligibleGetResponseEnvelopeMessages struct {
	Code    int64                                                `json:"code,required"`
	Message string                                               `json:"message,required"`
	JSON    v3DestinationEligibleGetResponseEnvelopeMessagesJSON `json:"-"`
}

func (*V3DestinationEligibleGetResponseEnvelopeMessages) UnmarshalJSON

func (r *V3DestinationEligibleGetResponseEnvelopeMessages) UnmarshalJSON(data []byte) (err error)

type V3DestinationEligibleGetResponseEnvelopeResultInfo

type V3DestinationEligibleGetResponseEnvelopeResultInfo struct {
	// Total number of results for the requested service
	Count float64 `json:"count"`
	// Current page within paginated list of results
	Page float64 `json:"page"`
	// Number of results per page of results
	PerPage float64 `json:"per_page"`
	// Total results available without any search parameters
	TotalCount float64                                                `json:"total_count"`
	JSON       v3DestinationEligibleGetResponseEnvelopeResultInfoJSON `json:"-"`
}

func (*V3DestinationEligibleGetResponseEnvelopeResultInfo) UnmarshalJSON

func (r *V3DestinationEligibleGetResponseEnvelopeResultInfo) UnmarshalJSON(data []byte) (err error)

type V3DestinationEligibleGetResponseEnvelopeSuccess

type V3DestinationEligibleGetResponseEnvelopeSuccess bool

Whether the API call was successful

const (
	V3DestinationEligibleGetResponseEnvelopeSuccessTrue V3DestinationEligibleGetResponseEnvelopeSuccess = true
)

type V3DestinationEligibleService

type V3DestinationEligibleService struct {
	Options []option.RequestOption
}

V3DestinationEligibleService contains methods and other services that help with interacting with the cloudflare API. Note, unlike clients, this service does not read variables from the environment automatically. You should not instantiate this service directly, and instead use the NewV3DestinationEligibleService method instead.

func NewV3DestinationEligibleService

func NewV3DestinationEligibleService(opts ...option.RequestOption) (r *V3DestinationEligibleService)

NewV3DestinationEligibleService generates a new service that applies the given options to each request. These options are applied after the parent client's options (if there is one), and before any request-specific options.

func (*V3DestinationEligibleService) Get

Get a list of all delivery mechanism types for which an account is eligible.

type V3DestinationPagerdutyDeleteParams

type V3DestinationPagerdutyDeleteParams struct {
	// The account id
	AccountID param.Field[string] `path:"account_id,required"`
}

type V3DestinationPagerdutyDeleteResponse

type V3DestinationPagerdutyDeleteResponse interface {
	ImplementsAlertingV3DestinationPagerdutyDeleteResponse()
}

Union satisfied by alerting.V3DestinationPagerdutyDeleteResponseUnknown, alerting.V3DestinationPagerdutyDeleteResponseArray or shared.UnionString.

type V3DestinationPagerdutyDeleteResponseArray

type V3DestinationPagerdutyDeleteResponseArray []interface{}

func (V3DestinationPagerdutyDeleteResponseArray) ImplementsAlertingV3DestinationPagerdutyDeleteResponse

func (r V3DestinationPagerdutyDeleteResponseArray) ImplementsAlertingV3DestinationPagerdutyDeleteResponse()

type V3DestinationPagerdutyDeleteResponseEnvelope

type V3DestinationPagerdutyDeleteResponseEnvelope struct {
	Errors   []V3DestinationPagerdutyDeleteResponseEnvelopeErrors   `json:"errors,required"`
	Messages []V3DestinationPagerdutyDeleteResponseEnvelopeMessages `json:"messages,required"`
	Result   V3DestinationPagerdutyDeleteResponse                   `json:"result,required,nullable"`
	// Whether the API call was successful
	Success    V3DestinationPagerdutyDeleteResponseEnvelopeSuccess    `json:"success,required"`
	ResultInfo V3DestinationPagerdutyDeleteResponseEnvelopeResultInfo `json:"result_info"`
	JSON       v3DestinationPagerdutyDeleteResponseEnvelopeJSON       `json:"-"`
}

func (*V3DestinationPagerdutyDeleteResponseEnvelope) UnmarshalJSON

func (r *V3DestinationPagerdutyDeleteResponseEnvelope) UnmarshalJSON(data []byte) (err error)

type V3DestinationPagerdutyDeleteResponseEnvelopeErrors

type V3DestinationPagerdutyDeleteResponseEnvelopeErrors struct {
	Code    int64                                                  `json:"code,required"`
	Message string                                                 `json:"message,required"`
	JSON    v3DestinationPagerdutyDeleteResponseEnvelopeErrorsJSON `json:"-"`
}

func (*V3DestinationPagerdutyDeleteResponseEnvelopeErrors) UnmarshalJSON

func (r *V3DestinationPagerdutyDeleteResponseEnvelopeErrors) UnmarshalJSON(data []byte) (err error)

type V3DestinationPagerdutyDeleteResponseEnvelopeMessages

type V3DestinationPagerdutyDeleteResponseEnvelopeMessages struct {
	Code    int64                                                    `json:"code,required"`
	Message string                                                   `json:"message,required"`
	JSON    v3DestinationPagerdutyDeleteResponseEnvelopeMessagesJSON `json:"-"`
}

func (*V3DestinationPagerdutyDeleteResponseEnvelopeMessages) UnmarshalJSON

func (r *V3DestinationPagerdutyDeleteResponseEnvelopeMessages) UnmarshalJSON(data []byte) (err error)

type V3DestinationPagerdutyDeleteResponseEnvelopeResultInfo

type V3DestinationPagerdutyDeleteResponseEnvelopeResultInfo struct {
	// Total number of results for the requested service
	Count float64 `json:"count"`
	// Current page within paginated list of results
	Page float64 `json:"page"`
	// Number of results per page of results
	PerPage float64 `json:"per_page"`
	// Total results available without any search parameters
	TotalCount float64                                                    `json:"total_count"`
	JSON       v3DestinationPagerdutyDeleteResponseEnvelopeResultInfoJSON `json:"-"`
}

func (*V3DestinationPagerdutyDeleteResponseEnvelopeResultInfo) UnmarshalJSON

func (r *V3DestinationPagerdutyDeleteResponseEnvelopeResultInfo) UnmarshalJSON(data []byte) (err error)

type V3DestinationPagerdutyDeleteResponseEnvelopeSuccess

type V3DestinationPagerdutyDeleteResponseEnvelopeSuccess bool

Whether the API call was successful

const (
	V3DestinationPagerdutyDeleteResponseEnvelopeSuccessTrue V3DestinationPagerdutyDeleteResponseEnvelopeSuccess = true
)

type V3DestinationPagerdutyGetParams

type V3DestinationPagerdutyGetParams struct {
	// The account id
	AccountID param.Field[string] `path:"account_id,required"`
}

type V3DestinationPagerdutyGetResponseEnvelope

type V3DestinationPagerdutyGetResponseEnvelope struct {
	Errors   []V3DestinationPagerdutyGetResponseEnvelopeErrors   `json:"errors,required"`
	Messages []V3DestinationPagerdutyGetResponseEnvelopeMessages `json:"messages,required"`
	Result   []AaaPagerduty                                      `json:"result,required,nullable"`
	// Whether the API call was successful
	Success    V3DestinationPagerdutyGetResponseEnvelopeSuccess    `json:"success,required"`
	ResultInfo V3DestinationPagerdutyGetResponseEnvelopeResultInfo `json:"result_info"`
	JSON       v3DestinationPagerdutyGetResponseEnvelopeJSON       `json:"-"`
}

func (*V3DestinationPagerdutyGetResponseEnvelope) UnmarshalJSON

func (r *V3DestinationPagerdutyGetResponseEnvelope) UnmarshalJSON(data []byte) (err error)

type V3DestinationPagerdutyGetResponseEnvelopeErrors

type V3DestinationPagerdutyGetResponseEnvelopeErrors struct {
	Code    int64                                               `json:"code,required"`
	Message string                                              `json:"message,required"`
	JSON    v3DestinationPagerdutyGetResponseEnvelopeErrorsJSON `json:"-"`
}

func (*V3DestinationPagerdutyGetResponseEnvelopeErrors) UnmarshalJSON

func (r *V3DestinationPagerdutyGetResponseEnvelopeErrors) UnmarshalJSON(data []byte) (err error)

type V3DestinationPagerdutyGetResponseEnvelopeMessages

type V3DestinationPagerdutyGetResponseEnvelopeMessages struct {
	Code    int64                                                 `json:"code,required"`
	Message string                                                `json:"message,required"`
	JSON    v3DestinationPagerdutyGetResponseEnvelopeMessagesJSON `json:"-"`
}

func (*V3DestinationPagerdutyGetResponseEnvelopeMessages) UnmarshalJSON

func (r *V3DestinationPagerdutyGetResponseEnvelopeMessages) UnmarshalJSON(data []byte) (err error)

type V3DestinationPagerdutyGetResponseEnvelopeResultInfo

type V3DestinationPagerdutyGetResponseEnvelopeResultInfo struct {
	// Total number of results for the requested service
	Count float64 `json:"count"`
	// Current page within paginated list of results
	Page float64 `json:"page"`
	// Number of results per page of results
	PerPage float64 `json:"per_page"`
	// Total results available without any search parameters
	TotalCount float64                                                 `json:"total_count"`
	JSON       v3DestinationPagerdutyGetResponseEnvelopeResultInfoJSON `json:"-"`
}

func (*V3DestinationPagerdutyGetResponseEnvelopeResultInfo) UnmarshalJSON

func (r *V3DestinationPagerdutyGetResponseEnvelopeResultInfo) UnmarshalJSON(data []byte) (err error)

type V3DestinationPagerdutyGetResponseEnvelopeSuccess

type V3DestinationPagerdutyGetResponseEnvelopeSuccess bool

Whether the API call was successful

const (
	V3DestinationPagerdutyGetResponseEnvelopeSuccessTrue V3DestinationPagerdutyGetResponseEnvelopeSuccess = true
)

type V3DestinationPagerdutyLinkParams

type V3DestinationPagerdutyLinkParams struct {
	// The account id
	AccountID param.Field[string] `path:"account_id,required"`
}

type V3DestinationPagerdutyLinkResponse

type V3DestinationPagerdutyLinkResponse struct {
	// UUID
	ID   string                                 `json:"id"`
	JSON v3DestinationPagerdutyLinkResponseJSON `json:"-"`
}

func (*V3DestinationPagerdutyLinkResponse) UnmarshalJSON

func (r *V3DestinationPagerdutyLinkResponse) UnmarshalJSON(data []byte) (err error)

type V3DestinationPagerdutyLinkResponseEnvelope

type V3DestinationPagerdutyLinkResponseEnvelope struct {
	Errors   []V3DestinationPagerdutyLinkResponseEnvelopeErrors   `json:"errors,required"`
	Messages []V3DestinationPagerdutyLinkResponseEnvelopeMessages `json:"messages,required"`
	Result   V3DestinationPagerdutyLinkResponse                   `json:"result,required"`
	// Whether the API call was successful
	Success V3DestinationPagerdutyLinkResponseEnvelopeSuccess `json:"success,required"`
	JSON    v3DestinationPagerdutyLinkResponseEnvelopeJSON    `json:"-"`
}

func (*V3DestinationPagerdutyLinkResponseEnvelope) UnmarshalJSON

func (r *V3DestinationPagerdutyLinkResponseEnvelope) UnmarshalJSON(data []byte) (err error)

type V3DestinationPagerdutyLinkResponseEnvelopeErrors

type V3DestinationPagerdutyLinkResponseEnvelopeErrors struct {
	Code    int64                                                `json:"code,required"`
	Message string                                               `json:"message,required"`
	JSON    v3DestinationPagerdutyLinkResponseEnvelopeErrorsJSON `json:"-"`
}

func (*V3DestinationPagerdutyLinkResponseEnvelopeErrors) UnmarshalJSON

func (r *V3DestinationPagerdutyLinkResponseEnvelopeErrors) UnmarshalJSON(data []byte) (err error)

type V3DestinationPagerdutyLinkResponseEnvelopeMessages

type V3DestinationPagerdutyLinkResponseEnvelopeMessages struct {
	Code    int64                                                  `json:"code,required"`
	Message string                                                 `json:"message,required"`
	JSON    v3DestinationPagerdutyLinkResponseEnvelopeMessagesJSON `json:"-"`
}

func (*V3DestinationPagerdutyLinkResponseEnvelopeMessages) UnmarshalJSON

func (r *V3DestinationPagerdutyLinkResponseEnvelopeMessages) UnmarshalJSON(data []byte) (err error)

type V3DestinationPagerdutyLinkResponseEnvelopeSuccess

type V3DestinationPagerdutyLinkResponseEnvelopeSuccess bool

Whether the API call was successful

const (
	V3DestinationPagerdutyLinkResponseEnvelopeSuccessTrue V3DestinationPagerdutyLinkResponseEnvelopeSuccess = true
)

type V3DestinationPagerdutyNewParams

type V3DestinationPagerdutyNewParams struct {
	// The account id
	AccountID param.Field[string] `path:"account_id,required"`
}

type V3DestinationPagerdutyNewResponse

type V3DestinationPagerdutyNewResponse struct {
	// token in form of UUID
	ID   string                                `json:"id"`
	JSON v3DestinationPagerdutyNewResponseJSON `json:"-"`
}

func (*V3DestinationPagerdutyNewResponse) UnmarshalJSON

func (r *V3DestinationPagerdutyNewResponse) UnmarshalJSON(data []byte) (err error)

type V3DestinationPagerdutyNewResponseEnvelope

type V3DestinationPagerdutyNewResponseEnvelope struct {
	Errors   []V3DestinationPagerdutyNewResponseEnvelopeErrors   `json:"errors,required"`
	Messages []V3DestinationPagerdutyNewResponseEnvelopeMessages `json:"messages,required"`
	Result   V3DestinationPagerdutyNewResponse                   `json:"result,required"`
	// Whether the API call was successful
	Success V3DestinationPagerdutyNewResponseEnvelopeSuccess `json:"success,required"`
	JSON    v3DestinationPagerdutyNewResponseEnvelopeJSON    `json:"-"`
}

func (*V3DestinationPagerdutyNewResponseEnvelope) UnmarshalJSON

func (r *V3DestinationPagerdutyNewResponseEnvelope) UnmarshalJSON(data []byte) (err error)

type V3DestinationPagerdutyNewResponseEnvelopeErrors

type V3DestinationPagerdutyNewResponseEnvelopeErrors struct {
	Code    int64                                               `json:"code,required"`
	Message string                                              `json:"message,required"`
	JSON    v3DestinationPagerdutyNewResponseEnvelopeErrorsJSON `json:"-"`
}

func (*V3DestinationPagerdutyNewResponseEnvelopeErrors) UnmarshalJSON

func (r *V3DestinationPagerdutyNewResponseEnvelopeErrors) UnmarshalJSON(data []byte) (err error)

type V3DestinationPagerdutyNewResponseEnvelopeMessages

type V3DestinationPagerdutyNewResponseEnvelopeMessages struct {
	Code    int64                                                 `json:"code,required"`
	Message string                                                `json:"message,required"`
	JSON    v3DestinationPagerdutyNewResponseEnvelopeMessagesJSON `json:"-"`
}

func (*V3DestinationPagerdutyNewResponseEnvelopeMessages) UnmarshalJSON

func (r *V3DestinationPagerdutyNewResponseEnvelopeMessages) UnmarshalJSON(data []byte) (err error)

type V3DestinationPagerdutyNewResponseEnvelopeSuccess

type V3DestinationPagerdutyNewResponseEnvelopeSuccess bool

Whether the API call was successful

const (
	V3DestinationPagerdutyNewResponseEnvelopeSuccessTrue V3DestinationPagerdutyNewResponseEnvelopeSuccess = true
)

type V3DestinationPagerdutyService

type V3DestinationPagerdutyService struct {
	Options []option.RequestOption
}

V3DestinationPagerdutyService contains methods and other services that help with interacting with the cloudflare API. Note, unlike clients, this service does not read variables from the environment automatically. You should not instantiate this service directly, and instead use the NewV3DestinationPagerdutyService method instead.

func NewV3DestinationPagerdutyService

func NewV3DestinationPagerdutyService(opts ...option.RequestOption) (r *V3DestinationPagerdutyService)

NewV3DestinationPagerdutyService generates a new service that applies the given options to each request. These options are applied after the parent client's options (if there is one), and before any request-specific options.

func (*V3DestinationPagerdutyService) Delete

Deletes all the PagerDuty Services connected to the account.

func (*V3DestinationPagerdutyService) Get

Get a list of all configured PagerDuty services.

Links PagerDuty with the account using the integration token.

func (*V3DestinationPagerdutyService) New

Creates a new token for integrating with PagerDuty.

type V3DestinationService

type V3DestinationService struct {
	Options   []option.RequestOption
	Eligible  *V3DestinationEligibleService
	Pagerduty *V3DestinationPagerdutyService
	Webhooks  *V3DestinationWebhookService
}

V3DestinationService contains methods and other services that help with interacting with the cloudflare API. Note, unlike clients, this service does not read variables from the environment automatically. You should not instantiate this service directly, and instead use the NewV3DestinationService method instead.

func NewV3DestinationService

func NewV3DestinationService(opts ...option.RequestOption) (r *V3DestinationService)

NewV3DestinationService generates a new service that applies the given options to each request. These options are applied after the parent client's options (if there is one), and before any request-specific options.

type V3DestinationWebhookDeleteParams

type V3DestinationWebhookDeleteParams struct {
	// The account id
	AccountID param.Field[string] `path:"account_id,required"`
}

type V3DestinationWebhookDeleteResponse

type V3DestinationWebhookDeleteResponse interface {
	ImplementsAlertingV3DestinationWebhookDeleteResponse()
}

Union satisfied by alerting.V3DestinationWebhookDeleteResponseUnknown, alerting.V3DestinationWebhookDeleteResponseArray or shared.UnionString.

type V3DestinationWebhookDeleteResponseArray

type V3DestinationWebhookDeleteResponseArray []interface{}

func (V3DestinationWebhookDeleteResponseArray) ImplementsAlertingV3DestinationWebhookDeleteResponse

func (r V3DestinationWebhookDeleteResponseArray) ImplementsAlertingV3DestinationWebhookDeleteResponse()

type V3DestinationWebhookDeleteResponseEnvelope

type V3DestinationWebhookDeleteResponseEnvelope struct {
	Errors   []V3DestinationWebhookDeleteResponseEnvelopeErrors   `json:"errors,required"`
	Messages []V3DestinationWebhookDeleteResponseEnvelopeMessages `json:"messages,required"`
	Result   V3DestinationWebhookDeleteResponse                   `json:"result,required,nullable"`
	// Whether the API call was successful
	Success    V3DestinationWebhookDeleteResponseEnvelopeSuccess    `json:"success,required"`
	ResultInfo V3DestinationWebhookDeleteResponseEnvelopeResultInfo `json:"result_info"`
	JSON       v3DestinationWebhookDeleteResponseEnvelopeJSON       `json:"-"`
}

func (*V3DestinationWebhookDeleteResponseEnvelope) UnmarshalJSON

func (r *V3DestinationWebhookDeleteResponseEnvelope) UnmarshalJSON(data []byte) (err error)

type V3DestinationWebhookDeleteResponseEnvelopeErrors

type V3DestinationWebhookDeleteResponseEnvelopeErrors struct {
	Code    int64                                                `json:"code,required"`
	Message string                                               `json:"message,required"`
	JSON    v3DestinationWebhookDeleteResponseEnvelopeErrorsJSON `json:"-"`
}

func (*V3DestinationWebhookDeleteResponseEnvelopeErrors) UnmarshalJSON

func (r *V3DestinationWebhookDeleteResponseEnvelopeErrors) UnmarshalJSON(data []byte) (err error)

type V3DestinationWebhookDeleteResponseEnvelopeMessages

type V3DestinationWebhookDeleteResponseEnvelopeMessages struct {
	Code    int64                                                  `json:"code,required"`
	Message string                                                 `json:"message,required"`
	JSON    v3DestinationWebhookDeleteResponseEnvelopeMessagesJSON `json:"-"`
}

func (*V3DestinationWebhookDeleteResponseEnvelopeMessages) UnmarshalJSON

func (r *V3DestinationWebhookDeleteResponseEnvelopeMessages) UnmarshalJSON(data []byte) (err error)

type V3DestinationWebhookDeleteResponseEnvelopeResultInfo

type V3DestinationWebhookDeleteResponseEnvelopeResultInfo struct {
	// Total number of results for the requested service
	Count float64 `json:"count"`
	// Current page within paginated list of results
	Page float64 `json:"page"`
	// Number of results per page of results
	PerPage float64 `json:"per_page"`
	// Total results available without any search parameters
	TotalCount float64                                                  `json:"total_count"`
	JSON       v3DestinationWebhookDeleteResponseEnvelopeResultInfoJSON `json:"-"`
}

func (*V3DestinationWebhookDeleteResponseEnvelopeResultInfo) UnmarshalJSON

func (r *V3DestinationWebhookDeleteResponseEnvelopeResultInfo) UnmarshalJSON(data []byte) (err error)

type V3DestinationWebhookDeleteResponseEnvelopeSuccess

type V3DestinationWebhookDeleteResponseEnvelopeSuccess bool

Whether the API call was successful

const (
	V3DestinationWebhookDeleteResponseEnvelopeSuccessTrue V3DestinationWebhookDeleteResponseEnvelopeSuccess = true
)

type V3DestinationWebhookGetParams

type V3DestinationWebhookGetParams struct {
	// The account id
	AccountID param.Field[string] `path:"account_id,required"`
}

type V3DestinationWebhookGetResponseEnvelope

type V3DestinationWebhookGetResponseEnvelope struct {
	Errors   []V3DestinationWebhookGetResponseEnvelopeErrors   `json:"errors,required"`
	Messages []V3DestinationWebhookGetResponseEnvelopeMessages `json:"messages,required"`
	Result   AaaWebhooks                                       `json:"result,required"`
	// Whether the API call was successful
	Success V3DestinationWebhookGetResponseEnvelopeSuccess `json:"success,required"`
	JSON    v3DestinationWebhookGetResponseEnvelopeJSON    `json:"-"`
}

func (*V3DestinationWebhookGetResponseEnvelope) UnmarshalJSON

func (r *V3DestinationWebhookGetResponseEnvelope) UnmarshalJSON(data []byte) (err error)

type V3DestinationWebhookGetResponseEnvelopeErrors

type V3DestinationWebhookGetResponseEnvelopeErrors struct {
	Code    int64                                             `json:"code,required"`
	Message string                                            `json:"message,required"`
	JSON    v3DestinationWebhookGetResponseEnvelopeErrorsJSON `json:"-"`
}

func (*V3DestinationWebhookGetResponseEnvelopeErrors) UnmarshalJSON

func (r *V3DestinationWebhookGetResponseEnvelopeErrors) UnmarshalJSON(data []byte) (err error)

type V3DestinationWebhookGetResponseEnvelopeMessages

type V3DestinationWebhookGetResponseEnvelopeMessages struct {
	Code    int64                                               `json:"code,required"`
	Message string                                              `json:"message,required"`
	JSON    v3DestinationWebhookGetResponseEnvelopeMessagesJSON `json:"-"`
}

func (*V3DestinationWebhookGetResponseEnvelopeMessages) UnmarshalJSON

func (r *V3DestinationWebhookGetResponseEnvelopeMessages) UnmarshalJSON(data []byte) (err error)

type V3DestinationWebhookGetResponseEnvelopeSuccess

type V3DestinationWebhookGetResponseEnvelopeSuccess bool

Whether the API call was successful

const (
	V3DestinationWebhookGetResponseEnvelopeSuccessTrue V3DestinationWebhookGetResponseEnvelopeSuccess = true
)

type V3DestinationWebhookListParams

type V3DestinationWebhookListParams struct {
	// The account id
	AccountID param.Field[string] `path:"account_id,required"`
}

type V3DestinationWebhookListResponseEnvelope

type V3DestinationWebhookListResponseEnvelope struct {
	Errors   []V3DestinationWebhookListResponseEnvelopeErrors   `json:"errors,required"`
	Messages []V3DestinationWebhookListResponseEnvelopeMessages `json:"messages,required"`
	Result   []AaaWebhooks                                      `json:"result,required,nullable"`
	// Whether the API call was successful
	Success    V3DestinationWebhookListResponseEnvelopeSuccess    `json:"success,required"`
	ResultInfo V3DestinationWebhookListResponseEnvelopeResultInfo `json:"result_info"`
	JSON       v3DestinationWebhookListResponseEnvelopeJSON       `json:"-"`
}

func (*V3DestinationWebhookListResponseEnvelope) UnmarshalJSON

func (r *V3DestinationWebhookListResponseEnvelope) UnmarshalJSON(data []byte) (err error)

type V3DestinationWebhookListResponseEnvelopeErrors

type V3DestinationWebhookListResponseEnvelopeErrors struct {
	Code    int64                                              `json:"code,required"`
	Message string                                             `json:"message,required"`
	JSON    v3DestinationWebhookListResponseEnvelopeErrorsJSON `json:"-"`
}

func (*V3DestinationWebhookListResponseEnvelopeErrors) UnmarshalJSON

func (r *V3DestinationWebhookListResponseEnvelopeErrors) UnmarshalJSON(data []byte) (err error)

type V3DestinationWebhookListResponseEnvelopeMessages

type V3DestinationWebhookListResponseEnvelopeMessages struct {
	Code    int64                                                `json:"code,required"`
	Message string                                               `json:"message,required"`
	JSON    v3DestinationWebhookListResponseEnvelopeMessagesJSON `json:"-"`
}

func (*V3DestinationWebhookListResponseEnvelopeMessages) UnmarshalJSON

func (r *V3DestinationWebhookListResponseEnvelopeMessages) UnmarshalJSON(data []byte) (err error)

type V3DestinationWebhookListResponseEnvelopeResultInfo

type V3DestinationWebhookListResponseEnvelopeResultInfo struct {
	// Total number of results for the requested service
	Count float64 `json:"count"`
	// Current page within paginated list of results
	Page float64 `json:"page"`
	// Number of results per page of results
	PerPage float64 `json:"per_page"`
	// Total results available without any search parameters
	TotalCount float64                                                `json:"total_count"`
	JSON       v3DestinationWebhookListResponseEnvelopeResultInfoJSON `json:"-"`
}

func (*V3DestinationWebhookListResponseEnvelopeResultInfo) UnmarshalJSON

func (r *V3DestinationWebhookListResponseEnvelopeResultInfo) UnmarshalJSON(data []byte) (err error)

type V3DestinationWebhookListResponseEnvelopeSuccess

type V3DestinationWebhookListResponseEnvelopeSuccess bool

Whether the API call was successful

const (
	V3DestinationWebhookListResponseEnvelopeSuccessTrue V3DestinationWebhookListResponseEnvelopeSuccess = true
)

type V3DestinationWebhookNewParams

type V3DestinationWebhookNewParams struct {
	// The account id
	AccountID param.Field[string] `path:"account_id,required"`
	// The name of the webhook destination. This will be included in the request body
	// when you receive a webhook notification.
	Name param.Field[string] `json:"name,required"`
	// The POST endpoint to call when dispatching a notification.
	URL param.Field[string] `json:"url,required"`
	// 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.
	Secret param.Field[string] `json:"secret"`
}

func (V3DestinationWebhookNewParams) MarshalJSON

func (r V3DestinationWebhookNewParams) MarshalJSON() (data []byte, err error)

type V3DestinationWebhookNewResponse

type V3DestinationWebhookNewResponse struct {
	// UUID
	ID   string                              `json:"id"`
	JSON v3DestinationWebhookNewResponseJSON `json:"-"`
}

func (*V3DestinationWebhookNewResponse) UnmarshalJSON

func (r *V3DestinationWebhookNewResponse) UnmarshalJSON(data []byte) (err error)

type V3DestinationWebhookNewResponseEnvelope

type V3DestinationWebhookNewResponseEnvelope struct {
	Errors   []V3DestinationWebhookNewResponseEnvelopeErrors   `json:"errors,required"`
	Messages []V3DestinationWebhookNewResponseEnvelopeMessages `json:"messages,required"`
	Result   V3DestinationWebhookNewResponse                   `json:"result,required"`
	// Whether the API call was successful
	Success V3DestinationWebhookNewResponseEnvelopeSuccess `json:"success,required"`
	JSON    v3DestinationWebhookNewResponseEnvelopeJSON    `json:"-"`
}

func (*V3DestinationWebhookNewResponseEnvelope) UnmarshalJSON

func (r *V3DestinationWebhookNewResponseEnvelope) UnmarshalJSON(data []byte) (err error)

type V3DestinationWebhookNewResponseEnvelopeErrors

type V3DestinationWebhookNewResponseEnvelopeErrors struct {
	Code    int64                                             `json:"code,required"`
	Message string                                            `json:"message,required"`
	JSON    v3DestinationWebhookNewResponseEnvelopeErrorsJSON `json:"-"`
}

func (*V3DestinationWebhookNewResponseEnvelopeErrors) UnmarshalJSON

func (r *V3DestinationWebhookNewResponseEnvelopeErrors) UnmarshalJSON(data []byte) (err error)

type V3DestinationWebhookNewResponseEnvelopeMessages

type V3DestinationWebhookNewResponseEnvelopeMessages struct {
	Code    int64                                               `json:"code,required"`
	Message string                                              `json:"message,required"`
	JSON    v3DestinationWebhookNewResponseEnvelopeMessagesJSON `json:"-"`
}

func (*V3DestinationWebhookNewResponseEnvelopeMessages) UnmarshalJSON

func (r *V3DestinationWebhookNewResponseEnvelopeMessages) UnmarshalJSON(data []byte) (err error)

type V3DestinationWebhookNewResponseEnvelopeSuccess

type V3DestinationWebhookNewResponseEnvelopeSuccess bool

Whether the API call was successful

const (
	V3DestinationWebhookNewResponseEnvelopeSuccessTrue V3DestinationWebhookNewResponseEnvelopeSuccess = true
)

type V3DestinationWebhookService

type V3DestinationWebhookService struct {
	Options []option.RequestOption
}

V3DestinationWebhookService contains methods and other services that help with interacting with the cloudflare API. Note, unlike clients, this service does not read variables from the environment automatically. You should not instantiate this service directly, and instead use the NewV3DestinationWebhookService method instead.

func NewV3DestinationWebhookService

func NewV3DestinationWebhookService(opts ...option.RequestOption) (r *V3DestinationWebhookService)

NewV3DestinationWebhookService generates a new service that applies the given options to each request. These options are applied after the parent client's options (if there is one), and before any request-specific options.

func (*V3DestinationWebhookService) Delete

Delete a configured webhook destination.

func (*V3DestinationWebhookService) Get

Get details for a single webhooks destination.

func (*V3DestinationWebhookService) List

Gets a list of all configured webhook destinations.

func (*V3DestinationWebhookService) New

Creates a new webhook destination.

func (*V3DestinationWebhookService) Update

Update a webhook destination.

type V3DestinationWebhookUpdateParams

type V3DestinationWebhookUpdateParams struct {
	// The account id
	AccountID param.Field[string] `path:"account_id,required"`
	// The name of the webhook destination. This will be included in the request body
	// when you receive a webhook notification.
	Name param.Field[string] `json:"name,required"`
	// The POST endpoint to call when dispatching a notification.
	URL param.Field[string] `json:"url,required"`
	// 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.
	Secret param.Field[string] `json:"secret"`
}

func (V3DestinationWebhookUpdateParams) MarshalJSON

func (r V3DestinationWebhookUpdateParams) MarshalJSON() (data []byte, err error)

type V3DestinationWebhookUpdateResponse

type V3DestinationWebhookUpdateResponse struct {
	// UUID
	ID   string                                 `json:"id"`
	JSON v3DestinationWebhookUpdateResponseJSON `json:"-"`
}

func (*V3DestinationWebhookUpdateResponse) UnmarshalJSON

func (r *V3DestinationWebhookUpdateResponse) UnmarshalJSON(data []byte) (err error)

type V3DestinationWebhookUpdateResponseEnvelope

type V3DestinationWebhookUpdateResponseEnvelope struct {
	Errors   []V3DestinationWebhookUpdateResponseEnvelopeErrors   `json:"errors,required"`
	Messages []V3DestinationWebhookUpdateResponseEnvelopeMessages `json:"messages,required"`
	Result   V3DestinationWebhookUpdateResponse                   `json:"result,required"`
	// Whether the API call was successful
	Success V3DestinationWebhookUpdateResponseEnvelopeSuccess `json:"success,required"`
	JSON    v3DestinationWebhookUpdateResponseEnvelopeJSON    `json:"-"`
}

func (*V3DestinationWebhookUpdateResponseEnvelope) UnmarshalJSON

func (r *V3DestinationWebhookUpdateResponseEnvelope) UnmarshalJSON(data []byte) (err error)

type V3DestinationWebhookUpdateResponseEnvelopeErrors

type V3DestinationWebhookUpdateResponseEnvelopeErrors struct {
	Code    int64                                                `json:"code,required"`
	Message string                                               `json:"message,required"`
	JSON    v3DestinationWebhookUpdateResponseEnvelopeErrorsJSON `json:"-"`
}

func (*V3DestinationWebhookUpdateResponseEnvelopeErrors) UnmarshalJSON

func (r *V3DestinationWebhookUpdateResponseEnvelopeErrors) UnmarshalJSON(data []byte) (err error)

type V3DestinationWebhookUpdateResponseEnvelopeMessages

type V3DestinationWebhookUpdateResponseEnvelopeMessages struct {
	Code    int64                                                  `json:"code,required"`
	Message string                                                 `json:"message,required"`
	JSON    v3DestinationWebhookUpdateResponseEnvelopeMessagesJSON `json:"-"`
}

func (*V3DestinationWebhookUpdateResponseEnvelopeMessages) UnmarshalJSON

func (r *V3DestinationWebhookUpdateResponseEnvelopeMessages) UnmarshalJSON(data []byte) (err error)

type V3DestinationWebhookUpdateResponseEnvelopeSuccess

type V3DestinationWebhookUpdateResponseEnvelopeSuccess bool

Whether the API call was successful

const (
	V3DestinationWebhookUpdateResponseEnvelopeSuccessTrue V3DestinationWebhookUpdateResponseEnvelopeSuccess = true
)

type V3HistoryListParams

type V3HistoryListParams struct {
	// The account id
	AccountID param.Field[string] `path:"account_id,required"`
	// Limit the returned results to history records older than the specified date.
	// This must be a timestamp that conforms to RFC3339.
	Before param.Field[time.Time] `query:"before" format:"date-time"`
	// Page number of paginated results.
	Page param.Field[float64] `query:"page"`
	// Number of items per page.
	PerPage param.Field[float64] `query:"per_page"`
	// Limit the returned results to history records newer than the specified date.
	// This must be a timestamp that conforms to RFC3339.
	Since param.Field[time.Time] `query:"since" format:"date-time"`
}

func (V3HistoryListParams) URLQuery

func (r V3HistoryListParams) URLQuery() (v url.Values)

URLQuery serializes V3HistoryListParams's query parameters as `url.Values`.

type V3HistoryService

type V3HistoryService struct {
	Options []option.RequestOption
}

V3HistoryService contains methods and other services that help with interacting with the cloudflare API. Note, unlike clients, this service does not read variables from the environment automatically. You should not instantiate this service directly, and instead use the NewV3HistoryService method instead.

func NewV3HistoryService

func NewV3HistoryService(opts ...option.RequestOption) (r *V3HistoryService)

NewV3HistoryService generates a new service that applies the given options to each request. These options are applied after the parent client's options (if there is one), and before any request-specific options.

func (*V3HistoryService) List

Gets a list of history records for notifications sent to an account. The records are displayed for last `x` number of days based on the zone plan (free = 30, pro = 30, biz = 30, ent = 90).

func (*V3HistoryService) ListAutoPaging

Gets a list of history records for notifications sent to an account. The records are displayed for last `x` number of days based on the zone plan (free = 30, pro = 30, biz = 30, ent = 90).

type V3ListParams

type V3ListParams struct {
	// The account id
	AccountID param.Field[string] `path:"account_id,required"`
}

type V3ListResponse

type V3ListResponse interface {
	ImplementsAlertingV3ListResponse()
}

Union satisfied by alerting.V3ListResponseUnknown, alerting.V3ListResponseArray or shared.UnionString.

type V3ListResponseArray

type V3ListResponseArray []interface{}

func (V3ListResponseArray) ImplementsAlertingV3ListResponse

func (r V3ListResponseArray) ImplementsAlertingV3ListResponse()

type V3ListResponseEnvelope

type V3ListResponseEnvelope struct {
	Errors   []V3ListResponseEnvelopeErrors   `json:"errors,required"`
	Messages []V3ListResponseEnvelopeMessages `json:"messages,required"`
	Result   V3ListResponse                   `json:"result,required,nullable"`
	// Whether the API call was successful
	Success    V3ListResponseEnvelopeSuccess    `json:"success,required"`
	ResultInfo V3ListResponseEnvelopeResultInfo `json:"result_info"`
	JSON       v3ListResponseEnvelopeJSON       `json:"-"`
}

func (*V3ListResponseEnvelope) UnmarshalJSON

func (r *V3ListResponseEnvelope) UnmarshalJSON(data []byte) (err error)

type V3ListResponseEnvelopeErrors

type V3ListResponseEnvelopeErrors struct {
	Code    int64                            `json:"code,required"`
	Message string                           `json:"message,required"`
	JSON    v3ListResponseEnvelopeErrorsJSON `json:"-"`
}

func (*V3ListResponseEnvelopeErrors) UnmarshalJSON

func (r *V3ListResponseEnvelopeErrors) UnmarshalJSON(data []byte) (err error)

type V3ListResponseEnvelopeMessages

type V3ListResponseEnvelopeMessages struct {
	Code    int64                              `json:"code,required"`
	Message string                             `json:"message,required"`
	JSON    v3ListResponseEnvelopeMessagesJSON `json:"-"`
}

func (*V3ListResponseEnvelopeMessages) UnmarshalJSON

func (r *V3ListResponseEnvelopeMessages) UnmarshalJSON(data []byte) (err error)

type V3ListResponseEnvelopeResultInfo

type V3ListResponseEnvelopeResultInfo struct {
	// Total number of results for the requested service
	Count float64 `json:"count"`
	// Current page within paginated list of results
	Page float64 `json:"page"`
	// Number of results per page of results
	PerPage float64 `json:"per_page"`
	// Total results available without any search parameters
	TotalCount float64                              `json:"total_count"`
	JSON       v3ListResponseEnvelopeResultInfoJSON `json:"-"`
}

func (*V3ListResponseEnvelopeResultInfo) UnmarshalJSON

func (r *V3ListResponseEnvelopeResultInfo) UnmarshalJSON(data []byte) (err error)

type V3ListResponseEnvelopeSuccess

type V3ListResponseEnvelopeSuccess bool

Whether the API call was successful

const (
	V3ListResponseEnvelopeSuccessTrue V3ListResponseEnvelopeSuccess = true
)

type V3PolicyDeleteParams

type V3PolicyDeleteParams struct {
	// The account id
	AccountID param.Field[string] `path:"account_id,required"`
}

type V3PolicyDeleteResponse

type V3PolicyDeleteResponse interface {
	ImplementsAlertingV3PolicyDeleteResponse()
}

Union satisfied by alerting.V3PolicyDeleteResponseUnknown, alerting.V3PolicyDeleteResponseArray or shared.UnionString.

type V3PolicyDeleteResponseArray

type V3PolicyDeleteResponseArray []interface{}

func (V3PolicyDeleteResponseArray) ImplementsAlertingV3PolicyDeleteResponse

func (r V3PolicyDeleteResponseArray) ImplementsAlertingV3PolicyDeleteResponse()

type V3PolicyDeleteResponseEnvelope

type V3PolicyDeleteResponseEnvelope struct {
	Errors   []V3PolicyDeleteResponseEnvelopeErrors   `json:"errors,required"`
	Messages []V3PolicyDeleteResponseEnvelopeMessages `json:"messages,required"`
	Result   V3PolicyDeleteResponse                   `json:"result,required,nullable"`
	// Whether the API call was successful
	Success    V3PolicyDeleteResponseEnvelopeSuccess    `json:"success,required"`
	ResultInfo V3PolicyDeleteResponseEnvelopeResultInfo `json:"result_info"`
	JSON       v3PolicyDeleteResponseEnvelopeJSON       `json:"-"`
}

func (*V3PolicyDeleteResponseEnvelope) UnmarshalJSON

func (r *V3PolicyDeleteResponseEnvelope) UnmarshalJSON(data []byte) (err error)

type V3PolicyDeleteResponseEnvelopeErrors

type V3PolicyDeleteResponseEnvelopeErrors struct {
	Code    int64                                    `json:"code,required"`
	Message string                                   `json:"message,required"`
	JSON    v3PolicyDeleteResponseEnvelopeErrorsJSON `json:"-"`
}

func (*V3PolicyDeleteResponseEnvelopeErrors) UnmarshalJSON

func (r *V3PolicyDeleteResponseEnvelopeErrors) UnmarshalJSON(data []byte) (err error)

type V3PolicyDeleteResponseEnvelopeMessages

type V3PolicyDeleteResponseEnvelopeMessages struct {
	Code    int64                                      `json:"code,required"`
	Message string                                     `json:"message,required"`
	JSON    v3PolicyDeleteResponseEnvelopeMessagesJSON `json:"-"`
}

func (*V3PolicyDeleteResponseEnvelopeMessages) UnmarshalJSON

func (r *V3PolicyDeleteResponseEnvelopeMessages) UnmarshalJSON(data []byte) (err error)

type V3PolicyDeleteResponseEnvelopeResultInfo

type V3PolicyDeleteResponseEnvelopeResultInfo struct {
	// Total number of results for the requested service
	Count float64 `json:"count"`
	// Current page within paginated list of results
	Page float64 `json:"page"`
	// Number of results per page of results
	PerPage float64 `json:"per_page"`
	// Total results available without any search parameters
	TotalCount float64                                      `json:"total_count"`
	JSON       v3PolicyDeleteResponseEnvelopeResultInfoJSON `json:"-"`
}

func (*V3PolicyDeleteResponseEnvelopeResultInfo) UnmarshalJSON

func (r *V3PolicyDeleteResponseEnvelopeResultInfo) UnmarshalJSON(data []byte) (err error)

type V3PolicyDeleteResponseEnvelopeSuccess

type V3PolicyDeleteResponseEnvelopeSuccess bool

Whether the API call was successful

const (
	V3PolicyDeleteResponseEnvelopeSuccessTrue V3PolicyDeleteResponseEnvelopeSuccess = true
)

type V3PolicyGetParams

type V3PolicyGetParams struct {
	// The account id
	AccountID param.Field[string] `path:"account_id,required"`
}

type V3PolicyGetResponseEnvelope

type V3PolicyGetResponseEnvelope struct {
	Errors   []V3PolicyGetResponseEnvelopeErrors   `json:"errors,required"`
	Messages []V3PolicyGetResponseEnvelopeMessages `json:"messages,required"`
	Result   AaaPolicies                           `json:"result,required"`
	// Whether the API call was successful
	Success V3PolicyGetResponseEnvelopeSuccess `json:"success,required"`
	JSON    v3PolicyGetResponseEnvelopeJSON    `json:"-"`
}

func (*V3PolicyGetResponseEnvelope) UnmarshalJSON

func (r *V3PolicyGetResponseEnvelope) UnmarshalJSON(data []byte) (err error)

type V3PolicyGetResponseEnvelopeErrors

type V3PolicyGetResponseEnvelopeErrors struct {
	Code    int64                                 `json:"code,required"`
	Message string                                `json:"message,required"`
	JSON    v3PolicyGetResponseEnvelopeErrorsJSON `json:"-"`
}

func (*V3PolicyGetResponseEnvelopeErrors) UnmarshalJSON

func (r *V3PolicyGetResponseEnvelopeErrors) UnmarshalJSON(data []byte) (err error)

type V3PolicyGetResponseEnvelopeMessages

type V3PolicyGetResponseEnvelopeMessages struct {
	Code    int64                                   `json:"code,required"`
	Message string                                  `json:"message,required"`
	JSON    v3PolicyGetResponseEnvelopeMessagesJSON `json:"-"`
}

func (*V3PolicyGetResponseEnvelopeMessages) UnmarshalJSON

func (r *V3PolicyGetResponseEnvelopeMessages) UnmarshalJSON(data []byte) (err error)

type V3PolicyGetResponseEnvelopeSuccess

type V3PolicyGetResponseEnvelopeSuccess bool

Whether the API call was successful

const (
	V3PolicyGetResponseEnvelopeSuccessTrue V3PolicyGetResponseEnvelopeSuccess = true
)

type V3PolicyListParams

type V3PolicyListParams struct {
	// The account id
	AccountID param.Field[string] `path:"account_id,required"`
}

type V3PolicyListResponseEnvelope

type V3PolicyListResponseEnvelope struct {
	Errors   []V3PolicyListResponseEnvelopeErrors   `json:"errors,required"`
	Messages []V3PolicyListResponseEnvelopeMessages `json:"messages,required"`
	Result   []AaaPolicies                          `json:"result,required,nullable"`
	// Whether the API call was successful
	Success    V3PolicyListResponseEnvelopeSuccess    `json:"success,required"`
	ResultInfo V3PolicyListResponseEnvelopeResultInfo `json:"result_info"`
	JSON       v3PolicyListResponseEnvelopeJSON       `json:"-"`
}

func (*V3PolicyListResponseEnvelope) UnmarshalJSON

func (r *V3PolicyListResponseEnvelope) UnmarshalJSON(data []byte) (err error)

type V3PolicyListResponseEnvelopeErrors

type V3PolicyListResponseEnvelopeErrors struct {
	Code    int64                                  `json:"code,required"`
	Message string                                 `json:"message,required"`
	JSON    v3PolicyListResponseEnvelopeErrorsJSON `json:"-"`
}

func (*V3PolicyListResponseEnvelopeErrors) UnmarshalJSON

func (r *V3PolicyListResponseEnvelopeErrors) UnmarshalJSON(data []byte) (err error)

type V3PolicyListResponseEnvelopeMessages

type V3PolicyListResponseEnvelopeMessages struct {
	Code    int64                                    `json:"code,required"`
	Message string                                   `json:"message,required"`
	JSON    v3PolicyListResponseEnvelopeMessagesJSON `json:"-"`
}

func (*V3PolicyListResponseEnvelopeMessages) UnmarshalJSON

func (r *V3PolicyListResponseEnvelopeMessages) UnmarshalJSON(data []byte) (err error)

type V3PolicyListResponseEnvelopeResultInfo

type V3PolicyListResponseEnvelopeResultInfo struct {
	// Total number of results for the requested service
	Count float64 `json:"count"`
	// Current page within paginated list of results
	Page float64 `json:"page"`
	// Number of results per page of results
	PerPage float64 `json:"per_page"`
	// Total results available without any search parameters
	TotalCount float64                                    `json:"total_count"`
	JSON       v3PolicyListResponseEnvelopeResultInfoJSON `json:"-"`
}

func (*V3PolicyListResponseEnvelopeResultInfo) UnmarshalJSON

func (r *V3PolicyListResponseEnvelopeResultInfo) UnmarshalJSON(data []byte) (err error)

type V3PolicyListResponseEnvelopeSuccess

type V3PolicyListResponseEnvelopeSuccess bool

Whether the API call was successful

const (
	V3PolicyListResponseEnvelopeSuccessTrue V3PolicyListResponseEnvelopeSuccess = true
)

type V3PolicyNewParams

type V3PolicyNewParams struct {
	// The account id
	AccountID param.Field[string] `path:"account_id,required"`
	// Refers to which event will trigger a Notification dispatch. You can use the
	// endpoint to get available alert types which then will give you a list of
	// possible values.
	AlertType param.Field[V3PolicyNewParamsAlertType] `json:"alert_type,required"`
	// Whether or not the Notification policy is enabled.
	Enabled param.Field[bool] `json:"enabled,required"`
	// List of IDs that will be used when dispatching a notification. IDs for email
	// type will be the email address.
	Mechanisms param.Field[map[string][]V3PolicyNewParamsMechanisms] `json:"mechanisms,required"`
	// Name of the policy.
	Name param.Field[string] `json:"name,required"`
	// Optional description for the Notification policy.
	Description param.Field[string] `json:"description"`
	// Optional filters that allow you to be alerted only on a subset of events for
	// that alert type based on some criteria. This is only available for select alert
	// types. See alert type documentation for more details.
	Filters param.Field[V3PolicyNewParamsFilters] `json:"filters"`
}

func (V3PolicyNewParams) MarshalJSON

func (r V3PolicyNewParams) MarshalJSON() (data []byte, err error)

type V3PolicyNewParamsAlertType

type V3PolicyNewParamsAlertType string

Refers to which event will trigger a Notification dispatch. You can use the endpoint to get available alert types which then will give you a list of possible values.

const (
	V3PolicyNewParamsAlertTypeAccessCustomCertificateExpirationType         V3PolicyNewParamsAlertType = "access_custom_certificate_expiration_type"
	V3PolicyNewParamsAlertTypeAdvancedDDOSAttackL4Alert                     V3PolicyNewParamsAlertType = "advanced_ddos_attack_l4_alert"
	V3PolicyNewParamsAlertTypeAdvancedDDOSAttackL7Alert                     V3PolicyNewParamsAlertType = "advanced_ddos_attack_l7_alert"
	V3PolicyNewParamsAlertTypeAdvancedHTTPAlertError                        V3PolicyNewParamsAlertType = "advanced_http_alert_error"
	V3PolicyNewParamsAlertTypeBGPHijackNotification                         V3PolicyNewParamsAlertType = "bgp_hijack_notification"
	V3PolicyNewParamsAlertTypeBillingUsageAlert                             V3PolicyNewParamsAlertType = "billing_usage_alert"
	V3PolicyNewParamsAlertTypeBlockNotificationBlockRemoved                 V3PolicyNewParamsAlertType = "block_notification_block_removed"
	V3PolicyNewParamsAlertTypeBlockNotificationNewBlock                     V3PolicyNewParamsAlertType = "block_notification_new_block"
	V3PolicyNewParamsAlertTypeBlockNotificationReviewRejected               V3PolicyNewParamsAlertType = "block_notification_review_rejected"
	V3PolicyNewParamsAlertTypeBrandProtectionAlert                          V3PolicyNewParamsAlertType = "brand_protection_alert"
	V3PolicyNewParamsAlertTypeBrandProtectionDigest                         V3PolicyNewParamsAlertType = "brand_protection_digest"
	V3PolicyNewParamsAlertTypeClickhouseAlertFwAnomaly                      V3PolicyNewParamsAlertType = "clickhouse_alert_fw_anomaly"
	V3PolicyNewParamsAlertTypeClickhouseAlertFwEntAnomaly                   V3PolicyNewParamsAlertType = "clickhouse_alert_fw_ent_anomaly"
	V3PolicyNewParamsAlertTypeCustomSSLCertificateEventType                 V3PolicyNewParamsAlertType = "custom_ssl_certificate_event_type"
	V3PolicyNewParamsAlertTypeDedicatedSSLCertificateEventType              V3PolicyNewParamsAlertType = "dedicated_ssl_certificate_event_type"
	V3PolicyNewParamsAlertTypeDosAttackL4                                   V3PolicyNewParamsAlertType = "dos_attack_l4"
	V3PolicyNewParamsAlertTypeDosAttackL7                                   V3PolicyNewParamsAlertType = "dos_attack_l7"
	V3PolicyNewParamsAlertTypeExpiringServiceTokenAlert                     V3PolicyNewParamsAlertType = "expiring_service_token_alert"
	V3PolicyNewParamsAlertTypeFailingLogpushJobDisabledAlert                V3PolicyNewParamsAlertType = "failing_logpush_job_disabled_alert"
	V3PolicyNewParamsAlertTypeFbmAutoAdvertisement                          V3PolicyNewParamsAlertType = "fbm_auto_advertisement"
	V3PolicyNewParamsAlertTypeFbmDosdAttack                                 V3PolicyNewParamsAlertType = "fbm_dosd_attack"
	V3PolicyNewParamsAlertTypeFbmVolumetricAttack                           V3PolicyNewParamsAlertType = "fbm_volumetric_attack"
	V3PolicyNewParamsAlertTypeHealthCheckStatusNotification                 V3PolicyNewParamsAlertType = "health_check_status_notification"
	V3PolicyNewParamsAlertTypeHostnameAopCustomCertificateExpirationType    V3PolicyNewParamsAlertType = "hostname_aop_custom_certificate_expiration_type"
	V3PolicyNewParamsAlertTypeHTTPAlertEdgeError                            V3PolicyNewParamsAlertType = "http_alert_edge_error"
	V3PolicyNewParamsAlertTypeHTTPAlertOriginError                          V3PolicyNewParamsAlertType = "http_alert_origin_error"
	V3PolicyNewParamsAlertTypeIncidentAlert                                 V3PolicyNewParamsAlertType = "incident_alert"
	V3PolicyNewParamsAlertTypeLoadBalancingHealthAlert                      V3PolicyNewParamsAlertType = "load_balancing_health_alert"
	V3PolicyNewParamsAlertTypeLoadBalancingPoolEnablementAlert              V3PolicyNewParamsAlertType = "load_balancing_pool_enablement_alert"
	V3PolicyNewParamsAlertTypeLogoMatchAlert                                V3PolicyNewParamsAlertType = "logo_match_alert"
	V3PolicyNewParamsAlertTypeMagicTunnelHealthCheckEvent                   V3PolicyNewParamsAlertType = "magic_tunnel_health_check_event"
	V3PolicyNewParamsAlertTypeMaintenanceEventNotification                  V3PolicyNewParamsAlertType = "maintenance_event_notification"
	V3PolicyNewParamsAlertTypeMTLSCertificateStoreCertificateExpirationType V3PolicyNewParamsAlertType = "mtls_certificate_store_certificate_expiration_type"
	V3PolicyNewParamsAlertTypePagesEventAlert                               V3PolicyNewParamsAlertType = "pages_event_alert"
	V3PolicyNewParamsAlertTypeRadarNotification                             V3PolicyNewParamsAlertType = "radar_notification"
	V3PolicyNewParamsAlertTypeRealOriginMonitoring                          V3PolicyNewParamsAlertType = "real_origin_monitoring"
	V3PolicyNewParamsAlertTypeScriptmonitorAlertNewCodeChangeDetections     V3PolicyNewParamsAlertType = "scriptmonitor_alert_new_code_change_detections"
	V3PolicyNewParamsAlertTypeScriptmonitorAlertNewHosts                    V3PolicyNewParamsAlertType = "scriptmonitor_alert_new_hosts"
	V3PolicyNewParamsAlertTypeScriptmonitorAlertNewMaliciousHosts           V3PolicyNewParamsAlertType = "scriptmonitor_alert_new_malicious_hosts"
	V3PolicyNewParamsAlertTypeScriptmonitorAlertNewMaliciousScripts         V3PolicyNewParamsAlertType = "scriptmonitor_alert_new_malicious_scripts"
	V3PolicyNewParamsAlertTypeScriptmonitorAlertNewMaliciousURL             V3PolicyNewParamsAlertType = "scriptmonitor_alert_new_malicious_url"
	V3PolicyNewParamsAlertTypeScriptmonitorAlertNewMaxLengthResourceURL     V3PolicyNewParamsAlertType = "scriptmonitor_alert_new_max_length_resource_url"
	V3PolicyNewParamsAlertTypeScriptmonitorAlertNewResources                V3PolicyNewParamsAlertType = "scriptmonitor_alert_new_resources"
	V3PolicyNewParamsAlertTypeSecondaryDNSAllPrimariesFailing               V3PolicyNewParamsAlertType = "secondary_dns_all_primaries_failing"
	V3PolicyNewParamsAlertTypeSecondaryDNSPrimariesFailing                  V3PolicyNewParamsAlertType = "secondary_dns_primaries_failing"
	V3PolicyNewParamsAlertTypeSecondaryDNSZoneSuccessfullyUpdated           V3PolicyNewParamsAlertType = "secondary_dns_zone_successfully_updated"
	V3PolicyNewParamsAlertTypeSecondaryDNSZoneValidationWarning             V3PolicyNewParamsAlertType = "secondary_dns_zone_validation_warning"
	V3PolicyNewParamsAlertTypeSentinelAlert                                 V3PolicyNewParamsAlertType = "sentinel_alert"
	V3PolicyNewParamsAlertTypeStreamLiveNotifications                       V3PolicyNewParamsAlertType = "stream_live_notifications"
	V3PolicyNewParamsAlertTypeTrafficAnomaliesAlert                         V3PolicyNewParamsAlertType = "traffic_anomalies_alert"
	V3PolicyNewParamsAlertTypeTunnelHealthEvent                             V3PolicyNewParamsAlertType = "tunnel_health_event"
	V3PolicyNewParamsAlertTypeTunnelUpdateEvent                             V3PolicyNewParamsAlertType = "tunnel_update_event"
	V3PolicyNewParamsAlertTypeUniversalSSLEventType                         V3PolicyNewParamsAlertType = "universal_ssl_event_type"
	V3PolicyNewParamsAlertTypeWebAnalyticsMetricsUpdate                     V3PolicyNewParamsAlertType = "web_analytics_metrics_update"
	V3PolicyNewParamsAlertTypeZoneAopCustomCertificateExpirationType        V3PolicyNewParamsAlertType = "zone_aop_custom_certificate_expiration_type"
)

type V3PolicyNewParamsFilters

type V3PolicyNewParamsFilters struct {
	// Usage depends on specific alert type
	Actions param.Field[[]string] `json:"actions"`
	// Used for configuring radar_notification
	AffectedASNs param.Field[[]string] `json:"affected_asns"`
	// Used for configuring incident_alert. A list of identifiers for each component to
	// monitor.
	AffectedComponents param.Field[[]string] `json:"affected_components"`
	// Used for configuring radar_notification
	AffectedLocations param.Field[[]string] `json:"affected_locations"`
	// Used for configuring maintenance_event_notification
	AirportCode param.Field[[]string] `json:"airport_code"`
	// Usage depends on specific alert type
	AlertTriggerPreferences param.Field[[]string] `json:"alert_trigger_preferences"`
	// Used for configuring magic_tunnel_health_check_event
	AlertTriggerPreferencesValue param.Field[[]V3PolicyNewParamsFiltersAlertTriggerPreferencesValue] `json:"alert_trigger_preferences_value"`
	// Used for configuring load_balancing_pool_enablement_alert
	Enabled param.Field[[]string] `json:"enabled"`
	// Used for configuring pages_event_alert
	Environment param.Field[[]string] `json:"environment"`
	// Used for configuring pages_event_alert
	Event param.Field[[]string] `json:"event"`
	// Used for configuring load_balancing_health_alert
	EventSource param.Field[[]string] `json:"event_source"`
	// Usage depends on specific alert type
	EventType param.Field[[]string] `json:"event_type"`
	// Usage depends on specific alert type
	GroupBy param.Field[[]string] `json:"group_by"`
	// Used for configuring health_check_status_notification
	HealthCheckID param.Field[[]string] `json:"health_check_id"`
	// Used for configuring incident_alert
	IncidentImpact param.Field[[]V3PolicyNewParamsFiltersIncidentImpact] `json:"incident_impact"`
	// Used for configuring stream_live_notifications
	InputID param.Field[[]string] `json:"input_id"`
	// Used for configuring billing_usage_alert
	Limit param.Field[[]string] `json:"limit"`
	// Used for configuring logo_match_alert
	LogoTag param.Field[[]string] `json:"logo_tag"`
	// Used for configuring advanced_ddos_attack_l4_alert
	MegabitsPerSecond param.Field[[]string] `json:"megabits_per_second"`
	// Used for configuring load_balancing_health_alert
	NewHealth param.Field[[]string] `json:"new_health"`
	// Used for configuring tunnel_health_event
	NewStatus param.Field[[]string] `json:"new_status"`
	// Used for configuring advanced_ddos_attack_l4_alert
	PacketsPerSecond param.Field[[]string] `json:"packets_per_second"`
	// Usage depends on specific alert type
	PoolID param.Field[[]string] `json:"pool_id"`
	// Used for configuring billing_usage_alert
	Product param.Field[[]string] `json:"product"`
	// Used for configuring pages_event_alert
	ProjectID param.Field[[]string] `json:"project_id"`
	// Used for configuring advanced_ddos_attack_l4_alert
	Protocol param.Field[[]string] `json:"protocol"`
	// Usage depends on specific alert type
	QueryTag param.Field[[]string] `json:"query_tag"`
	// Used for configuring advanced_ddos_attack_l7_alert
	RequestsPerSecond param.Field[[]string] `json:"requests_per_second"`
	// Usage depends on specific alert type
	Selectors param.Field[[]string] `json:"selectors"`
	// Used for configuring clickhouse_alert_fw_ent_anomaly
	Services param.Field[[]string] `json:"services"`
	// Usage depends on specific alert type
	Slo param.Field[[]string] `json:"slo"`
	// Used for configuring health_check_status_notification
	Status param.Field[[]string] `json:"status"`
	// Used for configuring advanced_ddos_attack_l7_alert
	TargetHostname param.Field[[]string] `json:"target_hostname"`
	// Used for configuring advanced_ddos_attack_l4_alert
	TargetIP param.Field[[]string] `json:"target_ip"`
	// Used for configuring advanced_ddos_attack_l7_alert
	TargetZoneName param.Field[[]string] `json:"target_zone_name"`
	// Used for configuring traffic_anomalies_alert
	TrafficExclusions param.Field[[]V3PolicyNewParamsFiltersTrafficExclusion] `json:"traffic_exclusions"`
	// Used for configuring tunnel_health_event
	TunnelID param.Field[[]string] `json:"tunnel_id"`
	// Used for configuring magic_tunnel_health_check_event
	TunnelName param.Field[[]string] `json:"tunnel_name"`
	// Usage depends on specific alert type
	Where param.Field[[]string] `json:"where"`
	// Usage depends on specific alert type
	Zones param.Field[[]string] `json:"zones"`
}

Optional filters that allow you to be alerted only on a subset of events for that alert type based on some criteria. This is only available for select alert types. See alert type documentation for more details.

func (V3PolicyNewParamsFilters) MarshalJSON

func (r V3PolicyNewParamsFilters) MarshalJSON() (data []byte, err error)

type V3PolicyNewParamsFiltersAlertTriggerPreferencesValue

type V3PolicyNewParamsFiltersAlertTriggerPreferencesValue string
const (
	V3PolicyNewParamsFiltersAlertTriggerPreferencesValue99_0 V3PolicyNewParamsFiltersAlertTriggerPreferencesValue = "99.0"
	V3PolicyNewParamsFiltersAlertTriggerPreferencesValue98_0 V3PolicyNewParamsFiltersAlertTriggerPreferencesValue = "98.0"
	V3PolicyNewParamsFiltersAlertTriggerPreferencesValue97_0 V3PolicyNewParamsFiltersAlertTriggerPreferencesValue = "97.0"
)

type V3PolicyNewParamsFiltersIncidentImpact

type V3PolicyNewParamsFiltersIncidentImpact string
const (
	V3PolicyNewParamsFiltersIncidentImpactIncidentImpactNone     V3PolicyNewParamsFiltersIncidentImpact = "INCIDENT_IMPACT_NONE"
	V3PolicyNewParamsFiltersIncidentImpactIncidentImpactMinor    V3PolicyNewParamsFiltersIncidentImpact = "INCIDENT_IMPACT_MINOR"
	V3PolicyNewParamsFiltersIncidentImpactIncidentImpactMajor    V3PolicyNewParamsFiltersIncidentImpact = "INCIDENT_IMPACT_MAJOR"
	V3PolicyNewParamsFiltersIncidentImpactIncidentImpactCritical V3PolicyNewParamsFiltersIncidentImpact = "INCIDENT_IMPACT_CRITICAL"
)

type V3PolicyNewParamsFiltersTrafficExclusion

type V3PolicyNewParamsFiltersTrafficExclusion string
const (
	V3PolicyNewParamsFiltersTrafficExclusionSecurityEvents V3PolicyNewParamsFiltersTrafficExclusion = "security_events"
)

type V3PolicyNewParamsMechanisms

type V3PolicyNewParamsMechanisms struct {
	// UUID
	ID param.Field[V3PolicyNewParamsMechanismsID] `json:"id"`
}

func (V3PolicyNewParamsMechanisms) MarshalJSON

func (r V3PolicyNewParamsMechanisms) MarshalJSON() (data []byte, err error)

type V3PolicyNewParamsMechanismsID

type V3PolicyNewParamsMechanismsID interface {
	ImplementsAlertingV3PolicyNewParamsMechanismsID()
}

UUID

Satisfied by shared.UnionString, shared.UnionString.

type V3PolicyNewResponse

type V3PolicyNewResponse struct {
	// UUID
	ID   string                  `json:"id"`
	JSON v3PolicyNewResponseJSON `json:"-"`
}

func (*V3PolicyNewResponse) UnmarshalJSON

func (r *V3PolicyNewResponse) UnmarshalJSON(data []byte) (err error)

type V3PolicyNewResponseEnvelope

type V3PolicyNewResponseEnvelope struct {
	Errors   []V3PolicyNewResponseEnvelopeErrors   `json:"errors,required"`
	Messages []V3PolicyNewResponseEnvelopeMessages `json:"messages,required"`
	Result   V3PolicyNewResponse                   `json:"result,required"`
	// Whether the API call was successful
	Success V3PolicyNewResponseEnvelopeSuccess `json:"success,required"`
	JSON    v3PolicyNewResponseEnvelopeJSON    `json:"-"`
}

func (*V3PolicyNewResponseEnvelope) UnmarshalJSON

func (r *V3PolicyNewResponseEnvelope) UnmarshalJSON(data []byte) (err error)

type V3PolicyNewResponseEnvelopeErrors

type V3PolicyNewResponseEnvelopeErrors struct {
	Code    int64                                 `json:"code,required"`
	Message string                                `json:"message,required"`
	JSON    v3PolicyNewResponseEnvelopeErrorsJSON `json:"-"`
}

func (*V3PolicyNewResponseEnvelopeErrors) UnmarshalJSON

func (r *V3PolicyNewResponseEnvelopeErrors) UnmarshalJSON(data []byte) (err error)

type V3PolicyNewResponseEnvelopeMessages

type V3PolicyNewResponseEnvelopeMessages struct {
	Code    int64                                   `json:"code,required"`
	Message string                                  `json:"message,required"`
	JSON    v3PolicyNewResponseEnvelopeMessagesJSON `json:"-"`
}

func (*V3PolicyNewResponseEnvelopeMessages) UnmarshalJSON

func (r *V3PolicyNewResponseEnvelopeMessages) UnmarshalJSON(data []byte) (err error)

type V3PolicyNewResponseEnvelopeSuccess

type V3PolicyNewResponseEnvelopeSuccess bool

Whether the API call was successful

const (
	V3PolicyNewResponseEnvelopeSuccessTrue V3PolicyNewResponseEnvelopeSuccess = true
)

type V3PolicyService

type V3PolicyService struct {
	Options []option.RequestOption
}

V3PolicyService contains methods and other services that help with interacting with the cloudflare API. Note, unlike clients, this service does not read variables from the environment automatically. You should not instantiate this service directly, and instead use the NewV3PolicyService method instead.

func NewV3PolicyService

func NewV3PolicyService(opts ...option.RequestOption) (r *V3PolicyService)

NewV3PolicyService generates a new service that applies the given options to each request. These options are applied after the parent client's options (if there is one), and before any request-specific options.

func (*V3PolicyService) Delete

func (r *V3PolicyService) Delete(ctx context.Context, policyID string, body V3PolicyDeleteParams, opts ...option.RequestOption) (res *V3PolicyDeleteResponse, err error)

Delete a Notification policy.

func (*V3PolicyService) Get

func (r *V3PolicyService) Get(ctx context.Context, policyID string, query V3PolicyGetParams, opts ...option.RequestOption) (res *AaaPolicies, err error)

Get details for a single policy.

func (*V3PolicyService) List

func (r *V3PolicyService) List(ctx context.Context, query V3PolicyListParams, opts ...option.RequestOption) (res *[]AaaPolicies, err error)

Get a list of all Notification policies.

func (*V3PolicyService) New

Creates a new Notification policy.

func (*V3PolicyService) Update

func (r *V3PolicyService) Update(ctx context.Context, policyID string, params V3PolicyUpdateParams, opts ...option.RequestOption) (res *V3PolicyUpdateResponse, err error)

Update a Notification policy.

type V3PolicyUpdateParams

type V3PolicyUpdateParams struct {
	// The account id
	AccountID param.Field[string] `path:"account_id,required"`
	// Refers to which event will trigger a Notification dispatch. You can use the
	// endpoint to get available alert types which then will give you a list of
	// possible values.
	AlertType param.Field[V3PolicyUpdateParamsAlertType] `json:"alert_type"`
	// Optional description for the Notification policy.
	Description param.Field[string] `json:"description"`
	// Whether or not the Notification policy is enabled.
	Enabled param.Field[bool] `json:"enabled"`
	// Optional filters that allow you to be alerted only on a subset of events for
	// that alert type based on some criteria. This is only available for select alert
	// types. See alert type documentation for more details.
	Filters param.Field[V3PolicyUpdateParamsFilters] `json:"filters"`
	// List of IDs that will be used when dispatching a notification. IDs for email
	// type will be the email address.
	Mechanisms param.Field[map[string][]V3PolicyUpdateParamsMechanisms] `json:"mechanisms"`
	// Name of the policy.
	Name param.Field[string] `json:"name"`
}

func (V3PolicyUpdateParams) MarshalJSON

func (r V3PolicyUpdateParams) MarshalJSON() (data []byte, err error)

type V3PolicyUpdateParamsAlertType

type V3PolicyUpdateParamsAlertType string

Refers to which event will trigger a Notification dispatch. You can use the endpoint to get available alert types which then will give you a list of possible values.

const (
	V3PolicyUpdateParamsAlertTypeAccessCustomCertificateExpirationType         V3PolicyUpdateParamsAlertType = "access_custom_certificate_expiration_type"
	V3PolicyUpdateParamsAlertTypeAdvancedDDOSAttackL4Alert                     V3PolicyUpdateParamsAlertType = "advanced_ddos_attack_l4_alert"
	V3PolicyUpdateParamsAlertTypeAdvancedDDOSAttackL7Alert                     V3PolicyUpdateParamsAlertType = "advanced_ddos_attack_l7_alert"
	V3PolicyUpdateParamsAlertTypeAdvancedHTTPAlertError                        V3PolicyUpdateParamsAlertType = "advanced_http_alert_error"
	V3PolicyUpdateParamsAlertTypeBGPHijackNotification                         V3PolicyUpdateParamsAlertType = "bgp_hijack_notification"
	V3PolicyUpdateParamsAlertTypeBillingUsageAlert                             V3PolicyUpdateParamsAlertType = "billing_usage_alert"
	V3PolicyUpdateParamsAlertTypeBlockNotificationBlockRemoved                 V3PolicyUpdateParamsAlertType = "block_notification_block_removed"
	V3PolicyUpdateParamsAlertTypeBlockNotificationNewBlock                     V3PolicyUpdateParamsAlertType = "block_notification_new_block"
	V3PolicyUpdateParamsAlertTypeBlockNotificationReviewRejected               V3PolicyUpdateParamsAlertType = "block_notification_review_rejected"
	V3PolicyUpdateParamsAlertTypeBrandProtectionAlert                          V3PolicyUpdateParamsAlertType = "brand_protection_alert"
	V3PolicyUpdateParamsAlertTypeBrandProtectionDigest                         V3PolicyUpdateParamsAlertType = "brand_protection_digest"
	V3PolicyUpdateParamsAlertTypeClickhouseAlertFwAnomaly                      V3PolicyUpdateParamsAlertType = "clickhouse_alert_fw_anomaly"
	V3PolicyUpdateParamsAlertTypeClickhouseAlertFwEntAnomaly                   V3PolicyUpdateParamsAlertType = "clickhouse_alert_fw_ent_anomaly"
	V3PolicyUpdateParamsAlertTypeCustomSSLCertificateEventType                 V3PolicyUpdateParamsAlertType = "custom_ssl_certificate_event_type"
	V3PolicyUpdateParamsAlertTypeDedicatedSSLCertificateEventType              V3PolicyUpdateParamsAlertType = "dedicated_ssl_certificate_event_type"
	V3PolicyUpdateParamsAlertTypeDosAttackL4                                   V3PolicyUpdateParamsAlertType = "dos_attack_l4"
	V3PolicyUpdateParamsAlertTypeDosAttackL7                                   V3PolicyUpdateParamsAlertType = "dos_attack_l7"
	V3PolicyUpdateParamsAlertTypeExpiringServiceTokenAlert                     V3PolicyUpdateParamsAlertType = "expiring_service_token_alert"
	V3PolicyUpdateParamsAlertTypeFailingLogpushJobDisabledAlert                V3PolicyUpdateParamsAlertType = "failing_logpush_job_disabled_alert"
	V3PolicyUpdateParamsAlertTypeFbmAutoAdvertisement                          V3PolicyUpdateParamsAlertType = "fbm_auto_advertisement"
	V3PolicyUpdateParamsAlertTypeFbmDosdAttack                                 V3PolicyUpdateParamsAlertType = "fbm_dosd_attack"
	V3PolicyUpdateParamsAlertTypeFbmVolumetricAttack                           V3PolicyUpdateParamsAlertType = "fbm_volumetric_attack"
	V3PolicyUpdateParamsAlertTypeHealthCheckStatusNotification                 V3PolicyUpdateParamsAlertType = "health_check_status_notification"
	V3PolicyUpdateParamsAlertTypeHostnameAopCustomCertificateExpirationType    V3PolicyUpdateParamsAlertType = "hostname_aop_custom_certificate_expiration_type"
	V3PolicyUpdateParamsAlertTypeHTTPAlertEdgeError                            V3PolicyUpdateParamsAlertType = "http_alert_edge_error"
	V3PolicyUpdateParamsAlertTypeHTTPAlertOriginError                          V3PolicyUpdateParamsAlertType = "http_alert_origin_error"
	V3PolicyUpdateParamsAlertTypeIncidentAlert                                 V3PolicyUpdateParamsAlertType = "incident_alert"
	V3PolicyUpdateParamsAlertTypeLoadBalancingHealthAlert                      V3PolicyUpdateParamsAlertType = "load_balancing_health_alert"
	V3PolicyUpdateParamsAlertTypeLoadBalancingPoolEnablementAlert              V3PolicyUpdateParamsAlertType = "load_balancing_pool_enablement_alert"
	V3PolicyUpdateParamsAlertTypeLogoMatchAlert                                V3PolicyUpdateParamsAlertType = "logo_match_alert"
	V3PolicyUpdateParamsAlertTypeMagicTunnelHealthCheckEvent                   V3PolicyUpdateParamsAlertType = "magic_tunnel_health_check_event"
	V3PolicyUpdateParamsAlertTypeMaintenanceEventNotification                  V3PolicyUpdateParamsAlertType = "maintenance_event_notification"
	V3PolicyUpdateParamsAlertTypeMTLSCertificateStoreCertificateExpirationType V3PolicyUpdateParamsAlertType = "mtls_certificate_store_certificate_expiration_type"
	V3PolicyUpdateParamsAlertTypePagesEventAlert                               V3PolicyUpdateParamsAlertType = "pages_event_alert"
	V3PolicyUpdateParamsAlertTypeRadarNotification                             V3PolicyUpdateParamsAlertType = "radar_notification"
	V3PolicyUpdateParamsAlertTypeRealOriginMonitoring                          V3PolicyUpdateParamsAlertType = "real_origin_monitoring"
	V3PolicyUpdateParamsAlertTypeScriptmonitorAlertNewCodeChangeDetections     V3PolicyUpdateParamsAlertType = "scriptmonitor_alert_new_code_change_detections"
	V3PolicyUpdateParamsAlertTypeScriptmonitorAlertNewHosts                    V3PolicyUpdateParamsAlertType = "scriptmonitor_alert_new_hosts"
	V3PolicyUpdateParamsAlertTypeScriptmonitorAlertNewMaliciousHosts           V3PolicyUpdateParamsAlertType = "scriptmonitor_alert_new_malicious_hosts"
	V3PolicyUpdateParamsAlertTypeScriptmonitorAlertNewMaliciousScripts         V3PolicyUpdateParamsAlertType = "scriptmonitor_alert_new_malicious_scripts"
	V3PolicyUpdateParamsAlertTypeScriptmonitorAlertNewMaliciousURL             V3PolicyUpdateParamsAlertType = "scriptmonitor_alert_new_malicious_url"
	V3PolicyUpdateParamsAlertTypeScriptmonitorAlertNewMaxLengthResourceURL     V3PolicyUpdateParamsAlertType = "scriptmonitor_alert_new_max_length_resource_url"
	V3PolicyUpdateParamsAlertTypeScriptmonitorAlertNewResources                V3PolicyUpdateParamsAlertType = "scriptmonitor_alert_new_resources"
	V3PolicyUpdateParamsAlertTypeSecondaryDNSAllPrimariesFailing               V3PolicyUpdateParamsAlertType = "secondary_dns_all_primaries_failing"
	V3PolicyUpdateParamsAlertTypeSecondaryDNSPrimariesFailing                  V3PolicyUpdateParamsAlertType = "secondary_dns_primaries_failing"
	V3PolicyUpdateParamsAlertTypeSecondaryDNSZoneSuccessfullyUpdated           V3PolicyUpdateParamsAlertType = "secondary_dns_zone_successfully_updated"
	V3PolicyUpdateParamsAlertTypeSecondaryDNSZoneValidationWarning             V3PolicyUpdateParamsAlertType = "secondary_dns_zone_validation_warning"
	V3PolicyUpdateParamsAlertTypeSentinelAlert                                 V3PolicyUpdateParamsAlertType = "sentinel_alert"
	V3PolicyUpdateParamsAlertTypeStreamLiveNotifications                       V3PolicyUpdateParamsAlertType = "stream_live_notifications"
	V3PolicyUpdateParamsAlertTypeTrafficAnomaliesAlert                         V3PolicyUpdateParamsAlertType = "traffic_anomalies_alert"
	V3PolicyUpdateParamsAlertTypeTunnelHealthEvent                             V3PolicyUpdateParamsAlertType = "tunnel_health_event"
	V3PolicyUpdateParamsAlertTypeTunnelUpdateEvent                             V3PolicyUpdateParamsAlertType = "tunnel_update_event"
	V3PolicyUpdateParamsAlertTypeUniversalSSLEventType                         V3PolicyUpdateParamsAlertType = "universal_ssl_event_type"
	V3PolicyUpdateParamsAlertTypeWebAnalyticsMetricsUpdate                     V3PolicyUpdateParamsAlertType = "web_analytics_metrics_update"
	V3PolicyUpdateParamsAlertTypeZoneAopCustomCertificateExpirationType        V3PolicyUpdateParamsAlertType = "zone_aop_custom_certificate_expiration_type"
)

type V3PolicyUpdateParamsFilters

type V3PolicyUpdateParamsFilters struct {
	// Usage depends on specific alert type
	Actions param.Field[[]string] `json:"actions"`
	// Used for configuring radar_notification
	AffectedASNs param.Field[[]string] `json:"affected_asns"`
	// Used for configuring incident_alert. A list of identifiers for each component to
	// monitor.
	AffectedComponents param.Field[[]string] `json:"affected_components"`
	// Used for configuring radar_notification
	AffectedLocations param.Field[[]string] `json:"affected_locations"`
	// Used for configuring maintenance_event_notification
	AirportCode param.Field[[]string] `json:"airport_code"`
	// Usage depends on specific alert type
	AlertTriggerPreferences param.Field[[]string] `json:"alert_trigger_preferences"`
	// Used for configuring magic_tunnel_health_check_event
	AlertTriggerPreferencesValue param.Field[[]V3PolicyUpdateParamsFiltersAlertTriggerPreferencesValue] `json:"alert_trigger_preferences_value"`
	// Used for configuring load_balancing_pool_enablement_alert
	Enabled param.Field[[]string] `json:"enabled"`
	// Used for configuring pages_event_alert
	Environment param.Field[[]string] `json:"environment"`
	// Used for configuring pages_event_alert
	Event param.Field[[]string] `json:"event"`
	// Used for configuring load_balancing_health_alert
	EventSource param.Field[[]string] `json:"event_source"`
	// Usage depends on specific alert type
	EventType param.Field[[]string] `json:"event_type"`
	// Usage depends on specific alert type
	GroupBy param.Field[[]string] `json:"group_by"`
	// Used for configuring health_check_status_notification
	HealthCheckID param.Field[[]string] `json:"health_check_id"`
	// Used for configuring incident_alert
	IncidentImpact param.Field[[]V3PolicyUpdateParamsFiltersIncidentImpact] `json:"incident_impact"`
	// Used for configuring stream_live_notifications
	InputID param.Field[[]string] `json:"input_id"`
	// Used for configuring billing_usage_alert
	Limit param.Field[[]string] `json:"limit"`
	// Used for configuring logo_match_alert
	LogoTag param.Field[[]string] `json:"logo_tag"`
	// Used for configuring advanced_ddos_attack_l4_alert
	MegabitsPerSecond param.Field[[]string] `json:"megabits_per_second"`
	// Used for configuring load_balancing_health_alert
	NewHealth param.Field[[]string] `json:"new_health"`
	// Used for configuring tunnel_health_event
	NewStatus param.Field[[]string] `json:"new_status"`
	// Used for configuring advanced_ddos_attack_l4_alert
	PacketsPerSecond param.Field[[]string] `json:"packets_per_second"`
	// Usage depends on specific alert type
	PoolID param.Field[[]string] `json:"pool_id"`
	// Used for configuring billing_usage_alert
	Product param.Field[[]string] `json:"product"`
	// Used for configuring pages_event_alert
	ProjectID param.Field[[]string] `json:"project_id"`
	// Used for configuring advanced_ddos_attack_l4_alert
	Protocol param.Field[[]string] `json:"protocol"`
	// Usage depends on specific alert type
	QueryTag param.Field[[]string] `json:"query_tag"`
	// Used for configuring advanced_ddos_attack_l7_alert
	RequestsPerSecond param.Field[[]string] `json:"requests_per_second"`
	// Usage depends on specific alert type
	Selectors param.Field[[]string] `json:"selectors"`
	// Used for configuring clickhouse_alert_fw_ent_anomaly
	Services param.Field[[]string] `json:"services"`
	// Usage depends on specific alert type
	Slo param.Field[[]string] `json:"slo"`
	// Used for configuring health_check_status_notification
	Status param.Field[[]string] `json:"status"`
	// Used for configuring advanced_ddos_attack_l7_alert
	TargetHostname param.Field[[]string] `json:"target_hostname"`
	// Used for configuring advanced_ddos_attack_l4_alert
	TargetIP param.Field[[]string] `json:"target_ip"`
	// Used for configuring advanced_ddos_attack_l7_alert
	TargetZoneName param.Field[[]string] `json:"target_zone_name"`
	// Used for configuring traffic_anomalies_alert
	TrafficExclusions param.Field[[]V3PolicyUpdateParamsFiltersTrafficExclusion] `json:"traffic_exclusions"`
	// Used for configuring tunnel_health_event
	TunnelID param.Field[[]string] `json:"tunnel_id"`
	// Used for configuring magic_tunnel_health_check_event
	TunnelName param.Field[[]string] `json:"tunnel_name"`
	// Usage depends on specific alert type
	Where param.Field[[]string] `json:"where"`
	// Usage depends on specific alert type
	Zones param.Field[[]string] `json:"zones"`
}

Optional filters that allow you to be alerted only on a subset of events for that alert type based on some criteria. This is only available for select alert types. See alert type documentation for more details.

func (V3PolicyUpdateParamsFilters) MarshalJSON

func (r V3PolicyUpdateParamsFilters) MarshalJSON() (data []byte, err error)

type V3PolicyUpdateParamsFiltersAlertTriggerPreferencesValue

type V3PolicyUpdateParamsFiltersAlertTriggerPreferencesValue string
const (
	V3PolicyUpdateParamsFiltersAlertTriggerPreferencesValue99_0 V3PolicyUpdateParamsFiltersAlertTriggerPreferencesValue = "99.0"
	V3PolicyUpdateParamsFiltersAlertTriggerPreferencesValue98_0 V3PolicyUpdateParamsFiltersAlertTriggerPreferencesValue = "98.0"
	V3PolicyUpdateParamsFiltersAlertTriggerPreferencesValue97_0 V3PolicyUpdateParamsFiltersAlertTriggerPreferencesValue = "97.0"
)

type V3PolicyUpdateParamsFiltersIncidentImpact

type V3PolicyUpdateParamsFiltersIncidentImpact string
const (
	V3PolicyUpdateParamsFiltersIncidentImpactIncidentImpactNone     V3PolicyUpdateParamsFiltersIncidentImpact = "INCIDENT_IMPACT_NONE"
	V3PolicyUpdateParamsFiltersIncidentImpactIncidentImpactMinor    V3PolicyUpdateParamsFiltersIncidentImpact = "INCIDENT_IMPACT_MINOR"
	V3PolicyUpdateParamsFiltersIncidentImpactIncidentImpactMajor    V3PolicyUpdateParamsFiltersIncidentImpact = "INCIDENT_IMPACT_MAJOR"
	V3PolicyUpdateParamsFiltersIncidentImpactIncidentImpactCritical V3PolicyUpdateParamsFiltersIncidentImpact = "INCIDENT_IMPACT_CRITICAL"
)

type V3PolicyUpdateParamsFiltersTrafficExclusion

type V3PolicyUpdateParamsFiltersTrafficExclusion string
const (
	V3PolicyUpdateParamsFiltersTrafficExclusionSecurityEvents V3PolicyUpdateParamsFiltersTrafficExclusion = "security_events"
)

type V3PolicyUpdateParamsMechanisms

type V3PolicyUpdateParamsMechanisms struct {
	// UUID
	ID param.Field[V3PolicyUpdateParamsMechanismsID] `json:"id"`
}

func (V3PolicyUpdateParamsMechanisms) MarshalJSON

func (r V3PolicyUpdateParamsMechanisms) MarshalJSON() (data []byte, err error)

type V3PolicyUpdateParamsMechanismsID

type V3PolicyUpdateParamsMechanismsID interface {
	ImplementsAlertingV3PolicyUpdateParamsMechanismsID()
}

UUID

Satisfied by shared.UnionString, shared.UnionString.

type V3PolicyUpdateResponse

type V3PolicyUpdateResponse struct {
	// UUID
	ID   string                     `json:"id"`
	JSON v3PolicyUpdateResponseJSON `json:"-"`
}

func (*V3PolicyUpdateResponse) UnmarshalJSON

func (r *V3PolicyUpdateResponse) UnmarshalJSON(data []byte) (err error)

type V3PolicyUpdateResponseEnvelope

type V3PolicyUpdateResponseEnvelope struct {
	Errors   []V3PolicyUpdateResponseEnvelopeErrors   `json:"errors,required"`
	Messages []V3PolicyUpdateResponseEnvelopeMessages `json:"messages,required"`
	Result   V3PolicyUpdateResponse                   `json:"result,required"`
	// Whether the API call was successful
	Success V3PolicyUpdateResponseEnvelopeSuccess `json:"success,required"`
	JSON    v3PolicyUpdateResponseEnvelopeJSON    `json:"-"`
}

func (*V3PolicyUpdateResponseEnvelope) UnmarshalJSON

func (r *V3PolicyUpdateResponseEnvelope) UnmarshalJSON(data []byte) (err error)

type V3PolicyUpdateResponseEnvelopeErrors

type V3PolicyUpdateResponseEnvelopeErrors struct {
	Code    int64                                    `json:"code,required"`
	Message string                                   `json:"message,required"`
	JSON    v3PolicyUpdateResponseEnvelopeErrorsJSON `json:"-"`
}

func (*V3PolicyUpdateResponseEnvelopeErrors) UnmarshalJSON

func (r *V3PolicyUpdateResponseEnvelopeErrors) UnmarshalJSON(data []byte) (err error)

type V3PolicyUpdateResponseEnvelopeMessages

type V3PolicyUpdateResponseEnvelopeMessages struct {
	Code    int64                                      `json:"code,required"`
	Message string                                     `json:"message,required"`
	JSON    v3PolicyUpdateResponseEnvelopeMessagesJSON `json:"-"`
}

func (*V3PolicyUpdateResponseEnvelopeMessages) UnmarshalJSON

func (r *V3PolicyUpdateResponseEnvelopeMessages) UnmarshalJSON(data []byte) (err error)

type V3PolicyUpdateResponseEnvelopeSuccess

type V3PolicyUpdateResponseEnvelopeSuccess bool

Whether the API call was successful

const (
	V3PolicyUpdateResponseEnvelopeSuccessTrue V3PolicyUpdateResponseEnvelopeSuccess = true
)

type V3Service

type V3Service struct {
	Options      []option.RequestOption
	Destinations *V3DestinationService
	Histories    *V3HistoryService
	Policies     *V3PolicyService
}

V3Service contains methods and other services that help with interacting with the cloudflare API. Note, unlike clients, this service does not read variables from the environment automatically. You should not instantiate this service directly, and instead use the NewV3Service method instead.

func NewV3Service

func NewV3Service(opts ...option.RequestOption) (r *V3Service)

NewV3Service generates a new service that applies the given options to each request. These options are applied after the parent client's options (if there is one), and before any request-specific options.

func (*V3Service) List

func (r *V3Service) List(ctx context.Context, query V3ListParams, opts ...option.RequestOption) (res *V3ListResponse, err error)

Gets a list of all alert types for which an account is eligible.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL