教程 / 实战普通
How to meter Claude API costs per user in a Next.js SaaS (with code)
内容摘要
Record every Claude API call per user, convert tokens to dollars with the official Claude 5.5 prices, enforce plan caps, and show a usage page. Drizzle + Postgres + the Anthropic TypeScript SDK.