Quickstart

This guide walks you through the core Rekord API workflow: defining a model, creating a decisioning context, ingesting evidence, and reading the resolved record.

Prerequisites

  • A Rekord workspace with a valid API token that has write permissions.

  • curl or any HTTP client

All examples use $REKORD_API_TOKEN and $REKORD_BASE_URL as environment variables. Replace these with your actual values.

Step 1: Create a model

Define an "Applicant" model with three fields:

curl -X POST "$REKORD_BASE_URL/models" \
  -H "Authorization: Bearer $REKORD_API_TOKEN" \
  -H "Content-Type: application/json" \
  -d '{
    "name": "Applicant",
    "description": "Mortgage applicant profile",
    "fields": [
      {
        "name": "firstName",
        "type": "text",
        "description": "Applicant legal first name",
        "required": true
      },
      {
        "name": "lastName",
        "type": "text",
        "description": "Applicant legal last name",
        "required": true
      },
      {
        "name": "annualIncome",
        "type": "currency",
        "description": "Gross annual income",
        "resolutionPolicy": "highest_confidence"
      }
    ]
  }'

The response includes the server-assigned modelId and a status of draft:

Step 2: Activate the model

A model in draft status cannot accept records. Transition it to active when you're happy it is complete:

Step 3: Create a decisioning context

Open a context to scope your decision:

The context starts with freshness: resolved because there is no evidence to process yet.

Step 4: Ingest a contribution

Submit evidence from a document extraction. The contribution includes per-field confidence scores:

The context is now stale — the platform will process this contribution and resolve it into a record.

Step 5: Read the resolved record

After the platform resolves the contribution (typically within seconds), read the record:

circle-info

Check the freshness field before relying on the data. If it is stale or computing, the record has not yet converged on the latest evidence.

Step 6: Update the record directly

You can also update a record directly through the API. This creates a contribution internally at maximum confidence:

The record is returned immediately with freshness: stale. Once the platform re-resolves, the annualIncome field will reflect the new value — and because direct API writes carry maximum confidence, the new value takes precedence over lower-confidence contributions.

Next steps

  • Learn about Querying & Filtering — filter, sort, expand, and select fields across any list endpoint

  • Explore the full API Reference — detailed endpoint documentation for Models, Records, Contributions, Contexts, Rules, and more

  • Read Building Integrations — production best practices for ingesting data, handling corrections, batch operations, and observing convergence

Last updated