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
980 changes: 980 additions & 0 deletions .generator/schemas/v2/openapi.yaml

Large diffs are not rendered by default.

Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
2026-01-16T00:21:52.989Z

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
2026-01-16T00:21:53.514Z

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
2026-01-16T00:23:39.895Z

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
2026-01-16T00:21:54.756Z

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
2026-01-16T00:21:55.952Z

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
2026-01-16T00:21:56.916Z

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

20 changes: 20 additions & 0 deletions examples/v2/web-integrations/CreateWebIntegrationAccount.rb
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
# Create integration account returns "Created: The account was successfully created." response

require "datadog_api_client"
api_instance = DatadogAPIClient::V2::WebIntegrationsAPI.new

body = DatadogAPIClient::V2::WebIntegrationAccountCreateRequest.new({
data: DatadogAPIClient::V2::WebIntegrationAccountCreateRequestData.new({
attributes: DatadogAPIClient::V2::WebIntegrationAccountCreateRequestAttributes.new({
name: "My Production Account",
secrets: {
"api_key_token": "xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx",
},
settings: {
"account_sid": "ACxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx", "alerts": "True", "api_key": "SKxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx", "call_summaries": "True", "ccm_enabled": "True", "censor_logs": "True", "events": "True", "messages": "True",
},
}),
type: DatadogAPIClient::V2::WebIntegrationAccountType::ACCOUNT,
}),
})
p api_instance.create_web_integration_account("integration_name", body)
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
# Create integration account returns "Created" response

require "datadog_api_client"
api_instance = DatadogAPIClient::V2::WebIntegrationsAPI.new

body = DatadogAPIClient::V2::WebIntegrationAccountCreateRequest.new({
data: DatadogAPIClient::V2::WebIntegrationAccountCreateRequestData.new({
type: DatadogAPIClient::V2::WebIntegrationAccountType::ACCOUNT,
attributes: DatadogAPIClient::V2::WebIntegrationAccountCreateRequestAttributes.new({
name: "Example-Web-Integration",
settings: {
"api_key": "SKxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx", "account_sid": "ACxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx", "events": "True", "messages": "True", "alerts": "True", "call_summaries": "True", "ccm_enabled": "True", "censor_logs": "True",
},
secrets: {
"api_key_token": "test_secret_token",
},
}),
}),
})
p api_instance.create_web_integration_account("twilio", body)
5 changes: 5 additions & 0 deletions examples/v2/web-integrations/DeleteWebIntegrationAccount.rb
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
# Delete integration account returns "OK: The account was successfully deleted." response

require "datadog_api_client"
api_instance = DatadogAPIClient::V2::WebIntegrationsAPI.new
p api_instance.delete_web_integration_account("integration_name", "account_id")
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
# Delete integration account returns "OK" response

require "datadog_api_client"
api_instance = DatadogAPIClient::V2::WebIntegrationsAPI.new

# there is a valid "web_integration_account" in the system
WEB_INTEGRATION_ACCOUNT_DATA_ID = ENV["WEB_INTEGRATION_ACCOUNT_DATA_ID"]
p api_instance.delete_web_integration_account("twilio", WEB_INTEGRATION_ACCOUNT_DATA_ID)
5 changes: 5 additions & 0 deletions examples/v2/web-integrations/GetWebIntegrationAccount.rb
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
# Get integration account returns "OK: The account details for the specified integration." response

require "datadog_api_client"
api_instance = DatadogAPIClient::V2::WebIntegrationsAPI.new
p api_instance.get_web_integration_account("integration_name", "account_id")
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
# Get account schema for an integration returns "OK: The JSON schema for the integration's account configuration."
response

require "datadog_api_client"
api_instance = DatadogAPIClient::V2::WebIntegrationsAPI.new
p api_instance.get_web_integration_account_schema("integration_name")
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
# Get account schema for an integration returns "OK" response

require "datadog_api_client"
api_instance = DatadogAPIClient::V2::WebIntegrationsAPI.new
p api_instance.get_web_integration_account_schema("twilio")
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
# Get integration account returns "OK" response

require "datadog_api_client"
api_instance = DatadogAPIClient::V2::WebIntegrationsAPI.new

# there is a valid "web_integration_account" in the system
WEB_INTEGRATION_ACCOUNT_DATA_ID = ENV["WEB_INTEGRATION_ACCOUNT_DATA_ID"]
p api_instance.get_web_integration_account("twilio", WEB_INTEGRATION_ACCOUNT_DATA_ID)
5 changes: 5 additions & 0 deletions examples/v2/web-integrations/ListWebIntegrationAccounts.rb
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
# List integration accounts returns "OK: List of all accounts for the specified integration." response

require "datadog_api_client"
api_instance = DatadogAPIClient::V2::WebIntegrationsAPI.new
p api_instance.list_web_integration_accounts("integration_name")
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
# List integration accounts returns "OK" response

require "datadog_api_client"
api_instance = DatadogAPIClient::V2::WebIntegrationsAPI.new
p api_instance.list_web_integration_accounts("twilio")
20 changes: 20 additions & 0 deletions examples/v2/web-integrations/UpdateWebIntegrationAccount.rb
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
# Update integration account returns "OK: The account was successfully updated." response

require "datadog_api_client"
api_instance = DatadogAPIClient::V2::WebIntegrationsAPI.new

body = DatadogAPIClient::V2::WebIntegrationAccountUpdateRequest.new({
data: DatadogAPIClient::V2::WebIntegrationAccountUpdateRequestData.new({
attributes: DatadogAPIClient::V2::WebIntegrationAccountUpdateRequestAttributes.new({
name: "My Production Account (Updated)",
secrets: {
"api_key_token": "new_secret_token_value",
},
settings: {
"ccm_enabled": "True", "events": "True", "messages": "False",
},
}),
type: DatadogAPIClient::V2::WebIntegrationAccountType::ACCOUNT,
}),
})
p api_instance.update_web_integration_account("integration_name", "account_id", body)
Loading
Loading