Note : This endpoint is in preview and is subject to change.
If you have any feedback, contact Datadog support .
POST https://api.ap1.datadoghq.com/api/v2/incidents/{incident_id}/page https://api.ap2.datadoghq.com/api/v2/incidents/{incident_id}/page https://api.datadoghq.eu/api/v2/incidents/{incident_id}/page https://api.ddog-gov.com/api/v2/incidents/{incident_id}/page https://api.us2.ddog-gov.com/api/v2/incidents/{incident_id}/page https://api.uk1.datadoghq.com/api/v2/incidents/{incident_id}/page https://api.datadoghq.com/api/v2/incidents/{incident_id}/page https://api.us3.datadoghq.com/api/v2/incidents/{incident_id}/page https://api.us5.datadoghq.com/api/v2/incidents/{incident_id}/page
概要 Create an on-call page directly from an incident.
This endpoint requires
all
of the following permissions:
oncall_pageincident_writeOAuth apps require the incident_write authorization scope to access this endpoint.
引数 パスパラメーター The UUID of the incident.
リクエスト Body Data (required) On-call page creation payload.
Expand All
On-call page data in a create request.
Attributes for creating an on-call page from an incident.
The description of the page.
A reference to an incident role for a page.
The type of incident role for a page.
Allowed enum values: incident_user_defined_roles,incident_reserved_roles
List of affected services.
List of tags for the page.
The target recipient for a page.
The identifier of the target (handle, UUID, or user UUID).
The type of target for a page request.
Allowed enum values: team_handle,team_uuid,user_uuid
Resource type for a page creation request.
Allowed enum values: page
{
"data" : {
"attributes" : {
"description" : "A critical incident affecting production systems." ,
"role" : {
"id" : "00000000-0000-0000-0000-000000000000" ,
"type" : "incident_user_defined_roles"
},
"services" : [
"web-store"
],
"tags" : [
"env:prod"
],
"target" : {
"identifier" : "my-team-handle" ,
"type" : "team_uuid"
},
"title" : "Production outage - SEV-1"
},
"type" : "page"
}
} 応答 OK
Response with a page UUID.
Expand All
Page UUID data in a response.
The UUID of the created page.
Resource type for a page UUID response.
Allowed enum values: page_uuid
{
"data" : {
"id" : "00000000-0000-0000-0000-000000000001" ,
"type" : "page_uuid"
}
} Bad Request
{
"errors" : [
"Bad Request"
]
} Unauthorized
{
"errors" : [
"Bad Request"
]
} Forbidden
{
"errors" : [
"Bad Request"
]
} Not Found
{
"errors" : [
"Bad Request"
]
} Too many requests
{
"errors" : [
"Bad Request"
]
} コード例 コピー
## default
#
# Path parameters export incident_id = "CHANGE_ME" # Use a Personal Access Token or Service Access Token export DD_BEARER_TOKEN = "<PERSONAL_ACCESS_TOKEN OR SERVICE_ACCESS_TOKEN>" # Curl command curl -X POST "https://api.ap1.datadoghq.com "https://api.ap2.datadoghq.com "https://api.datadoghq.eu "https://api.ddog-gov.com "https://api.us2.ddog-gov.com "https://api.uk1.datadoghq.com "https://api.datadoghq.com "https://api.us3.datadoghq.com "https://api.us5.datadoghq.com /api/v2/incidents/${incident_id}/page " \
-H "Accept: application/json" \
-H "Content-Type: application/json" \
-H "Authorization: Bearer ${DD_BEARER_TOKEN} " \
-d @- << EOF
{
"data": {
"attributes": {
"description": "A critical incident affecting production systems.",
"services": [
"web-store"
],
"target": {
"identifier": "my-oncall-team",
"type": "team_handle"
},
"title": "Production outage - SEV-1"
},
"type": "page"
}
}
EOF