v1
latestOpenAPI 3.0.02026-07-141,4077,1665.2 MBMetrics
Update a tag indexing rule
Partially update a tag indexing rule. Fields omitted from the request body are left unchanged. Setting rule_order to a value already used by another rule returns 409; use the reorder endpoint for atomic re-sequencing. Requires the Manage Tags for Metrics permission.
put/api/v2/metrics/tag-indexing-rules/{id}
Path parameters
idstring required
ID of the tag indexing rule.
Request body
Example request
{
"data": {
"attributes": {
"metric_name_matches": [
"dd.test.*"
],
"name": "my-indexing-rule",
"options": {
"data": {
"dynamic_tags": {
"queried_tags_window_seconds": 3600
},
"manage_preexisting_metrics": true,
"metric_match": {
"queried_window_seconds": 3600
}
},
"version": 1
},
"rule_order": 2,
"tags": [
"env",
"service"
]
},
"type": "tag_indexing_rules"
}
}Response
OK
Example response
{
"data": {
"attributes": {
"created_at": "2024-01-15T12:00:00.000Z",
"created_by_handle": "user@datadoghq.com",
"ignored_metric_name_matches": [
"dd.test.excluded.*"
],
"metric_name_matches": [
"dd.test.*"
],
"modified_at": "2024-01-15T12:00:00.000Z",
"modified_by_handle": "user@datadoghq.com",
"name": "my-indexing-rule",
"options": {
"data": {
"dynamic_tags": {
"queried_tags_window_seconds": 3600
},
"manage_preexisting_metrics": true,
"metric_match": {
"queried_window_seconds": 3600
}
},
"version": 1
},
"rule_order": 1,
"tags": [
"env",
"service"
]
},
"id": "00000000-0000-0000-0000-000000000001",
"type": "tag_indexing_rules"
}
}