dcloud billing costs queryCost over time, grouped and filtered by any dimension
Dimensions: service, usageType, resource, resourceType, region, zone, project, tag (with tagKey), creator. Returns the stacked series, group totals vs the previous period of equal length, top movers by group and by resource, anomaly hints with the rule spelled out, a month-end forecast, discounts and credits, every billed resource with idle/detached/untagged hints, and the budgets. Amounts are EUR strings at 8 decimal places, exact. A read behind a POST: nothing is written.
Synopsis
dcloud billing costs query --start start --end end [flags]Flags
--startRequiredstring
First day of the window, YYYY-MM-DD, UTC, inclusive
Constraints: /^\d{4}-\d{2}-\d{2}$/
--endRequiredstring
Last day of the window, YYYY-MM-DD, UTC, inclusive; not before start, and the window is at most 400 days
Constraints: /^\d{4}-\d{2}-\d{2}$/
--granularityOptionalenum
Width of each bar: hour (windows of at most 14 days), day (default) or month
One of:
hour,day,monthDefault:
"day"--group-byOptionalobject
What the bars are stacked by: {dimension, tagKey}; default {dimension: service}
Constraints: JSON
Default:
{"dimension":"service"}--filtersOptionalarray of json
Narrow to rows matching every filter, at most 20: {dimension, values, tagKey, exclude}; default none
Default:
[]--max-groupsOptionalnumber
Groups drawn on their own, 1–50 (default 8); the rest are summed into "Other"
Constraints: integer, 1-50
Default:
8
Example
dcloud billing costs query --start example --end exampleGenerated from the API description, the same one the API checks requests against and the CLI is built from.