Skip to main content

List Gates

List review gates with GET /v1/structuring/gates: per-schema gates with embedded rules that decide whether each structuring result auto-approves or queues.

A review gate sits between structuring and delivery: after a result's validation checks run, every active gate for the result's schema evaluates its rules, and each gate records an approval decisionauto_approved when every active rule passes, pending when any rule fails. GET /v1/structuring/gates lists all active gates for your organization with their active rules embedded, so one call shows the full quality policy in force.

Gates are scoped to one schema via user_schema_id and evaluated in creation order. Rule evaluation is strict AND: a single failing rule flags the result. A schema with no gates at all records no decision — results carry approval status none and flow onward unguarded. A gate whose rule list is empty passes vacuously and auto-approves every result, which is a common misconfiguration to check for when records seem to skip review.

Gates without any active rules auto-approve all results. After creating a gate, always attach at least one rule via POST /v1/structuring/gates/{id}/rules — the embedded rules array in this listing is the quickest way to audit which gates are actually enforcing anything.

Use this listing as the audit view of your review policy: filter by schema_id to see exactly which conditions a document type must clear before delivery, and read each gate's embedded rules without a second fetch. The links.rules URL on each gate is the management route for attaching new rules; the links.self URL is the detail route that also accepts PUT and DELETE.

GET/v1/structuring/gates

Query parameters

schema_iduuidFilter gates to one schema scope. Omit to list gates across all schemas.

curl

curl -s "https://api.talonic.com/v1/structuring/gates?schema_id=36ef3a00-a4dc-4e49-af6a-66ae20f9b58a" \
  -H "Authorization: Bearer tlnc_your_api_key"

Response

Response fields

dataarrayArray of review gate objects, ordered by created_at ascending.
data[].idstringGate UUID.
data[].namestringGate name.
data[].user_schema_idstringSchema this gate evaluates.
data[].destination_idstring | nullDelivery destination associated with this gate, if any.
data[].on_approvestringConfigured action label on approval. Default: export.
data[].on_flagstringConfigured action label on flag. Default: queue.
data[].auto_approve_after_hoursnumber | nullOptional auto-approval window in hours recorded on the gate.
data[].is_activebooleanWhether the gate evaluates new results. The list returns only active gates.
data[].rulesarrayActive rules attached to this gate (inactive rules are omitted).
data[].rules[].idstringRule UUID.
data[].rules[].namestringRule name.
data[].rules[].typestringRule type: min_confidence, field_confidence, validation_pass, field_presence, field_value, or canonical_complete.
data[].rules[].configobject | nullRule configuration (see Gate Rules for per-type shapes).
data[].rules[].sort_orderintegerRule display order. All active rules are evaluated regardless of order.
data[].created_atstringISO 8601 creation timestamp.
data[].updated_atstringISO 8601 last update timestamp.
data[].linksobjectRelated resource URLs (self, rules).

Response

{
  "data": [
    {
      "id": "4014c518-7f75-425c-bf67-3052464b95a0",
      "name": "Finance approval gate",
      "user_schema_id": "36ef3a00-a4dc-4e49-af6a-66ae20f9b58a",
      "destination_id": null,
      "on_approve": "export",
      "on_flag": "queue",
      "auto_approve_after_hours": 24,
      "is_active": true,
      "rules": [
        {
          "id": "285aae61-8378-49e2-926a-ac54e4e54853",
          "name": "Row confidence at least 0.85",
          "type": "min_confidence",
          "config": { "min": 0.85 },
          "sort_order": 0
        },
        {
          "id": "c79acb3e-3f43-419c-abcc-72f25ff7a058",
          "name": "No failed checks",
          "type": "validation_pass",
          "config": { "scope": "all", "max_failures": 0 },
          "sort_order": 1
        }
      ],
      "created_at": "2026-08-29T11:35:09.040Z",
      "updated_at": "2026-08-29T11:35:09.040Z",
      "links": {
        "self": "/v1/structuring/gates/4014c518-7f75-425c-bf67-3052464b95a0",
        "rules": "/v1/structuring/gates/4014c518-7f75-425c-bf67-3052464b95a0/rules"
      }
    }
  ]
}

Errors

Error responses

401unauthorizedMissing or invalid API key.
429rate_limitedToo many requests. Retry after the period indicated in the Retry-After header.

When a gate flags a result, the decision is recorded with status pending together with per-rule outcomes (rule_results) and a summary of the check outcomes that fed it (validation_summary: total/passed/failed/skipped/errors). When every rule passes, the decision lands as auto_approved with decision_source: "auto". Multiple gates on the same schema each record their own independent decision for every result, which is why [approve/reject](approve-reject-result) calls require a gate_id.

Frequently asked questions

What happens when a schema has multiple gates?+
Every active gate for the schema evaluates independently and records its own approval decision per result. A result can therefore be auto-approved by one gate and pending on another; decisions are per (result, gate) pair, and manual approve/reject actions name the gate they apply to.
Can I link a gate to a delivery destination?+
Yes. Set destination_id when creating or updating a gate to associate approved output with a specific delivery destination configured under the Delivery API. The gate stores the association; routing itself is configured through delivery bindings.
Are soft-deleted gates included in the list?+
No. Only active gates (is_active: true) are returned, and each gate embeds only its active rules. Soft-deleted gates stop evaluating new results, but decisions they already recorded remain and can still be actioned.
What does a result with approval status "none" mean?+
No active gate existed for its schema at evaluation time, so no decision was recorded at all. That is different from auto_approved (a gate evaluated and passed) — "none" means the result was never subject to gating.