apiVersion: String!
Schema/contract version marker for compatibility checks.
API reference
Generated from the repository's canonical SDL artifact
(schema/billing_core.graphql), which is regenerated from
the running schema and diff-tested in CI — this page cannot drift from
the code. The endpoint is POST /api/graphql with a
Bearer API token; every team-scoped field takes an
explicit teamId and is authorized against the caller's
membership scope. Mutations return typed result unions — validation
problems are data, not HTTP errors.
apiVersion: String! Schema/contract version marker for compatibility checks.
auditExport(…): AuditExport Audit package for an invoice chain: canonical evidence files + checksum manifest (BC-US-114).
teamId | ID! | |
invoiceIntentId | ID! |
billingRun(…): BillingRun A billing run by ID.
teamId | ID! | |
id | ID! |
contract(…): Contract A team contract by ID.
teamId | ID! | |
id | ID! |
creditAccounts(…): [CreditAccount!]! Credit accounts linked to a customer, with subledger evidence (BC-US-107).
teamId | ID! | |
customerId | ID! |
creditClose(…): CreditClose One monthly customer-credit close (BC-US-163…165).
teamId | ID! | |
id | ID! |
creditClosePolicies(…): [CreditClosePolicy!]! The team's close posting-policy versions, newest first.
teamId | ID! |
creditCloses(…): [CreditClose!]! The team's monthly customer-credit closes, newest period first (max 100).
teamId | ID! | |
currency | String | |
state | String |
creditSettlements(…): [CreditSettlement!]! Receivable settlements opened by credit applications (SPEC §9.4.1).
teamId | ID! | |
invoiceIntentId | ID | |
state | String |
customer(…): Customer A team customer by ID.
teamId | ID! | |
id | ID! |
customers(…): CustomerConnection Team customers as a bounded cursor connection (SPEC §14.6).
teamId | ID! | |
first | Int | |
after | String |
discount(…): Discount A discount by ID.
teamId | ID! | |
id | ID! |
erpConnection(…): ErpConnection The team's ERP connection.
teamId | ID! |
invoiceIntent(…): InvoiceIntent An immutable invoice intent with lines and lifecycle state.
teamId | ID! | |
id | ID! |
invoicePreview(…): InvoicePreview Deterministic invoice preview for a subscription (BC-US-068).
teamId | ID! | |
subscriptionId | ID! | |
asOf | Date! |
operation(…): Operation A durable operation by ID (team-scoped).
teamId | ID! | |
id | ID! |
organization(…): Organization A single organization the caller belongs to.
organizationId | ID! |
organizationInvitations(…): [OrganizationInvitation!]! Pending and settled membership invitations of an organization (BC-US-144).
organizationId | ID! |
organizationMemberships(…): [OrganizationMembershipRecord!]! Active membership directory of an organization (owners/admins).
organizationId | ID! |
organizations: [Organization!]! Organizations the caller actively belongs to.
plan(…): Plan A plan by ID.
teamId | ID! | |
id | ID! |
planVersion(…): PlanVersion A plan version by ID (draft or published).
teamId | ID! | |
id | ID! |
product(…): Product A catalog product by ID.
teamId | ID! | |
id | ID! |
products(…): ProductConnection Team products as a bounded cursor connection.
teamId | ID! | |
first | Int | |
after | String |
subscription(…): Subscription A subscription by ID.
teamId | ID! | |
id | ID! |
subscriptions(…): SubscriptionConnection Team subscriptions as a bounded cursor connection.
teamId | ID! | |
first | Int | |
after | String |
team(…): Team A team the caller is a member of.
teamId | ID! |
teamMemberships(…): [TeamMembershipRecord!]! Active membership directory of a team (any team member).
teamId | ID! |
teams(…): [Team!]! Active teams of an organization the caller belongs to.
organizationId | ID! |
usagePreview(…): UsageAggregate Usage aggregation preview for a metric over a period (BC-US-053).
teamId | ID! | |
subscriptionId | ID! | |
metricCode | String! | |
periodStart | Date! | |
periodEndExclusive | Date! | |
cutoff | DateTime | |
aggregation | String |
viewer: Viewer The authenticated principal and its memberships.
addTeamMember(…): AddTeamMemberResult! Adds an existing organization member to a team (team admins, INV-024).
input | AddTeamMemberInput! |
approveCreditClose(…): ApproveCreditCloseResult! Approves the exact frozen report hash for ERP posting (BC-US-164).
input | ApproveCreditCloseInput! |
approveInvoice(…): ApproveInvoiceResult! Approves a reconciled ERP draft for booking (BC-US-084).
input | ApproveInvoiceInput! |
archiveTeam(…): ArchiveTeamResult! Archives a team; the last active team is protected (owners/admins, INV-033).
input | ArchiveTeamInput! |
bookInvoice(…): BookInvoiceResult! Enqueues booking of an approved draft (BC-US-085).
input | BookInvoiceInput! |
cancelSubscription(…): CancelSubscriptionResult! Cancels a subscription immediately or at period end (BC-US-038).
input | CancelSubscriptionInput! |
changeOrganizationRoles(…): ChangeOrganizationRolesResult! Replaces a member's organization roles; the last owner is protected (owners/admins).
input | ChangeOrganizationRolesInput! |
changeSubscription(…): ChangeSubscriptionResult! Changes a subscription's quantity by appending a version (BC-US-036).
input | ChangeSubscriptionInput! |
changeTeamRoles(…): ChangeTeamRolesResult! Replaces a team member's role grants (team admins).
input | ChangeTeamRolesInput! |
closeCreditPeriod(…): CloseCreditPeriodResult! Accepts a fully reconciled close as the authoritative period close (BC-US-165).
input | CloseCreditPeriodInput! |
createBillingRun(…): CreateBillingRunResult! Opens (or returns) a billing run by stable run key (SPEC §18.1).
input | CreateBillingRunInput! |
createChargeInstance(…): CreateChargeInstanceResult! Creates an idempotent one-time charge instance (BC-US-041).
input | CreateChargeInstanceInput! |
createContract(…): CreateContractResult! Creates a contract with its immutable version 1 (BC-US-033).
input | CreateContractInput! |
createCreditClosePolicy(…): CreateCreditClosePolicyResult! Creates a monthly-close posting-policy version (BC-US-163).
input | CreateCreditClosePolicyInput! |
createOrganization(…): CreateOrganizationResult! Creates an organization with its first team (INV-033).
input | CreateOrganizationInput! |
createPlan(…): CreatePlanResult! Creates a plan (stable code owner, BC-US-013).
input | CreatePlanInput! |
createPlanVersion(…): CreatePlanVersionResult! Creates a draft plan version with its components in one command.
input | CreatePlanVersionInput! |
createProduct(…): CreateProductResult! Creates a product with its version 1 snapshot (BC-US-010).
input | CreateProductInput! |
createSubscription(…): CreateSubscriptionResult! Starts a subscription (BC-US-034/035, SPEC §14.9).
input | CreateSubscriptionInput! |
createTeam(…): CreateTeamResult! Creates an additional team (organization admins).
input | CreateTeamInput! |
freezeInvoiceIntent(…): FreezeInvoiceIntentResult! Freezes a subscription's preview into immutable invoice intent (BC-US-069).
input | FreezeInvoiceIntentInput! |
generateCreditClose(…): GenerateCreditCloseResult! Freezes one deterministic close for a currency and calendar month (BC-US-163).
input | GenerateCreditCloseInput! |
generateCreditCloseReplacement(…): GenerateCreditCloseReplacementResult! Freezes a replacement close for a reversed period under a corrected policy (ADR-031).
input | GenerateCreditCloseReplacementInput! |
grantCredit(…): GrantCreditResult! Grants customer credit into the subledger — a liability, never a discount (BC-US-107).
input | GrantCreditInput! |
ingestUsageBatch(…): IngestUsageBatchResult! Ingests usage events in a batch with per-event independence (BC-US-051).
input | IngestUsageBatchInput! |
ingestUsageEvent(…): IngestUsageEventResult! Ingests one usage event idempotently by external event ID (BC-US-050).
input | IngestUsageEventInput! |
inviteOrganizationMember(…): InviteOrganizationMemberResult! Invites an email to organization/team memberships (BC-US-144).
input | InviteOrganizationMemberInput! |
mapCustomerToErp(…): MapCustomerToErpResult! Maps a customer to an ERP customer number (BC-US-031).
input | MapCustomerToErpInput! |
mapProductToErp(…): MapProductToErpResult! Maps a product to an ERP product number (BC-US-011).
input | MapProductToErpInput! |
publishPlanVersion(…): PublishPlanVersionResult! Publishes a draft plan version, making it immutable (BC-US-014).
input | PublishPlanVersionInput! |
recordExternalSettlement(…): RecordExternalSettlementResult! Records the external receivables system's settlement reference exactly once (SPEC §9.4.1).
input | RecordExternalSettlementInput! |
removeTeamMember(…): RemoveTeamMemberResult! Removes a member from a team; the history row is retained (team admins).
input | RemoveTeamMemberInput! |
renameTeam(…): RenameTeamResult! Renames a team; UUID and slug stay stable (team admins, BC-US-140).
input | RenameTeamInput! |
requestCreditClosePosting(…): RequestCreditClosePostingResult! Creates the durable, idempotent ERP posting operation (BC-US-164).
input | RequestCreditClosePostingInput! |
requestCreditCloseReversal(…): RequestCreditCloseReversalResult! Freezes a compensating reversal close for an accepted close (ADR-031, BC-US-165).
input | RequestCreditCloseReversalInput! |
retryOperation(…): RetryOperationResult! Manually retries a failed durable operation (finance role, §11.3).
input | RetryOperationInput! |
revokeOrganizationInvitation(…): RevokeOrganizationInvitationResult! Revokes a pending membership invitation (BC-US-144).
input | RevokeOrganizationInvitationInput! |
setCreditDispositionPolicy(…): SetCreditDispositionPolicyResult! Sets the versioned remaining-credit disposition policy (BC-US-109).
input | SetCreditDispositionPolicyInput! |
supersedeInvoiceIntent(…): SupersedeInvoiceIntentResult! Replaces a frozen, unsynchronized intent in its chain (BC-US-100).
input | SupersedeInvoiceIntentInput! |
synchronizeInvoice(…): SynchronizeInvoiceResult! Enqueues ERP draft synchronization; follow the returned operation (§14.11).
input | SynchronizeInvoiceInput! |
upsertCustomer(…): UpsertCustomerResult! Creates or updates a customer as an immutable version snapshot (BC-US-030).
input | UpsertCustomerInput! |
validateErpConnection(…): ValidateErpConnectionResult! Runs the ERP adapter preflight and records capabilities (BC-US-004).
input | ValidateErpConnectionInput! |
voidUsageEvent(…): VoidUsageEventResult! Voids a measurement, optionally submitting a replacement (BC-US-052).
input | VoidUsageEventInput! |
AddTeamMemberSuccess object membership | TeamMembershipRecord! | |
clientMutationId | String! |
ApproveCreditCloseSuccess object creditClose | CreditClose! | |
clientMutationId | String! |
ApproveInvoiceSuccess object invoiceIntent | InvoiceIntent! | |
clientMutationId | String! |
ArchiveTeamSuccess object team | Team! | |
clientMutationId | String! |
AuditExport object An audit package for one invoice chain with its checksum manifest.
invoiceChainId | ID! | |
intentCount | Int! | |
generatedAt | String! | |
manifestJson | String! | Canonical JSON manifest listing per-file SHA-256 checksums. |
files | [AuditExportFile!]! |
AuditExportFile object One canonical evidence file with its exact bytes, base64-encoded.
name | String! | |
contentType | String! | |
sha256 | String! | |
contentBase64 | String! |
AuthorizationProblem object code | String! | |
message | String! | |
clientMutationId | String |
BillingRun object id | ID! | |
runKey | String! | |
status | String! | |
invoiceDate | Date! | |
usageCutoff | DateTime! | |
engineVersion | String! | |
startedAt | DateTime | |
closedAt | DateTime |
BookInvoiceAccepted object operation | Operation! | Durable booking operation to follow. |
clientMutationId | String! |
CancelSubscriptionSuccess object subscription | Subscription! | |
clientMutationId | String! |
ChangeOrganizationRolesSuccess object membership | OrganizationMembershipRecord! | |
clientMutationId | String! |
ChangeSubscriptionSuccess object subscription | Subscription! | |
clientMutationId | String! |
ChangeTeamRolesSuccess object membership | TeamMembershipRecord! | |
clientMutationId | String! |
ChargeInstance object id | ID! | |
externalId | String! | |
contractId | ID! | |
subscriptionId | ID | |
status | String! | |
eligibleOn | Date! | |
quantity | Decimal | |
amountMinor | MoneyMinorUnits | |
currency | String! | |
recognitionMode | String! | |
serviceStart | Date | |
serviceEndExclusive | Date |
CloseCreditPeriodSuccess object creditClose | CreditClose! | |
clientMutationId | String! |
Contract object id | ID! | |
customerId | ID! | |
externalReference | String | |
status | String! | |
currency | String! | |
startDate | Date! | |
endDateExclusive | Date | |
currentVersion | Int! |
CreateBillingRunSuccess object billingRun | BillingRun! | |
clientMutationId | String! |
CreateChargeInstanceSuccess object chargeInstance | ChargeInstance! | |
clientMutationId | String! |
CreateContractSuccess object contract | Contract! | |
clientMutationId | String! |
CreateCreditClosePolicySuccess object policy | CreditClosePolicy! | |
clientMutationId | String! |
CreateOrganizationSuccess object organization | Organization! | |
team | Team! | |
clientMutationId | String! |
CreatePlanSuccess object plan | Plan! | |
clientMutationId | String! |
CreatePlanVersionSuccess object planVersion | PlanVersion! | |
clientMutationId | String! |
CreateProductSuccess object product | Product! | |
clientMutationId | String! |
CreateSubscriptionSuccess object subscription | Subscription! | |
clientMutationId | String! |
CreateTeamSuccess object team | Team! | |
clientMutationId | String! |
CreditAccount object A team-scoped credit account projection over the append-only ledger.
id | ID! | |
accountId | ID! | The organization-level commercial account this projects. |
currency | String! | |
availableMinor | MoneyMinorUnits! | |
reservedMinor | MoneyMinorUnits! | |
grants | [CreditGrant!]! | |
transactions | [CreditTransaction!]! | |
dispositionPolicy | CreditDispositionPolicy | The currently effective disposition policy, or null when unset. |
CreditClose object One monthly customer-credit close (§11.5 lifecycle).
id | ID! | |
currency | String! | |
periodStart | Date! | |
periodEndExclusive | Date! | |
transactionCutoff | DateTime! | |
closeKind | String! | regular, reversal, or replacement (ADR-031 compensating closes). |
reversalOfCloseId | ID | For a correction close: the close it corrects. |
corrections | [CreditClose!]! | Correction closes referencing this close, oldest first. |
state | String! | Current §11.5 state (open, ready, approved, posting, reconciled, closed, ...). |
openingMinor | MoneyMinorUnits | |
closingMinor | MoneyMinorUnits | |
netChangeMinor | MoneyMinorUnits | |
economicLiabilityLineMinor | MoneyMinorUnits | |
ledgerTransactionCount | Int | |
reportSha256 | String | |
closedAt | DateTime | |
movements | [CreditCloseMovement!]! | |
evidence | [CreditCloseEvidenceMeta!]! | |
externalVoucherNumber | String | Voucher number of the posted aggregate document, once posted. |
report | CreditCloseReport | One stored immutable evidence file with its exact bytes. |
CreditCloseEvidenceMeta object Metadata of one immutable evidence file (never inline bytes).
evidenceType | String! | |
sha256 | String! | |
contentType | String! | |
byteSize | Int! |
CreditCloseMovement object Movement-type roll-up inside one close period.
movementType | String! | |
amountMinor | MoneyMinorUnits! | |
liabilityEffectMinor | MoneyMinorUnits! | |
transactionCount | Int! |
CreditClosePolicy object An accountant-approved posting policy version for monthly closes.
id | ID! | |
version | Int! | |
effectiveFrom | Date! | |
journalNumber | Int! | |
liabilityAccountNumber | Int! | |
postingMode | String! | |
defaultOffsetAccountNumber | Int | |
postZeroDelta | Boolean! | |
vatNeutral | Boolean! | |
settlementMode | String! | SPEC §9.4.1: none, erp_customer_settlement, or external_reference. |
settlementClearingAccountNumber | Int | |
settlementContraAccountNumber | Int |
CreditCloseReport object One immutable evidence file with its exact bytes, base64-encoded.
evidenceType | String! | |
sha256 | String! | |
contentType | String! | |
contentBase64 | String! |
CreditDispositionPolicy object A versioned remaining-credit disposition policy (BC-US-109).
version | Int! | |
policy | String! | retain, refund, or expire_after. |
expireAfterDays | Int | |
effectiveFrom | DateTime! |
CreditGrant object A credit grant — an individual liability movement, never a discount.
id | ID! | |
originType | String! | |
originId | ID | |
originInvoiceLineId | ID | |
grantedMinor | MoneyMinorUnits! | |
remainingMinor | MoneyMinorUnits! | |
reservedMinor | MoneyMinorUnits! | |
currency | String! | |
status | String! | |
grantedAt | DateTime! | |
expiresAt | DateTime |
CreditSettlement object One receivable settlement opened by one credit application (SPEC §9.4.1).
id | ID! | |
invoiceIntentId | ID! | |
creditAccountId | ID! | |
currency | String! | |
amountMinor | Int! | |
mode | String! | |
state | String! | |
externalReference | String | |
externalVoucherNumber | String | |
reconciledAt | DateTime | |
createdAt | DateTime! |
CreditTransaction object One append-only subledger transaction.
id | ID! | |
transactionType | String! | |
amountMinor | MoneyMinorUnits! | |
currency | String! | |
grantId | ID | |
invoiceIntentId | ID | |
operationId | ID | |
reasonCode | String | |
accountingEffectiveOn | Date! | |
occurredAt | DateTime! |
Customer object id | ID! | |
externalId | String! | |
status | String! | |
currentVersion | Int! | |
legalName | String | Legal name from the current immutable customer version snapshot. |
CustomerConnection object edges | [CustomerEdge!]! | |
pageInfo | PageInfo! |
CustomerEdge object cursor | String! | |
node | Customer! |
CustomerErpMapping object id | ID! | |
customerId | ID! | |
erpConnectionId | ID! | |
externalCustomerNumber | String! | |
validationStatus | String! |
Discount object id | ID! | |
code | String! | |
status | String! | |
currentVersion | Int! |
ErpConnection object id | ID! | |
provider | String! | |
status | String! | |
externalAgreementId | String | |
capabilitiesHash | String | |
lastValidatedAt | DateTime |
FieldProblem object path | [String!]! | |
code | String! | |
message | String! |
FreezeInvoiceIntentSuccess object invoiceIntent | InvoiceIntent! | |
clientMutationId | String! |
GenerateCreditCloseReplacementSuccess object replacementClose | CreditClose! | |
clientMutationId | String! |
GenerateCreditCloseSuccess object creditClose | CreditClose! | |
clientMutationId | String! |
GrantCreditSuccess object creditGrant | CreditGrant! | |
clientMutationId | String! |
IdempotencyConflict object The idempotency key was reused with materially different input.
code | String! | |
message | String! | |
clientMutationId | String |
IngestUsageBatchSuccess object accepted | Int! | |
duplicate | Int! | |
rejected | Int! | |
quarantined | Int! | |
items | [UsageBatchItemResult!]! | |
clientMutationId | String! |
IngestUsageEventSuccess object outcome | UsageIngestOutcome! | |
duplicate | Boolean! | |
clientMutationId | String! |
InviteOrganizationMemberSuccess object invitation | OrganizationInvitation! | |
acceptUrl | String! | The single-use accept URL — shown once; only a hash is stored. |
clientMutationId | String! |
InvoiceIntent object Immutable frozen invoice intent plus its mutable lifecycle state (§11.2).
id | ID! | |
state | String! | Current §11.2 lifecycle state (frozen, sync_pending, erp_draft, ...). |
customerId | ID! | |
customerVersion | Int! | |
contractId | ID | |
billingRunId | ID | |
currency | String! | |
invoiceDate | Date! | |
intentVersion | Int! | |
supersedesInvoiceIntentId | ID | |
documentKind | String! | |
contentHash | String! | |
netAmountMinor | MoneyMinorUnits! | |
frozenAt | DateTime | |
lines | [InvoiceLine!]! |
InvoiceLine object id | ID! | |
lineKey | String! | |
description | String! | |
quantity | Decimal! | |
amountMinor | MoneyMinorUnits! | |
currency | String! | |
recognitionMode | String! | |
serviceStart | Date | |
serviceEndExclusive | Date | |
ordinal | Int! | |
productId | ID! | |
productVersion | Int! |
InvoicePreview object Deterministic, side-effect-free invoice preview (BC-US-068).
subscriptionId | ID! | |
customerId | ID! | |
contractId | ID! | |
currency | String! | |
invoiceDate | Date! | |
periodStart | Date! | |
periodEndExclusive | Date! | |
netAmountMinor | MoneyMinorUnits! | |
fingerprint | String! | Stable for unchanged inputs; freezing verifies against this. |
blockers | [String!]! | Stable-coded conditions preventing freeze; empty means freezable. |
lines | [PreviewLine!]! |
MapCustomerToErpSuccess object mapping | CustomerErpMapping! | |
clientMutationId | String! |
MappingProblem object Missing/invalid ERP mappings or other unmet preconditions (SPEC §14.11).
code | String! | |
message | String! | |
fields | [FieldProblem!]! | |
clientMutationId | String |
MapProductToErpSuccess object mapping | ProductErpMapping! | |
clientMutationId | String! |
Operation object Durable asynchronous operation; clients follow it instead of HTTP 202 semantics.
id | ID! | |
type | String! | |
state | String! | |
attemptCount | Int! | |
errorClass | String | |
safeErrorCode | String | |
safeErrorSummary | String | |
blockedReason | String | |
nextAttemptAt | DateTime | |
correlationId | ID | |
startedAt | DateTime | |
finishedAt | DateTime |
Organization object id | ID! | |
name | String! | |
slug | String! | |
status | String! |
OrganizationInvitation object A pending or settled membership invitation.
id | ID! | |
email | String! | |
organizationRoles | [String!]! | |
teamId | ID | |
teamRoles | [String!]! | |
expiresAt | DateTime! | |
acceptedAt | DateTime | |
revokedAt | DateTime | |
pending | Boolean! |
OrganizationMembershipRecord object An active organization membership in the admin directory.
id | ID! | |
userId | ID! | |
email | String | |
roles | [String!]! | |
status | String! | |
createdAt | DateTime! |
PageInfo object hasNextPage | Boolean! | |
endCursor | String |
Plan object id | ID! | |
code | String! | |
name | String! | |
status | String! | |
currentVersion | Int! | Highest published version; 0 while no version is published. |
PlanVersion object id | ID! | |
planId | ID! | |
version | Int! | |
status | String! | |
currency | String! | |
intervalUnit | String! | |
intervalCount | Int! | |
billingTiming | String! | |
effectiveFrom | Date | |
contentHash | String | |
publishedAt | DateTime | |
priceComponents | [PriceComponent!]! |
PreviewLine object lineKey | String! | |
description | String! | |
quantity | Decimal! | |
amountMinor | MoneyMinorUnits! | |
recognitionMode | String! | |
serviceStart | Date | |
serviceEndExclusive | Date | |
ordinal | Int! | |
productId | ID! |
PriceComponent object id | ID! | |
code | String! | |
productId | ID! | |
productVersion | Int | |
pricingModel | String! | |
recognitionMode | String! | |
prorationPolicy | String! | |
ordinal | Int! |
Product object id | ID! | |
code | String! | |
name | String! | |
description | String | |
status | String! | |
recognitionMode | String | |
currentVersion | Int! |
ProductConnection object edges | [ProductEdge!]! | |
pageInfo | PageInfo! |
ProductEdge object cursor | String! | |
node | Product! |
ProductErpMapping object id | ID! | |
productId | ID! | |
erpConnectionId | ID! | |
externalProductNumber | String! | |
validationStatus | String! |
PublishPlanVersionSuccess object planVersion | PlanVersion! | |
clientMutationId | String! |
RecordExternalSettlementSuccess object settlement | CreditSettlement! | |
clientMutationId | String! |
RemoveTeamMemberSuccess object membership | TeamMembershipRecord! | |
clientMutationId | String! |
RenameTeamSuccess object team | Team! | |
clientMutationId | String! |
RequestCreditClosePostingSuccess object operation | Operation! | |
creditClose | CreditClose! | |
clientMutationId | String! |
RequestCreditCloseReversalSuccess object reversalClose | CreditClose! | The frozen reversal close carrying the mirrored bridge. |
clientMutationId | String! |
RetryOperationSuccess object operation | Operation! | |
clientMutationId | String! |
RevokeOrganizationInvitationSuccess object invitation | OrganizationInvitation! | |
clientMutationId | String! |
SetCreditDispositionPolicySuccess object dispositionPolicy | CreditDispositionPolicy! | |
clientMutationId | String! |
Subscription object A contract subscription (SPEC §11.1 lifecycle).
id | ID! | |
externalId | String! | |
contractId | ID! | |
state | String! | §11.1 lifecycle state. |
startsOn | Date! | |
endDateExclusive | Date | |
billingAnchorDay | Int | |
timeZone | String! | |
version | Int! | Optimistic-concurrency version of the aggregate (SPEC §14.3). |
currentVersion | Int! |
SubscriptionConnection object edges | [SubscriptionEdge!]! | |
pageInfo | PageInfo! |
SubscriptionEdge object cursor | String! | |
node | Subscription! |
SupersedeInvoiceIntentSuccess object invoiceIntent | InvoiceIntent! | The replacement intent (intentVersion incremented, same chain). |
clientMutationId | String! |
SynchronizeInvoiceAccepted object operation | Operation! | Durable operation to follow; work continues asynchronously. |
clientMutationId | String! |
Team object id | ID! | |
organizationId | ID! | |
name | String! | |
slug | String! | |
legalName | String | |
baseCurrency | String! | |
timeZone | String! | |
locale | String! | |
status | String! |
TeamMembershipRecord object A team membership in the admin directory.
id | ID! | |
userId | ID! | |
email | String | |
roles | [String!]! | |
status | String! | |
createdAt | DateTime! |
UpsertCustomerSuccess object customer | Customer! | |
clientMutationId | String! |
UsageAggregate object Aggregation preview for a metric over a period at a fixed cutoff (BC-US-053).
metricCode | String! | |
aggregation | String! | |
quantity | Decimal! | |
eventCount | Int! | |
excludedLate | Int! | |
firstOccurredAt | DateTime | |
lastOccurredAt | DateTime | |
cutoff | DateTime! |
UsageBatchItemResult object externalEventId | String! | |
status | String! | accepted | duplicate | rejected | quarantined |
detail | String |
UsageEventConflict object The external event ID was already used with a different payload (BC-US-050).
code | String! | |
message | String! | |
clientMutationId | String |
UsageIngestOutcome object Result of one ingested usage event.
status | String! | accepted | duplicate | quarantined |
usageEventId | ID | |
quarantineReason | String |
ValidateErpConnectionSuccess object erpConnection | ErpConnection! | |
clientMutationId | String! |
ValidationProblem object code | String! | |
message | String! | |
fields | [FieldProblem!]! | |
clientMutationId | String |
VersionConflict object expectedVersion | Int | |
actualVersion | Int | |
clientMutationId | String |
Viewer object The authenticated principal and its memberships.
id | ID! | |
status | String! | |
platformAdmin | Boolean! | |
organizationMemberships | [ViewerOrganizationMembership!]! | |
teamMemberships | [ViewerTeamMembership!]! |
ViewerOrganizationMembership object organization | Organization! | |
roles | [String!]! |
ViewerTeamMembership object team | Team! | |
roles | [String!]! |
VoidUsageEventSuccess object status | String! | voided | already_voided |
clientMutationId | String! |
AddTeamMemberResult union
= AddTeamMemberSuccess | ValidationProblem | AuthorizationProblem
ApproveCreditCloseResult union
= ApproveCreditCloseSuccess | ValidationProblem | AuthorizationProblem
ApproveInvoiceResult union
= ApproveInvoiceSuccess | ValidationProblem | AuthorizationProblem
ArchiveTeamResult union
= ArchiveTeamSuccess | ValidationProblem | AuthorizationProblem
BookInvoiceResult union
= BookInvoiceAccepted | ValidationProblem | AuthorizationProblem | IdempotencyConflict
CancelSubscriptionResult union
= CancelSubscriptionSuccess | ValidationProblem | AuthorizationProblem | IdempotencyConflict
ChangeOrganizationRolesResult union
= ChangeOrganizationRolesSuccess | ValidationProblem | AuthorizationProblem
ChangeSubscriptionResult union
= ChangeSubscriptionSuccess | ValidationProblem | AuthorizationProblem | IdempotencyConflict
ChangeTeamRolesResult union
= ChangeTeamRolesSuccess | ValidationProblem | AuthorizationProblem
CloseCreditPeriodResult union
= CloseCreditPeriodSuccess | ValidationProblem | AuthorizationProblem
CreateBillingRunResult union
= CreateBillingRunSuccess | ValidationProblem | AuthorizationProblem | IdempotencyConflict
CreateChargeInstanceResult union
= CreateChargeInstanceSuccess | ValidationProblem | AuthorizationProblem | IdempotencyConflict
CreateContractResult union
= CreateContractSuccess | ValidationProblem | AuthorizationProblem
CreateCreditClosePolicyResult union
= CreateCreditClosePolicySuccess | ValidationProblem | AuthorizationProblem
CreateOrganizationResult union
= CreateOrganizationSuccess | ValidationProblem | AuthorizationProblem
CreatePlanResult union
= CreatePlanSuccess | ValidationProblem | AuthorizationProblem
CreatePlanVersionResult union
= CreatePlanVersionSuccess | ValidationProblem | AuthorizationProblem
CreateProductResult union
= CreateProductSuccess | ValidationProblem | AuthorizationProblem
CreateSubscriptionResult union
= CreateSubscriptionSuccess | ValidationProblem | AuthorizationProblem | VersionConflict | IdempotencyConflict
CreateTeamResult union
= CreateTeamSuccess | ValidationProblem | AuthorizationProblem
FreezeInvoiceIntentResult union
= FreezeInvoiceIntentSuccess | ValidationProblem | MappingProblem | AuthorizationProblem | IdempotencyConflict
GenerateCreditCloseReplacementResult union
= GenerateCreditCloseReplacementSuccess | ValidationProblem | AuthorizationProblem
GenerateCreditCloseResult union
= GenerateCreditCloseSuccess | ValidationProblem | AuthorizationProblem | IdempotencyConflict
GrantCreditResult union
= GrantCreditSuccess | ValidationProblem | AuthorizationProblem | IdempotencyConflict
IngestUsageBatchResult union
= IngestUsageBatchSuccess | ValidationProblem | AuthorizationProblem
IngestUsageEventResult union
= IngestUsageEventSuccess | UsageEventConflict | ValidationProblem | AuthorizationProblem
InviteOrganizationMemberResult union
= InviteOrganizationMemberSuccess | ValidationProblem | AuthorizationProblem
MapCustomerToErpResult union
= MapCustomerToErpSuccess | ValidationProblem | AuthorizationProblem
MapProductToErpResult union
= MapProductToErpSuccess | ValidationProblem | AuthorizationProblem
PublishPlanVersionResult union
= PublishPlanVersionSuccess | ValidationProblem | AuthorizationProblem
RecordExternalSettlementResult union
= RecordExternalSettlementSuccess | ValidationProblem | AuthorizationProblem
RemoveTeamMemberResult union
= RemoveTeamMemberSuccess | ValidationProblem | AuthorizationProblem
RenameTeamResult union
= RenameTeamSuccess | ValidationProblem | AuthorizationProblem
RequestCreditClosePostingResult union
= RequestCreditClosePostingSuccess | ValidationProblem | AuthorizationProblem | IdempotencyConflict
RequestCreditCloseReversalResult union
= RequestCreditCloseReversalSuccess | ValidationProblem | AuthorizationProblem
RetryOperationResult union
= RetryOperationSuccess | ValidationProblem | AuthorizationProblem
RevokeOrganizationInvitationResult union
= RevokeOrganizationInvitationSuccess | ValidationProblem | AuthorizationProblem
SetCreditDispositionPolicyResult union
= SetCreditDispositionPolicySuccess | ValidationProblem | AuthorizationProblem
SupersedeInvoiceIntentResult union
= SupersedeInvoiceIntentSuccess | ValidationProblem | MappingProblem | AuthorizationProblem
SynchronizeInvoiceResult union
= SynchronizeInvoiceAccepted | MappingProblem | ValidationProblem | AuthorizationProblem | IdempotencyConflict
UpsertCustomerResult union
= UpsertCustomerSuccess | ValidationProblem | AuthorizationProblem | VersionConflict | IdempotencyConflict
ValidateErpConnectionResult union
= ValidateErpConnectionSuccess | ValidationProblem | AuthorizationProblem
VoidUsageEventResult union
= VoidUsageEventSuccess | UsageEventConflict | ValidationProblem | AuthorizationProblem
AddTeamMemberInput input teamId | ID! | |
userId | ID! | An existing user with an active membership in the owning organization. |
teamRoles | [String!]! | team_admin, billing_admin, finance_operator, auditor, integration_client. |
clientMutationId | String! |
ApproveCreditCloseInput input teamId | ID! | |
creditCloseId | ID! | |
reason | String | |
clientMutationId | String! |
ApproveInvoiceInput input teamId | ID! | |
invoiceIntentId | ID! | |
reason | String | |
clientMutationId | String! |
ArchiveTeamInput input organizationId | ID! | |
targetTeamId | ID! | The team to archive. Named so the scope stays organization-level: an owner/admin need not be a member of the team being archived. |
clientMutationId | String! |
BookInvoiceInput input teamId | ID! | |
invoiceIntentId | ID! | |
idempotencyKey | String! | |
clientMutationId | String! |
CancelSubscriptionInput input teamId | ID! | |
subscriptionId | ID! | |
mode | CancellationMode! | |
effectiveDate | Date | |
periodEndDate | Date | Required for END_OF_PERIOD: the period boundary computed by billing. |
reason | String | |
idempotencyKey | String! | |
clientMutationId | String! |
ChangeOrganizationRolesInput input organizationId | ID! | |
membershipId | ID! | |
organizationRoles | [String!]! | organization_owner, organization_admin, or organization_member. |
clientMutationId | String! |
ChangeSubscriptionInput input teamId | ID! | |
subscriptionId | ID! | |
quantity | Decimal! | |
effectiveDate | Date | Defaults to today in the subscription's time zone. |
idempotencyKey | String! | |
clientMutationId | String! |
ChangeTeamRolesInput input teamId | ID! | |
membershipId | ID! | |
teamRoles | [String!]! | team_admin, billing_admin, finance_operator, auditor, integration_client. |
clientMutationId | String! |
CloseCreditPeriodInput input teamId | ID! | |
creditCloseId | ID! | |
clientMutationId | String! |
CreateBillingRunInput input teamId | ID! | |
runKey | String! | Stable run key; reopening the same key returns the existing run. |
invoiceDate | Date! | |
usageCutoff | DateTime! | |
idempotencyKey | String! | |
clientMutationId | String! |
CreateChargeInstanceInput input teamId | ID! | |
contractId | ID! | |
subscriptionId | ID | |
externalId | String! | |
productId | ID! | |
productVersion | Int! | |
eligibleOn | Date! | |
recognitionMode | RecognitionMode! | |
amountMinor | MoneyMinorUnits | Pricing source A: explicit amount in minor units (quantity fixed at 1). |
priceComponentId | ID | Pricing source B: a price component with a positive quantity. |
quantity | Decimal | |
currency | String | |
serviceStart | Date | |
serviceEndExclusive | Date | |
idempotencyKey | String! | |
clientMutationId | String! |
CreateContractInput input teamId | ID! | |
customerId | ID! | |
externalReference | String | |
currency | String! | |
startDate | Date! | |
endDateExclusive | Date | |
clientMutationId | String! |
CreateCreditClosePolicyInput input teamId | ID! | |
effectiveFrom | Date! | |
journalNumber | Int! | |
liabilityAccountNumber | Int! | |
defaultOffsetAccountNumber | Int! | |
postZeroDelta | Boolean | |
vatNeutral | Boolean | |
settlementMode | String | none (default — blocks automatic credit application), erp_customer_settlement, or external_reference. |
settlementClearingAccountNumber | Int | |
settlementContraAccountNumber | Int | |
clientMutationId | String! |
CreateOrganizationInput input name | String! | |
teamName | String | |
legalName | String | |
baseCurrency | String | |
timeZone | String | |
locale | String | |
clientMutationId | String! |
CreatePlanInput input teamId | ID! | |
code | String! | |
name | String! | |
clientMutationId | String! |
CreatePlanVersionInput input teamId | ID! | |
planId | ID! | |
currency | String! | |
intervalUnit | IntervalUnit! | |
intervalCount | Int! | |
billingTiming | BillingTiming! | |
effectiveFrom | Date | |
components | [PriceComponentInput!]! | |
clientMutationId | String! |
CreateProductInput input teamId | ID! | |
code | String! | |
name | String! | |
description | String | |
recognitionMode | RecognitionMode | |
servicePeriodSource | String | |
clientMutationId | String! |
CreateSubscriptionInput input teamId | ID! | |
contractId | ID! | |
externalId | String! | |
planVersionId | ID! | |
startsOn | Date! | |
endDateExclusive | Date | |
billingAnchorDay | Int | |
quantity | Decimal! | |
idempotencyKey | String! | |
clientMutationId | String! |
CreateTeamInput input organizationId | ID! | |
name | String! | |
legalName | String | |
baseCurrency | String | |
timeZone | String | |
locale | String | |
clientMutationId | String! |
FixedRecurringPricingInput input unitPrice | Decimal! | Unit price per interval in major currency units. |
FreezeInvoiceIntentInput input teamId | ID! | |
subscriptionId | ID! | |
asOf | Date! | The preview date; the billing period containing it is frozen. |
billingRunId | ID | |
idempotencyKey | String! | |
clientMutationId | String! |
GenerateCreditCloseInput input teamId | ID! | |
currency | String! | |
periodDate | Date! | Any date inside the close month; the calendar month is frozen. |
bootstrapOpeningMinor | MoneyMinorUnits | Required only for the very first close of a currency (zero is valid). |
policyVersionId | ID | Defaults to the latest policy version. |
idempotencyKey | String! | |
clientMutationId | String! |
GenerateCreditCloseReplacementInput input teamId | ID! | |
creditCloseId | ID! | The reversed close whose period is being reposted. |
policyVersionId | ID! | The corrected posting-policy version. |
reason | String! | Recorded correction reason — required for the audit trail. |
clientMutationId | String! |
GrantCreditInput input teamId | ID! | |
creditAccountId | ID! | |
originType | String! | unused_prepaid_service, goodwill, external_correction, or manual. |
amountMinor | MoneyMinorUnits! | |
currency | String! | |
reasonCode | String | |
expiresAt | DateTime | |
idempotencyKey | String! | |
clientMutationId | String! |
IngestUsageBatchInput input teamId | ID! | |
events | [UsageBatchEventInput!]! | |
clientMutationId | String! |
IngestUsageEventInput input teamId | ID! | |
externalEventId | String! | |
subscriptionId | ID | |
subscriptionExternalId | String | |
metricCode | String! | |
occurredAt | DateTime! | |
value | Decimal! | |
properties | Json | |
clientMutationId | String! |
InviteOrganizationMemberInput input organizationId | ID! | |
email | String! | |
organizationRoles | [String!] | organization_owner, organization_admin, or organization_member. |
teamId | ID | |
teamRoles | [String!] | team_admin, billing_admin, finance_operator, auditor, integration_client. |
clientMutationId | String! |
MapCustomerToErpInput input teamId | ID! | |
customerId | ID! | |
erpConnectionId | ID! | |
externalCustomerNumber | String! | |
clientMutationId | String! |
MapProductToErpInput input teamId | ID! | |
productId | ID! | |
erpConnectionId | ID! | |
externalProductNumber | String! | |
clientMutationId | String! |
MinimumCommitPricingInput input Minimum commit wrapping an inner usage model (SPEC §10.6).
minimumAmountMinor | MoneyMinorUnits! | |
inner | PricingDefinitionInput! |
OneTimePricingInput input unitPrice | Decimal! |
PackagePricingInput input packageSize | Decimal! | |
packagePrice | Decimal! | Price per whole package in major currency units. |
PriceComponentInput input code | String! | |
productId | ID! | |
pricingDefinition | PricingDefinitionInput! | |
prorationPolicy | String | |
ordinal | Int | |
metricCode | String | Required for metered models: the usage metric this component rates. |
aggregation | String | sum | count | max | unique_count |
PricingDefinitionInput input Versioned pricing definition; exactly one model group is set (SPEC §9.6).
fixedRecurring | FixedRecurringPricingInput | |
oneTime | OneTimePricingInput | |
standardMetered | StandardMeteredPricingInput | |
volumeTier | TieredPricingInput | |
graduatedTier | TieredPricingInput | |
package | PackagePricingInput | |
minimumCommit | MinimumCommitPricingInput |
PricingTierInput input Contiguous tier: half-open [from, to); the final tier omits `to` (SPEC §10.3/10.4).
from | Decimal! | |
to | Decimal | |
unitRate | Decimal! | |
flatFeeMinor | MoneyMinorUnits |
PublishPlanVersionInput input teamId | ID! | |
planVersionId | ID! | |
clientMutationId | String! |
RecordExternalSettlementInput input teamId | ID! | |
settlementId | ID! | |
externalReference | String! | The authoritative external receivables system's settlement reference. |
clientMutationId | String! |
RemoveTeamMemberInput input teamId | ID! | |
membershipId | ID! | |
clientMutationId | String! |
RenameTeamInput input teamId | ID! | |
name | String! | |
clientMutationId | String! |
RequestCreditClosePostingInput input teamId | ID! | |
creditCloseId | ID! | |
idempotencyKey | String! | |
clientMutationId | String! |
RequestCreditCloseReversalInput input teamId | ID! | |
creditCloseId | ID! | |
reason | String! | Recorded correction reason — required for the audit trail. |
clientMutationId | String! |
RetryOperationInput input teamId | ID! | |
operationId | ID! | |
clientMutationId | String! |
RevokeOrganizationInvitationInput input organizationId | ID! | |
invitationId | ID! | |
clientMutationId | String! |
SetCreditDispositionPolicyInput input teamId | ID! | |
creditAccountId | ID! | |
policy | String! | retain, refund, or expire_after. |
expireAfterDays | Int | Required for expire_after. |
clientMutationId | String! |
StandardMeteredPricingInput input unitRate | Decimal! | Per-unit rate in major currency units. |
SupersedeInvoiceIntentInput input teamId | ID! | |
invoiceIntentId | ID! | |
subscriptionId | ID! | |
asOf | Date! | Preview date for the replacement intent's lines. |
reason | String | |
clientMutationId | String! |
SynchronizeInvoiceInput input teamId | ID! | |
invoiceIntentId | ID! | |
idempotencyKey | String! | |
clientMutationId | String! |
TieredPricingInput input tiers | [PricingTierInput!]! |
UpsertCustomerInput input teamId | ID! | |
externalId | String! | |
legalName | String! | |
country | String! | |
email | String! | |
addressLine | String | |
zip | String | |
city | String | |
vatNumber | String | |
currencyPreference | String | |
expectedVersion | Int | Optimistic concurrency against the customer's currentVersion. |
idempotencyKey | String! | |
clientMutationId | String! |
UsageBatchEventInput input externalEventId | String! | |
subscriptionId | ID | |
subscriptionExternalId | String | |
metricCode | String! | |
occurredAt | DateTime! | |
value | Decimal! | |
properties | Json |
ValidateErpConnectionInput input teamId | ID! | |
erpConnectionId | ID! | |
clientMutationId | String! |
VoidUsageEventInput input teamId | ID! | |
externalEventId | String! | The measurement to void. |
voidEventId | String! | External ID of the void itself (idempotency). |
replacement | UsageBatchEventInput | Optional corrected measurement submitted with the void (BC-US-052). |
clientMutationId | String! |
BillingTiming enum IN_ADVANCE | |
IN_ARREARS |
CancellationMode enum IMMEDIATE | |
END_OF_PERIOD |
IntervalUnit enum MONTH | |
DAY |
RecognitionMode enum POINT_IN_TIME | |
OVER_TIME |
Boolean scalar The `Boolean` scalar type represents `true` or `false`.
Date scalar ISO 8601 calendar date, e.g. `2026-09-15`.
DateTime scalar ISO 8601 UTC timestamp, e.g. `2026-08-21T15:00:00Z`.
Decimal scalar Arbitrary-precision decimal serialized as a string, e.g. `"12.5"`. Floats are rejected to protect precision.
ID scalar The `ID` scalar type represents a unique identifier, often used to refetch an object or as key for a cache. The ID type appears in a JSON response as a String; however, it is not intended to be human-readable. When expected as an input type, any string (such as `"4"`) or integer (such as `4`) input value will be accepted as an ID.
Int scalar The `Int` scalar type represents non-fractional signed whole numeric values. Int can represent values between -(2^31) and 2^31 - 1.
Json scalar A JSON object (string keys, JSON-safe values). Used only where a stable typed structure is not yet known (SPEC §14.8 discourages generic blobs; usage-event properties are schema-allowlisted downstream).
MoneyMinorUnits scalar Integer currency amount in minor units (e.g. øre/cents). Currency travels in a sibling field. JSON floats are rejected.
String scalar The `String` scalar type represents textual data, represented as UTF-8 character sequences. The String type is most often used by GraphQL to represent free-form human-readable text.