Skip to main content
Two read endpoints return the data behind the Logs and Usage pages, so you can pull it into your own monitoring, alerting or cost reports.

Access

  • Authenticate with an API key or an OAuth token. A restricted key needs the usage:read scope.
  • Workspace admins see every call and every key. Other members see the calls they made and the keys they own.
  • Times are Unix seconds. start_time and end_time are required, and one request covers up to 90 days.
  • Both endpoints page with limit and token: pass the previous response’s next_token as token while has_more is true.

Request log

GET /v3/requests lists write calls (POST, PUT, PATCH, DELETE). Calls are kept for 12 months.

Find a call

Every response carries its request ID in the X-HeyGen-Request-Id header, and error bodies include it too. Log it with your own records, then pass it as request_id to see how the call was handled and charged. To trace a video back to the calls that created it, pass the video ID as job_id.

Response

Usage

GET /v3/usage returns what your API keys spent, per credit pool. It counts charges made with an API key, so OAuth, MCP and web usage sit outside these rows and the total can differ from your workspace balance.

Response

Each row lists spend per pool (api, plan_credit or generative_credit) in that pool’s unit. Read each pool on its own, since units can differ. Refunds count on the day they are made. Periods without spend have no row, and recorded_since marks when per-key recording began. Tag keys with a project and environment on the API keys page to split spend by product line or by staging and production.