billing_profiles
Fetch the rate cards (billing profiles) of the account, with their customers and number of rates by category.
Arguments
| Argument | Type | Required | Default | Description |
|---|---|---|---|---|
customer_account_id | String | No | Filter by public API customer account ID: every rate card the customer is on. | |
name | String | No | Filter by part of the rate card name, ignoring case. | |
include_archived | Boolean | No | If true, archived rate cards are returned too. Default: false. | |
analyze | Boolean | No | If true, the query will only be analyzed (cost estimated) without executing it. |
Return Type
Query
query billing_profiles(
$customer_account_id: String,
$name: String,
$include_archived: Boolean,
$analyze: Boolean
) {
billing_profiles(
customer_account_id: $customer_account_id,
name: $name,
include_archived: $include_archived,
analyze: $analyze
) {
request_id
complexity
data {
pageInfo {
hasNextPage
hasPreviousPage
startCursor
endCursor
}
edges {
node {
id
legacy_id
name
archived
last_changed_at
customers {
account_id
name
}
rate_counts {
category
total
active
}
}
cursor
}
}
}
}Variables
{
"customer_account_id": "QWNjb3VudDoxMjM0",
"name": "standard",
"include_archived": true,
"analyze": true
}Response
{
"data": {
"billing_profiles": {
"request_id": "UmVjb3JkOjEyMzQ=",
"complexity": 100,
"data": [{id: "QmlsbGluZ1Byb2ZpbGU6MTIzNA=="}]
}
}
}