Skip to content
Docs

    Billing

    Get Organization Billing Summary
    GET/v1/organizations/{organization_id}/billing/summary
    Get Organization Daily Cost
    GET/v1/organizations/{organization_id}/billing/cost
    List Organization Billing History
    GET/v1/organizations/{organization_id}/billing/history
    Top Up Organization Prepaid Balance
    POST/v1/organizations/{organization_id}/billing/topup
    Re-trigger Organization Prepaid Recharge
    POST/v1/organizations/{organization_id}/billing/recharge
    Get Organization Usage Statement
    GET/v1/organizations/{organization_id}/billing/statements
    ModelsExpand Collapse
    BillingHistoryEntry object { id, amount, created_at, 5 more }

    A single billing history line item: a prepaid credit or a manual adjustment.

    id: string

    Unique identifier for the entry.

    amount: string

    Arbitrary-precision decimal serialized as a string (e.g. “58.40”).

    formatdecimal
    created_at: string

    When the entry was recorded.

    formatdate-time
    currency: string

    ISO 4217 currency code.

    Kind of entry.

    One of the following:
    "grant"
    "adjustment"
    description: optional string

    Human-readable note describing the entry, when available.

    funding_purpose: optional "first_charge" or "auto_recharge" or "manual_top_up" or "manual_recharge"

    Funding flow that produced this entry, for a grant: “first_charge”, “auto_recharge”, “manual_top_up”, or “manual_recharge”. Null for adjustments.

    One of the following:
    "first_charge"
    "auto_recharge"
    "manual_top_up"
    "manual_recharge"
    receipt_url: optional string

    Link to the hosted receipt for the payment behind this entry, when one is available. Present for prepaid credits funded by a card charge; absent for manual adjustments and while a payment’s receipt is still being finalized.

    BillingHistoryEntryList object { items, pagination }
    items: array of BillingHistoryEntry { id, amount, created_at, 5 more }
    id: string

    Unique identifier for the entry.

    amount: string

    Arbitrary-precision decimal serialized as a string (e.g. “58.40”).

    formatdecimal
    created_at: string

    When the entry was recorded.

    formatdate-time
    currency: string

    ISO 4217 currency code.

    Kind of entry.

    One of the following:
    "grant"
    "adjustment"
    description: optional string

    Human-readable note describing the entry, when available.

    funding_purpose: optional "first_charge" or "auto_recharge" or "manual_top_up" or "manual_recharge"

    Funding flow that produced this entry, for a grant: “first_charge”, “auto_recharge”, “manual_top_up”, or “manual_recharge”. Null for adjustments.

    One of the following:
    "first_charge"
    "auto_recharge"
    "manual_top_up"
    "manual_recharge"
    receipt_url: optional string

    Link to the hosted receipt for the payment behind this entry, when one is available. Present for prepaid credits funded by a card charge; absent for manual adjustments and while a payment’s receipt is still being finalized.

    BillingHistoryEntryType = "grant" or "adjustment"

    Kind of entry.

    One of the following:
    "grant"
    "adjustment"
    DailyCostPoint object { cost, date }

    Total usage cost for a single UTC day.

    cost: string

    Arbitrary-precision decimal serialized as a string (e.g. “58.40”).

    formatdecimal
    date: string

    UTC calendar day (YYYY-MM-DD).

    OrganizationDailyCost object { currency, days, from, to }

    Daily usage cost over a date range: one entry per UTC day (zero on idle days), summing open and closed resources. Suitable for a daily cost bar chart.

    currency: string

    ISO 4217 currency code.

    days: array of DailyCostPoint { cost, date }

    One entry per UTC day in the range, oldest first.

    cost: string

    Arbitrary-precision decimal serialized as a string (e.g. “58.40”).

    formatdecimal
    date: string

    UTC calendar day (YYYY-MM-DD).

    from: string

    Inclusive start of the range, as a UTC calendar day (YYYY-MM-DD).

    to: string

    Inclusive end of the range, as a UTC calendar day (YYYY-MM-DD).

    OrganizationUsageStatement object { currency, month, projects, total }

    Itemized usage statement for a billing month: consumption grouped by project, resource type, and dimension. Costs are recorded at consumption time, not re-priced.

    currency: string

    ISO 4217 currency code.

    month: string

    Billing month the statement covers, as YYYY-MM (UTC).

    projects: array of StatementProject { project_id, project_name, resource_types, subtotal }

    One entry per project with consumption in the month, ordered by name.

    project_id: string

    Project identifier.

    project_name: string

    Human-readable project name.

    resource_types: array of StatementResourceType { items, resource_type, subtotal }

    Consumption grouped by resource type.

    items: array of StatementLineItem { children, cost, dimension, 3 more }

    Top-level metered dimensions; a dimension expanded into components carries them in children.

    children: array of StatementLineItemLeaf { cost, dimension, display_name, 2 more }

    Component dimensions nested under this one (e.g. vCPU and memory under an instance type). Empty for a leaf.

    cost: string

    Arbitrary-precision decimal serialized as a string (e.g. “58.40”).

    formatdecimal
    dimension: string

    Metered dimension identifier (e.g. “compute_vcpu”, “compute_memory_gb”).

    display_name: string

    Human-readable label for the dimension.

    quantity_hours: string

    Arbitrary-precision decimal serialized as a string (e.g. “58.40”).

    formatdecimal
    unit_price: string

    Arbitrary-precision decimal serialized as a string (e.g. “58.40”).

    formatdecimal
    cost: string

    Arbitrary-precision decimal serialized as a string (e.g. “58.40”).

    formatdecimal
    dimension: string

    Metered dimension identifier (e.g. “compute_n1_standard_8”, “storage_abs_gb”).

    display_name: string

    Human-readable label for the dimension.

    quantity_hours: string

    Arbitrary-precision decimal serialized as a string (e.g. “58.40”).

    formatdecimal
    unit_price: optional string

    Arbitrary-precision decimal serialized as a string (e.g. “58.40”).

    formatdecimal
    resource_type: string

    Resource type the line items belong to (e.g. “vm”, “volume”, “nks_node_pool”).

    subtotal: string

    Arbitrary-precision decimal serialized as a string (e.g. “58.40”).

    formatdecimal
    subtotal: string

    Arbitrary-precision decimal serialized as a string (e.g. “58.40”).

    formatdecimal
    total: string

    Arbitrary-precision decimal serialized as a string (e.g. “58.40”).

    formatdecimal
    StatementLineItem object { children, cost, dimension, 3 more }

    A top-level metered dimension. Heads nest components as children (cost is the subtotal, unit_price null); standalone dimensions carry a unit price and an empty children array.

    children: array of StatementLineItemLeaf { cost, dimension, display_name, 2 more }

    Component dimensions nested under this one (e.g. vCPU and memory under an instance type). Empty for a leaf.

    cost: string

    Arbitrary-precision decimal serialized as a string (e.g. “58.40”).

    formatdecimal
    dimension: string

    Metered dimension identifier (e.g. “compute_vcpu”, “compute_memory_gb”).

    display_name: string

    Human-readable label for the dimension.

    quantity_hours: string

    Arbitrary-precision decimal serialized as a string (e.g. “58.40”).

    formatdecimal
    unit_price: string

    Arbitrary-precision decimal serialized as a string (e.g. “58.40”).

    formatdecimal
    cost: string

    Arbitrary-precision decimal serialized as a string (e.g. “58.40”).

    formatdecimal
    dimension: string

    Metered dimension identifier (e.g. “compute_n1_standard_8”, “storage_abs_gb”).

    display_name: string

    Human-readable label for the dimension.

    quantity_hours: string

    Arbitrary-precision decimal serialized as a string (e.g. “58.40”).

    formatdecimal
    unit_price: optional string

    Arbitrary-precision decimal serialized as a string (e.g. “58.40”).

    formatdecimal
    StatementLineItemLeaf object { cost, dimension, display_name, 2 more }

    A priced dimension line: a component nested under a head, or one rate segment of a dimension whose price changed mid-period.

    cost: string

    Arbitrary-precision decimal serialized as a string (e.g. “58.40”).

    formatdecimal
    dimension: string

    Metered dimension identifier (e.g. “compute_vcpu”, “compute_memory_gb”).

    display_name: string

    Human-readable label for the dimension.

    quantity_hours: string

    Arbitrary-precision decimal serialized as a string (e.g. “58.40”).

    formatdecimal
    unit_price: string

    Arbitrary-precision decimal serialized as a string (e.g. “58.40”).

    formatdecimal
    StatementProject object { project_id, project_name, resource_types, subtotal }

    A single project’s consumption within a usage statement.

    project_id: string

    Project identifier.

    project_name: string

    Human-readable project name.

    resource_types: array of StatementResourceType { items, resource_type, subtotal }

    Consumption grouped by resource type.

    items: array of StatementLineItem { children, cost, dimension, 3 more }

    Top-level metered dimensions; a dimension expanded into components carries them in children.

    children: array of StatementLineItemLeaf { cost, dimension, display_name, 2 more }

    Component dimensions nested under this one (e.g. vCPU and memory under an instance type). Empty for a leaf.

    cost: string

    Arbitrary-precision decimal serialized as a string (e.g. “58.40”).

    formatdecimal
    dimension: string

    Metered dimension identifier (e.g. “compute_vcpu”, “compute_memory_gb”).

    display_name: string

    Human-readable label for the dimension.

    quantity_hours: string

    Arbitrary-precision decimal serialized as a string (e.g. “58.40”).

    formatdecimal
    unit_price: string

    Arbitrary-precision decimal serialized as a string (e.g. “58.40”).

    formatdecimal
    cost: string

    Arbitrary-precision decimal serialized as a string (e.g. “58.40”).

    formatdecimal
    dimension: string

    Metered dimension identifier (e.g. “compute_n1_standard_8”, “storage_abs_gb”).

    display_name: string

    Human-readable label for the dimension.

    quantity_hours: string

    Arbitrary-precision decimal serialized as a string (e.g. “58.40”).

    formatdecimal
    unit_price: optional string

    Arbitrary-precision decimal serialized as a string (e.g. “58.40”).

    formatdecimal
    resource_type: string

    Resource type the line items belong to (e.g. “vm”, “volume”, “nks_node_pool”).

    subtotal: string

    Arbitrary-precision decimal serialized as a string (e.g. “58.40”).

    formatdecimal
    subtotal: string

    Arbitrary-precision decimal serialized as a string (e.g. “58.40”).

    formatdecimal
    StatementResourceType object { items, resource_type, subtotal }

    Consumption for one resource type within a project (e.g. every VM, every volume).

    items: array of StatementLineItem { children, cost, dimension, 3 more }

    Top-level metered dimensions; a dimension expanded into components carries them in children.

    children: array of StatementLineItemLeaf { cost, dimension, display_name, 2 more }

    Component dimensions nested under this one (e.g. vCPU and memory under an instance type). Empty for a leaf.

    cost: string

    Arbitrary-precision decimal serialized as a string (e.g. “58.40”).

    formatdecimal
    dimension: string

    Metered dimension identifier (e.g. “compute_vcpu”, “compute_memory_gb”).

    display_name: string

    Human-readable label for the dimension.

    quantity_hours: string

    Arbitrary-precision decimal serialized as a string (e.g. “58.40”).

    formatdecimal
    unit_price: string

    Arbitrary-precision decimal serialized as a string (e.g. “58.40”).

    formatdecimal
    cost: string

    Arbitrary-precision decimal serialized as a string (e.g. “58.40”).

    formatdecimal
    dimension: string

    Metered dimension identifier (e.g. “compute_n1_standard_8”, “storage_abs_gb”).

    display_name: string

    Human-readable label for the dimension.

    quantity_hours: string

    Arbitrary-precision decimal serialized as a string (e.g. “58.40”).

    formatdecimal
    unit_price: optional string

    Arbitrary-precision decimal serialized as a string (e.g. “58.40”).

    formatdecimal
    resource_type: string

    Resource type the line items belong to (e.g. “vm”, “volume”, “nks_node_pool”).

    subtotal: string

    Arbitrary-precision decimal serialized as a string (e.g. “58.40”).

    formatdecimal

    BillingRecharge Policy

    Get Organization Recharge Policy
    GET/v1/organizations/{organization_id}/billing/recharge_policy
    Update Organization Recharge Policy
    PATCH/v1/organizations/{organization_id}/billing/recharge_policy
    ModelsExpand Collapse
    AutomaticPolicyArgs object { fixed, runway_days, monthly_cap }

    PolicyArgs carries the threshold parameters. Required when policy is “automatic”; must be omitted when policy is “manual”.

    fixed: string

    Arbitrary-precision decimal serialized as a string (e.g. “58.40”).

    formatdecimal
    runway_days: string

    Arbitrary-precision decimal serialized as a string (e.g. “58.40”).

    formatdecimal
    monthly_cap: optional string

    Arbitrary-precision decimal serialized as a string (e.g. “58.40”).

    formatdecimal
    OrganizationRechargePolicy object { policy, policy_args, policy_since }

    An organization’s current recharge policy. policy_args is null for a manual policy.

    Policy is the top-up mode.

    One of the following:
    "manual"
    "automatic"
    policy_args: AutomaticPolicyArgs { fixed, runway_days, monthly_cap }

    PolicyArgs carries the threshold parameters. Required when policy is “automatic”; must be omitted when policy is “manual”.

    fixed: string

    Arbitrary-precision decimal serialized as a string (e.g. “58.40”).

    formatdecimal
    runway_days: string

    Arbitrary-precision decimal serialized as a string (e.g. “58.40”).

    formatdecimal
    monthly_cap: optional string

    Arbitrary-precision decimal serialized as a string (e.g. “58.40”).

    formatdecimal
    policy_since: string

    PolicySince is when the policy currently in force took effect. Any change moves it, including an edit to the threshold parameters of an automatic policy.

    formatdate-time
    RechargePolicyMode = "manual" or "automatic"

    Policy is the top-up mode.

    One of the following:
    "manual"
    "automatic"