Export a period as a PDF report or a CSV table.
Builds the consumption of the period as a file, a report as PDF or a table as CSV, and
answers with a presigned download, as GET /skill-libraries/{libraryId}/export does.
The bytes do not travel through this API. The link is valid for expiresIn seconds,
needs no API key, and downloads the file under filename; anyone holding it can
download the file until then, so a caller fetches it right away and never stores or
shares it. The answer comes once the file is ready; a report takes a few seconds.
The file is named galilea-usage_<tenant short name>_<from>_<to>.<pdf|csv>, for
example galilea-usage_hansen-logistik_2026-10-01_2026-10-31.csv.
The table is built as the Galilea application builds it: UTF-8 with byte order mark,
semicolon as separator, CRLF as line end, every text cell quoted and guarded against
spreadsheet formulas, numbers without thousands separator, credits as whole numbers,
the date as 2026-10-23 and the time as 14:05 in Europe/Berlin, the column names in
the language of the key's user, one line per action whatever the scope. The columns
depend on scope:
| Column | personal | organization |
|---|---|---|
| Date | yes | yes |
| Time | yes | yes |
| Type | yes | yes |
| Action | title of the action | no |
| Person | no | name |
| no | e-mail address | |
| Model | name of the model, empty without a model | yes |
| Credits | whole number | whole number |
Every key exports the consumption of its own user in the running month. Only a tenant
manager or an administrator exports another period or the organization with
scope=organization.
apiKeyX-API-Key<token>API key issued in the Galilea settings.
application/json- body
What to export: the format and the parameters of the other credit operations, with the same defaults and limits.
format*stringpdf for the report, csv for the table.
"pdf""csv"scope?string"personal""personal""organization"period?string"month""week""month""quarter""year""custom"anchor?stringdatefrom?stringdateto?stringdatetype?CreditUsageTypeThe kind of action that consumed credits.
chat: an answer of the agent in a chat.import: a file read into the workspace, a project or a library.search: a search.audit: an audit.skillScan: the scan of an imported skill.llmGateway: calls of the LLM operations made with an API key; one action is one day of one key.apiKey: calls of the other operations made with an API key; one action is one day of one key.workflow: a run of a workflow.
"chat""import""search""audit""skillScan""llmGateway""apiKey""workflow"userId?stringuuidThe presigned download.
application/json- response
A presigned download of a credit report or table.
downloadUrl*stringPresigned download URL; fetch the file with a single HTTP GET and no API key.
expiresIn*integerSeconds until the URL expires.
filename*stringcurl -X POST "https://example.com/credits/exports" \ -H "Content-Type: application/json" \ -d '{ "format": "csv", "scope": "organization", "period": "month", "anchor": "2026-10-23" }'{ "downloadUrl": "https://download.example.com/exports/3adb7c10/galilea-usage_hansen-logistik_2026-10-01_2026-10-31.csv?expires=600&signature=...", "expiresIn": 600, "filename": "galilea-usage_hansen-logistik_2026-10-01_2026-10-31.csv"}