Import historical events
Bulk-load pre-existing history — score requests, post-call telemetry, identity events and labels — each at its own customer-supplied timestamp, so a new account is not starting from an empty history. An onboarding tool, not a live-traffic path.
Imported rows are inert. They are never scored at ingest, never evaluated against spend caps, never shadow-masked, never counted in live metrics, and never trigger alerts.
An event that fails validation does not fail the batch — it is reported per-event in results. A body that is not valid JSON for this schema (wrong field types, an event_time that is not RFC 3339) fails the whole batch with a 400. Retries are safe: an event_id already loaded comes back as duplicate, not an error.
Availability is deployment-gated; both import routes return a plain-text 404 where it is not enabled.
Bulk-load your pre-existing history — score requests, post-call telemetry, identity events, and labels — each at its own original timestamp. It answers the question you actually want answered before you enforce anything: how would this have scored my last six months?
This is an onboarding tool, not a live-traffic path.
Imported rows are inert
An imported row is never scored at ingest, never evaluated against spend caps, never shadow-masked, never counted in live metrics, and never triggers an alert.
Batching and retries
Up to 1,000 events per call, and 8 MiB per body — a larger cap than the 1 MiB that applies everywhere else.
event_id is required on every event and is what makes retries safe: an id already
loaded comes back as duplicate, not an error, so re-posting a batch after a timeout
is the correct move. Uniqueness is per event type and spans every import_id, so a
new import_id does not make an old event_id loadable again. Give the whole load a
stable import_id so the batches accumulate into one job you can query — without one,
each batch gets its own generated id.
An event that fails validation does not fail the batch. It is reported per-event in
results, and the other events still land. Always check rejected and
results[].reason — a 200 does not mean everything was accepted.
Export post-call events, not just score requests
Token velocity, model mix, and per-account spend all come from post-call telemetry. A score-only import leaves that entire block empty, which is the single most common way to waste a large import. Export both event types together.
Getting the timestamps right
event_time must not be after the server's clock — there is no skew allowance — and
must fall within the deployment's age bound (400 days by default). It becomes the row's
real timestamp, which is the whole point of the endpoint.
Prompt fingerprints on an imported score event enter the comparison corpus at their own
event_time too — otherwise every imported fingerprint would look like it arrived at
once, and the similarity windows would be meaningless.
Warnings on accepted events
A reason can appear on an accepted event when part of it was dropped while the
event itself landed: fingerprint_dropped:<why> for a malformed prompt_fingerprint
block, or fingerprint_store_error when the fingerprint write failed (re-posting the
batch retries it).
OpenAPI
/v1/importRequest body
| Field | Type | Description |
|---|---|---|
import_idOptional | string | Groups every batch of one load into a single job, readable via |
eventsRequired | object[] | 1–1,000 events. The whole body is capped at 8 MiB. An empty or missing array, or more than 1,000 events, is a whole-batch |
Response 200
Batch processed. A per-event rejection does not fail the call — check rejected and results[].reason. There is no 202: every event's outcome is final when the response returns.
| Field | Type | Description |
|---|---|---|
import_idRequired | string | The job this batch counted toward — yours, or the generated one if you sent none. |
receivedRequired | integer | Counts are for this batch only. Cumulative per-load totals live on |
acceptedRequired | integer | |
duplicateRequired | integer | |
rejectedRequired | integer | |
resultsRequired | object[] | One entry per submitted event, in request order — accepted and duplicate events included. |
Response 400
Whole-batch failure; nothing was stored. One of: decode: … (body is not valid JSON, a field has the wrong type, or an event_time is not RFC 3339), events required (missing or empty events), too many events in one batch (more than 1,000), or read body: http: request body too large (body over 8 MiB — a 400, not a 413).
| Field | Type | Description |
|---|---|---|
errorRequired | string | Human-readable message. Not stable — don't parse it. |
Response 401
Missing, malformed, unknown, expired, or revoked API key.
| Field | Type | Description |
|---|---|---|
errorRequired | string | Human-readable message. Not stable — don't parse it. |
Response 404
Not enabled for this deployment. The route is not registered, so the server answers with a plain-text 404 page not found, not a JSON error body. Authentication still runs first, so a request without a valid key gets 401 either way.
View complete OpenAPI definition
openapi: 3.1.0
info:
title: Vectoral API
version: 1.0.0
description: >-
Fraud and abuse detection for AI app builders. Score the accounts hitting
your AI features and catch the abuse draining your inference budget.
servers:
- url: https://api.vectoral.cloud
description: Hosted
- url: http://localhost:8080
description: Self-hosted (default bind)
security:
- bearerAuth: []
paths:
/v1/import:
post:
tags:
- Integration
summary: Import historical events
description: >-
Bulk-load pre-existing history — score requests, post-call telemetry,
identity events and labels — each at its **own customer-supplied
timestamp**, so a new account is not starting from an empty history. An
onboarding tool, not a live-traffic path.
**Imported rows are inert.** They are never scored at ingest, never
evaluated against spend caps, never shadow-masked, never counted in live
metrics, and never trigger alerts.
An event that fails validation does not fail the batch — it is reported
per-event in `results`. A body that is not valid JSON for this schema
(wrong field types, an `event_time` that is not RFC 3339) fails the
**whole batch** with a `400`. Retries are safe: an `event_id` already
loaded comes back as `duplicate`, not an error.
Availability is deployment-gated; both import routes return a plain-text
404 where it is not enabled.
operationId: import
requestBody:
required: true
content:
application/json:
schema:
$ref: '#/components/schemas/ImportRequest'
example:
import_id: csv-export-2026-05
events:
- event_id: evt-001
type: score
event_time: '2026-05-01T09:12:00Z'
score:
account_id: user_abc123
session_id: sess_old_1
request:
ip: 203.0.113.10
user_agent: acme-backend/1.0
model_requested: gpt-4o
estimated_prompt_tokens: 900
- event_id: evt-002
type: post_call
event_time: '2026-05-01T09:12:04Z'
post_call:
account_id: user_abc123
session_id: sess_old_1
model: gpt-4o
prompt_tokens: 900
completion_tokens: 210
inference_cost_usd: 0.0187
- event_id: evt-003
type: label
event_time: '2026-05-02T00:00:00Z'
label:
account_id: user_abc123
label: legitimate
- event_id: evt-004
type: label
event_time: '2026-05-02T00:00:00Z'
label:
account_id: user_abc123
label: maybe
responses:
'200':
description: >-
Batch processed. A per-event rejection does not fail the call —
check `rejected` and `results[].reason`. There is no `202`: every
event's outcome is final when the response returns.
content:
application/json:
schema:
$ref: '#/components/schemas/ImportResponse'
example:
import_id: csv-export-2026-05
received: 4
accepted: 3
duplicate: 0
rejected: 1
results:
- event_id: evt-001
status: accepted
- event_id: evt-002
status: accepted
- event_id: evt-003
status: accepted
- event_id: evt-004
status: rejected
reason: invalid_label
'400':
description: >-
Whole-batch failure; nothing was stored. One of: `decode: …` (body
is not valid JSON, a field has the wrong type, or an `event_time` is
not RFC 3339), `events required` (missing or empty `events`), `too
many events in one batch` (more than 1,000), or `read body: http:
request body too large` (body over 8 MiB — a `400`, not a `413`).
content:
application/json:
schema:
$ref: '#/components/schemas/ErrorResponse'
example:
error: too many events in one batch
'401':
$ref: '#/components/responses/Unauthorized'
'404':
$ref: '#/components/responses/NotEnabled'
components:
schemas:
ImportRequest:
type: object
required:
- events
properties:
import_id:
type: string
description: >-
Groups every batch of one load into a single job, readable via `GET
/v1/import/{importId}`. Server-generated (`imp-` plus 16 hex
characters) if omitted or empty — a fresh id per batch, so batches
without an id never accumulate. Supply your own stable id for
anything beyond a single small batch.
example: csv-export-2026-05
events:
type: array
minItems: 1
maxItems: 1000
items:
$ref: '#/components/schemas/ImportEvent'
description: >-
1–1,000 events. The whole body is capped at 8 MiB. An empty or
missing array, or more than 1,000 events, is a whole-batch `400`.
ImportResponse:
type: object
properties:
import_id:
type: string
example: csv-export-2026-05
description: >-
The job this batch counted toward — yours, or the generated one if
you sent none.
received:
type: integer
description: >-
Counts are for **this batch only**. Cumulative per-load totals live
on `GET /v1/import/{importId}`.
example: 3
accepted:
type: integer
example: 3
duplicate:
type: integer
example: 0
rejected:
type: integer
example: 0
results:
type: array
items:
$ref: '#/components/schemas/ImportResult'
description: >-
One entry per submitted event, in request order — accepted and
duplicate events included.
required:
- import_id
- received
- accepted
- duplicate
- rejected
- results
ErrorResponse:
type: object
properties:
error:
type: string
example: account_id required
description: Human-readable message. Not stable — don't parse it.
required:
- error
description: >-
Uniform error envelope. The message is for humans and is not stable;
branch on the HTTP status.
ImportEvent:
type: object
required:
- event_id
- type
- event_time
description: >-
One historical event. Set exactly one payload field, matching `type`.
Only `account_id` (and, for labels, `label`) is validated inside the
payload; everything else is stored as sent.
Validation runs in this order and the first failure is the event's
`reason`: `missing_event_id`, `missing_event_time`,
`event_time_in_future`, `event_time_too_old`, `unknown_type`,
`multiple_payloads`, `missing_payload` (including a payload set under
the wrong key for `type`), `missing_account_id`, `invalid_label`.
properties:
event_id:
type: string
description: >-
**Your** identifier for this event. Required, and what makes retries
idempotent: an `event_id` already stored for your account comes back
as `duplicate` and nothing is written.
Uniqueness is per event **type**, across every `import_id` — and it
shares a namespace with the optional `event_id` on the live
endpoints. Reusing an id across two different `type`s does not
collide; reusing it within one type always does, even under a new
`import_id`. An `event_id` inside the `score` payload itself is
ignored; this envelope field is the one that counts.
example: evt-001
type:
type: string
enum:
- score
- post_call
- identity
- label
description: Selects which payload field must be set.
example: score
event_time:
type: string
format: date-time
description: >-
When the event actually happened, as an RFC 3339 timestamp. A value
that does not parse fails the **whole batch** with a `400`; a
missing or `null` one rejects just this event
(`missing_event_time`).
Must not be after the server's current time (no skew allowance —
`event_time_in_future`) and no older than the deployment's import
age bound, 400 days by default (`event_time_too_old`). Becomes the
row's timestamp — `received_at` for score/post-call/identity,
`submitted_at` for labels. A `score` event also creates or widens
the account's first/last-seen at this time.
Give each event a **distinct** `event_time` where your source data
allows: two events for one account sharing an exact timestamp each
exclude the other from the other's request-stream windows.
example: '2026-05-01T09:12:00Z'
score:
allOf:
- $ref: '#/components/schemas/ScoreRequest'
description: >-
Required when `type` is `score`. Same body as `POST /v1/score`; only
`account_id` is required here. Stored unscored.
post_call:
allOf:
- $ref: '#/components/schemas/PostCallEvent'
description: >-
Required when `type` is `post_call`. Same body as `POST
/v1/events/post-call`.
identity:
allOf:
- $ref: '#/components/schemas/IdentityRequest'
description: >-
Required when `type` is `identity`. Same body as `POST
/v1/identity`.
label:
allOf:
- $ref: '#/components/schemas/LabelRequest'
description: >-
Required when `type` is `label`. Same body as `POST /v1/labels`;
`label` must be `fraud` or `legitimate`.
ImportResult:
type: object
properties:
event_id:
type: string
example: evt-004
description: >-
Echo of the event's `event_id`. An empty string when the event was
rejected for `missing_event_id`.
status:
type: string
enum:
- accepted
- duplicate
- rejected
description: >-
`duplicate` means this `event_id` was already loaded — the expected,
non-error result of retrying a batch after a timeout. Distinct from
`rejected`.
example: rejected
reason:
type: string
description: >-
Omitted when there is nothing to report. Explains a `rejected`
status: `missing_event_id`, `missing_event_time`,
`event_time_in_future`, `event_time_too_old`, `unknown_type`,
`missing_payload`, `multiple_payloads`, `missing_account_id`,
`invalid_label`, `unserializable_payload`, `store_error` (a database
write failed — re-post the batch; `event_id` makes it safe).
Also appears on an **accepted** event when part of it was dropped
while the event itself landed: `fingerprint_dropped:<why>` for a
malformed `prompt_fingerprint` block, where `<why>` is one of
`unknown_version`, `missing_salt_id`, `bad_simhash`,
`bad_exact_hash`, `bad_conversation_key`,
`minhash_bandkeys_mismatch`, `bad_minhash`, `bad_band_keys`,
`bad_simhash_global`; or `fingerprint_store_error` when the
fingerprint write failed (re-posting retries it). Worth fixing on
the first batch, because `/v1/score` drops a bad block silently.
This vocabulary is a versioned contract — values are added, never
renamed or removed.
example: invalid_label
required:
- event_id
- status
NotEnabledText:
type: string
description: Plain-text body of an unregistered route.
example: |
404 page not found
ScoreRequest:
type: object
required:
- account_id
properties:
account_id:
type: string
description: >-
Your stable identifier for the end-user. The primary join key for
all scoring history. Required and non-empty.
example: user_abc123
session_id:
type: string
description: >-
Your session id. Used as the legacy soft join for browser-signal
fusion when no `request.sensor_token` is sent, and stored for
correlation.
example: sess_xyz
account:
allOf:
- $ref: '#/components/schemas/AccountBlock'
description: Facts about the account in your product. Optional.
request:
allOf:
- $ref: '#/components/schemas/RequestBlock'
description: >-
Per-request context. Optional in the schema, but almost every signal
reads from it — send it.
event_id:
type: string
description: >-
Optional idempotency key. Repeating the same `(customer, event_id)`
returns the **original** verdict with `duplicate: true` and writes
nothing. Make it stable across your own retries; do not derive it
from a transport message id.
example: req_2f9c1a
PostCallEvent:
type: object
required:
- account_id
properties:
account_id:
type: string
example: user_abc123
description: Must match the `account_id` you scored. Required and non-empty.
session_id:
type: string
example: sess_xyz
description: Your session id, stored for correlation.
model:
type: string
example: gpt-4o
description: >-
The model that served the call. Used for the cost fallback and the
model-mix signals; an unrecognised model prices at a default
mid-tier rate.
prompt_tokens:
type:
- integer
- 'null'
description: >-
Omit (or send `null`) when the call has no meaningful count — **do
not send `0`**. An omitted count is recorded as absent; a literal
`0` is recorded as a real zero and read as zero-value abuse
evidence.
example: 1247
completion_tokens:
type:
- integer
- 'null'
description: >-
Same absent-vs-zero rule as `prompt_tokens`, and it matters most
here: image, TTS, STT, rerank and embedding calls legitimately
produce no completion tokens. Sending `0` for those makes every one
of them look like a zero-value call.
example: 340
latency_ms:
type: integer
description: >-
End-to-end latency in milliseconds. Also the input to the
concurrency signal — without it a call cannot be placed on the
timeline. `0` is treated as absent.
example: 2100
inference_cost_usd:
type: number
description: >-
What the call cost you, in USD. When omitted **or `0`** and a token
count is above zero, it is computed from a bundled rate table — so
an explicit `0` cannot override the table for a call with tokens.
Sending the real figure is strongly preferred: the spend-velocity
signal gates on the count of priced rows, so an integration that
never sends it sums to $0.00 indistinguishably from an account that
genuinely spent nothing.
example: 0.0234
event_id:
type: string
description: >-
Optional idempotency key. Repeating the same `(customer, event_id)`
writes nothing and returns `duplicate: true` — spend is not
double-counted and reputation is not re-accrued.
example: call_7d31b0
IdentityRequest:
type: object
required:
- account_id
properties:
account_id:
type: string
example: user_abc123
event_type:
type: string
description: >-
`signup`, `login`, or `dashboard`. Defaults to `login` when omitted.
Not validated — other values are stored verbatim but get no special
treatment; `signup` events anchor the signup-wave detection.
example: login
ip:
type: string
description: >-
The user's real browser IP (IPv4 or IPv6) captured at this
auth/dashboard moment. Wins over `ip_hash` if both are sent.
example: 203.0.113.9
ip_hash:
type: string
maxLength: 128
description: >-
Customer-keyed token instead of `ip`, with identical semantics to
the `/v1/score` field. Ignored when `ip` is also present; a value
over 128 characters is dropped, not rejected. **Use the same form
you use on `/v1/score`** — the account-farming signal unions score
requests and identity events, so sending raw IPs on one endpoint and
tokens on the other splits your own sybil graph and silently weakens
the detection.
example: 9f2c…
asn:
type: integer
minimum: 1
maximum: 4294967295
description: >-
Customer-resolved autonomous system number. `0` means not provided.
Stored only.
example: 13335
ip_country:
type: string
description: >-
Customer-resolved ISO 3166-1 alpha-2 country (case-insensitive).
Anything that isn't two ASCII letters is dropped. When a raw `ip` is
sent and geo enrichment is on, the looked-up country wins. Stored
only.
example: US
minLength: 2
maxLength: 2
user_agent:
type: string
description: Stored for forensic use and signup-wave detection.
event_id:
type: string
description: >-
Optional idempotency key. Repeating the same `(customer, event_id)`
writes nothing and returns `duplicate: true`.
example: login_0c41f2
registration_id:
type: string
description: >-
Links this account to the registration that produced it — the handle
returned by `POST /v1/registrations/score`. Normally sent once, on
the `signup` event. An unknown or already-linked value is ignored
rather than rejected.
example: reg_4k2m9xqv7...
LabelRequest:
type: object
required:
- account_id
- label
properties:
account_id:
type: string
example: user_abc123
description: The account being labelled. Doesn't need prior `/v1/score` calls.
label:
type: string
enum:
- fraud
- legitimate
example: fraud
description: Exact, lower-case. Any other value returns `400`.
notes:
type: string
example: chargeback observed; reseller wrapper detected
description: Free-form reviewer context. Stored, not scored.
event_id:
type: string
description: >-
Optional idempotency key. Repeating the same `(customer, event_id)`
writes nothing and returns `duplicate: true`.
example: label_5510aa
AccountBlock:
type: object
properties:
subscription_tier:
type: string
example: free
description: >-
Free-form tier label from your product (`free`, `pro`, …). Stored on
the account for filtering and review.
first_seen:
type: string
format: date-time
description: >-
When the account was created in your system (RFC 3339).
Informational only. A value that is not a valid RFC 3339 timestamp
fails the request with a `400`.
example: '2026-01-04T12:00:00Z'
context:
$ref: '#/components/schemas/AccountContext'
RequestBlock:
type: object
properties:
ip:
type: string
description: >-
Client IP (IPv4 or IPv6) — strongly recommended. Send the **end
user's** address, not your gateway's: a private or CGNAT egress
address is shared by everyone behind it, so account-farming
detection reports it as uncomputable rather than flagging your own
users.
example: 203.0.113.9
ip_hash:
type: string
maxLength: 128
description: >-
A customer-keyed one-way token standing in for `ip`, for callers who
cannot transmit raw addresses. Preserves credential-sharing and
account-farming detection, which need only equality;
datacenter-origin detection and geo enrichment need the address
itself and become unavailable. Ignored when `ip` is also present; a
value over 128 characters is dropped (not rejected). Use the **same
form consistently** on `/v1/score` and `/v1/identity` — mixing raw
IPs on one and tokens on the other splits your own sybil graph.
example: 9f2c…
asn:
type: integer
minimum: 0
maximum: 4294967295
description: >-
Customer-resolved autonomous system number. Stored for investigation
and review. `0` is treated as absent. A negative, fractional, or
out-of-range value fails JSON decoding and returns `400`.
example: 13335
ip_country:
type: string
description: >-
Customer-resolved ISO 3166-1 alpha-2 country (two letters,
case-insensitive). Fills in `country` when no geo lookup succeeded.
Anything else is dropped. Stored for investigation and review.
example: US
user_agent:
type: string
description: Client user agent. Stored for investigation.
model_requested:
type: string
example: gpt-4o
description: The LLM model you are about to invoke.
estimated_prompt_tokens:
type: integer
example: 1247
description: Your estimate of the prompt token count before invocation.
session_signals:
allOf:
- $ref: '#/components/schemas/SessionSignals'
description: >-
Client-observed session timing. Sending the block at all — even `{}`
— turns on the signals derived from it; omitting it (or `null`)
leaves them gated off.
sensor_token:
type: string
description: >-
The signed token the browser received from `/v1/sensor/collect`,
forwarded by your backend. The trusted, unforgeable way to join the
browser bot verdict — its signed claims carry the real session id,
so it supersedes `session_id` for fusion. A token that fails
verification skips fusion (it does not fall back to `session_id`).
prompt_text:
type: string
description: Only used when Deep Mode is enabled.
prompt_embedding:
type: array
items:
type: number
description: >-
Optional precomputed prompt embedding. Only used when Deep Mode is
enabled; an alternative to `prompt_text`.
prompt_fingerprint:
allOf:
- $ref: '#/components/schemas/PromptFingerprintBlock'
AccountContext:
type: object
description: >-
Optional, customer-attested account facts used as trust/risk priors.
Every field is optional and an omitted field means **unknown** — it is
gated off in scoring, never defaulted to a misleading value. Positive
facts (paid, payment on file, verified) raise trust and can earn a
bounded score discount; negative ones raise risk. Send it inline here
per request, or hydrate it once per account with `POST
/v1/accounts/{accountId}/context`; an inline block overlays the stored
one.
properties:
plan_type:
type: string
enum:
- paid
- unpaid
- trial
- free
description: >-
Case-insensitive. `paid` is a trust signal; `unpaid`, `trial` and
`free` are risk signals. Any other value is ignored (treated as
unknown).
example: paid
has_payment_method:
type: boolean
description: >-
A verified card or payment method on file. The strongest single
trust signal — real identity plus a cost to replace the account.
`false` is a risk signal.
example: true
email_verified:
type: boolean
example: true
description: '`true` raises trust; `false` is a risk signal.'
identity_verified:
type: boolean
description: KYC or equivalent identity verification. `true` raises trust.
example: false
prior_chargeback:
type: boolean
description: A prior chargeback or payment dispute. Strong risk signal.
example: false
billing_delinquent:
type: boolean
example: false
description: Overdue or failed billing. `true` is a risk signal.
trust_label:
type: string
enum:
- vip
- allowlisted
- allowlist
- trusted
description: >-
Case-insensitive. Any of these grants the maximal trust floor. Still
bounded — this is not a hard allowlist and will not suppress an
egregious score. Other values are ignored.
example: vip
SessionSignals:
type: object
properties:
ms_since_last_request:
type: integer
description: Milliseconds since this user's previous request in the same session.
ms_since_page_load:
type: integer
description: Milliseconds since the page that initiated this call loaded.
interaction_events_count:
type: integer
example: 12
description: >-
Mouse / keyboard / focus events you observed in this session. `0` is
meaningful: on a non-first request it fires `no_user_interaction`.
is_first_request_in_session:
type: boolean
description: >-
Whether this is the first request of the session. Interaction-based
signals are skipped on the first request.
ms_since_signup:
type: integer
description: >-
Milliseconds since the account was created. Only read on the first
score Vectoral sees for the account.
description: >-
All fields optional. Inside a sent block, an omitted field reads as
`0`/`false`.
PromptFingerprintBlock:
type: object
description: >-
Optional client-computed prompt fingerprint, enabling the
prompt-similarity signals **without prompt text ever reaching
Vectoral**. Your SDK hashes the prompt locally under a per-tenant salt.
64-bit values travel as strings because JSON cannot carry them safely. A
malformed block is dropped with a logged reason and the request is still
scored — never a 4xx. Nothing fingerprint-derived is echoed in the score
response.
required:
- v
- salt_id
- simhash
- exact_hash
properties:
v:
type: integer
enum:
- 1
description: Format version. Must be `1`.
example: 1
salt_id:
type: string
description: >-
Identifies the tenant salt generation. Fingerprints only ever
compare within one `salt_id`, so a change here starts a fresh
corpus.
example: live
simhash:
type: string
pattern: ^[0-9a-f]{16}$
description: 16 hex digits — 64-bit SimHash of the normalized prompt shingles.
example: 3f2a91c40b7de815
exact_hash:
type: string
pattern: ^[0-9a-f]{16}$
description: >-
16 hex digits — exact-form hash (digit collapse skipped), which
separates verbatim repetition from template reuse.
example: a91c40b7de8153f2
conversation_key:
type: string
maxLength: 256
description: >-
Groups multi-turn context. Same-conversation rows are excluded from
within-account comparison, since follow-up turns are expected to
resemble each other.
example: conv_88f1
minhash:
type: string
description: >-
Base64 (standard alphabet, padded) of the 128-byte MinHash signature
(64 little-endian uint16 values). Present if and only if `band_keys`
is.
example: Zm9vYmFy…
band_keys:
type: array
items:
type: string
minItems: 16
maxItems: 16
description: >-
Exactly 16 LSH band keys as decimal int64 strings. Present if and
only if `minhash` is. **The single highest-yield optional field
here** — cross-account farm detection is unavailable without it.
example:
- '8123456789012345'
- '8123456789117074'
- '8123456789221803'
- '8123456789326532'
- '8123456789431261'
- '8123456789535990'
- '8123456789640719'
- '8123456789745448'
- '8123456789850177'
- '8123456789954906'
- '8123456790059635'
- '8123456790164364'
- '8123456790269093'
- '8123456790373822'
- '8123456790478551'
- '8123456790583280'
simhash_global:
type: string
pattern: ^[0-9a-f]{16}$
description: >-
16 hex digits — unsalted global-tier SimHash. Only sent by customers
who opted into cross-customer sharing.
responses:
Unauthorized:
description: Missing, malformed, unknown, expired, or revoked API key.
content:
application/json:
schema:
$ref: '#/components/schemas/ErrorResponse'
examples:
missing:
summary: No or malformed Authorization header
value:
error: 'missing or malformed Authorization: Bearer <api key>'
invalid:
summary: Unknown, expired, or revoked key
value:
error: invalid, expired, or revoked api key
NotEnabled:
description: >-
Not enabled for this deployment. The route is not registered, so the
server answers with a plain-text `404 page not found`, not a JSON error
body. Authentication still runs first, so a request without a valid key
gets `401` either way.
content:
text/plain:
schema:
$ref: '#/components/schemas/NotEnabledText'
example: |
404 page not found
securitySchemes:
bearerAuth:
type: http
scheme: bearer
description: >-
Your secret API key: `vg_live_` followed by 43 base64url characters.
Send it as `Authorization: Bearer vg_live_…` on every `/v1` request
(except `POST /v1/sensor/collect`, which uses a publishable site key in
the body).