GET
/
v1
/
billing
/
{organizationId}
/
credits
TypeScript client
import { TxAgentKitClient } from '@tx-agent-kit/sdk'

const client = new TxAgentKitClient({
  token: process.env.TX_AGENT_KIT_TOKEN
})

const response = await client.billing.getCreditBalance({
  organizationId: process.env.TX_AGENT_KIT_ORGANIZATION_ID ?? "organizationId",
})
{
  "creditsBalanceDecimillicents": 123,
  "reservedCreditsDecimillicents": 123,
  "availableDecimillicents": 123,
  "isSuspended": true,
  "suspendedAt": "<string>",
  "paymentGracePeriodEndsAt": "<string>"
}

Path Parameters

organizationId
string
required

Response

Success

creditsBalanceDecimillicents
number
required
reservedCreditsDecimillicents
number
required
availableDecimillicents
number
required
isSuspended
boolean
required
suspendedAt
string | null
required
paymentGracePeriodEndsAt
string | null
required