API ReferenceUsage

Get Usage Summary

Returns credit usage for the active billing scope. Team owners and billing members receive team-wide usage by default; other team members receive their own usage.

GET/v2/usage/summary

Usage

TypeScript Example
import { v0 } from 'v0'const result = await v0.usage.getSummary()console.log(result)

API Signature

Request

Query Parameters

start?: string

Inclusive ISO 8601 start timestamp. Defaults to seven days ago.

end?: string

Exclusive ISO 8601 end timestamp. Defaults to the current time.

userId?: string

Filter usage by user. Team owners and billing members may select any team member; other callers may select only themselves.

Response

object: 'usage_summary'

Object type identifier.

range: object

Time range covered by the response.

start: string

Inclusive ISO 8601 start timestamp.

end: string

Exclusive ISO 8601 end timestamp.

scope: object

Authorized billing scope used for this response.

id: string

Billing scope identifier.

type: 'team' | 'personal'

Billing scope type.

isTeamWide: boolean

Whether the response includes usage for the entire team.

userId?: string

User attribution applied to the response, when filtered.

credits: object

Credits consumed during the selected range.

plan: number

Credits consumed from included plan credits.

onDemand: number

Credits consumed from on-demand credits.

total: number

Total credits consumed.

daily: object[]

Daily credit totals in chronological order.

date: string

UTC date in YYYY-MM-DD format.

credits: object

Credits consumed during the selected range.

plan: number

Credits consumed from included plan credits.

onDemand: number

Credits consumed from on-demand credits.

total: number

Total credits consumed.

dataAsOf?: string

Timestamp of the reporting snapshot backing this response.