Get an organization's prepaid units (internal)

Add MCP server to your AI tool

Allow AI tools and LLMs to interact with the API documentation portal through MCP.

MCP server URL

https://docs.usehearsay.com/mcp

Standard setup for AI tools providing an mcp.json file

mcp.json
{
  "integrations MCP server": {
    "url": "https://docs.usehearsay.com/mcp"
  }
}

Close
GET /admin/orgs/{orgId}/prepaid

Returns the organization's prepaid settings (null when it has none), its remaining units per SKU and its prepaid ledger entries, newest first (limit default 20, skip). Super admin only.

Path parameters

  • orgId string Required

    Id of the organization

Query parameters

  • limit number
  • skip number

Responses

  • 200 application/json
    Hide response attributes Show response attributes object
    • data object Required
      Hide data attributes Show data attributes object
      • prepaid object Required
        Hide prepaid attributes Show prepaid attributes object
        • enabled boolean Required

          Whether this org has prepaid settlement at all

        • allowUnpaid boolean Required

          Support override: lets collections through unpaid

        • allowUnpaidReason string | null Required

          Required when allowUnpaid is true; null otherwise

      • balances array[object] Required
        Hide balances attributes Show balances attributes object
        • skuKey string Required

          Values are collection.phone, collection.social, collection.email, collection.ai-chat, collection.financial, collection.discord, collection.reddit, collection.linkedin, collection.legal, collection.file, collection.other, case.flat, case.pro-upgrade, addon.kit-rental, addon.laptop-rental, addon.laptop-rental-setup, addon.managed-service, addon.shipping, addon.live-bank, plan.base, source.per, ai.tokens-overage, adjustment.manual, or adjustment.discount.

        • unitsRemaining number Required
      • ledger array[object] Required
        Hide ledger attributes Show ledger attributes object
        • skuKey string Required

          Values are collection.phone, collection.social, collection.email, collection.ai-chat, collection.financial, collection.discord, collection.reddit, collection.linkedin, collection.legal, collection.file, collection.other, case.flat, case.pro-upgrade, addon.kit-rental, addon.laptop-rental, addon.laptop-rental-setup, addon.managed-service, addon.shipping, addon.live-bank, plan.base, source.per, ai.tokens-overage, adjustment.manual, or adjustment.discount.

        • deltaUnits number Required

          Positive for a grant, negative for a consume/revoke

        • balanceAfterUnits number Required
        • balanceApplied boolean Required

          False means the row is RESERVED: its ledger append landed but its balance move has not. balanceAfterUnits is a placeholder 0 on such a row.

        • reason string Required

          Values are grant, consume, revoke, restore, or admin_grant.

        • description string Required
        • productKey string | null Required
        • quantity number | null Required
        • amountPaidCents number | null Required

          Integer cents

        • currency string Required
        • sourceCase string | null Required
        • sourceExtractionCode string | null Required
        • stripeChargeId string | null Required
        • createdBy string | null Required
        • createdAt string(date-time) Required
    • statusCode number Required
    • timestamp string(date-time) Required
GET /admin/orgs/{orgId}/prepaid
curl \
 --request GET 'http://api.example.com/admin/orgs/{orgId}/prepaid' \
 --header "Authorization: Bearer $ACCESS_TOKEN"
Response examples (200)
{
  "data": {
    "prepaid": {
      "enabled": true,
      "allowUnpaid": false,
      "allowUnpaidReason": "string"
    },
    "balances": [
      {
        "skuKey": "collection.phone",
        "unitsRemaining": 3
      }
    ],
    "ledger": [
      {
        "skuKey": "collection.phone",
        "deltaUnits": 5,
        "balanceAfterUnits": 5,
        "balanceApplied": true,
        "reason": "grant",
        "description": "Purchased 5 phone collections",
        "productKey": "string",
        "quantity": 5,
        "amountPaidCents": 50000,
        "currency": "usd",
        "sourceCase": "string",
        "sourceExtractionCode": "string",
        "stripeChargeId": "ch_3Q2w3E4r5T6y7U8i",
        "createdBy": "string",
        "createdAt": "2026-01-15T10:15:00.000Z"
      }
    ]
  },
  "statusCode": 200,
  "timestamp": "2026-01-15T10:15:00.000Z"
}