Skip to content

Commit 9c34ec6

Browse files
api-clients-generation-pipeline[bot]ci.datadog-api-spec
andauthored
document v2 stable mcnulty-web-py3 endpoints (#3174)
Co-authored-by: ci.datadog-api-spec <packages@datadoghq.com>
1 parent 218ba8f commit 9c34ec6

File tree

65 files changed

+7848
-0
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

65 files changed

+7848
-0
lines changed

.generator/schemas/v2/openapi.yaml

Lines changed: 1287 additions & 0 deletions
Large diffs are not rendered by default.
Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
# Get parent tests for a subtest returns "OK" response
2+
3+
require "datadog_api_client"
4+
api_instance = DatadogAPIClient::V2::SyntheticsAPI.new
5+
p api_instance.get_api_multistep_subtest_parents("public_id")
Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
# Get available subtests for a multistep test returns "OK" response
2+
3+
require "datadog_api_client"
4+
api_instance = DatadogAPIClient::V2::SyntheticsAPI.new
5+
p api_instance.get_api_multistep_subtests("public_id")
Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
# Get a specific version of a test returns "OK" response
2+
3+
require "datadog_api_client"
4+
api_instance = DatadogAPIClient::V2::SyntheticsAPI.new
5+
p api_instance.get_synthetics_test_version("public_id", 9223372036854775807)
Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
# Get parent suites for a test returns "OK" response
2+
3+
require "datadog_api_client"
4+
api_instance = DatadogAPIClient::V2::SyntheticsAPI.new
5+
p api_instance.get_test_parent_suites("public_id")
Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
# Get version history of a test returns "OK" response
2+
3+
require "datadog_api_client"
4+
api_instance = DatadogAPIClient::V2::SyntheticsAPI.new
5+
p api_instance.list_synthetics_test_versions("public_id")
Lines changed: 19 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,19 @@
1+
# Patch a test suite returns "OK" response
2+
3+
require "datadog_api_client"
4+
api_instance = DatadogAPIClient::V2::SyntheticsAPI.new
5+
6+
body = DatadogAPIClient::V2::SuiteJsonPatchRequest.new({
7+
data: DatadogAPIClient::V2::SuiteJsonPatchRequestData.new({
8+
attributes: DatadogAPIClient::V2::SuiteJsonPatchRequestDataAttributes.new({
9+
json_patch: [
10+
DatadogAPIClient::V2::JsonPatchOperation.new({
11+
op: DatadogAPIClient::V2::JsonPatchOperationOp::ADD,
12+
path: "/name",
13+
}),
14+
],
15+
}),
16+
type: DatadogAPIClient::V2::SuiteJsonPatchType::SUITES_JSON_PATCH,
17+
}),
18+
})
19+
p api_instance.patch_test_suite("123-abc-456", body)
Lines changed: 18 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,18 @@
1+
# Create a widget returns "OK" response
2+
3+
require "datadog_api_client"
4+
api_instance = DatadogAPIClient::V2::WidgetsAPI.new
5+
6+
body = DatadogAPIClient::V2::CreateOrUpdateWidgetRequest.new({
7+
data: DatadogAPIClient::V2::CreateOrUpdateWidgetRequestData.new({
8+
attributes: DatadogAPIClient::V2::CreateOrUpdateWidgetRequestAttributes.new({
9+
definition: DatadogAPIClient::V2::WidgetDefinition.new({
10+
title: "My Widget",
11+
type: DatadogAPIClient::V2::WidgetType::BAR_CHART,
12+
}),
13+
tags: [],
14+
}),
15+
type: "widgets",
16+
}),
17+
})
18+
p api_instance.create_widget(WidgetExperienceType::CCM_REPORTS, body)
Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
# Delete a widget returns "No Content" response
2+
3+
require "datadog_api_client"
4+
api_instance = DatadogAPIClient::V2::WidgetsAPI.new
5+
api_instance.delete_widget(WidgetExperienceType::CCM_REPORTS, "9b1deb4d-3b7d-4bad-9bdd-2b0d7b3dcb6d")

examples/v2/widgets/GetWidget.rb

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
# Get a widget returns "OK" response
2+
3+
require "datadog_api_client"
4+
api_instance = DatadogAPIClient::V2::WidgetsAPI.new
5+
p api_instance.get_widget(WidgetExperienceType::CCM_REPORTS, "9b1deb4d-3b7d-4bad-9bdd-2b0d7b3dcb6d")

0 commit comments

Comments
 (0)