You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
How to get the Query value widget through datadog api #1915
I already have the Datadog dashboard in that we have few widgets which was created to show the trace count query.
I am planning to get the value of the trace count query through Datadog Api using postman. like how we get the details of a dashboard by giving the dashboard id.
I have used the get dashboard Api call through postman, I can the widget and the query also, but I am not getting the value in the response.
Can someone help me in getting the query value from widget trace count?
Hi there, you can try using the query_scalar_data function of the Metrics API - docs here. There's some more info about the endpoint here, and an example usage here.
Hopefully that helps, feel free to reach out if you run into any issues.
This issue has been automatically marked as stale because it has not had activity in the last 30 days. Note that the issue will not be automatically closed, but this notification will remind us to investigate why there's been inactivity. Thank you for participating in the Datadog open source community.
If you would like this issue to remain open:
Verify that you can still reproduce the issue in the latest version of this project.
Comment that the issue is still reproducible and include updated details requested in the issue template.
This issue has been automatically marked as stale because it has not had activity in the last 30 days. Note that the issue will not be automatically closed, but this notification will remind us to investigate why there's been inactivity. Thank you for participating in the Datadog open source community.
If you would like this issue to remain open:
Verify that you can still reproduce the issue in the latest version of this project.
Comment that the issue is still reproducible and include updated details requested in the issue template.
Activity
nkzou commentedon Mar 22, 2024
Hi there, you can try using the
query_scalar_datafunction of the Metrics API - docs here. There's some more info about the endpoint here, and an example usage here.Hopefully that helps, feel free to reach out if you run into any issues.
github-actions commentedon Apr 22, 2024
Thanks for your contribution!
This issue has been automatically marked as stale because it has not had activity in the last 30 days. Note that the issue will not be automatically closed, but this notification will remind us to investigate why there's been inactivity. Thank you for participating in the Datadog open source community.
If you would like this issue to remain open:
Verify that you can still reproduce the issue in the latest version of this project.
Comment that the issue is still reproducible and include updated details requested in the issue template.
felipefrodrigues commentedon Feb 5, 2025
Hello @kumarsyamala
Did you find any solution ?
kumarsyamala commentedon Feb 5, 2025
@felipefrodrigues No
I couldn't find the solution
I looked everywhere but didn't find it
felipefrodrigues commentedon Feb 5, 2025
I need to extract data from the widget and I consulted queryscalardata as @nkzou recommended
look at this example: https://github.com/DataDog/datadog-api-client-python/blob/master/examples/v2/metrics/QueryScalarData.py
I used this to create my script and it worked
main script
script to get the dashboard:
Script to extract widget data
I hope it helps you
github-actions commentedon Mar 9, 2025
Thanks for your contribution!
This issue has been automatically marked as stale because it has not had activity in the last 30 days. Note that the issue will not be automatically closed, but this notification will remind us to investigate why there's been inactivity. Thank you for participating in the Datadog open source community.
If you would like this issue to remain open:
Verify that you can still reproduce the issue in the latest version of this project.
Comment that the issue is still reproducible and include updated details requested in the issue template.