Skip to content
Merged
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
8 changes: 4 additions & 4 deletions .apigentools-info
Original file line number Diff line number Diff line change
Expand Up @@ -4,13 +4,13 @@
"spec_versions": {
"v1": {
"apigentools_version": "1.6.6",
"regenerated": "2023-12-27 15:08:50.488939",
"spec_repo_commit": "61dc4c3e"
"regenerated": "2023-12-28 18:22:58.398305",
"spec_repo_commit": "42c21a14"
},
"v2": {
"apigentools_version": "1.6.6",
"regenerated": "2023-12-27 15:08:50.504687",
"spec_repo_commit": "61dc4c3e"
"regenerated": "2023-12-28 18:22:58.412796",
"spec_repo_commit": "42c21a14"
}
}
}
30 changes: 23 additions & 7 deletions .generator/schemas/v1/openapi.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -22984,7 +22984,9 @@ paths:
x-codegen-request-body-name: body
/api/v1/downtime:
get:
description: Get all scheduled downtimes.
deprecated: true
description: Get all scheduled downtimes. **Note:** This endpoint has been deprecated.
Please use v2 endpoints.
operationId: ListDowntimes
parameters:
- description: Only return downtimes that are active when the request is made.
Expand Down Expand Up @@ -23025,7 +23027,9 @@ paths:
tags:
- Downtimes
post:
description: Schedule a downtime.
deprecated: true
description: Schedule a downtime. **Note:** This endpoint has been deprecated.
Please use v2 endpoints.
operationId: CreateDowntime
requestBody:
content:
Expand Down Expand Up @@ -23066,7 +23070,11 @@ paths:
x-codegen-request-body-name: body
/api/v1/downtime/cancel/by_scope:
post:
description: Delete all downtimes that match the scope of `X`.
deprecated: true
description: Delete all downtimes that match the scope of `X`. **Note:** This
only interacts with Downtimes created using v1 endpoints. This endpoint has
been deprecated and will not be replaced. Please use v2 endpoints to find
and cancel downtimes.
operationId: CancelDowntimesByScope
requestBody:
content:
Expand Down Expand Up @@ -23113,7 +23121,9 @@ paths:
x-codegen-request-body-name: body
/api/v1/downtime/{downtime_id}:
delete:
description: Cancel a downtime.
deprecated: true
description: Cancel a downtime. **Note:** This endpoint has been deprecated.
Please use v2 endpoints.
operationId: CancelDowntime
parameters:
- description: ID of the downtime to cancel.
Expand Down Expand Up @@ -23150,7 +23160,9 @@ paths:
tags:
- Downtimes
get:
description: Get downtime detail by `downtime_id`.
deprecated: true
description: Get downtime detail by `downtime_id`. **Note:** This endpoint has
been deprecated. Please use v2 endpoints.
operationId: GetDowntime
parameters:
- description: ID of the downtime to fetch.
Expand Down Expand Up @@ -23191,7 +23203,9 @@ paths:
tags:
- Downtimes
put:
description: Update a single downtime by `downtime_id`.
deprecated: true
description: Update a single downtime by `downtime_id`. **Note:** This endpoint
has been deprecated. Please use v2 endpoints.
operationId: UpdateDowntime
parameters:
- description: ID of the downtime to update.
Expand Down Expand Up @@ -27176,7 +27190,9 @@ paths:
x-codegen-request-body-name: body
/api/v1/monitor/{monitor_id}/downtimes:
get:
description: Get all active downtimes for the specified monitor.
deprecated: true
description: Get all active v1 downtimes for the specified monitor. **Note:**
This endpoint has been deprecated. Please use v2 endpoints.
operationId: ListMonitorDowntimes
parameters:
- description: The id of the monitor
Expand Down
35 changes: 28 additions & 7 deletions lib/datadog_api_client/v1/api/downtimes_api.rb
Original file line number Diff line number Diff line change
Expand Up @@ -33,12 +33,15 @@ def cancel_downtime(downtime_id, opts = {})

# Cancel a downtime.
#
# Cancel a downtime.
# Cancel a downtime. **Note:** This endpoint has been deprecated. Please use v2 endpoints.
#
# @deprecated This API is deprecated.
#
# @param downtime_id [Integer] ID of the downtime to cancel.
# @param opts [Hash] the optional parameters
# @return [Array<(nil, Integer, Hash)>] nil, response status code and response headers
def cancel_downtime_with_http_info(downtime_id, opts = {})
warn "[DEPRECATION] `CancelDowntime` is deprecated."

if @api_client.config.debugging
@api_client.config.logger.debug 'Calling API: DowntimesAPI.cancel_downtime ...'
Expand Down Expand Up @@ -98,12 +101,15 @@ def cancel_downtimes_by_scope(body, opts = {})

# Cancel downtimes by scope.
#
# Delete all downtimes that match the scope of `X`.
# Delete all downtimes that match the scope of `X`. **Note:** This only interacts with Downtimes created using v1 endpoints. This endpoint has been deprecated and will not be replaced. Please use v2 endpoints to find and cancel downtimes.
#
# @deprecated This API is deprecated.
#
# @param body [CancelDowntimesByScopeRequest] Scope to cancel downtimes for.
# @param opts [Hash] the optional parameters
# @return [Array<(CanceledDowntimesIds, Integer, Hash)>] CanceledDowntimesIds data, response status code and response headers
def cancel_downtimes_by_scope_with_http_info(body, opts = {})
warn "[DEPRECATION] `CancelDowntimesByScope` is deprecated."

if @api_client.config.debugging
@api_client.config.logger.debug 'Calling API: DowntimesAPI.cancel_downtimes_by_scope ...'
Expand Down Expand Up @@ -165,12 +171,15 @@ def create_downtime(body, opts = {})

# Schedule a downtime.
#
# Schedule a downtime.
# Schedule a downtime. **Note:** This endpoint has been deprecated. Please use v2 endpoints.
#
# @deprecated This API is deprecated.
#
# @param body [Downtime] Schedule a downtime request body.
# @param opts [Hash] the optional parameters
# @return [Array<(Downtime, Integer, Hash)>] Downtime data, response status code and response headers
def create_downtime_with_http_info(body, opts = {})
warn "[DEPRECATION] `CreateDowntime` is deprecated."

if @api_client.config.debugging
@api_client.config.logger.debug 'Calling API: DowntimesAPI.create_downtime ...'
Expand Down Expand Up @@ -232,12 +241,15 @@ def get_downtime(downtime_id, opts = {})

# Get a downtime.
#
# Get downtime detail by `downtime_id`.
# Get downtime detail by `downtime_id`. **Note:** This endpoint has been deprecated. Please use v2 endpoints.
#
# @deprecated This API is deprecated.
#
# @param downtime_id [Integer] ID of the downtime to fetch.
# @param opts [Hash] the optional parameters
# @return [Array<(Downtime, Integer, Hash)>] Downtime data, response status code and response headers
def get_downtime_with_http_info(downtime_id, opts = {})
warn "[DEPRECATION] `GetDowntime` is deprecated."

if @api_client.config.debugging
@api_client.config.logger.debug 'Calling API: DowntimesAPI.get_downtime ...'
Expand Down Expand Up @@ -297,13 +309,16 @@ def list_downtimes(opts = {})

# Get all downtimes.
#
# Get all scheduled downtimes.
# Get all scheduled downtimes. **Note:** This endpoint has been deprecated. Please use v2 endpoints.
#
# @deprecated This API is deprecated.
#
# @param opts [Hash] the optional parameters
# @option opts [Boolean] :current_only Only return downtimes that are active when the request is made.
# @option opts [Boolean] :with_creator Return creator information.
# @return [Array<(Array<Downtime>, Integer, Hash)>] Array<Downtime> data, response status code and response headers
def list_downtimes_with_http_info(opts = {})
warn "[DEPRECATION] `ListDowntimes` is deprecated."

if @api_client.config.debugging
@api_client.config.logger.debug 'Calling API: DowntimesAPI.list_downtimes ...'
Expand Down Expand Up @@ -361,12 +376,15 @@ def list_monitor_downtimes(monitor_id, opts = {})

# Get active downtimes for a monitor.
#
# Get all active downtimes for the specified monitor.
# Get all active v1 downtimes for the specified monitor. **Note:** This endpoint has been deprecated. Please use v2 endpoints.
#
# @deprecated This API is deprecated.
#
# @param monitor_id [Integer] The id of the monitor
# @param opts [Hash] the optional parameters
# @return [Array<(Array<Downtime>, Integer, Hash)>] Array<Downtime> data, response status code and response headers
def list_monitor_downtimes_with_http_info(monitor_id, opts = {})
warn "[DEPRECATION] `ListMonitorDowntimes` is deprecated."

if @api_client.config.debugging
@api_client.config.logger.debug 'Calling API: DowntimesAPI.list_monitor_downtimes ...'
Expand Down Expand Up @@ -426,13 +444,16 @@ def update_downtime(downtime_id, body, opts = {})

# Update a downtime.
#
# Update a single downtime by `downtime_id`.
# Update a single downtime by `downtime_id`. **Note:** This endpoint has been deprecated. Please use v2 endpoints.
#
# @deprecated This API is deprecated.
#
# @param downtime_id [Integer] ID of the downtime to update.
# @param body [Downtime] Update a downtime request body.
# @param opts [Hash] the optional parameters
# @return [Array<(Downtime, Integer, Hash)>] Downtime data, response status code and response headers
def update_downtime_with_http_info(downtime_id, body, opts = {})
warn "[DEPRECATION] `UpdateDowntime` is deprecated."

if @api_client.config.debugging
@api_client.config.logger.debug 'Calling API: DowntimesAPI.update_downtime ...'
Expand Down