The data layer your agents actually use
AI agents need a shared, persistent data layer — not just to store data, but to query it, link it, and share it with other agents and external systems. Rekor gives agents a structured system of record they can read, write, and collaborate through — schemas defined at runtime, no migrations, no setup.
// Agent creates a collection and upserts a document
> manage_collection({ action: "upsert", database_id: "ws_ops",
collection: "incidents", json_schema: {
type: "object",
required: ["title", "severity", "status"],
properties: {
title: { type: "string" },
severity: { type: "string", enum: ["p0","p1","p2","p3"] },
status: { type: "string", enum: ["open","investigating","resolved"] },
assignee: { type: "string" }
}
}
})
< { id: "incidents", name: "incidents", version: 1 }
> manage_document({ action: "upsert", database_id: "ws_ops",
collection: "incidents",
external_id: "INC-2847", external_source: "pagerduty",
data: {
title: "API latency spike in us-east-1",
severity: "p1",
status: "investigating",
assignee: "oncall@team.dev"
}
})
< { id: "01961a3b-...", external_id: "INC-2847", version: 1 }Three Primitives
Everything in Rekor is a collection, a document, or a relationship between documents.
JSON Schema defining a document type. Created at runtime, no migrations needed.
JSON document conforming to a collection schema. Upsert by external ID for idempotency.
Typed, directed link between two documents with metadata. First-class entity, queryable in any direction.
# Define a collection schema
rekor collections upsert incidents \
--schema '{"type":"object","properties":{"title":{"type":"string"}}}'
# Upsert a document by external ID
rekor documents upsert incidents \
--external-id INC-2847 --source pagerduty \
--data '{"title":"API spike","severity":"p1"}'
# Link two documents with a typed relationship
rekor relationships upsert \
--type caused_by --source incidents/rec_1 \
--target deployments/rec_2Three Interfaces
Builders design schemas via CLI. Agents operate in production via MCP. External systems integrate via REST.
For agent builders. Set up schemas, configure collections, and test in preview environments.
For agent operators. Production agents upsert/read documents, upload/download files via 11 tools.
For external integrations. Connect external systems to Rekor via standard HTTP.
# CLI — agent builders set up schemas and test in preview
npm install -g @rekor/cli
rekor collections upsert incidents --database my-ws--preview \
--schema '{"type":"object","properties":{"title":{"type":"string"}}}'
rekor databases promote my-ws --from my-ws--preview
# MCP — production agents read and write documents
{
"mcpServers": {
"rekor": { "url": "https://mcp.rekor.pro/sse?token=rec_..." }
}
}
# REST — external systems integrate via HTTP
curl https://api.rekor.pro/v1/{database}/documents/incidents \
-H "Authorization: Bearer rec_..." \
-d '{"data":{"title":"Alert from monitoring"}}'Core Data Engine
Atomic, consistent writes per database
Filter, sort, aggregate, and group by at scale
Up to 1,000 atomic operations in a single request
# Atomic operations — all succeed or all fail
rekor batch --database my-database --operations '[
{"type":"upsert_document","collection":"orders",
"data":{"customer":"Acme","total":5000}},
{"type":"upsert_document","collection":"line_items",
"data":{"product":"Widget","qty":10}},
{"type":"upsert_relationship",
"rel_type":"contains",
"source_collection":"orders","source_id":"ord_1",
"target_collection":"line_items","target_id":"li_1"}
]'
# Up to 1,000 operations per batch
# Documents, relationships, and collections supportedFile Attachments
Attach files to any document. Agents upload directly via presigned URLs and retrieve signed download links on demand.
# Upload files with folder structure
rekor attachments upload incidents rec_abc \
--filename docs/runbook.md --content-type text/markdown
rekor attachments upload incidents rec_abc \
--filename docs/screenshots/error.png --content-type image/png
# Get a signed download URL for any file
rekor attachments url incidents rec_abc --filename docs/runbook.md
# List all files, or filter by folder
rekor attachments list incidents rec_abc --prefix docs/Integrations
Integrate with external systems. Configure any REST API as a data source, receive webhooks, and push notifications when data changes.
Configure collections to proxy any REST API — agents use the same tools
Inbound webhooks — external systems push data in
Outbound webhooks — react to data changes
# Same tool, different backends — the agent doesn't know the difference
# Upsert a Stripe invoice (proxied to Stripe API)
rekor documents upsert invoices \
--external-id inv_2847 --source stripe \
--data '{"amount":5000,"status":"issued"}'
# Upsert a native document (stored in Rekor)
rekor documents upsert notes \
--data '{"title":"Follow up on invoice"}'
# Query documents — same interface for both
rekor documents query invoices --source stripe --limit 10# Create a hook — external systems POST data to Rekor
rekor hooks create --database my-database \
--name "PagerDuty Incidents" --collection incidents
# Hook returns a unique URL: /v1/{ws}/hooks/{hook_id}/ingest
# External system POSTs JSON → Rekor creates a document automatically
# Create a trigger — Rekor notifies you when data changes
rekor triggers create --database my-database \
--name "Notify Slack on P1" --collection incidents \
--url https://hooks.slack.com/services/T00/B00/xxx \
--events '["create","update"]'
# When a document is created or updated, Rekor POSTs to the URL
# with an HMAC signature for authenticityMCP Factory
Create custom MCP servers from your data schemas. Build purpose-built tool sets for specialized agents — no code required.
Agents see create_invoice, list_payments — not generic database operations
Each endpoint exposes exactly the tools an agent needs — nothing more
Tool definitions generated from your collection schemas automatically
# Quick: create an endpoint with shorthand flags
rekor endpoints upsert invoicing-agent \
--name "Invoicing Agent" \
--tool "invoices:get,list" \
--tool "payments:create,get,list" \
--relationship "invoice_payment:list" \
--batch "invoices:create,update" --batch "payments:create" \
--sql-query
# Advanced: customize tool names and descriptions
rekor endpoints upsert invoicing-agent --config '{
"name": "Invoicing Agent",
"tools": [
{ "collection": "invoices", "operations": ["get", "list"],
"name_override": "search_invoices",
"description_override": "Find invoices by customer or status" }
]
}'
# Get the MCP connection URL
rekor endpoints url invoicing-agent
# → https://mcp.rekor.pro/e/invoicing-agent/mcpAccess & Governance
Scope API keys to specific databases, collections, and permissions. Tag databases to organize by client, project, or team.
Granular access control per database, collection, and permission
Multi-user collaboration with shared databases
Group databases by client, project, or team
# Create a scoped API key for a specific agent
rekor tokens create --name "client-a-agent" \
--grants '[{
"scope": {"databases": ["client-a"], "environments": ["production"]},
"permissions": ["read:documents", "write:documents"]
}]'
# Create a read-only key for a dashboard integration
rekor tokens create --name "dashboard-reader" \
--grants '[{
"scope": {"databases": ["*"]},
"permissions": ["read:documents", "read:collections"]
}]'
# Group databases by client with tags
rekor databases create client-a --name "Client A" \
--tags "client:acme,region:us"
rekor databases list --tag "client:acme"
# List and revoke keys
rekor tokens list
rekor tokens revoke <token_id>Environments
Agents experiment in preview databases. Humans review and promote to production. Schema compatibility checks catch breaking changes before they ship.
# Create a preview database to experiment safely
rekor databases create-preview my-database --name "add-invoices"
# Agent works freely in preview — modify schemas, test with data
rekor collections upsert invoices \
--database my-database--add-invoices \
--schema '{"type":"object","properties":{"amount":{"type":"number"}}}'
# Human reviews and promotes to production
rekor databases promote my-database \
--from my-database--add-invoices --dry-run
# Apply when ready
rekor databases promote my-database \
--from my-database--add-invoices