DataDog / terraform-provider-datadog

Terraform Datadog provider
https://www.terraform.io/docs/providers/datadog/
Mozilla Public License 2.0
403 stars 380 forks source link

Feature Request: Add Cloud Cost Management Integration #2051

Open matt-long-92 opened 1 year ago

matt-long-92 commented 1 year ago

What resources or data sources are affected?

Add Cloud Cost Management Integration

Feature Request

Please add a resource for Cloud Cost Management so that it can be managed via Terraform.

References

No response

therve commented 1 year ago

Hi,

I forwarded the request to the CCM team, as we're lacking an API to do this operation. Thanks for your feedback.

josh-mcq commented 11 months ago

Hi,

I forwarded the request to the CCM team, as we're lacking an API to do this operation. Thanks for your feedback.

It is now possible to create widgets with data_source: cloud_cost via the api. Is this the functionality required for this provider to support cloud cost widgets?

` curl -X POST "https://api.datadoghq.com/api/v1/dashboard" \ -H "Accept: application/json" \ -H "Content-Type: application/json" \ -H "DD-API-KEY: ${DD_API_KEY}" \ -H "DD-APPLICATION-KEY: ${DD_APP_KEY}" \ -d @- << EOF { "title": "dashboard-cloudcost-widget", "description": "dashboard with cloudcost widget", "widgets": [ { "definition": { "type": "timeseries", "requests": [ { "response_format": "timeseries", "queries": [ { "data_source": "cloud_cost", "name": "query1", "query": "sum:aws.cost.net.amortized{aws_product:lambda}.rollup(sum, weekly)" } ] } ] } } ], "layout_type": "ordered" } EOF

{"id":"585-dk8-e44","title":"dashboard-cloudcost-widget","description":"dashboard with cloudcost widget","author_handle":"josh-mcq","layout_type":"ordered","url":"/dashboard/585-dk8-e44/dashboard-cloudcost-widget","is_read_only":false,"template_variables":null,"widgets":[{"definition":{"type":"timeseries","requests":[{"response_format":"timeseries","queries":[{"data_source":"cloud_cost","name":"query1","query":"sum:aws.cost.net.amortized{aws_product:lambda}.rollup(sum, weekly)"}]}]},"id":669022218144393}],"notify_list":null,"created_at":"2023-12-07T19:50:23.986766+00:00","modified_at":"2023-12-07T19:50:23.986766+00:00","restricted_roles":[]} `

therve commented 11 months ago

Hi,

For dashboards the cloud_cost datasource has been available for a while. This is for managing cloud cost itself.

0robustus1 commented 3 weeks ago

It seems there is (now) an API for this:

Is there an ETA on adding this support to the provider as well?