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
548 changes: 540 additions & 8 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-06-22T19:51:31.598Z

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

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

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

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

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

8 changes: 8 additions & 0 deletions examples/v2/cloud-cost-management/DeleteCustomForecast.rb
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
# Delete a budget's custom forecast returns "No Content" response

require "datadog_api_client"
DatadogAPIClient.configure do |config|
config.unstable_operations["v2.delete_custom_forecast".to_sym] = true
end
api_instance = DatadogAPIClient::V2::CloudCostManagementAPI.new
api_instance.delete_custom_forecast("budget_id")
14 changes: 14 additions & 0 deletions examples/v2/cloud-cost-management/UpsertBudget.rb
Original file line number Diff line number Diff line change
Expand Up @@ -6,11 +6,25 @@
body = DatadogAPIClient::V2::BudgetWithEntries.new({
data: DatadogAPIClient::V2::BudgetWithEntriesData.new({
attributes: DatadogAPIClient::V2::BudgetAttributes.new({
costs: DatadogAPIClient::V2::BudgetAttributesCosts.new({
actual: nil,
amount: nil,
forecast: nil,
ootb_forecast: nil,
}),
costs_unit: DatadogAPIClient::V2::BudgetAttributesCostsUnit.new({}),
created_at: 1738258683590,
created_by: "00000000-0a0a-0a0a-aaa0-00000000000a",
end_month: 202502,
entries: [
DatadogAPIClient::V2::BudgetWithEntriesDataAttributesEntriesItems.new({
costs: DatadogAPIClient::V2::BudgetWithEntriesDataAttributesEntriesItemsCosts.new({
actual: nil,
amount: nil,
custom_forecast: nil,
forecast: nil,
ootb_forecast: nil,
}),
tag_filters: [
DatadogAPIClient::V2::BudgetWithEntriesDataAttributesEntriesItemsTagFiltersItems.new({}),
],
Expand Down
30 changes: 30 additions & 0 deletions examples/v2/cloud-cost-management/UpsertCustomForecast.rb
Original file line number Diff line number Diff line change
@@ -0,0 +1,30 @@
# Create or replace a budget's custom forecast returns "OK" response

require "datadog_api_client"
DatadogAPIClient.configure do |config|
config.unstable_operations["v2.upsert_custom_forecast".to_sym] = true
end
api_instance = DatadogAPIClient::V2::CloudCostManagementAPI.new

body = DatadogAPIClient::V2::CustomForecastUpsertRequest.new({
data: DatadogAPIClient::V2::CustomForecastUpsertRequestData.new({
attributes: DatadogAPIClient::V2::CustomForecastUpsertRequestDataAttributes.new({
budget_uid: "00000000-0000-0000-0000-000000000001",
entries: [
DatadogAPIClient::V2::CustomForecastEntry.new({
amount: 400,
month: 202501,
tag_filters: [
DatadogAPIClient::V2::CustomForecastEntryTagFilter.new({
tag_key: "service",
tag_value: "ec2",
}),
],
}),
],
}),
id: "",
type: DatadogAPIClient::V2::CustomForecastType::CUSTOM_FORECAST,
}),
})
p api_instance.upsert_custom_forecast(body)
Loading
Loading