Skip to main content
GET
Get monthly usage, quota, and billing

Authorizations

Authorization
string
header
required

Partner API key as a Bearer token: Authorization: Bearer gsk_live_.... Live keys (gsk_live_) run real scans; test keys (gsk_test_) run request validation then return deterministic sandbox mocks (sandbox: true, nothing persisted, no rate-limit consumption). Keys are issued per partner and are revokable.

Query Parameters

month
string

UTC calendar month to report on, YYYY-MM. Defaults to the current (in-progress) month.

Pattern: ^\d{4}-(0[1-9]|1[0-2])$

Response

Usage summary for the requested (or current) month.

Per-partner usage rollup for one UTC calendar month — scan counts, quota headroom, and the amount billed for the period. scans.total excludes failed scans (failed scans are not billed and do not count toward the quota) and is the same figure used to evaluate the monthly quota, so quota.used always equals scans.total. Billing is base-fee-plus-overage: a partner with a configured monthly allowance (quota.monthly_scan_quota) is charged a monthly base fee plus a metered rate for scans beyond the allowance, counted chronologically by scan creation time within the period; a partner with no allowance configured is billed flat per scan at the same per-surface-package rate, with no base fee. See billing for the full split.

Only scans you requested through this API are counted. If you also send traffic to Surfaced through a referral link, the signups attributed to you are NOT partner-API scans: they do not appear in GET /api/partner/scans, they do not consume your monthly allowance, and they are never billed to you. Referral attribution and API usage are separate ledgers on purpose — one is credit for traffic you sent, the other is what you asked us to run.

period
object
required
scans
object
required
quota
object | null
required

Null when no monthly_scan_quota is configured for this partner (unlimited).

prorated
boolean
required

True when this period is the partner's first (activation) period, in which case the included allowance and the base fee are scaled by the fraction of the month remaining from activation. Mirrored inside quota for convenience, but authoritative here: quota is null for a partner with no configured allowance, and such a partner can still have a prorated billing.base_fee_cents.

rate_limit_per_hour
integer
required

This partner's configured hourly scan-creation rate limit.

billed_cents
integer | null
required
deprecated

Deprecated — kept for one release for back-compat, always equal to billing.billed_cents. Prefer billing.billed_cents. Null when the partner has no pricing configured at all (distinct from a partner who owes exactly $0).

billing
object
required

Base-fee-plus-overage billing breakdown for the period. billed_cents is null when the partner has no pricing configured at all — distinct from a partner who is correctly billed $0 (e.g. a base fee of 0 and no overage).