Billing and usage types
GraphQL schema reference · API guide · SDKs · Types of Billing and usage
BalanceTransaction
Section titled “BalanceTransaction”object
A single balance transaction (top-up, usage deduction, refund, etc.).
- id:
ID!— Unique transaction identifier. - tenantId:
String!— Owning tenant identifier. - amountCents:
Int!— Amount in cents (positive = credit, negative = debit). - balanceAfterCents:
Int!— Balance after this transaction. - transactionType:
String!— Transaction type: topup, usage, refund, adjustment. - description:
String— Human-readable description. - referenceId:
String— Reference to related object (crypto payment, usage record, etc.). - referenceType:
String— Type of the referenced object. - createdAt:
Time!(Time) — When the transaction occurred.
BalanceTransactionEdge
Section titled “BalanceTransactionEdge”object
Balance transaction connection for pagination.
- cursor:
String! - node:
BalanceTransaction!(BalanceTransaction)
BalanceTransactionsConnection
Section titled “BalanceTransactionsConnection”object
- edges:
[BalanceTransactionEdge!]!(BalanceTransactionEdge) - nodes:
[BalanceTransaction!]!(BalanceTransaction) - pageInfo:
PageInfo!(PageInfo) - totalCount:
Int!
BillingAddress
Section titled “BillingAddress”object
Structured billing address for invoices.
- street:
String!— Street address line 1. - city:
String!— City name. - state:
String— State or province. - postalCode:
String!— Postal or ZIP code. - country:
String!— ISO 3166-1 alpha-2 country code.
BillingAddressInput
Section titled “BillingAddressInput”input_object
Input for billing address.
- street:
String!— Street address line 1. - city:
String!— City name. - state:
String— State or province. - postalCode:
String!— Postal or ZIP code. - country:
String!— ISO 3166-1 alpha-2 country code.
BillingArrangement
Section titled “BillingArrangement”object
A billing arrangement FrameWorks set up for an account. Only the terms the account is billed under are shown.
- basePrice:
String— Monthly base fee in EUR in place of the plan’s, as a decimal string. Null keeps the plan’s fee. - waiveUsage:
Boolean!— Usage is metered and shown at zero cost. - collection:
String!— How invoices are collected: provider (Stripe or Mollie) or invoice (FrameWorks sends invoices to pay by bank transfer). - expiresAt:
Time(Time) — When the arrangement ends. Null runs until FrameWorks ends it. - fallbackTierName:
String— Plan the account returns to when the arrangement ends, when it is not the current plan. - fallbackTierDisplayName:
String— Display name of fallbackTierName.
BillingDetails
Section titled “BillingDetails”object
Billing details for a tenant. These are optional for Free and small simplified top-ups, and required when paid postpaid collection or a full invoice needs them.
- customerType:
String!— Personal or business billing; unspecified for an unclassified historical profile. - email:
String— Billing contact email. - name:
String— Customer legal or person name shown on full invoices. - company:
String— Company name for invoices. - vatNumber:
String— VAT number (EU format: XX123456789). - address:
BillingAddress(BillingAddress) — Structured billing address. - isComplete:
Boolean!— True if all full-invoice fields are present (legal name + email + address). - taxReviewRequired:
Boolean!— True while recurring invoices use domestic VAT because saved billing details require review. - updatedAt:
Time(Time) — When billing details were last updated. - presentmentCurrency:
Currency(Currency) — Currency the tenant is invoiced and charged in (EUR, USD, GBP), derived from the billing address country. It cannot change while a provider subscription, an open invoice, or a card first payment started in the last day exists.
BillingFeatures
Section titled “BillingFeatures”object
Contractual and enforced properties of a billing tier. Usage limits are entitlements, not features.
- supportLevel:
String!— Support level (community, email, priority, dedicated). - sla:
Boolean!— Whether SLA guarantees apply. - processingCustomizable:
Boolean!— Whether the tenant may override the tier’s processing profiles.
BillingLifecycle
Section titled “BillingLifecycle”object
A tenant’s plan lifecycle, as its billing page shows it.
- billingStatus:
String!— Subscription status: active, past_due, pending_cancellation, suspended or none. - collectionReady:
Boolean!— True only after a reusable postpaid provider subscription or mandate is confirmed. - collectionProvider:
String— Confirmed postpaid collection provider, when ready. - effectiveBasePrice:
String!— Monthly base fee in EUR this account pays after any arrangement, as a decimal string. - operatorGrant:
BillingArrangement(BillingArrangement) — Billing arrangement FrameWorks set up for this account, such as a trial or a custom price, while it is in force. - freeFallback:
FreeFallback(FreeFallback) — Scheduled move to the Free plan after a failed renewal payment or a cancellation. - pendingTier:
BillingTier(BillingTier) — Plan the subscription changes to, when a change is scheduled or being confirmed. - pendingEffectiveAt:
Time(Time) — When a scheduled downgrade takes effect. - pendingReason:
PendingTierReason(PendingTierReason) — Why pendingTier is set. - pendingTierState:
PendingTierState(PendingTierState) — Progress of pendingTier while pendingReason is DOWNGRADE. - downgradeEffectiveAt:
Time(Time) — When a downgrade chosen now takes effect: the end of the current billing period. - freeMoveFinalAt:
Time(Time) — For a Stripe- or Mollie-billed subscription: a move to Free chosen now can be undone until this time, when the payment subscription is cancelled. Null when no payment subscription has to be cancelled.
BillingStatus
Section titled “BillingStatus”object
- currentTier:
BillingTier(BillingTier) - subscription:
TenantSubscription(TenantSubscription) - billingStatus:
String! - paymentMethods:
[PaymentMethod!]!(PaymentMethod) — Invoice payment methods currently configured for this tenant. - collectionReady:
Boolean!— True only after a reusable postpaid provider subscription or mandate is confirmed. - collectionProvider:
String— Confirmed postpaid collection provider, when ready. - setupProviders:
[String!]!— Fully configured providers that can start postpaid setup. - recentPayments:
[InvoicePayment!]!(InvoicePayment) — Recent invoice payments, newest first. Retry or resume through createPayment on the invoice. - nextBillingDate:
Time(Time) - trialEndsAt:
Time(Time) - outstandingAmount:
Float! - currency:
String! - liveUsage:
LiveUsageSummary!(LiveUsageSummary) - invoicePreview:
Invoice(Invoice)
BillingTier
Section titled “BillingTier”object
A subscription tier defining pricing rules, entitlements, and features. Tenants subscribe to a tier which determines their billing and capabilities.
- id:
ID!— Unique tier identifier. - tierName:
String!— Internal tier name (payg, free, supporter, developer, production, enterprise). - tierLevel:
Int!— Numeric ordering of tiers; 0 = payg (prepaid), 1 = free, 5 = enterprise. Used to compare upgrade vs downgrade direction. - displayName:
String!— User-facing tier name. - description:
String— Tier description for marketing. - basePrice:
Float!— Base monthly price. - currency:
String!— Currency code (USD, EUR, etc.). - billingPeriod:
String!— Billing period (monthly, yearly). - features:
BillingFeatures!(BillingFeatures) — Feature flags for this tier. - pricingRules:
[PricingRule!]!(PricingRule) — Priced behaviors per meter (rating engine input). - entitlements:
[EntitlementEntry!]!(EntitlementEntry) — Non-billing grants (e.g. recording_retention_days). Values are JSON-encoded strings. - supportLevel:
String— Support level included (community, email, priority, dedicated). - slaLevel:
String— SLA guarantee level for enterprise tiers. - meteringEnabled:
Boolean!— Whether usage metering is enabled for this tier. - isEnterprise:
Boolean!— Whether this is an enterprise tier with custom terms.
CardPaymentProvider
Section titled “CardPaymentProvider”enum
Card payment provider for top-ups.
STRIPE— Stripe checkout.MOLLIE— Mollie checkout.
CardTopupResult
Section titled “CardTopupResult”object
Result from creating a card top-up checkout session.
- topupId:
ID!— Internal top-up ID for tracking. - checkoutUrl:
String!— URL to redirect user for checkout. - expiresAt:
Time!(Time) — When the checkout session expires. - amountCents:
Int!— Amount charged, in cents ofcurrency. - currency:
Currency!(Currency) — Tenant presentment currency the checkout charges in (EUR, USD, GBP). - conversion:
CurrencyConversion(CurrencyConversion) — EUR amount the top-up credits, locked at the ECB rate when the checkout was created.
ChangeBillingTierPayload
Section titled “ChangeBillingTierPayload”object
Result of a postpaid tier change. appliedTier identifies a committed upgrade. pendingTier identifies an upgrade awaiting reconciliation or a scheduled downgrade.
- success:
Boolean!— Whether the request was accepted. - message:
String!— Human-readable status message. - appliedTier:
BillingTier(BillingTier) — The active tier after the upgrade’s billing boundary commits. - pendingTier:
BillingTier(BillingTier) — The target of a pending upgrade or scheduled downgrade. - effectiveAt:
Time(Time) — When a scheduled downgrade will take effect.
ChangeBillingTierResult
Section titled “ChangeBillingTierResult”union
- Member: ChangeBillingTierPayload
- Member: ValidationError
- Member: AuthError
CostEntry
Section titled “CostEntry”object
- resourceType:
String! - cost:
Float!
CountryMetrics
Section titled “CountryMetrics”object
- countryCode:
String! - viewerCount:
Int! - viewerHours:
Float! - egressGb:
Float!
CreateCardTopupInput
Section titled “CreateCardTopupInput”input_object
Input for creating a card-based prepaid balance top-up.
- amountCents:
Int!— Amount to charge, in cents of the tenant’s presentment currency. Minimum 500 cents; maximum 10,000,000 cents. - provider:
CardPaymentProvider!(CardPaymentProvider) — Payment provider to use. - successUrl:
String!— URL to redirect after successful payment. - cancelUrl:
String!— URL to redirect if user cancels. - billingEmail:
String— Optional billing email for invoice. - billingName:
String— Optional billing name for invoice. - billingCompany:
String— Optional company name for invoice. - billingVatNumber:
String— Optional VAT number for invoice.
CreateCryptoTopupInput
Section titled “CreateCryptoTopupInput”input_object
Input for creating a crypto top-up deposit address.
- amountCents:
Int!— Amount in cents of the tenant’s presentment currency. Minimum 1 cent; maximum 10,000,000 cents. - asset:
CryptoAsset!(CryptoAsset) — Crypto asset to receive (ETH or USDC; LPT not yet supported).
CreatePaymentInput
Section titled “CreatePaymentInput”input_object
- invoiceId:
ID! - method:
PaymentMethod!(PaymentMethod) - returnUrl:
String
CreatePaymentResult
Section titled “CreatePaymentResult”union
- Member: Payment
- Member: ValidationError
- Member: AuthError
CryptoAsset
Section titled “CryptoAsset”enum
Supported crypto assets for top-up (ETH network only).
ETH— Native EthereumUSDC— USDC stablecoin (ERC-20)LPT— Livepeer Token (ERC-20). Currently reserved — prepaid top-ups gated until a non-Chainlink price source is wired.
CryptoTopupResult
Section titled “CryptoTopupResult”object
Result from creating a crypto top-up. The price is locked at this response. Send exactly expectedAmountToken of asset to depositAddress; on confirmation, the balance is credited at quotedPriceUsd regardless of price drift inside the address TTL.
- topupId:
ID!— Internal top-up ID for tracking/polling. - depositAddress:
String!— HD-derived Ethereum address to send funds to. - asset:
CryptoAsset!(CryptoAsset) — Asset to send (ETH or USDC). - assetSymbol:
String!— Human-readable asset symbol (“ETH” | “USDC”). - expectedAmountCents:
Int!— Echo of input amountCents, in cents of the tenant’s presentment currency. - expiresAt:
Time!(Time) — When this deposit address expires (24 hours from creation). - expectedAmountBaseUnits:
String!— Token base units to send (decimal string; wei for 18-decimal assets). - expectedAmountToken:
String!— Human-friendly decimal of expectedAmountBaseUnits, e.g. “0.01515”. - quotedPriceUsd:
String!— Locked USD price per 1 whole token, e.g. “3300.45”. - quoteSource:
String!— Source of the price quote (“chainlink” | “one_to_one”). - quotedAt:
Time!(Time) — When the price was locked. - network:
String!— Network the deposit address lives on (“ethereum” | “arbitrum” | “base”). - conversion:
CurrencyConversion(CurrencyConversion) — Presentment amount and the EUR credit it converts to, locked with the quote.
CryptoTopupStatus
Section titled “CryptoTopupStatus”object
Status of a crypto top-up (for polling). status cycles: pending → confirming → completed (or expired).
- id:
ID!— Top-up ID. - depositAddress:
String!— Deposit address. - asset:
CryptoAsset!(CryptoAsset) — Asset being received. - status:
String!— Current status: pending, confirming, completed, expired. - txHash:
String— Blockchain transaction hash (when detected). - confirmations:
Int!— Number of block confirmations. - receivedAmountBaseUnits:
String— Amount received in token base units (decimal string). - receivedAmountToken:
String— Human-friendly decimal of receivedAmountBaseUnits. - creditedAmountCents:
Int— Amount credited to balance increditedAmountCurrencycents. - creditedAmountCurrency:
String— Ledger currency of the credit, EUR. - quoteSource:
String— Source of the locked price quote (“chainlink” | “one_to_one”). - network:
String— Network the deposit address lives on. - expiresAt:
Time!(Time) — When the deposit address expires. - detectedAt:
Time(Time) — When payment was first detected on-chain. - completedAt:
Time(Time) — When balance was credited. - conversion:
CurrencyConversion(CurrencyConversion) — Presentment amount and the EUR credit it converts to, locked with the quote.
Currency
Section titled “Currency”scalar
CurrencyConversion
Section titled “CurrencyConversion”object
Conversion of a payment into the EUR prepaid ledger and invoice currency. EUR amounts use the identity rate.
- originalAmountCents:
Int!— Amount charged, in cents oforiginalCurrency. - originalCurrency:
Currency!(Currency) — Currency charged (EUR, USD, GBP). - eurAmountCents:
Int!— EUR cents credited or applied. - unitsPerEur:
String!— Units oforiginalCurrencyone euro buys, as a decimal string (“1” for EUR). - source:
String!— Rate source: identity (EUR), ecb (ECB reference rate), or legacy_quote (USD rate quoted before ECB rates were stored). - referenceDate:
String!— ECB reference date of the rate (YYYY-MM-DD).
EntitlementEntry
Section titled “EntitlementEntry”object
A key-value entitlement entry. Values are JSON-encoded for type flexibility.
- key:
String! - value:
String!
FreeFallback
Section titled “FreeFallback”object
A scheduled move to the Free plan.
- reason:
FreeFallbackReason!(FreeFallbackReason) - at:
Time!(Time) — When the move happens, or happened once stage is MOVED. - stage:
FreeFallbackStage!(FreeFallbackStage) - providerCancelled:
Boolean!— The Stripe or Mollie subscription is cancelled, so no renewal follows.
FreeFallbackReason
Section titled “FreeFallbackReason”enum
Why an account moves to the Free plan.
PAYMENT_FAILED— A renewal payment failed. The plan stays active through the 14-day grace period.CANCELLED— The subscription was cancelled. The plan runs to the end of its paid period.
FreeFallbackStage
Section titled “FreeFallbackStage”enum
Where a scheduled move to the Free plan stands.
SCHEDULED— Before the move date. Paying the failed invoice or subscribing again keeps the plan.APPLYING— The move date passed and the final invoice is being settled.MOVED— The account is on Free.
Invoice
Section titled “Invoice”object
A billing invoice for a subscription period. Includes base subscription and metered usage charges. Amounts are computed in EUR; a finalized invoice is presented and charged in the tenant’s presentment currency at the ECB rate of its finalization date.
- id:
ID!— Unique invoice identifier. - amount:
Money!(Money) — Total amount due in EUR (after credits applied). - baseAmount:
Money!(Money) — Base subscription amount in EUR. - meteredAmount:
Money!(Money) — Metered usage charges in EUR (net; 0 while usage is waived during beta). - grossMeteredAmount:
Money!(Money) — Unwaived metered total — what usage would have cost. Equals meteredAmount when usage is not waived; the would-have-cost figure when it is. - prepaidCreditApplied:
Money!(Money) — Prepaid balance credit applied to this invoice, in EUR. - currency:
Currency!(Currency) — Currency of the amounts above, EUR. - presentmentAmountCents:
Int— Total charged, in cents ofpresentmentCurrency. Null until the invoice is finalized. - presentmentCurrency:
String— Currency the invoice is presented and charged in (EUR, USD, GBP). Empty until the invoice is finalized. - presentmentUnitsPerEur:
String— Units ofpresentmentCurrencyone euro buys at finalization, as a decimal string. Empty until the invoice is finalized. - presentmentReferenceDate:
String— ECB reference date of the presentment rate (YYYY-MM-DD). Empty until the invoice is finalized. - finalizedAt:
Time(Time) — When the invoice was finalized and its presentment amount fixed. - status:
InvoiceStatus!(InvoiceStatus) — Invoice status (draft, open, paid, void). - dueDate:
Time!(Time) — Payment due date. - paidAt:
Time(Time) — When payment was received. - createdAt:
Time!(Time) — When the invoice was created. - updatedAt:
Time!(Time) — When the invoice was last updated. - periodStart:
Time(Time) — Billing period start date. - periodEnd:
Time(Time) — Billing period end date. - usageDetails:
JSON(JSON) — Detailed usage breakdown (JSON). - lineItems:
[LineItem!]!(LineItem) — Individual line items on the invoice.
InvoiceEdge
Section titled “InvoiceEdge”object
- cursor:
String! - node:
Invoice!(Invoice)
InvoicePayment
Section titled “InvoicePayment”object
A tenant-visible invoice payment record. Provider secrets and raw payloads are never exposed.
- id:
ID! - invoiceId:
ID! - method:
String! - amount:
Money!(Money) - currency:
Currency!(Currency) - status:
String! - confirmedAt:
Time(Time) - createdAt:
Time!(Time) - updatedAt:
Time!(Time) - conversion:
CurrencyConversion(CurrencyConversion) — Amount charged and the EUR amount applied to the invoice, at the ECB rate of payment creation.
InvoicePaymentEdge
Section titled “InvoicePaymentEdge”object
- cursor:
String! - node:
InvoicePayment!(InvoicePayment)
InvoicePaymentsConnection
Section titled “InvoicePaymentsConnection”object
- edges:
[InvoicePaymentEdge!]!(InvoicePaymentEdge) - nodes:
[InvoicePayment!]!(InvoicePayment) - pageInfo:
PageInfo!(PageInfo) - totalCount:
Int!
InvoiceStatus
Section titled “InvoiceStatus”enum
Invoice lifecycle status.
DRAFT— Invoice being prepared, not yet sent.PENDING— Invoice sent, awaiting payment.PAID— Invoice paid in full.OVERDUE— Payment past due date.FAILED— Payment processing failed.MANUAL_REVIEW— Invoice requires operator review and cannot be paid.CANCELLED— Invoice cancelled.
InvoicesConnection
Section titled “InvoicesConnection”object
- edges:
[InvoiceEdge!]!(InvoiceEdge) - nodes:
[Invoice!]!(Invoice) - pageInfo:
PageInfo!(PageInfo) - totalCount:
Int!
LineItem
Section titled “LineItem”object
A single line item on an invoice or usage preview, produced by the rating engine. Decimal quantities are strings to preserve precision.
- lineKey:
String!— Stable identity: ‘base_subscription’, ‘meter:<name>:<cluster_id>:<yyyymm>’. - meter:
String!— Meter name; empty for base_subscription. - description:
String!— Description of the charge. - quantity:
String!— Total quantity used (decimal as string). - includedQuantity:
String!— Free quantity (decimal as string). - billableQuantity:
String!— Billable quantity (decimal as string). - unitPrice:
String!— Price per unit (decimal as string). - total:
String!— Total for this line item (= billableQuantity * unitPrice), decimal as string. - currency:
String!— Currency (ISO 4217). - clusterId:
String— Cluster id this line was attributed to; null for tenant-scoped lines (base_subscription). - clusterName:
String— Display name of the cluster, joined from Quartermaster at read time. Null when clusterId is null. - clusterKind:
String— platform_official | tenant_private | third_party_marketplace; null when clusterId is null. - pricingSource:
String!— Why the line was priced as it was: tier, cluster_metered, cluster_monthly, cluster_custom, free_unmetered, self_hosted, included_subscription, beta_free (usage waived to zero by the platform waiver) or grant_waived (usage waived to zero by the tenant’s FrameWorks arrangement). - pricingLabel:
String!— Human-readable label of pricingSource (e.g. ‘Self-hosted (no charge)’, ‘Marketplace metered’). Empty when not populated by the gateway. - unit:
String!— Canonical quantity unit. - dimensions:
JSON!(JSON) — Bounded pricing dimensions such as codec, rendition, backend, or model.
LiveUsageSummary
Section titled “LiveUsageSummary”object
- tenantId:
String - periodStart:
Time(Time) - periodEnd:
Time(Time) - streamHours:
Float! - egressGb:
Float! - peakBandwidthMbps:
Float! - displayStorageGb:
Float! - livepeerH264Seconds:
Float! - livepeerVp9Seconds:
Float! - livepeerAv1Seconds:
Float! - livepeerHevcSeconds:
Float! - nativeAvH264Seconds:
Float! - nativeAvVp9Seconds:
Float! - nativeAvAv1Seconds:
Float! - nativeAvHevcSeconds:
Float! - nativeAvAacSeconds:
Float! - nativeAvOpusSeconds:
Float! - totalStreams:
Int! - totalViewers:
Int! - viewerHours:
Float! - maxViewers:
Int! - uniqueUsers:
Int! - livepeerSegmentCount:
Int! - livepeerUniqueStreams:
Int! - nativeAvSegmentCount:
Int! - nativeAvUniqueStreams:
Int! - uniqueCountries:
Int! - uniqueCities:
Int! - geoBreakdown:
[CountryMetrics!]!(CountryMetrics) - clipsCreated:
Int! - clipsDeleted:
Int! - dvrCreated:
Int! - dvrDeleted:
Int! - vodCreated:
Int! - vodDeleted:
Int! - clipBytes:
Int! - dvrBytes:
Int! - vodBytes:
Int! - frozenClipBytes:
Int! - frozenDvrBytes:
Int! - frozenVodBytes:
Int! - syncedArtifactCount:
Int! - syncedArtifactBytes:
Int!
MollieFirstPayment
Section titled “MollieFirstPayment”object
Mollie First Payment - redirect URL for initial payment that creates a mandate.
- paymentId:
ID!— Mollie payment ID (tr_xxx). - customerId:
String!— Mollie customer ID (cst_xxx). - paymentUrl:
String!— URL to redirect user to for payment.
MollieFirstPaymentResult
Section titled “MollieFirstPaymentResult”union
- Member: MollieFirstPayment
- Member: ValidationError
- Member: NotFoundError
- Member: AuthError
MollieMandate
Section titled “MollieMandate”object
Mollie Mandate - recurring payment authorization for a customer.
- mandateId:
ID!— Mollie mandate ID (mdt_xxx). - customerId:
String!— Mollie customer ID (cst_xxx). - status:
String!— Mandate status (valid, pending, invalid, revoked). - method:
String!— Mandate method (directdebit, creditcard, ideal). - details:
JSON(JSON) — Mandate details (bank/card info). - createdAt:
Time(Time) — Mandate creation timestamp.
MollieSubscription
Section titled “MollieSubscription”object
Mollie Subscription - recurring subscription created after mandate is valid.
- subscriptionId:
ID!— Mollie subscription ID (sub_xxx). - status:
String!— Subscription status (active, pending, etc.). - nextPaymentDate:
String— Next payment date (ISO 8601).
MollieSubscriptionResult
Section titled “MollieSubscriptionResult”union
- Member: MollieSubscription
- Member: ValidationError
- Member: NotFoundError
- Member: AuthError
scalar
Payment
Section titled “Payment”object
- id:
ID! - paymentUrl:
String - walletAddress:
String - amount:
Money!(Money) - currency:
Currency!(Currency) - method:
PaymentMethod!(PaymentMethod) - status:
PaymentStatus!(PaymentStatus) - expiresAt:
Time(Time) - qrCode:
String - expectedAmountBaseUnits:
String - expectedAmountToken:
String - quotedPriceUsd:
String - quoteSource:
String - assetSymbol:
String - network:
String - quotedAt:
Time(Time) - createdAt:
Time!(Time) - conversion:
CurrencyConversion(CurrencyConversion) — Amount charged and the EUR amount applied to the invoice, at the ECB rate of payment creation.
PaymentMethod
Section titled “PaymentMethod”enum
Supported payment methods.
CARD— Credit/debit card via the configured card provider.CRYPTO_ETH— Ethereum invoice payment.CRYPTO_USDC— USDC invoice payment.
PaymentStatus
Section titled “PaymentStatus”enum
Payment processing status.
PENDING— Payment initiated, awaiting confirmation.CONFIRMED— Payment successfully processed.FAILED— Payment failed or declined.
PendingTierReason
Section titled “PendingTierReason”enum
Why a subscription has a pending plan.
DOWNGRADE— A downgrade scheduled with changeBillingTier for the end of the period.TIER_UPGRADE— A paid upgrade whose payment is being confirmed.STRIPE_CHECKOUT— A Stripe checkout awaiting payment.
PendingTierState
Section titled “PendingTierState”enum
Progress of a scheduled downgrade.
SCHEDULED— Selecting the current plan with changeBillingTier cancels the downgrade.FINAL— The payment provider subscription is cancelled. The move cannot be undone.APPLYING— The effective time passed. The downgrade applies with the closing invoice.
PrepaidBalance
Section titled “PrepaidBalance”object
Prepaid balance for wallet-based accounts. Wallet-only accounts MUST use prepaid billing (balance-based, pay first).
- id:
ID!— Unique balance record identifier. - tenantId:
String!— Owning tenant identifier. - balanceCents:
Int!— Settled ledger balance in cents before active usage reservations. - reservedBalanceCents:
Int!— Active in-flight usage reservations in cents. - availableBalanceCents:
Int!— Spendable balance after active reservations (balanceCents - reservedBalanceCents). - currency:
String!— Ledger currency, always EUR. - lowBalanceThresholdCents:
Int!— Alert threshold in cents. - isLowBalance:
Boolean!— True if available balance is below threshold. - drainRateCentsPerHour:
Int!— Estimated spend rate in cents per hour (based on last hour’s usage). - createdAt:
Time!(Time) — When the balance was created. - updatedAt:
Time!(Time) — When the balance was last updated.
PricingRule
Section titled “PricingRule”object
A pricing rule: how a meter rates to money. Decimal fields are strings to preserve precision.
- meter:
String!— Canonical meter name (for example delivered_minutes, storage_gb_seconds_cold, media_seconds, or a marketplace-defined meter). - model:
String!— Pricing model (tiered_graduated, all_usage, dimensioned). - currency:
String!— Currency (ISO 4217). - includedQuantity:
String!— Free quantity included before billing kicks in. - unitPrice:
String!— Price per unit (decimal as string). - configJson:
String!— Model-specific config (for example dimension selector rates); JSON-encoded.
PromoteToPaidPayload
Section titled “PromoteToPaidPayload”object
Successful promotion to postpaid billing.
- success:
Boolean!— Whether the promotion succeeded. - message:
String!— Human-readable status message. - newBillingModel:
String!— The new billing model (postpaid). - creditBalanceCents:
Int!— Prepaid balance carried forward as credit (in cents). - subscriptionId:
ID!— The new subscription ID.
PromoteToPaidResult
Section titled “PromoteToPaidResult”union
- Member: PromoteToPaidPayload
- Member: ValidationError
- Member: AuthError
StripeBillingPortalResult
Section titled “StripeBillingPortalResult”union
- Member: StripeBillingPortalSession
- Member: ValidationError
- Member: NotFoundError
- Member: AuthError
StripeBillingPortalSession
Section titled “StripeBillingPortalSession”object
Stripe Billing Portal Session - redirect URL for subscription management.
- portalUrl:
String!— URL to redirect user to for billing management.
StripeCheckoutResult
Section titled “StripeCheckoutResult”union
- Member: StripeCheckoutSession
- Member: ValidationError
- Member: NotFoundError
- Member: AuthError
StripeCheckoutSession
Section titled “StripeCheckoutSession”object
Stripe Checkout Session - redirect URL for hosted checkout.
- sessionId:
ID!— Stripe Checkout Session ID (cs_xxx). - checkoutUrl:
String!— URL to redirect user to for checkout.
SubmitX402PaymentResult
Section titled “SubmitX402PaymentResult”union
- Member: X402PaymentResult
- Member: ValidationError
- Member: NotFoundError
- Member: AuthError
TenantSubscription
Section titled “TenantSubscription”object
- id:
ID! - tenantId:
ID! - tierId:
String! - status:
String! - billingEmail:
String! - startedAt:
Time!(Time) - trialEndsAt:
Time(Time) - nextBillingDate:
Time(Time) - cancelledAt:
Time(Time) - customFeatures:
BillingFeatures(BillingFeatures) - pricingOverrides:
[PricingRule!]!(PricingRule) - entitlementOverrides:
[EntitlementEntry!]!(EntitlementEntry) - paymentMethod:
String - billingModel:
String! - pendingTier:
BillingTier(BillingTier) - pendingEffectiveAt:
Time(Time) - pendingReason:
String— Why pendingTier is set: downgrade (applies at pendingEffectiveAt; see BillingLifecycle.pendingTierState), tier_upgrade (a paid upgrade being confirmed) or stripe_checkout (a checkout awaiting payment). - presentmentCurrency:
Currency!(Currency) — Currency the tenant is invoiced and charged in (EUR, USD, GBP), derived from the billing country. The prepaid ledger is always EUR. - createdAt:
Time!(Time) - updatedAt:
Time!(Time)
TenantUsage
Section titled “TenantUsage”object
- billingPeriod:
String! - usage:
[UsageEntry!]!(UsageEntry) - costs:
[CostEntry!]!(CostEntry) - totalCost:
Float! - currency:
String! - lineItems:
[LineItem!]!(LineItem) — Rated line items for the period (rating engine output). - baseAmount:
String!— Decimal-string base subscription portion. - usageAmount:
String!— Decimal-string metered portion.
UpdateBillingDetailsInput
Section titled “UpdateBillingDetailsInput”input_object
Input for updating billing details.
- customerType:
String— consumer or business. Omitted preserves the saved classification. - email:
String— Billing contact email. - name:
String— Customer legal or person name shown on full invoices. - company:
String— Company name for invoices. - vatNumber:
String— VAT number (EU format: XX123456789). - address:
BillingAddressInput(BillingAddressInput) — Structured billing address.
UsageAggregate
Section titled “UsageAggregate”object
- usageType:
String! - periodStart:
Time(Time) - periodEnd:
Time(Time) - usageValue:
Float! - granularity:
String!
UsageEntry
Section titled “UsageEntry”object
- resourceType:
String! - amount:
Float!
UsageRecord
Section titled “UsageRecord”object
- id:
ID! - clusterId:
String - clusterName:
String - usageType:
String! - unit:
String!— Canonical physical unit for usageValue. - dimensions:
JSON!(JSON) — Bounded dimensions that distinguish records for the same meter. - usageValue:
Float! - createdAt:
Time(Time) - periodStart:
Time(Time) - periodEnd:
Time(Time) - granularity:
String
UsageRecordEdge
Section titled “UsageRecordEdge”object
- cursor:
String! - node:
UsageRecord!(UsageRecord)
UsageRecordsConnection
Section titled “UsageRecordsConnection”object
- edges:
[UsageRecordEdge!]!(UsageRecordEdge) - nodes:
[UsageRecord!]!(UsageRecord) - pageInfo:
PageInfo!(PageInfo) - totalCount:
Int!
X402PaymentResult
Section titled “X402PaymentResult”object
Result from submitting an x402 payment for settlement.
- success:
Boolean!— Whether the payment settlement succeeded. - isAuthOnly:
Boolean!— True if this was an auth-only payload (always false for settlement). - tenantId:
ID!— Tenant that was credited. - walletAddress:
String!— Wallet address that paid. - creditedCents:
Int!— Amount credited in cents. - newBalanceCents:
Int— New balance in cents (if available). - txHash:
String— Blockchain transaction hash (if available). - message:
String!— Human-readable status message.