Organizations

Get organization usage

Changed on

Returns usage charged across every workspace in an organization for an inclusive UTC day range (default: the last 30 days), as USD totals and run counts. Pass group_by to add one breakdown: per workspace, per member, per model, or per day. The figures come from the same aggregates as the in-app Organization Analytics tab; for per-generation detail with project and user columns, create a usage export instead. Requires an organization with multiple workspaces enabled, and the credential's user must hold billing permissions in that organization. An API key works for the organization that owns its workspace; an OAuth token works for any organization the user administers. Other organizations return 403.

get/organizations/{organizationId}/usage

Request

  • Base URL
    https://app.flora.ai/api/v1
  • URL
    https://app.flora.ai/api/v1/organizations/{organizationId}/usage
  • Auth
    HTTP bearer

Path parameters

organizationIdstring required

Organization identifier

Example:org_abc123

Query parameters

start_datestring

First UTC day to include (YYYY-MM-DD). Defaults to 29 days before end_date.

Example:2026-08-01
end_datestring

Last UTC day to include (YYYY-MM-DD). Defaults to today (UTC).

Example:2026-08-01
group_by'workspace' | 'user' | 'model' | 'day'

Breakdown axis. workspace: one row per organization workspace. user: one row per member (plus agent-attributed pool spend). model: one row per model endpoint, with all technique runs combined under model_id technique. day: one row per UTC day.

Response

Organization usage returned.

organization_idstring required

Organization identifier

total_costnumber required

Usage charged across the organization in USD, derived from the same per-day aggregate as the Organization Analytics tab. Breakdown rows and CSV exports sum exact per-charge amounts, so their totals can differ from this figure by rounding, well under 0.1%.

total_runsinteger required

Charged runs across the organization

group_by'workspace' | 'user' | 'model' | 'day' nullable required

Breakdown axis. workspace: one row per organization workspace. user: one row per member (plus agent-attributed pool spend). model: one row per model endpoint, with all technique runs combined under model_id technique. day: one row per UTC day.

unattributed_costnumber

With group_by=model: USD charged in the covered workspaces that no model row accounts for. Mostly endpoints no longer in any catalog; a small residue can also come from rounding between the per-day and per-model aggregates. Zero when every row was readable. Present when group_by is model.

Example response

{
  "organization_id": "org_abc123",
  "period": {
    "start_date": "2026-08-01",
    "end_date": "2026-08-01"
  },
  "workspaces": [
    {
      "workspace_id": "ws_abc123"
    }
  ],
  "by_workspace": [
    {
      "workspace_id": "ws_abc123"
    }
  ],
  "by_model": [
    {
      "model_id": "t2i-flux-2-pro"
    }
  ],
  "by_day": [
    {
      "date": "2026-08-01"
    }
  ]
}

Changes

    • warning

      added the new not_configured enum value to the / response property for the response status

    • warning

      added the new not_configured enum value to the / response property for the response status

    • warning

      added the new not_configured enum value to the / response property for the response status

    • warning

      added the new not_configured enum value to the / response property for the response status

    • warning

      added the new not_configured enum value to the / response property for the response status

    • warning

      added the new not_configured enum value to the / response property for the response status

    • warning

      added the new not_configured enum value to the / response property for the response status

    • warning

      added the new not_configured enum value to the / response property for the response status

    • warning

      added the new not_configured enum value to the / response property for the response status

    • info

      endpoint added