Billing
Use the Billing API to retrieve information about the billing accounts in an organization, to modify billing accounts, and to delete billing accounts.
Billing-Account Object{
"name": "account1",
"id": "cebe4692-498e-4c04-81ac-8ad04210ca9d",
"email": "user@company.com",
"type": "INVOICE",
"balance": 1006,
"createdAt": 1644426138824,
"createdBy": "3426883f-6968-4b1b-8f3c-c097be2afef3",
"modifiedAt": 1644569952075,
"modifiedBy": "678cc92c-01ed-4db3-9a28-d1f871042d9f"
}
Billing-Account Attributes
name String
The name of the billing account.
Example: account1
id String
The UUID of the billing account.
Example: cebe4692-498e-4c04-81ac-8ad04210ca9d
email String
The email address that invoices and transactional emails for the billing account are sent to.
Example: user@company.com
type String
The type of billing account. The value must be INVOICE.
balance Double
The balance of the billing account. This value can be negative if the account has charges that have not been paid.
Example: 1006
createdAt Integer
The number of milliseconds since UNIX epoch at which the billing account was created.
Example: 1644426138824
createdBy String
The UUID of the user who created the billing account.
Example: 3426883f-6968-4b1b-8f3c-c097be2afef3
modifiedAt Integer
The number of milliseconds since UNIX epoch at which the billing account was last modified.
Example: 1644569952075
modifiedBy String
The UUID of the user who last modified the billing account.
Example: 678cc92c-01ed-4db3-9a28-d1f871042d9f
Listing All Billing Accounts
Returns a list of billing-account objects for the billing accounts for an organization specified by its ID.
Method and URLGET /v0/billing
curl -X GET 'https://api.dremio.cloud/v0/billing' \
-H 'Authorization: Bearer <personal access token>' \
-H 'Content-Type: application/json'
[
{
"name": "account38479",
"id": "cebe4692-498e-4c04-81ac-8ad04210ca9d",
"email": "user@company.com",
"type": "INVOICE",
"balance": 1006,
"createdAt": 1644426138824,
"createdBy": "3426883f-6968-4b1b-8f3c-c097be2afef3",
"modifiedAt": 1644569952075,
"modifiedBy": "678cc92c-01ed-4db3-9a28-d1f871042d9f"
},
{
"name": "account42837",
"id": "dfbg4602-498e-5e14-55ec-8aa04216cb0f",
"email": "user@company.com",
"type": "INVOICE",
"balance": 989.07,
"createdAt": 1644426139093,
"createdBy": "3426883f-6968-4b1b-8f3c-c097be2afef3",
"modifiedAt": 1644569954444,
"modifiedBy": "678cc92c-01ed-4db3-9a28-d1f871042d9f"
}
]
Response Status Codes
200 OK
401 Unauthorized
Retrieving a Billing Account
Retrieves a billing-account object specified by its ID.
Method and URLGET /v0/billing/{id}
Parameters
id Path String
The UUID for the billing account.
Example: cebe4692-498e-4c04-81ac-8ad04210ca9d
Example Requestcurl -X GET 'https://api.dremio.cloud/v0/billing/cebe4692-498e-4c04-81ac-8ad04210ca9d' \
-H 'Authorization: Bearer <personal access token>' \
-H 'Content-Type: application/json'
{
"name": "account1",
"id": "cebe4692-498e-4c04-81ac-8ad04210ca9d",
"email": "user@company.com",
"type": "INVOICE",
"balance": 1006,
"createdAt": 1644426138824,
"createdBy": "3426883f-6968-4b1b-8f3c-c097be2afef3",
"modifiedAt": 1644569952075,
"modifiedBy": "678cc92c-01ed-4db3-9a28-d1f871042d9f"
}
Response Status Codes
200 OK
401 Unauthorized
404 Not Found
Modifying a Billing Account
Returns a modified billing-account object for a billing account specified by its ID. You can change the name of a billing account, the email associated with the billing account, or both.
Method and URLPUT /v0/billing/{id}
Parameters
id Path String
The UUID for the billing account.
Example: cebe4692-498e-4c04-81ac-8ad04210ca9d
name Body String
The name to give to the billing account.
Example: newAccountName
email Body String
The email address to associate with the billing account.
Example: differentUser@company.com
Example Requestcurl -X PUT 'https://api.dremio.cloud/v0/billing/cebe4692-498e-4c04-81ac-8ad04210ca9d' \
-H 'Authorization: Bearer <personal access token>' \
-H 'Content-Type: application/json' \
-d '{
"name": "newAccountName",
"email": "differentUser@company.com"
}'
{
"name": "newAccountName",
"id": "cebe4692-498e-4c04-81ac-8ad04210ca9d",
"email": "differentUser@company.com",
"type": "INVOICE",
"balance": 1006,
"createdAt": 1644426138824,
"createdBy": "3426883f-6968-4b1b-8f3c-c097be2afef3",
"modifiedAt": 1644605639932,
"modifiedBy": "3426883f-6968-4b1b-8f3c-c097be2afef3"
}
Response Status Codes
200 OK
401 Unauthorized
404 Not Found
405 Method Not Allowed
Deleting a Billing Account
Deletes a billing account specified by its ID.
Method and URLDELETE /v0/billing/{id}
Parameters
id Path String
The UUID for the billing account.
Example: cebe4692-498e-4c04-81ac-8ad04210ca9d
Example Requestcurl -X DELETE 'https://api.dremio.cloud/v0/billing/cebe4692-498e-4c04-81ac-8ad04210ca9d' \
-H 'Authorization: Bearer <personal access token>' \
-H 'Content-Type: application/json'
No response
Response Status Codes
200 OK
401 Unauthorized
404 Not Found