The key’s role does not hold the capability the operation needs, the key is narrowed away from the resource, or the account already holds as many of the resource as it may.
No
Use a key whose role holds the capability, or one that is not narrowed; delete what you no longer need, or ask for a higher limit. (more)
Read the account's writes of yesterday and today, hourly
GET /v1/usage/today · CLI: tonbo usage today
Needs usage.read, which owner and admin hold. A narrowed key may not.
The account's Streams writes per UTC hour of yesterday and today, in three lanes: databases (its databases, with each Machine's database, logs and inbox), streams (its raw streams) and other (session processing, a Volume's ledger and usage accounted to a bucket rather than a stream), as the other rows of /usage/databases and /usage/streams hold them; every write is in exactly one lane. Summed over every region the account reaches, with each region's meter checkpoint; a region that cannot be read is named in unavailable_regions and left out of the sums. A write counts in the hour that holds its settlement hour, so the current hour grows until it ends; an hour that starts after now answers null. Activity, not money: Usage & billing (/usage) shows what is charged.
The key’s role does not hold the capability the operation needs, the key is narrowed away from the resource, or the account already holds as many of the resource as it may.
No
Use a key whose role holds the capability, or one that is not narrowed; delete what you no longer need, or ask for a higher limit. (more)
Read each database's usage of one month at list price
GET /v1/usage/databases · CLI: tonbo database usage
Needs usage.read, which owner and admin hold. A narrowed key may not.
One row per listed database version (name, stream creation time and counting history) metered in the month, rolled up by contracts/streams-databases/v1.json kinds.values.<kind>.usage: a Machine's logs and inbox streams are added into its database's row, and a Volume's ledger into other; in every region the account reaches, including databases deleted during the month, plus other for metered usage outside the account's databases (its streams, which /usage/streams lists, session processing and anything unattributed), so the rows and other add up to the account's metered total. Values are at list price, before the monthly allowance and credit; Usage & billing (/usage) shows what is charged.
Parameters
Name
In
Type
Required
Description
period
query
string
no
The calendar month in UTC; the current month when omitted. Matches ^[0-9]{4}-(0[1-9]|1[0-2])$.
sort
query
one of "-list_value" or "name"
no
By list value, highest first (the default), or by name. Default "-list_value".
prefix
query
string
no
Only databases whose name starts with this prefix. 1 to 85 characters. Matches ^(?!m\.)(?!vol\.)(?!s\.)(?!session\.)(?!proc\.)[a-z0-9][a-z0-9._-]{0,84}$.
names
query
string
no
Only these databases, 1 to 100 listed names, comma-separated (a database name or a Machine's database). At least 1 characters.
cursor
query
string
no
Opaque cursor tied to the original query shape. At least 1 characters.
limit
query
integer
no
The most items one page holds, 1 to 200; 50 when omitted. A page may hold fewer; read on with next_cursor until it is null. Default 50. 1 to 200.
Response
Status
Answer
200
Per-database usage
Field
Type
Required
Description
period
string
yes
The calendar month counted, in UTC; the period asked for, or the current month. Matches ^[0-9]{4}-(0[1-9]|1[0-2])$.
as_of
string (date-time) or null
yes
The oldest meter checkpoint among the regions read; usage after it is not yet counted. Null before a region's first.
currency
"usd"
yes
usd: every _micros value is in millionths of a US dollar.
basis
"at_list_price_before_allowance_and_credit"
yes
Values are at list price, before the monthly allowance and credit apply; GET /v1/usage answers what the account is charged.
pricing
object
yes
The list prices of contracts/billing/streams-prices-v1.json the values use.
pricing.write_unit_bytes
integer
yes
The bytes of one write unit. A write counts one unit for each started unit of its bytes, and at least one.
pricing.write_micros_per_million_units
integer
yes
The price of a million write units, in micro-dollars.
pricing.retention_micros_per_gib_month
integer
yes
The price of keeping one GiB for one month, in micro-dollars.
pricing.retention_unit_bytes
integer
yes
The bytes of the GiB that price is quoted for, 1024^3.
pricing.retention_month_seconds
integer
yes
The seconds of the month that price is quoted for, 30 days.
The key’s role does not hold the capability the operation needs, the key is narrowed away from the resource, or the account already holds as many of the resource as it may.
No
Use a key whose role holds the capability, or one that is not narrowed; delete what you no longer need, or ask for a higher limit. (more)
Read each stream's usage of one month at list price
GET /v1/usage/streams · CLI: tonbo stream usage
Needs usage.read, which owner and admin hold. A narrowed key may not.
One row per stream version (name, stream creation time and counting history) metered in the month, in every region the account reaches, including streams deleted during the month, plus other for metered usage outside the account's streams (its databases, session processing and anything unattributed), so the rows and other add up to the account's metered total, as /usage/databases does for databases; no stream is a row of both. Values are at list price, before the monthly allowance and credit, which databases and streams share; Usage & billing (/usage) shows what is charged.
Parameters
Name
In
Type
Required
Description
period
query
string
no
The calendar month in UTC; the current month when omitted. Matches ^[0-9]{4}-(0[1-9]|1[0-2])$.
sort
query
one of "-list_value" or "name"
no
By list value, highest first (the default), or by name. Default "-list_value".
prefix
query
string
no
Only streams whose name starts with this prefix. 1 to 85 characters. Matches ^(?!m\.)(?!vol\.)(?!s\.)(?!session\.)(?!proc\.)[a-z0-9][a-z0-9._-]{0,84}$.
names
query
string
no
Only these streams, 1 to 100 stream names, comma-separated. At least 1 characters.
cursor
query
string
no
Opaque cursor tied to the original query shape. At least 1 characters.
limit
query
integer
no
The most items one page holds, 1 to 200; 50 when omitted. A page may hold fewer; read on with next_cursor until it is null. Default 50. 1 to 200.
Response
Status
Answer
200
Per-stream usage
Field
Type
Required
Description
period
string
yes
The calendar month counted, in UTC; the period asked for, or the current month. Matches ^[0-9]{4}-(0[1-9]|1[0-2])$.
as_of
string (date-time) or null
yes
The oldest meter checkpoint among the regions read; usage after it is not yet counted. Null before a region's first.
currency
"usd"
yes
usd: every _micros value is in millionths of a US dollar.
basis
"at_list_price_before_allowance_and_credit"
yes
Values are at list price, before the monthly allowance and credit apply; GET /v1/usage answers what the account is charged.
pricing
object
yes
The list prices of contracts/billing/streams-prices-v1.json the values use.
pricing.write_unit_bytes
integer
yes
The bytes of one write unit. A write counts one unit for each started unit of its bytes, and at least one.
pricing.write_micros_per_million_units
integer
yes
The price of a million write units, in micro-dollars.
pricing.retention_micros_per_gib_month
integer
yes
The price of keeping one GiB for one month, in micro-dollars.
pricing.retention_unit_bytes
integer
yes
The bytes of the GiB that price is quoted for, 1024^3.
pricing.retention_month_seconds
integer
yes
The seconds of the month that price is quoted for, 30 days.
The key’s role does not hold the capability the operation needs, the key is narrowed away from the resource, or the account already holds as many of the resource as it may.
No
Use a key whose role holds the capability, or one that is not narrowed; delete what you no longer need, or ask for a higher limit. (more)
Write units, an integer as text. Matches ^(0|[1-9][0-9]*)$.
retention_gib_months
string
yes
The retained log in GiB-months (GiB = 1024^3 bytes, month = retention_month_seconds), a decimal as text.
snapshot_gib_months
string or null
yes
Snapshots in GiB-months, a decimal as text; null when never reported.
list_value_micros
integer
yes
The value at list price in micro-dollars, before allowance and credit. At least 0.
name
string
yes
The stream's name, without s.. 1 to 83 characters. Matches ^(?!m\.)(?!vol\.)(?!s\.)(?!session\.)(?!proc\.)(?!(?:streams|new)$)(?!.*\.\.)[a-z0-9](?:[a-z0-9._-]{0,81}[a-z0-9])?$.
region
string
yes
The stream's region. Matches ^[a-z]{2}-[a-z]+-[0-9]$.
stream_created_at
string (date-time)
yes
When Ursula created the stream version; with counted_since, the version the row is.
counted_since
string
yes
The Ursula usage history the version began counting in, 16 hex digits. Matches ^[0-9a-f]{16}$.
state
one of "active" or "deleted"
yes
active while this version of the stream exists, deleted once it was deleted; a deleted version's usage in the month still counts.
created_at
string (date-time) or null
yes
Null for a metered version the registry does not know.
deleted_at
string (date-time) or null
yes
When this version was deleted; null while it is active.