Get an organization's plan usage (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 /organization/{orgId}/usages-stat

Returns the org's billing model, whether its plan is active and paid, seat, device and storage allowances and usage (storage also in KB/MB/GB/TB), whether the caller may manage billing, and whether the device in deviceId/deviceType is new to the org's cases. Requires a role in the organization (403 otherwise). Returns 400 when the organization has no active plan record.

Path parameters

  • orgId string Required

Query parameters

  • deviceId string
  • deviceType string

    Values are unknown, android, ios, facebook_dump, instagram_dump, threads_dump, or email.

Responses

  • 200 application/json
    Hide response attributes Show response attributes object
    • data object Required
      Hide data attributes Show data attributes object
      • isActive boolean Required
      • billingModel string Required

        Which billing system the org is on. On case-billing there is no seat/device allowance: seats/devices are -1 (unlimited) and clients must not gate work on them.

        Values are legacy or case-billing.

      • isPaidPlan boolean Required
      • isPayAsYouGo boolean Required
      • seats number Required
      • seatsUsed number Required
      • devices number Required
      • deviceUsed number Required
      • storage number Required

        Storage in bytes

      • storageUsed number Required

        Storage used in bytes

      • organizationName string Required
      • organizationSlug string Required
      • organizationId string Required
      • hasUserAccessToBilling boolean Required
      • isNewDevice boolean Required
      • clientPayDetails object | null
      • canAddFreeDevice boolean Required
      • canAddFreeSeats boolean Required
      • storageInKb number Required
      • storageUsedInKb number Required
      • storageInMb number Required
      • storageUsedInMb number Required
      • storageInGb number Required
      • storageUsedInGb number Required
      • storageInTb number Required
      • storageUsedInTb number Required
    • statusCode number Required
    • timestamp string(date-time) Required
GET /organization/{orgId}/usages-stat
curl \
 --request GET 'http://api.example.com/organization/{orgId}/usages-stat' \
 --header "Authorization: Bearer $ACCESS_TOKEN"
Response examples (200)
{
  "data": {
    "isActive": true,
    "billingModel": "legacy",
    "isPaidPlan": true,
    "isPayAsYouGo": false,
    "seats": 10,
    "seatsUsed": 4,
    "devices": 20,
    "deviceUsed": 7,
    "storage": 100000000000,
    "storageUsed": 25000000000,
    "organizationName": "Acme Law LLP",
    "organizationSlug": "acme-law-llp",
    "organizationId": "65a1b2c3d4e5f6a7b8c9d0e1",
    "hasUserAccessToBilling": true,
    "isNewDevice": true,
    "clientPayDetails": {},
    "canAddFreeDevice": true,
    "canAddFreeSeats": true,
    "storageInKb": 100000000,
    "storageUsedInKb": 25000000,
    "storageInMb": 100000,
    "storageUsedInMb": 25000,
    "storageInGb": 100,
    "storageUsedInGb": 25,
    "storageInTb": 0.1,
    "storageUsedInTb": 0.025
  },
  "statusCode": 200,
  "timestamp": "2026-01-15T10:15:00.000Z"
}