GET /api/virtual-tags/dimensions
Auth:reader
Returns all available virtual tag dimensions. Each dimension is a reusable business axis such as BusinessRegion, CostCenter, Application, Owner, or Environment.
Example response
POST /api/virtual-tags/dimensions
Auth:admin
Creates or updates a virtual tag dimension.
Request body
Pass a dimension definition object as a JSON body. Key fields:Responses
DELETE /api/virtual-tags/dimensions/
Auth:admin
Soft-deletes a virtual tag dimension. The dimension is marked inactive rather than physically removed, preserving existing rule and override history.
Path parameter
Responses
GET /api/virtual-tags/rules
Auth:admin
Returns all virtual tag rules. Each rule is an effective-dated, prioritized include or exclude assignment for a dimension. Rules support nested AND/OR condition groups evaluated against subscription, resource group, resource type, region, resource name, native tag key/value, service name, meter category, and billing scope.
Example response (truncated)
POST /api/virtual-tags/rules
Auth:admin
Creates or updates a virtual tag rule. Saving a rule creates a new version; edits, activation, and deactivation increment the version and append audit records.
Request body
Pass a rule definition object. Key fields:
Supported condition fields:
subscriptionId, subscriptionName, resourceGroup, resourceType, region, resourceName, tagKey, tagValue, serviceName, meterCategory, billingScope
Supported operators: equals, not_equals, contains, starts_with, in, exists, not_exists
Responses
POST /api/virtual-tags/rules//status
Auth:admin
Activates or deactivates an existing rule. Deactivated rules do not participate in evaluation.
Path parameter
Request body
Responses
DELETE /api/virtual-tags/rules/
Auth:admin
Soft-deletes a rule, setting its status to inactive. The rule history and audit records are preserved.
Path parameter
Responses
POST /api/virtual-tags/preview
Auth:admin
Evaluates a rule definition against the current inventory without saving it. Returns the affected-resource count, total inventory count, a resource sample, and the current monthly ActualCost for matching resources. Use this before saving a new rule to understand its impact.
Request body
Pass the same rule definition object asPOST /api/virtual-tags/rules. The rule is not persisted.
Example response
Responses
GET /api/virtual-tags/effective
Auth:reader
Returns the effective virtual tag values for a single resource with precedence fully applied: manual overrides take highest precedence, followed by imported overrides, matching rules (lowest numeric priority first), and finally Azure native tags.
Query parameters
Example request
Example response
POST /api/virtual-tags/overrides/import
Auth:admin
Bulk-imports resource-specific tag overrides. Overrides are the highest-precedence source below manual assignments and are commonly imported from a spreadsheet or external system. The full previous state is returned in the response so that a rollback can be performed if needed.
Request body
Each override object:
Responses
POST /api/virtual-tags/overrides/rollback
Auth:admin
Rolls back a previous import by restoring the prior state. Pass the previous array returned by the import response. Uses optimistic concurrency — the rollback fails if the current state no longer matches what was captured.
Request body
Responses
GET /api/reports/virtual-tags
Auth:reader
Returns the virtual tag showback report for a dimension and optional value filter. The report includes cost totals by value, a classified/unclassified breakdown, monthly cost history, and per-resource cost with assignment provenance. Historical charge rows are evaluated through the current effective tag set; this is current-state reclassification, not point-in-time reconstruction.
Query parameters
Example request
Example response (truncated)
GET /api/reports/virtual-tags/export
Auth:reader
Streams the virtual tag showback report as a CSV download. Accepts the same query parameters as GET /api/reports/virtual-tags.
The CSV columns are: dimension, value, resource_id, resource_name, subscription, resource_group, resource_type, source, cost, currency, cost_type.
Query parameters
Same asGET /api/reports/virtual-tags: dimension, value, costType, startDate, endDate.