Update a deployment’s change failure status. Use this to mark a deployment as a change failure or back to stable. You can optionally include remediation details to enable failed deployment recovery time calculation.
This endpoint requires the dora_metrics_write permission.
Indicates whether the deployment resulted in a change failure.
remediation
object
Remediation details for the deployment. Optional, but required to calculate failed deployment recovery time.
id
string
The ID of the remediation deployment. Required when the failed deployment must be linked to a remediation deployment.
type
enum
The type of remediation action taken. Required when the failed deployment must be linked to a remediation deployment.
Allowed enum values: rollback,rollforward
id [required]
string
The ID of the deployment to patch.
type [required]
enum
JSON:API type for DORA deployment patch request.
Allowed enum values: dora_deployment_patch_request
DD_SITE="datadoghq.comus3.datadoghq.comus5.datadoghq.comdatadoghq.euap1.datadoghq.comap2.datadoghq.comuk1.datadoghq.comddog-gov.comus2.ddog-gov.com"DD_API_KEY="<DD_API_KEY>"DD_APP_KEY="<DD_APP_KEY>"cargo run
/**
* Patch a deployment event returns "Accepted" response
*/import{client,v2}from"@datadog/datadog-api-client";constconfiguration=client.createConfiguration();constapiInstance=newv2.DORAMetricsApi(configuration);constparams: v2.DORAMetricsApiPatchDORADeploymentRequest={body:{data:{attributes:{changeFailure: true,remediation:{id:"eG42zNIkVjM",type:"rollback",},},id:"z_RwVLi7v4Y",type:"dora_deployment_patch_request",},},deploymentId:"deployment_id",};apiInstance.patchDORADeployment(params).then((data: any)=>{console.log("API called successfully. Returned data: "+JSON.stringify(data));}).catch((error: any)=>console.error(error));