Hello Francisco,
Even though volumes in the allocated state have not yet been created in
any storage, they are already considered as owned by the account and
could, therefore, be subject to billing, as shown in the following
example:
I created a data volume and did not attach it to a VM (keeping it on the
Allocated state).
"volume": [
{
"account": "admin",
"created": "2023-11-09T19:42:18+0000",
"destroyed": false,
"diskofferingdisplaytext": "Small Disk, 5 GB",
"diskofferingid": "7eec9944-9edf-4428-b894-54961ab19571",
"diskofferingname": "Small",
"displayvolume": true,
"domain": "ROOT",
"domainid": "72b54c4a-771d-11ee-8e59-5254003754dc",
"hasannotations": false,
"hypervisor": "None",
"id": "0ff8ac1c-5ff7-4a2c-b0de-d6931d3567fb",
"isextractable": true,
"name": "TestVolume",
"provisioningtype": "thin",
"quiescevm": false,
"size": 5368709120,
"state": "Allocated",
"storagetype": "shared",
"supportsstoragesnapshot": false,
"tags": [],
"type": "DATADISK",
"zoneid": "0ea94256-6969-46a8-b02e-b1604c81dd01",
"zonename": "zn-fln"
},
And listed the usage records.
list usagerecords startdate=2023-11-10 enddate=2023-11-11 type=6
usageid=0ff8ac1c-5ff7-4a2c-b0de-d6931d3567fb
{
"count": 11,
"usagerecord": [
{
"account": "admin",
"accountid": "b88e1a97-771e-11ee-8e59-5254003754dc",
"description": "Volume usage for TestVolume
(0ff8ac1c-5ff7-4a2c-b0de-d6931d3567fb) with disk offering Small
(7eec9944-9edf-4428-b894-54961ab19571) and size (5.00 GB) 5368709120",
"domain": "ROOT",
"domainid": "72b54c4a-771d-11ee-8e59-5254003754dc",
"enddate": "2023-11-10'T'00:59:59+00:00",
"offeringid": "7eec9944-9edf-4428-b894-54961ab19571",
"rawusage": "1",
"size": 5368709120,
"startdate": "2023-11-10'T'00:00:00+00:00",
"tags": [],
"usage": "1 Hrs",
"usageid": "0ff8ac1c-5ff7-4a2c-b0de-d6931d3567fb",
"usagetype": 6,
"zoneid": "0ea94256-6969-46a8-b02e-b1604c81dd01"
},
Since usage records are being processed for it, introducing a tariff for
volumes would result in billing for this volume aswell.
Kind regards.