[PIX-7733] fix costs API cost attribution for usage-only agents #45
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "fix/PIX-7733-cost-attribution"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Что сделано
/api/companies/:companyId/costs/by-agentи legacy/costs, когда heartbeat usage есть, а price data отсутствуетestimatedCostCents,estimatedTotalCostUsd,costStatus,meteredUnpricedRunCount,meteredUnpricedTokensКак проверено
pnpm exec vitest run server/src/__tests__/costs-service.test.ts --reporter=verbosepnpm --filter @paperclipai/server typecheckв основном checkout/api/health= 200/api/companies/$PAPERCLIP_COMPANY_ID/costs/by-agentи/costsтеперь возвращают ненулевойcostCents