Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
9 changes: 1 addition & 8 deletions .generator/schemas/v2/openapi.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -17098,7 +17098,6 @@ components:
type: component
domain_prefix: status-page-us1
email_header_image: data:image/png;base64,pQSLAw0KGgoAAAANSUhEUgAAAQ4AASJKFF
enabled: true
favicon: data:image/png;base64,kWMRNw0KGgoAAAANSUhEUgAAAEAAAABACA
name: Status Page US1
subscriptions_enabled: true
Expand Down Expand Up @@ -17157,10 +17156,6 @@ components:
description: Base64-encoded image data included in email notifications sent to status page subscribers.
example: data:image/png;base64,pQSLAw0KGgoAAAANSUhEUgAAAQ4AASJKFF
type: string
enabled:
description: Whether the status page is enabled.
example: true
type: boolean
favicon:
description: Base64-encoded image data displayed in the browser tab.
example: data:image/png;base64,kWMRNw0KGgoAAAANSUhEUgAAAEAAAABACA
Expand All @@ -17181,7 +17176,6 @@ components:
example: bars_and_uptime_percentage
required:
- domain_prefix
- enabled
- name
- type
- visualization_type
Expand Down Expand Up @@ -127086,7 +127080,7 @@ paths:
permissions:
- status_pages_settings_read
post:
description: "Creates a new status page. **Note**: Publishing a status page on creation via the `enabled` property will be deprecated. Use the dedicated [publish](#publish-status-page) status page endpoint after creation instead."
description: "Creates a new status page in an unpublished state. Use the dedicated [publish](#publish-status-page) status page endpoint to publish the page after creation."
operationId: CreateStatusPage
parameters:
- description: "Comma-separated list of resources to include. Supported values: created_by_user, last_modified_by_user."
Expand Down Expand Up @@ -127122,7 +127116,6 @@ paths:
type: component
domain_prefix: status-page-us1
email_header_image: data:image/png;base64,pQSLAw0KGgoAAAANSUhEUgAAAQ4AASJKFF
enabled: true
favicon: data:image/png;base64,kWMRNw0KGgoAAAANSUhEUgAAAEAAAABACA
name: Status Page US1
subscriptions_enabled: true
Expand Down
2 changes: 1 addition & 1 deletion api/datadogV2/api_status_pages.go
Original file line number Diff line number Diff line change
Expand Up @@ -381,7 +381,7 @@ func (r *CreateStatusPageOptionalParameters) WithInclude(include string) *Create
}

// CreateStatusPage Create status page.
// Creates a new status page. **Note**: Publishing a status page on creation via the `enabled` property will be deprecated. Use the dedicated [publish](#publish-status-page) status page endpoint after creation instead.
// Creates a new status page in an unpublished state. Use the dedicated [publish](#publish-status-page) status page endpoint to publish the page after creation.
func (a *StatusPagesApi) CreateStatusPage(ctx _context.Context, body CreateStatusPageRequest, o ...CreateStatusPageOptionalParameters) (StatusPage, *_nethttp.Response, error) {
var (
localVarHTTPMethod = _nethttp.MethodPost
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -20,8 +20,6 @@ type CreateStatusPageRequestDataAttributes struct {
DomainPrefix string `json:"domain_prefix"`
// Base64-encoded image data included in email notifications sent to status page subscribers.
EmailHeaderImage *string `json:"email_header_image,omitempty"`
// Whether the status page is enabled.
Enabled bool `json:"enabled"`
// Base64-encoded image data displayed in the browser tab.
Favicon *string `json:"favicon,omitempty"`
// The name of the status page.
Expand All @@ -41,10 +39,9 @@ type CreateStatusPageRequestDataAttributes struct {
// This constructor will assign default values to properties that have it defined,
// and makes sure properties required by API are set, but the set of arguments
// will change when the set of required properties is changed.
func NewCreateStatusPageRequestDataAttributes(domainPrefix string, enabled bool, name string, typeVar CreateStatusPageRequestDataAttributesType, visualizationType CreateStatusPageRequestDataAttributesVisualizationType) *CreateStatusPageRequestDataAttributes {
func NewCreateStatusPageRequestDataAttributes(domainPrefix string, name string, typeVar CreateStatusPageRequestDataAttributesType, visualizationType CreateStatusPageRequestDataAttributesVisualizationType) *CreateStatusPageRequestDataAttributes {
this := CreateStatusPageRequestDataAttributes{}
this.DomainPrefix = domainPrefix
this.Enabled = enabled
this.Name = name
this.Type = typeVar
this.VisualizationType = visualizationType
Expand Down Expand Up @@ -166,29 +163,6 @@ func (o *CreateStatusPageRequestDataAttributes) SetEmailHeaderImage(v string) {
o.EmailHeaderImage = &v
}

// GetEnabled returns the Enabled field value.
func (o *CreateStatusPageRequestDataAttributes) GetEnabled() bool {
if o == nil {
var ret bool
return ret
}
return o.Enabled
}

// GetEnabledOk returns a tuple with the Enabled field value
// and a boolean to check if the value has been set.
func (o *CreateStatusPageRequestDataAttributes) GetEnabledOk() (*bool, bool) {
if o == nil {
return nil, false
}
return &o.Enabled, true
}

// SetEnabled sets field value.
func (o *CreateStatusPageRequestDataAttributes) SetEnabled(v bool) {
o.Enabled = v
}

// GetFavicon returns the Favicon field value if set, zero value otherwise.
func (o *CreateStatusPageRequestDataAttributes) GetFavicon() string {
if o == nil || o.Favicon == nil {
Expand Down Expand Up @@ -330,7 +304,6 @@ func (o CreateStatusPageRequestDataAttributes) MarshalJSON() ([]byte, error) {
if o.EmailHeaderImage != nil {
toSerialize["email_header_image"] = o.EmailHeaderImage
}
toSerialize["enabled"] = o.Enabled
if o.Favicon != nil {
toSerialize["favicon"] = o.Favicon
}
Expand All @@ -354,7 +327,6 @@ func (o *CreateStatusPageRequestDataAttributes) UnmarshalJSON(bytes []byte) (err
Components []CreateStatusPageRequestDataAttributesComponentsItems `json:"components,omitempty"`
DomainPrefix *string `json:"domain_prefix"`
EmailHeaderImage *string `json:"email_header_image,omitempty"`
Enabled *bool `json:"enabled"`
Favicon *string `json:"favicon,omitempty"`
Name *string `json:"name"`
SubscriptionsEnabled *bool `json:"subscriptions_enabled,omitempty"`
Expand All @@ -367,9 +339,6 @@ func (o *CreateStatusPageRequestDataAttributes) UnmarshalJSON(bytes []byte) (err
if all.DomainPrefix == nil {
return fmt.Errorf("required field domain_prefix missing")
}
if all.Enabled == nil {
return fmt.Errorf("required field enabled missing")
}
if all.Name == nil {
return fmt.Errorf("required field name missing")
}
Expand All @@ -381,7 +350,7 @@ func (o *CreateStatusPageRequestDataAttributes) UnmarshalJSON(bytes []byte) (err
}
additionalProperties := make(map[string]interface{})
if err = datadog.Unmarshal(bytes, &additionalProperties); err == nil {
datadog.DeleteKeys(additionalProperties, &[]string{"company_logo", "components", "domain_prefix", "email_header_image", "enabled", "favicon", "name", "subscriptions_enabled", "type", "visualization_type"})
datadog.DeleteKeys(additionalProperties, &[]string{"company_logo", "components", "domain_prefix", "email_header_image", "favicon", "name", "subscriptions_enabled", "type", "visualization_type"})
} else {
return err
}
Expand All @@ -391,7 +360,6 @@ func (o *CreateStatusPageRequestDataAttributes) UnmarshalJSON(bytes []byte) (err
o.Components = all.Components
o.DomainPrefix = *all.DomainPrefix
o.EmailHeaderImage = all.EmailHeaderImage
o.Enabled = *all.Enabled
o.Favicon = all.Favicon
o.Name = *all.Name
o.SubscriptionsEnabled = all.SubscriptionsEnabled
Expand Down
1 change: 0 additions & 1 deletion examples/v2/status-pages/CreateStatusPage.go
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,6 @@ func main() {
Position: datadog.PtrInt64(1),
},
},
Enabled: true,
Type: datadogV2.CREATESTATUSPAGEREQUESTDATAATTRIBUTESTYPE_INTERNAL,
VisualizationType: datadogV2.CREATESTATUSPAGEREQUESTDATAATTRIBUTESVISUALIZATIONTYPE_BARS_AND_UPTIME_PERCENTAGE,
},
Expand Down
6 changes: 3 additions & 3 deletions examples/v2/status-pages/PublishStatusPage.go
Original file line number Diff line number Diff line change
Expand Up @@ -13,14 +13,14 @@ import (
)

func main() {
// there is a valid "unpublished_status_page" in the system
UnpublishedStatusPageDataID := uuid.MustParse(os.Getenv("UNPUBLISHED_STATUS_PAGE_DATA_ID"))
// there is a valid "status_page" in the system
StatusPageDataID := uuid.MustParse(os.Getenv("STATUS_PAGE_DATA_ID"))

ctx := datadog.NewDefaultContext(context.Background())
configuration := datadog.NewConfiguration()
apiClient := datadog.NewAPIClient(configuration)
api := datadogV2.NewStatusPagesApi(apiClient)
r, err := api.PublishStatusPage(ctx, UnpublishedStatusPageDataID)
r, err := api.PublishStatusPage(ctx, StatusPageDataID)

if err != nil {
fmt.Fprintf(os.Stderr, "Error when calling `StatusPagesApi.PublishStatusPage`: %v\n", err)
Expand Down
5 changes: 1 addition & 4 deletions examples/v2/status-pages/UnpublishStatusPage.go
Original file line number Diff line number Diff line change
Expand Up @@ -13,14 +13,11 @@ import (
)

func main() {
// there is a valid "status_page" in the system
StatusPageDataID := uuid.MustParse(os.Getenv("STATUS_PAGE_DATA_ID"))

ctx := datadog.NewDefaultContext(context.Background())
configuration := datadog.NewConfiguration()
apiClient := datadog.NewAPIClient(configuration)
api := datadogV2.NewStatusPagesApi(apiClient)
r, err := api.UnpublishStatusPage(ctx, StatusPageDataID)
r, err := api.UnpublishStatusPage(ctx, uuid.MustParse("9b1deb4d-3b7d-4bad-9bdd-2b0d7b3dcb6d"))

if err != nil {
fmt.Fprintf(os.Stderr, "Error when calling `StatusPagesApi.UnpublishStatusPage`: %v\n", err)
Expand Down
Original file line number Diff line number Diff line change
@@ -1 +1 @@
2026-03-31T18:43:45.443Z
2026-04-24T14:12:37.493Z
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
interactions:
- request:
body: |
{"data":{"attributes":{"components":[{"components":[{"name":"Login","position":0,"type":"component"},{"name":"Settings","position":1,"type":"component"}],"name":"Application","type":"group"}],"domain_prefix":"9dbd15ff66733c82","enabled":true,"name":"A Status Page","type":"internal","visualization_type":"bars_and_uptime_percentage"},"type":"status_pages"}}
{"data":{"attributes":{"components":[{"components":[{"name":"Login","position":0,"type":"component"},{"name":"Settings","position":1,"type":"component"}],"name":"Application","type":"group"}],"domain_prefix":"f456820b7958024f","name":"A Status Page","type":"internal","visualization_type":"bars_and_uptime_percentage"},"type":"status_pages"}}
form: {}
headers:
Accept:
Expand All @@ -12,8 +12,8 @@ interactions:
method: POST
url: https://api.datadoghq.com/api/v2/statuspages
response:
body: '{"data":{"id":"daae96b1-2114-4979-8668-2f782fe4a82b","type":"status_pages","attributes":{"company_logo":null,"components":[{"id":"0827c72a-5886-4850-b9a0-3c0b62fd5cbd","name":"Application","type":"group","position":0,"components":[{"id":"2944ac68-cc1f-43bc-9950-a81912daf613","name":"Login","type":"component","status":"operational","position":0},{"id":"7374a8e5-7d66-43be-83f0-4337a739bdfb","name":"Settings","type":"component","status":"operational","position":1}]}],"created_at":"2026-03-31T18:43:45.548049Z","custom_domain":null,"custom_domain_enabled":false,"domain_prefix":"9dbd15ff66733c82","email_header_image":null,"enabled":true,"favicon":null,"modified_at":"2026-03-31T18:43:45.548049Z","name":"A
Status Page","page_url":"https://frog.datadoghq.com/status-pages/daae96b1-2114-4979-8668-2f782fe4a82b/view","subscriptions_enabled":false,"type":"internal","visualization_type":"bars_and_uptime_percentage"},"relationships":{"created_by_user":{"data":{"id":"3ad549bf-eba0-11e9-a77a-0705486660d0","type":"users"}},"last_modified_by_user":{"data":{"id":"3ad549bf-eba0-11e9-a77a-0705486660d0","type":"users"}}}}}'
body: '{"data":{"id":"b02801ff-949d-467e-967d-5943c8f1c7af","type":"status_pages","attributes":{"company_logo":null,"components":[{"id":"7f96e5c3-f033-4640-bf8a-7018e134c8b5","name":"Application","type":"group","position":0,"components":[{"id":"feefa8d8-7485-4bfb-82a6-86268c1d68b3","name":"Login","type":"component","status":"operational","position":0},{"id":"b2f95a96-3261-40fb-bb5a-f95203741608","name":"Settings","type":"component","status":"operational","position":1}]}],"created_at":"2026-04-24T14:12:37.623742Z","custom_domain":null,"custom_domain_enabled":false,"domain_prefix":"f456820b7958024f","email_header_image":null,"enabled":false,"favicon":null,"modified_at":"2026-04-24T14:12:37.623742Z","name":"A
Status Page","page_url":"https://frog.datadoghq.com/status-pages/b02801ff-949d-467e-967d-5943c8f1c7af/view","subscriptions_enabled":false,"type":"internal","visualization_type":"bars_and_uptime_percentage"},"relationships":{"created_by_user":{"data":{"id":"3ad549bf-eba0-11e9-a77a-0705486660d0","type":"users"}},"last_modified_by_user":{"data":{"id":"3ad549bf-eba0-11e9-a77a-0705486660d0","type":"users"}}}}}'
code: 201
duration: 0ms
headers:
Expand All @@ -31,9 +31,9 @@ interactions:
- application/json
id: 1
method: POST
url: https://api.datadoghq.com/api/v2/statuspages/daae96b1-2114-4979-8668-2f782fe4a82b/components
url: https://api.datadoghq.com/api/v2/statuspages/b02801ff-949d-467e-967d-5943c8f1c7af/components
response:
body: '{"data":{"id":"dc1f6182-86a0-4f18-a4de-78f99ff1455f","type":"components","attributes":{"created_at":"2026-03-31T18:43:46.083871Z","modified_at":"2026-03-31T18:43:46.083871Z","name":"Logs","position":0,"status":"operational","type":"component"},"relationships":{"created_by_user":{"data":{"id":"3ad549bf-eba0-11e9-a77a-0705486660d0","type":"users"}},"group":{"data":null},"last_modified_by_user":{"data":{"id":"3ad549bf-eba0-11e9-a77a-0705486660d0","type":"users"}},"status_page":{"data":{"id":"daae96b1-2114-4979-8668-2f782fe4a82b","type":"status_pages"}}}}}'
body: '{"data":{"id":"ef964967-c6b6-465a-a260-0468b697036c","type":"components","attributes":{"created_at":"2026-04-24T14:12:38.188993Z","modified_at":"2026-04-24T14:12:38.188993Z","name":"Logs","position":0,"status":"operational","type":"component"},"relationships":{"created_by_user":{"data":{"id":"3ad549bf-eba0-11e9-a77a-0705486660d0","type":"users"}},"group":{"data":null},"last_modified_by_user":{"data":{"id":"3ad549bf-eba0-11e9-a77a-0705486660d0","type":"users"}},"status_page":{"data":{"id":"b02801ff-949d-467e-967d-5943c8f1c7af","type":"status_pages"}}}}}'
code: 201
duration: 0ms
headers:
Expand All @@ -48,7 +48,7 @@ interactions:
- '*/*'
id: 2
method: DELETE
url: https://api.datadoghq.com/api/v2/statuspages/daae96b1-2114-4979-8668-2f782fe4a82b/components/dc1f6182-86a0-4f18-a4de-78f99ff1455f
url: https://api.datadoghq.com/api/v2/statuspages/b02801ff-949d-467e-967d-5943c8f1c7af/components/ef964967-c6b6-465a-a260-0468b697036c
response:
body: ''
code: 204
Expand All @@ -63,7 +63,7 @@ interactions:
- '*/*'
id: 3
method: DELETE
url: https://api.datadoghq.com/api/v2/statuspages/daae96b1-2114-4979-8668-2f782fe4a82b
url: https://api.datadoghq.com/api/v2/statuspages/b02801ff-949d-467e-967d-5943c8f1c7af
response:
body: ''
code: 204
Expand Down
Original file line number Diff line number Diff line change
@@ -1 +1 @@
2026-03-31T18:43:46.834Z
2026-04-24T14:12:38.944Z
Loading
Loading