Skip to main content

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.


id

String

The UUID of the billing account.


email

String

The email address that invoices and transactional emails for the billing account are sent to.


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.


createdAt

Integer

The number of milliseconds since UNIX epoch at which the billing account was created.


createdBy

String

The UUID of the user who created the billing account.


modifiedAt

Integer

The number of milliseconds since UNIX epoch at which the billing account was last modified.


modifiedBy

String

The UUID of the user who last modified the billing account.


Listing All Billing Accounts

Returns a list of billing-account objects for the billing accounts for an organization specified by its ID.

List All Billing Accounts
GET /v0/billing
Example Request
curl -X GET 'https://api.dremio.cloud/v0/billing' \
-H 'Authorization: Bearer <personal access token>' \
-H 'Content-Type: application/json'
Example Response
[
{
"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"
}
]

Responses

200

Success.

401

User is not allowed to view billing accounts.


Retrieving a Billing Account

Retrieves a billing-account object specified by its ID.

Retrieve a Billing Account
GET /v0/billing/{id}

Parameters

id

path

String

The UUID for the billing account.

Example Request
curl -X GET 'https://api.dremio.cloud/v0/billing/cebe4692-498e-4c04-81ac-8ad04210ca9d' \
-H 'Authorization: Bearer <personal access token>' \
-H 'Content-Type: application/json'
Example Response
{
"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"
}

Responses

200

Success.

401

User is not allowed to view this billing account.

404

No billing account with the provided ID was 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.

Modify a Billing Account
PUT /v0/billing/{id}

Parameters

id

path

String

The UUID for the billing account.


name

body

String

The name to give to the billing account.


email

body

String

The email address to associate with the billing account.

Example Request
curl -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"
}'
Example Response
{
"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"
}

Responses

200

Success.

401

User is not allowed to edit this billing account.

404

No billing account with the provided ID was found.

405

Once set, the value for 'type' cannot be modified.


Deleting a Billing Account

Deletes a billing account specified by its ID.

Delete a Billing Account
DELETE /v0/billing/{id}

Parameters

id

path

String

The UUID for the billing account.

Example Request
curl -X DELETE 'https://api.dremio.cloud/v0/billing/cebe4692-498e-4c04-81ac-8ad04210ca9d' \
-H 'Authorization: Bearer <personal access token>' \
-H 'Content-Type: application/json'
Example Response
No response

Responses

200

Success.

401

User is not allowed to delete this billing account.

404

No billing account with the provided ID was found.