v1
latestOpenAPI 3.0.02026-07-141,4077,1665.2 MBReporting And Sharing
Create a graph snapshot
Create a snapshot of a graph widget. The snapshot is rendered asynchronously; the returned URL can be polled until the image is ready.
post/api/v2/snapshot
Request body
Example request
{
"data": {
"attributes": {
"additional_config": {
"template_variables": [
{
"name": "host",
"prefix": "host",
"values": [
"web-server-1",
"web-server-2"
]
}
],
"timeseries_legend_type": "expanded",
"timezone_offset_minutes": 300
},
"end": 1692464800000,
"height": 185,
"start": 1692464000000,
"ttl": "60d",
"widget_definition": {
"requests": [
{
"q": "avg:system.cpu.user{*}"
}
],
"type": "timeseries"
},
"width": 300
},
"type": "create_snapshot"
}
}Response
OK
Example response
{
"data": {
"attributes": {
"url": "https://app.datadoghq.com/api/v2/snapshot/view/public/60d/00000000-0000-0000-0000-000000000000/1692464400000-12345678-1234-5678-9abc-def123456789.png"
},
"id": "12345678-1234-5678-9abc-def123456789",
"type": "create_snapshot"
}
}