Organizations

Start an organization usage CSV export

Changed on

Queues a CSV export of every charged generation and technique run across the organization's workspaces for an inclusive UTC day range of at most 366 days. Columns: Workspace, Date, Project ID, Project Name, User Email, Modality, Model, Media URL, Cost, Modifiers, Usage pool. The export builds in the background; poll GET /organizations/{organizationId}/usage-exports/{exportId} until status is completed, then download the listed files. A copy of the download link is also emailed to the credential's user. One export per user may be in progress at a time; a second request within a few minutes returns rate_limited. 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.

post/organizations/{organizationId}/usage-exports

Request

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

Path parameters

organizationIdstring required

Organization identifier

Example:org_abc123

Request body

start_datestring required

First UTC day to include (YYYY-MM-DD)

end_datestring required

Last UTC day to include (YYYY-MM-DD)

Example request

{
  "start_date": "2026-08-01",
  "end_date": "2026-08-01"
}

Response

Export queued.

export_idstring required

Usage export identifier

organization_idstring required

Organization identifier

status'queued' | 'running' | 'completed' | 'failed' required

queued and running exports have no files yet; poll until completed or failed

start_datestring required

UTC calendar day in YYYY-MM-DD form

end_datestring required

UTC calendar day in YYYY-MM-DD form

workspace_countinteger required

Workspaces included in the export

row_countinteger nullable required

Total data rows across all parts; null until completed

errorstring nullable required

Failure reason when status is failed

created_atinteger required

When the export was requested (ms since epoch)

completed_atinteger nullable required

When the export finished (ms since epoch); null while in progress

Example response

{
  "export_id": "export_abc123",
  "organization_id": "org_abc123",
  "start_date": "2026-08-01",
  "end_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