← Back to schema index

ValidationStats

Aggregated counters for the authenticated user's validations. Returned by `GET /v1/validations/stats`. Honors the same filter set as `GET /v1/validations` (`date_from`, `date_to`, `type`, `search`, `with_deleted`, `playground`, `batch_id`).

Properties

Field Type Description
type string JSON:API resource type (always `validation_stats`).
attributes object Aggregated counters of the user's validations (matching the filters). The top-level buckets count by `banxico_status` (verdict); `by_status` breaks down by the `status` column (lifecycle).
total integer Total count of the user's validations matching the filters. Counts every row regardless of Banxico status.
valid integer Subset of the total with `banxico_status='valid'` (transfer confirmed).
not_found integer Subset of the total with `banxico_status='not_found'`.
cep_unavailable integer Subset of the total with `banxico_status='cep_unavailable'` (the Banxico CEP service was unavailable at validation time).
error integer Subset of the total with `banxico_status='error'` (Banxico error, e.g. HTTP 5xx or network failure).
pending integer Subset of the total with `banxico_status='pending'`: async validations still queued or processing, with no CEP result yet.
deleted integer Count of the user's soft-deleted validations (matching the same filters).
other integer Remainder of the total after subtracting `valid`, `not_found`, `cep_unavailable`, `error` and `pending`. In practice this is the `invalid` count. Computed as `max(0, total - valid - not_found - cep_unavailable - error - pending)`.
by_type object Breakdown by validation type. `direct + ocr` always sums to `total`.
direct * integer Direct validations (by CLABE/card/phone fields).
ocr * integer OCR validations (from a receipt image).
by_status object Breakdown by lifecycle status (the `status` column: `queued` / `processing` / `valid` / `not_found` / `cep_unavailable` / `invalid` / `failed` / `error`). This is the SAME axis the validations table filters on (unlike `valid` / `not_found` / `cep_unavailable` / `error` / `pending` above, which count by `banxico_status`): an in-flight row shows as `processing`/`queued` here but as `pending` in those buckets. All eight keys are always present (0 when absent) and always sum to `total`.
queued * integer Validations queued, not yet processed (async).
processing * integer Validations being processed against Banxico right now.
valid * integer Validations with lifecycle status `valid` (confirmed).
not_found * integer Validations with status `not_found`.
cep_unavailable * integer Validations with status `cep_unavailable`.
invalid * integer Validations with status `invalid` (invalid input).
failed * integer Validations with status `failed` (pipeline failure).
error * integer Validations with status `error`.

Used in operations

  • GET /v1/validations/stats