메인 콘텐츠로 건너뛰기
GET
/
billing
/
usage
/api/v1/billing/usage
curl --request GET \
  --url https://api.venice.ai/api/v1/billing/usage \
  --header 'Authorization: Bearer <token>'
{
  "data": [
    {
      "amount": -0.1,
      "currency": "DIEM",
      "inferenceDetails": null,
      "notes": "API Inference",
      "pricePerUnitUsd": 0.1,
      "sku": "grok-imagine-image-image-unit",
      "timestamp": {},
      "units": 1
    },
    {
      "amount": -0.06356,
      "currency": "DIEM",
      "inferenceDetails": {
        "completionTokens": 227,
        "inferenceExecutionTime": 2964,
        "promptTokens": 339,
        "requestId": "chatcmpl-4007fd29f42b7d3c4107f4345e8d174a"
      },
      "notes": "API Inference",
      "pricePerUnitUsd": 2.8,
      "sku": "zai-org-glm-5-1-llm-output-mtoken",
      "timestamp": {},
      "units": 0.000227
    }
  ],
  "pagination": {
    "limit": 1,
    "page": 200,
    "total": 56090,
    "totalPages": 56090
  }
}
사용자의 사용량 데이터를 내보냅니다. 응답 필드 설명은 아래에서 확인할 수 있습니다:
  • timestamp: 청구 사용량 항목이 생성된 타임스탬프
  • sku: 청구 사용량 항목과 연결된 제품
  • pricePerUnitUsd: 단위당 USD 가격
  • unit: 소비된 단위 수
  • amount: 청구 사용량 항목에 청구된 총 금액
  • currency: 청구 사용량 항목에 청구된 통화
  • notes: 청구 사용량 항목에 대한 메모
  • inferenceDetails.requestId: 추론과 연결된 요청 ID
  • inferenceDetails.inferenceExecutionTime: 추론 실행 시간(밀리초)
  • inferenceDetails.promptTokens: 프롬프트에서 요청한 토큰 수. LLM 사용에만 표시됩니다.
  • inferenceDetails.completionTokens: 완료에서 사용된 토큰 수. LLM 사용에만 표시됩니다.

인증

Authorization
string
header
필수

Bearer authentication header of the form Bearer <token>, where <token> is your auth token.

헤더

Accept
string

Accept header to specify the response format

예시:

"application/json, text/csv"

쿼리 매개변수

currency
enum<string>

Filter by currency

사용 가능한 옵션:
USD,
VCU,
DIEM,
BUNDLED_CREDITS
예시:

"USD"

endDate
string<date-time>

End date for filtering records (ISO 8601)

예시:

"2024-12-31T23:59:59.000Z"

limit
integer
기본값:200

Number of items per page

필수 범위: 0 < x <= 500
예시:

200

page
integer
기본값:1

Page number for pagination

필수 범위: x > 0
예시:

1

sortOrder
enum<string>
기본값:desc

Sort order for createdAt field

사용 가능한 옵션:
asc,
desc
예시:

"desc"

startDate
string<date-time>

Start date for filtering records (ISO 8601)

예시:

"2024-01-01T00:00:00.000Z"

응답

Successful response

The response schema for the billing usage endpoint

data
object[]
필수
pagination
object
필수
warningMessage
string

A warning message to disambiguate DIEM usage from legacy DIEM (formerly VCU) usage