ReferenceSDKClient
costs
SDK reference for costs —
getProjectBreakdown
Credit and usage breakdown for one project over a time range
POST
Usage:
const result = await swirls.client.costs.getProjectBreakdown({
projectId: '...',
})Input:
| Parameter | Type | Required | Description |
|---|---|---|---|
projectId | string | Yes | |
range | "24h" | "7d" | "30d" | No |
Output:
| Field | Type | Description |
|---|---|---|
range | string | |
from | string | |
to | string | |
totals | object | |
daily | object[] | |
workflows | object[] | |
nodeTypes | object[] | |
agents | object[] | |
vendors | object[] | |
toolSpendByAgent | object[] |