Retrieves the result of a deployment gate evaluation by its evaluation ID.
If the evaluation is still in progress, data.attributes.gate_status will be in_progress;
continue polling until it returns pass or fail.
Polling every 10-20 seconds is recommended.
The endpoint may return a 404 if called too soon after triggering; retry after a few seconds.
This endpoint requires the deployment_gates_evaluate permission.
Arguments
Path Parameters
Name
Type
Description
id [required]
string
The evaluation ID returned by the trigger endpoint.
{"data":{"attributes":{"dry_run":false,"evaluation_id":"e9d2f04f-4f4b-494b-86e5-52f03e10c8e9","evaluation_url":"https://app.datadoghq.com/ci/deployment-gates/evaluations?index=cdgates\u0026query=level%3Agate+%40evaluation_id%3Ae9d2f04f-4f4b-494b-86e5-52f03e10c8e9","gate_id":"e140302e-0cba-40d2-978c-6780647f8f1c","gate_status":"pass","rules":[{"dry_run":false,"name":"Check service monitors","reason":"One or more monitors in ALERT state","status":"pass"}]},"id":"e9d2f04f-4f4b-494b-86e5-52f03e10c8e9","type":"deployment_gates_evaluation_result_response"}}
"""
Get a deployment gate evaluation result returns "OK" response
"""fromdatadog_api_clientimportApiClient,Configurationfromdatadog_api_client.v2.api.deployment_gates_apiimportDeploymentGatesApifromuuidimportUUIDconfiguration=Configuration()configuration.unstable_operations["get_deployment_gates_evaluation_result"]=TruewithApiClient(configuration)asapi_client:api_instance=DeploymentGatesApi(api_client)response=api_instance.get_deployment_gates_evaluation_result(id=UUID("9b1deb4d-3b7d-4bad-9bdd-2b0d7b3dcb6d"),)print(response)
# Get a deployment gate evaluation result returns "OK" responserequire"datadog_api_client"DatadogAPIClient.configuredo|config|config.unstable_operations["v2.get_deployment_gates_evaluation_result".to_sym]=trueendapi_instance=DatadogAPIClient::V2::DeploymentGatesAPI.newpapi_instance.get_deployment_gates_evaluation_result("9b1deb4d-3b7d-4bad-9bdd-2b0d7b3dcb6d")
// Get a deployment gate evaluation result returns "OK" responsepackagemainimport("context""encoding/json""fmt""os""github.com/DataDog/datadog-api-client-go/v2/api/datadog""github.com/DataDog/datadog-api-client-go/v2/api/datadogV2""github.com/google/uuid")funcmain(){ctx:=datadog.NewDefaultContext(context.Background())configuration:=datadog.NewConfiguration()configuration.SetUnstableOperationEnabled("v2.GetDeploymentGatesEvaluationResult",true)apiClient:=datadog.NewAPIClient(configuration)api:=datadogV2.NewDeploymentGatesApi(apiClient)resp,r,err:=api.GetDeploymentGatesEvaluationResult(ctx,uuid.MustParse("9b1deb4d-3b7d-4bad-9bdd-2b0d7b3dcb6d"))iferr!=nil{fmt.Fprintf(os.Stderr,"Error when calling `DeploymentGatesApi.GetDeploymentGatesEvaluationResult`: %v\n",err)fmt.Fprintf(os.Stderr,"Full HTTP response: %v\n",r)}responseContent,_:=json.MarshalIndent(resp,""," ")fmt.Fprintf(os.Stdout,"Response from `DeploymentGatesApi.GetDeploymentGatesEvaluationResult`:\n%s\n",responseContent)}
// Get a deployment gate evaluation result returns "OK" responseimportcom.datadog.api.client.ApiClient;importcom.datadog.api.client.ApiException;importcom.datadog.api.client.v2.api.DeploymentGatesApi;importcom.datadog.api.client.v2.model.DeploymentGatesEvaluationResultResponse;importjava.util.UUID;publicclassExample{publicstaticvoidmain(String[]args){ApiClientdefaultClient=ApiClient.getDefaultApiClient();defaultClient.setUnstableOperationEnabled("v2.getDeploymentGatesEvaluationResult",true);DeploymentGatesApiapiInstance=newDeploymentGatesApi(defaultClient);try{DeploymentGatesEvaluationResultResponseresult=apiInstance.getDeploymentGatesEvaluationResult(UUID.fromString("9b1deb4d-3b7d-4bad-9bdd-2b0d7b3dcb6d"));System.out.println(result);}catch(ApiExceptione){System.err.println("Exception when calling DeploymentGatesApi#getDeploymentGatesEvaluationResult");System.err.println("Status code: "+e.getCode());System.err.println("Reason: "+e.getResponseBody());System.err.println("Response headers: "+e.getResponseHeaders());e.printStackTrace();}}}
// Get a deployment gate evaluation result returns "OK" response
usedatadog_api_client::datadog;usedatadog_api_client::datadogV2::api_deployment_gates::DeploymentGatesAPI;useuuid::Uuid;#[tokio::main]asyncfnmain(){letmutconfiguration=datadog::Configuration::new();configuration.set_unstable_operation_enabled("v2.GetDeploymentGatesEvaluationResult",true);letapi=DeploymentGatesAPI::with_config(configuration);letresp=api.get_deployment_gates_evaluation_result(Uuid::parse_str("00000000-0000-0000-0000-000000000000").expect("invalid UUID"),).await;ifletOk(value)=resp{println!("{:#?}",value);}else{println!("{:#?}",resp.unwrap_err());}}
DD_SITE="datadoghq.comus3.datadoghq.comus5.datadoghq.comdatadoghq.euap1.datadoghq.comap2.datadoghq.comddog-gov.comus2.ddog-gov.com"DD_API_KEY="<DD_API_KEY>"DD_APP_KEY="<DD_APP_KEY>"cargo run
/**
* Get a deployment gate evaluation result returns "OK" response
*/import{client,v2}from"@datadog/datadog-api-client";constconfiguration=client.createConfiguration();configuration.unstableOperations["v2.getDeploymentGatesEvaluationResult"]=true;constapiInstance=newv2.DeploymentGatesApi(configuration);constparams: v2.DeploymentGatesApiGetDeploymentGatesEvaluationResultRequest={id:"9b1deb4d-3b7d-4bad-9bdd-2b0d7b3dcb6d",};apiInstance.getDeploymentGatesEvaluationResult(params).then((data: v2.DeploymentGatesEvaluationResultResponse)=>{console.log("API called successfully. Returned data: "+JSON.stringify(data));}).catch((error: any)=>console.error(error));