버전별 배포 이벤트 패치
https://api.datadoghq.com/api/v2/dora/deploymentshttps://api.us3.datadoghq.com/api/v2/dora/deploymentshttps://api.us5.datadoghq.com/api/v2/dora/deploymentshttps://api.datadoghq.eu/api/v2/dora/deploymentshttps://api.ap1.datadoghq.com/api/v2/dora/deploymentshttps://api.ap2.datadoghq.com/api/v2/dora/deploymentshttps://api.uk1.datadoghq.com/api/v2/dora/deploymentshttps://api.ddog-gov.com/api/v2/dora/deploymentshttps://api.us2.ddog-gov.com/api/v2/dora/deployments개요
배포의 변경 실패 상태를 업데이트하며 ID 대신 서비스, 환경 및 버전을 사용해 배포를 식별합니다. 이를 통해 배포를 변경 실패 또는 안정 상태로 표시합니다. 실패한 배포 복구 시간 계산을 활성화하기 위해 수정 세부 정보를 필요시 포함할 수 있습니다. 지정된 서비스, 환경 및 버전과 일치하는 배포가 여러 개인 경우 가장 최근에 완료된 배포가 업데이트됩니다.
요청
Body Data (required)
data [required]서비스, 환경 및 버전으로 식별되는 DORA 배포 이벤트를 패치하도록 요청합니다.
attributes [required]Attributes for patching a DORA deployment event identified by service, environment, and version.
change_failure [required]Indicates whether the deployment resulted in a change failure.
env [required]The environment the deployment was performed in.
remediationRemediation details for the deployment. Optional, but required to calculate failed deployment recovery time. Specify either id or version to identify the remediation deployment, but not both.
Object 1Remediation details identified by the ID of the remediation deployment.
id [required]The ID of the remediation deployment.
type [required]The type of remediation action taken. Required when the failed deployment must be linked to a remediation deployment.
rollback, rollforwardObject 2Remediation details identified by the version of the remediation deployment, matched against the same service and environment as the failed deployment.
type [required]The type of remediation action taken. Required when the failed deployment must be linked to a remediation deployment.
rollback, rollforwardversion [required]The version of the remediation deployment.
service [required]The name of the service that was deployed.
version [required]The version deployed. This can be seen in the Service Catalog or in the APM Deployment Tracking.
type [required]JSON:API type for DORA deployment patch request.
dora_deployment_patch_requestdora_deployment_patch_request{
"data": {
"attributes": {
"change_failure": true,
"env": "prod",
"remediation": {
"id": "eG42zNIkVjM",
"type": "rollback"
},
"service": "my-service",
"version": "v1.2.3"
},
"type": "dora_deployment_patch_request"
}
}응답
Accepted
Bad Request
API error response.
errors [required]A list of errors.
detailA human-readable explanation specific to this occurrence of the error.
metaNon-standard meta-information about the error
sourceReferences to the source of the error.
headerA string indicating the name of a single request header which caused the error.
parameterA string indicating which URI query parameter caused the error.
pointerA JSON pointer to the value in the request document that caused the error.
statusStatus code of the response.
titleShort human-readable summary of the error.
{
"errors": [
{
"detail": "Missing required attribute in body",
"meta": {},
"source": {
"header": "Authorization",
"parameter": "limit",
"pointer": "/data/attributes/title"
},
"status": "400",
"title": "Bad Request"
}
]
}Not Authorized
API error response.
errors [required]A list of errors.
{
"errors": [
"Bad Request"
]
}Too many requests
API error response.
errors [required]A list of errors.
{
"errors": [
"Bad Request"
]
}코드 예시
# Set your Datadog site and credentials
export DD_SITE="datadoghq.com"
# Use a Personal Access Token or Service Access Token
export DD_BEARER_TOKEN="<PERSONAL_ACCESS_TOKEN OR SERVICE_ACCESS_TOKEN>"
curl -X PATCH "https://api.${DD_SITE}/api/v2/dora/deployments" \
-H "Accept: application/json" \
-H "Content-Type: application/json" \
-H "Authorization: Bearer ${DD_BEARER_TOKEN}" \
-d @- << EOF
{
"data": {
"attributes": {
"change_failure": true,
"env": "production",
"service": "my-service",
"version": "v1.2.3"
},
"type": "dora_deployment_patch_request"
}
}
EOF# Set your Datadog site and credentials
export DD_SITE="us3.datadoghq.com"
# Use a Personal Access Token or Service Access Token
export DD_BEARER_TOKEN="<PERSONAL_ACCESS_TOKEN OR SERVICE_ACCESS_TOKEN>"
curl -X PATCH "https://api.${DD_SITE}/api/v2/dora/deployments" \
-H "Accept: application/json" \
-H "Content-Type: application/json" \
-H "Authorization: Bearer ${DD_BEARER_TOKEN}" \
-d @- << EOF
{
"data": {
"attributes": {
"change_failure": true,
"env": "production",
"service": "my-service",
"version": "v1.2.3"
},
"type": "dora_deployment_patch_request"
}
}
EOF# Set your Datadog site and credentials
export DD_SITE="us5.datadoghq.com"
# Use a Personal Access Token or Service Access Token
export DD_BEARER_TOKEN="<PERSONAL_ACCESS_TOKEN OR SERVICE_ACCESS_TOKEN>"
curl -X PATCH "https://api.${DD_SITE}/api/v2/dora/deployments" \
-H "Accept: application/json" \
-H "Content-Type: application/json" \
-H "Authorization: Bearer ${DD_BEARER_TOKEN}" \
-d @- << EOF
{
"data": {
"attributes": {
"change_failure": true,
"env": "production",
"service": "my-service",
"version": "v1.2.3"
},
"type": "dora_deployment_patch_request"
}
}
EOF# Set your Datadog site and credentials
export DD_SITE="datadoghq.eu"
# Use a Personal Access Token or Service Access Token
export DD_BEARER_TOKEN="<PERSONAL_ACCESS_TOKEN OR SERVICE_ACCESS_TOKEN>"
curl -X PATCH "https://api.${DD_SITE}/api/v2/dora/deployments" \
-H "Accept: application/json" \
-H "Content-Type: application/json" \
-H "Authorization: Bearer ${DD_BEARER_TOKEN}" \
-d @- << EOF
{
"data": {
"attributes": {
"change_failure": true,
"env": "production",
"service": "my-service",
"version": "v1.2.3"
},
"type": "dora_deployment_patch_request"
}
}
EOF# Set your Datadog site and credentials
export DD_SITE="ap1.datadoghq.com"
# Use a Personal Access Token or Service Access Token
export DD_BEARER_TOKEN="<PERSONAL_ACCESS_TOKEN OR SERVICE_ACCESS_TOKEN>"
curl -X PATCH "https://api.${DD_SITE}/api/v2/dora/deployments" \
-H "Accept: application/json" \
-H "Content-Type: application/json" \
-H "Authorization: Bearer ${DD_BEARER_TOKEN}" \
-d @- << EOF
{
"data": {
"attributes": {
"change_failure": true,
"env": "production",
"service": "my-service",
"version": "v1.2.3"
},
"type": "dora_deployment_patch_request"
}
}
EOF# Set your Datadog site and credentials
export DD_SITE="ap2.datadoghq.com"
# Use a Personal Access Token or Service Access Token
export DD_BEARER_TOKEN="<PERSONAL_ACCESS_TOKEN OR SERVICE_ACCESS_TOKEN>"
curl -X PATCH "https://api.${DD_SITE}/api/v2/dora/deployments" \
-H "Accept: application/json" \
-H "Content-Type: application/json" \
-H "Authorization: Bearer ${DD_BEARER_TOKEN}" \
-d @- << EOF
{
"data": {
"attributes": {
"change_failure": true,
"env": "production",
"service": "my-service",
"version": "v1.2.3"
},
"type": "dora_deployment_patch_request"
}
}
EOF# Set your Datadog site and credentials
export DD_SITE="uk1.datadoghq.com"
# Use a Personal Access Token or Service Access Token
export DD_BEARER_TOKEN="<PERSONAL_ACCESS_TOKEN OR SERVICE_ACCESS_TOKEN>"
curl -X PATCH "https://api.${DD_SITE}/api/v2/dora/deployments" \
-H "Accept: application/json" \
-H "Content-Type: application/json" \
-H "Authorization: Bearer ${DD_BEARER_TOKEN}" \
-d @- << EOF
{
"data": {
"attributes": {
"change_failure": true,
"env": "production",
"service": "my-service",
"version": "v1.2.3"
},
"type": "dora_deployment_patch_request"
}
}
EOF# Set your Datadog site and credentials
export DD_SITE="ddog-gov.com"
# Use a Personal Access Token or Service Access Token
export DD_BEARER_TOKEN="<PERSONAL_ACCESS_TOKEN OR SERVICE_ACCESS_TOKEN>"
curl -X PATCH "https://api.${DD_SITE}/api/v2/dora/deployments" \
-H "Accept: application/json" \
-H "Content-Type: application/json" \
-H "Authorization: Bearer ${DD_BEARER_TOKEN}" \
-d @- << EOF
{
"data": {
"attributes": {
"change_failure": true,
"env": "production",
"service": "my-service",
"version": "v1.2.3"
},
"type": "dora_deployment_patch_request"
}
}
EOF# Set your Datadog site and credentials
export DD_SITE="us2.ddog-gov.com"
# Use a Personal Access Token or Service Access Token
export DD_BEARER_TOKEN="<PERSONAL_ACCESS_TOKEN OR SERVICE_ACCESS_TOKEN>"
curl -X PATCH "https://api.${DD_SITE}/api/v2/dora/deployments" \
-H "Accept: application/json" \
-H "Content-Type: application/json" \
-H "Authorization: Bearer ${DD_BEARER_TOKEN}" \
-d @- << EOF
{
"data": {
"attributes": {
"change_failure": true,
"env": "production",
"service": "my-service",
"version": "v1.2.3"
},
"type": "dora_deployment_patch_request"
}
}
EOF