The included related resources of a degradation. Client must explicitly request these resources by name in the include query parameter.
Option 1
object
The included Datadog user resource.
attributes
object
Attributes of the Datadog user.
email
string
The email of the Datadog user.
handle
string
The handle of the Datadog user.
icon
string
The icon of the Datadog user.
name
string
The name of the Datadog user.
uuid
string
The UUID of the Datadog user.
id
uuid
The ID of the Datadog user.
type [required]
enum
Users resource type.
Allowed enum values: users
default: users
Option 2
object
The included status page resource.
attributes
object
The attributes of a status page.
company_logo
string
The base64-encoded image data displayed in the company logo.
components
[object]
Components displayed on the status page.
components
[object]
If the component is of type group, the components within the group.
id
uuid
The ID of the grouped component.
name
string
The name of the grouped component.
position
int64
The zero-indexed position of the grouped component. Relative to the other components in the group.
status
enum
The status of the component.
Allowed enum values: operational,degraded,partial_outage,major_outage,maintenance
type
enum
The type of the component.
Allowed enum values: component
id
uuid
The ID of the component.
name
string
The name of the component.
position
int64
The zero-indexed position of the component.
status
enum
The status of the component.
Allowed enum values: operational,degraded,partial_outage,major_outage,maintenance
type
enum
The type of the component.
Allowed enum values: component,group
created_at
date-time
Timestamp of when the status page was created.
custom_domain
string
If configured, the url that the status page is accessible at.
custom_domain_enabled
boolean
Whether the custom domain is configured.
domain_prefix
string
The subdomain of the status page's url taking the form https://{domain_prefix}.statuspage.datadoghq.com. Globally unique across Datadog Status Pages.
email_header_image
string
Base64-encoded image data included in email notifications sent to status page subscribers.
enabled
boolean
Whether the status page is enabled.
favicon
string
Base64-encoded image data displayed in the browser tab.
modified_at
date-time
Timestamp of when the status page was last modified.
name
string
The name of the status page.
page_url
string
The url that the status page is accessible at.
slack_app_icon
string
The Slack app icon URL for the status page.
slack_subscriptions_enabled
boolean
Whether Slack subscriptions are enabled for the status page.
subscriptions_enabled
boolean
Whether users can subscribe to the status page.
type
enum
The type of the status page controlling how the status page is accessed.
Allowed enum values: public,internal
visualization_type
enum
The visualization type of the status page.
Allowed enum values: bars_and_uptime_percentage,bars_only,component_name_only
id
uuid
The ID of the status page.
relationships
object
The relationships of a status page.
created_by_user
object
The Datadog user who created the status page.
data [required]
object
The data object identifying the Datadog user who created the status page.
id [required]
string
The ID of the Datadog user who created the status page.
type [required]
enum
Users resource type.
Allowed enum values: users
default: users
last_modified_by_user
object
The Datadog user who last modified the status page.
data [required]
object
The data object identifying the Datadog user who last modified the status page.
id [required]
string
The ID of the Datadog user who last modified the status page.
type [required]
enum
Users resource type.
Allowed enum values: users
default: users
type [required]
enum
Status pages resource type.
Allowed enum values: status_pages
default: status_pages
Option 3
object
The included status page resource.
attributes
object
The attributes of a status page.
company_logo
string
The base64-encoded image data displayed in the company logo.
components
[object]
Components displayed on the status page.
components
[object]
If the component is of type group, the components within the group.
id
uuid
The ID of the grouped component.
name
string
The name of the grouped component.
position
int64
The zero-indexed position of the grouped component. Relative to the other components in the group.
status
enum
The status of the component.
Allowed enum values: operational,degraded,partial_outage,major_outage,maintenance
type
enum
The type of the component.
Allowed enum values: component
id
uuid
The ID of the component.
name
string
The name of the component.
position
int64
The zero-indexed position of the component.
status
enum
The status of the component.
Allowed enum values: operational,degraded,partial_outage,major_outage,maintenance
type
enum
The type of the component.
Allowed enum values: component,group
created_at
date-time
Timestamp of when the status page was created.
custom_domain
string
If configured, the url that the status page is accessible at.
custom_domain_enabled
boolean
Whether the custom domain is configured.
domain_prefix
string
The subdomain of the status page's url taking the form https://{domain_prefix}.statuspage.datadoghq.com. Globally unique across Datadog Status Pages.
email_header_image
string
Base64-encoded image data included in email notifications sent to status page subscribers.
enabled
boolean
Whether the status page is enabled.
favicon
string
Base64-encoded image data displayed in the browser tab.
modified_at
date-time
Timestamp of when the status page was last modified.
name
string
The name of the status page.
page_url
string
The url that the status page is accessible at.
slack_app_icon
string
The Slack app icon URL for the status page.
slack_subscriptions_enabled
boolean
Whether Slack subscriptions are enabled for the status page.
subscriptions_enabled
boolean
Whether users can subscribe to the status page.
type
enum
The type of the status page controlling how the status page is accessed.
Allowed enum values: public,internal
visualization_type
enum
The visualization type of the status page.
Allowed enum values: bars_and_uptime_percentage,bars_only,component_name_only
id
uuid
The ID of the status page.
relationships
object
The relationships of a status page.
created_by_user
object
The Datadog user who created the status page.
data [required]
object
The data object identifying the Datadog user who created the status page.
id [required]
string
The ID of the Datadog user who created the status page.
type [required]
enum
Users resource type.
Allowed enum values: users
default: users
last_modified_by_user
object
The Datadog user who last modified the status page.
data [required]
object
The data object identifying the Datadog user who last modified the status page.
id [required]
string
The ID of the Datadog user who last modified the status page.
type [required]
enum
Users resource type.
Allowed enum values: users
default: users
type [required]
enum
Status pages resource type.
Allowed enum values: status_pages
## default
#
# Path parameters exportdegradation_id="CHANGE_ME" exportpage_id="CHANGE_ME" exportupdate_id="CHANGE_ME" # Curl command curl-XPATCH"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/statuspages/${page_id}/degradations/${degradation_id}/updates/${update_id}" \
-H"Accept: application/json" \
-H"Content-Type: application/json" \
-H"DD-API-KEY: ${DD_API_KEY}" \
-H"DD-APPLICATION-KEY: ${DD_APP_KEY}" \
-d@-<<EOF{
"data": {
"attributes": {
"description": "We've identified the source of the latency increase and are deploying a fix.",
"status": "identified"
},
"id": "00000000-0000-0000-0000-000000000000",
"type": "degradation_updates"
}
}EOF
"""
Edit degradation update returns "OK" response
"""fromdatadog_api_clientimportApiClient,Configurationfromdatadog_api_client.v2.api.status_pages_apiimportStatusPagesApifromdatadog_api_client.v2.model.patch_degradation_update_requestimportPatchDegradationUpdateRequestfromdatadog_api_client.v2.model.patch_degradation_update_request_dataimportPatchDegradationUpdateRequestDatafromdatadog_api_client.v2.model.patch_degradation_update_request_data_attributesimport(PatchDegradationUpdateRequestDataAttributes,)fromdatadog_api_client.v2.model.patch_degradation_update_request_data_attributes_statusimport(PatchDegradationUpdateRequestDataAttributesStatus,)fromdatadog_api_client.v2.model.patch_degradation_update_request_data_typeimportPatchDegradationUpdateRequestDataTypefromuuidimportUUIDbody=PatchDegradationUpdateRequest(data=PatchDegradationUpdateRequestData(attributes=PatchDegradationUpdateRequestDataAttributes(description="We've identified the source of the latency increase and are deploying a fix.",status=PatchDegradationUpdateRequestDataAttributesStatus.IDENTIFIED,),id="00000000-0000-0000-0000-000000000000",type=PatchDegradationUpdateRequestDataType.DEGRADATION_UPDATES,),)configuration=Configuration()withApiClient(configuration)asapi_client:api_instance=StatusPagesApi(api_client)response=api_instance.edit_degradation_update(degradation_id=UUID("9b1deb4d-3b7d-4bad-9bdd-2b0d7b3dcb6d"),page_id=UUID("9b1deb4d-3b7d-4bad-9bdd-2b0d7b3dcb6d"),update_id=UUID("9b1deb4d-3b7d-4bad-9bdd-2b0d7b3dcb6d"),body=body,)print(response)
# Edit degradation update returns "OK" responserequire"datadog_api_client"api_instance=DatadogAPIClient::V2::StatusPagesAPI.newbody=DatadogAPIClient::V2::PatchDegradationUpdateRequest.new({data:DatadogAPIClient::V2::PatchDegradationUpdateRequestData.new({attributes:DatadogAPIClient::V2::PatchDegradationUpdateRequestDataAttributes.new({description:"We've identified the source of the latency increase and are deploying a fix.",status:DatadogAPIClient::V2::PatchDegradationUpdateRequestDataAttributesStatus::IDENTIFIED,}),id:"00000000-0000-0000-0000-000000000000",type:DatadogAPIClient::V2::PatchDegradationUpdateRequestDataType::DEGRADATION_UPDATES,}),})papi_instance.edit_degradation_update("9b1deb4d-3b7d-4bad-9bdd-2b0d7b3dcb6d","9b1deb4d-3b7d-4bad-9bdd-2b0d7b3dcb6d","9b1deb4d-3b7d-4bad-9bdd-2b0d7b3dcb6d",body)
// Edit degradation update 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(){body:=datadogV2.PatchDegradationUpdateRequest{Data:&datadogV2.PatchDegradationUpdateRequestData{Attributes:&datadogV2.PatchDegradationUpdateRequestDataAttributes{Description:datadog.PtrString("We've identified the source of the latency increase and are deploying a fix."),Status:datadogV2.PATCHDEGRADATIONUPDATEREQUESTDATAATTRIBUTESSTATUS_IDENTIFIED.Ptr(),},Id:datadog.PtrString("00000000-0000-0000-0000-000000000000"),Type:datadogV2.PATCHDEGRADATIONUPDATEREQUESTDATATYPE_DEGRADATION_UPDATES,},}ctx:=datadog.NewDefaultContext(context.Background())configuration:=datadog.NewConfiguration()apiClient:=datadog.NewAPIClient(configuration)api:=datadogV2.NewStatusPagesApi(apiClient)resp,r,err:=api.EditDegradationUpdate(ctx,uuid.MustParse("9b1deb4d-3b7d-4bad-9bdd-2b0d7b3dcb6d"),uuid.MustParse("9b1deb4d-3b7d-4bad-9bdd-2b0d7b3dcb6d"),uuid.MustParse("9b1deb4d-3b7d-4bad-9bdd-2b0d7b3dcb6d"),body,*datadogV2.NewEditDegradationUpdateOptionalParameters())iferr!=nil{fmt.Fprintf(os.Stderr,"Error when calling `StatusPagesApi.EditDegradationUpdate`: %v\n",err)fmt.Fprintf(os.Stderr,"Full HTTP response: %v\n",r)}responseContent,_:=json.MarshalIndent(resp,""," ")fmt.Fprintf(os.Stdout,"Response from `StatusPagesApi.EditDegradationUpdate`:\n%s\n",responseContent)}
// Edit degradation update returns "OK" responseimportcom.datadog.api.client.ApiClient;importcom.datadog.api.client.ApiException;importcom.datadog.api.client.v2.api.StatusPagesApi;importcom.datadog.api.client.v2.model.DegradationUpdate;importcom.datadog.api.client.v2.model.PatchDegradationUpdateRequest;importcom.datadog.api.client.v2.model.PatchDegradationUpdateRequestData;importcom.datadog.api.client.v2.model.PatchDegradationUpdateRequestDataAttributes;importcom.datadog.api.client.v2.model.PatchDegradationUpdateRequestDataAttributesStatus;importcom.datadog.api.client.v2.model.PatchDegradationUpdateRequestDataType;importjava.util.UUID;publicclassExample{publicstaticvoidmain(String[]args){ApiClientdefaultClient=ApiClient.getDefaultApiClient();StatusPagesApiapiInstance=newStatusPagesApi(defaultClient);PatchDegradationUpdateRequestbody=newPatchDegradationUpdateRequest().data(newPatchDegradationUpdateRequestData().attributes(newPatchDegradationUpdateRequestDataAttributes().description("We've identified the source of the latency increase and are"+" deploying a fix.").status(PatchDegradationUpdateRequestDataAttributesStatus.IDENTIFIED)).id("00000000-0000-0000-0000-000000000000").type(PatchDegradationUpdateRequestDataType.DEGRADATION_UPDATES));try{DegradationUpdateresult=apiInstance.editDegradationUpdate(UUID.fromString("9b1deb4d-3b7d-4bad-9bdd-2b0d7b3dcb6d"),UUID.fromString("9b1deb4d-3b7d-4bad-9bdd-2b0d7b3dcb6d"),UUID.fromString("9b1deb4d-3b7d-4bad-9bdd-2b0d7b3dcb6d"),body);System.out.println(result);}catch(ApiExceptione){System.err.println("Exception when calling StatusPagesApi#editDegradationUpdate");System.err.println("Status code: "+e.getCode());System.err.println("Reason: "+e.getResponseBody());System.err.println("Response headers: "+e.getResponseHeaders());e.printStackTrace();}}}
// Edit degradation update returns "OK" response
usedatadog_api_client::datadog;usedatadog_api_client::datadogV2::api_status_pages::EditDegradationUpdateOptionalParams;usedatadog_api_client::datadogV2::api_status_pages::StatusPagesAPI;usedatadog_api_client::datadogV2::model::PatchDegradationUpdateRequest;usedatadog_api_client::datadogV2::model::PatchDegradationUpdateRequestData;usedatadog_api_client::datadogV2::model::PatchDegradationUpdateRequestDataAttributes;usedatadog_api_client::datadogV2::model::PatchDegradationUpdateRequestDataAttributesStatus;usedatadog_api_client::datadogV2::model::PatchDegradationUpdateRequestDataType;useuuid::Uuid;#[tokio::main]asyncfnmain(){letbody=PatchDegradationUpdateRequest::new().data(PatchDegradationUpdateRequestData::new(PatchDegradationUpdateRequestDataType::DEGRADATION_UPDATES,).attributes(PatchDegradationUpdateRequestDataAttributes::new().description("We've identified the source of the latency increase and are deploying a fix.".to_string(),).status(PatchDegradationUpdateRequestDataAttributesStatus::IDENTIFIED),).id("00000000-0000-0000-0000-000000000000".to_string()),);letconfiguration=datadog::Configuration::new();letapi=StatusPagesAPI::with_config(configuration);letresp=api.edit_degradation_update(Uuid::parse_str("00000000-0000-0000-0000-000000000000").expect("invalid UUID"),Uuid::parse_str("00000000-0000-0000-0000-000000000000").expect("invalid UUID"),Uuid::parse_str("00000000-0000-0000-0000-000000000000").expect("invalid UUID"),body,EditDegradationUpdateOptionalParams::default(),).await;ifletOk(value)=resp{println!("{:#?}",value);}else{println!("{:#?}",resp.unwrap_err());}}
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
/**
* Edit degradation update returns "OK" response
*/import{client,v2}from"@datadog/datadog-api-client";constconfiguration=client.createConfiguration();constapiInstance=newv2.StatusPagesApi(configuration);constparams: v2.StatusPagesApiEditDegradationUpdateRequest={body:{data:{attributes:{description:"We've identified the source of the latency increase and are deploying a fix.",status:"identified",},id:"00000000-0000-0000-0000-000000000000",type:"degradation_updates",},},degradationId:"9b1deb4d-3b7d-4bad-9bdd-2b0d7b3dcb6d",pageId:"9b1deb4d-3b7d-4bad-9bdd-2b0d7b3dcb6d",updateId:"9b1deb4d-3b7d-4bad-9bdd-2b0d7b3dcb6d",};apiInstance.editDegradationUpdate(params).then((data: v2.DegradationUpdate)=>{console.log("API called successfully. Returned data: "+JSON.stringify(data));}).catch((error: any)=>console.error(error));