Read the sums of a period.
The consumption of one period as sums: the period the service worked out, the trend
against earlier periods, the average per day, the total, the split by type and the
consumption over time. Single actions are read with GET /credits/usage.
The caller names the period with period and anchor, or with period=custom,
from and to; the answer carries the first and last day the service used. To walk
backwards, send an anchor inside the period before, down to firstBookingDay.
Every key reads the consumption of its own user. Only a tenant manager or an
administrator reads a period other than the running month, gets trend, and reads
the organization with scope=organization.
apiKeyX-API-Key<token>API key issued in the Galilea settings.
scope?stringWhose consumption is read. personal, the default, is the consumption of the key's
user; organization is the whole tenant and is open to a tenant manager or an
administrator only, otherwise the request is refused with 403. Titles of actions
never appear with organization.
"personal""personal""organization"period?stringThe kind of period to read. The service works out its first and last day from
anchor in Europe/Berlin; a caller never sends timestamps. custom reads the days
from from to to. A key of any role other than tenant manager or administrator
reads the running month only: any other value, or month with an anchor outside
the running month, is refused with 403.
"month""week""month""quarter""year""custom"anchor?stringAny day inside the period to read; defaults to today in Europe/Berlin. To read the
period before, send a day inside it, for example the day before period.from of
the last answer. Refused with 400 before 2026-10-01 or after today. Ignored with
period=custom. Nothing booked before 2026-10-01 is readable, for any caller: a
period that begins before it is read from that day on.
datefrom?stringFirst day of a custom period in Europe/Berlin. Required with period=custom and
refused with 400 for every other period. Not before 2026-10-01; a custom period
spans at most 366 days.
dateto?stringLast day of a custom period in Europe/Berlin, inclusive. Required with
period=custom and refused with 400 for every other period. Not after today; at
most 365 days after from.
datetype?CreditUsageTypeReads only actions of this type. Without the parameter every type is read.
"chat""import""search""audit""skillScan""llmGateway""apiKey""workflow"userId?stringReads only the consumption of this person. Valid only with scope=organization;
with scope=personal the request is refused with 400. A person who is not a member
of the key's tenant is answered with 404.
uuidThe sums of the period.
application/json- response
The consumption of one period as sums.
period*The period the service worked out from the parameters.
trend?How consumption developed against earlier periods. Present only for a key of a tenant manager or an administrator.
perDay*integerAverage credits per day in the read period, over the days passed.
0 <= valuetotal*integerCredits consumed in the read period.
0 <= valuebyType*array<>Credits per type in the read period, largest first. Types without consumption are missing.
series*Consumption over time, one point per step from the first day of the period up to today.
curl -X GET "https://example.com/credits/summary?anchor=2026-10-23&from=2026-10-01&to=2026-10-31"{ "period": { "kind": "week", "from": "2019-08-24", "to": "2019-08-24", "daysPassed": 23, "daysLeft": 8, "firstBookingDay": "2026-10-01" }, "trend": { "change": 0.3, "points": [ { "from": "2019-08-24", "perDay": 0 } ] }, "perDay": 49, "total": 1130, "byType": [ { "type": "chat", "credits": 0, "share": 0.945 } ], "series": { "step": "day", "points": [ { "date": "2019-08-24", "byType": { "chat": 812, "import": 30 } } ] }}