Seal

Documentation

Authentication

Last updated May 2026

Seal uses organisation API keys. Pilot access is configured with the team running the workflow, then keys are managed in Settings → API Keys.

Use a key

Aqta keys begin with aqta_.

http
Authorization: Bearer aqta_your_key
python
import os
from openai import OpenAI

client = OpenAI(
    base_url="https://api.aqta.ai/v1",
    api_key=os.environ["SEAL_API_KEY"],
)
typescript
import OpenAI from 'openai';

const client = new OpenAI({
  baseURL: 'https://api.aqta.ai/v1',
  apiKey: process.env.SEAL_API_KEY,
});

Key handling

  • Store keys in a server-side secret manager or environment variable.
  • Do not put keys in browser code, source control, tickets, or screenshots.
  • Use separate keys for separate environments where that helps you investigate a workflow safely.
  • Revoke a key immediately if you believe it has been exposed.

Key scopes

Choose a scope when you create a key in Settings → API Keys. Give each holder the narrowest one that does its job.

ScopeWhat it can doWho holds it
actionsAsk for decisions (POST /v1/actions/authorize) and make model callsAn agent
read,writeEverything an agent key can, plus reading records and routine managementA service you run
read,write,assertAlso signs outcomes your own system reports (POST /v1/actions/receipt)A trusted integration
read,write,adminAlso creates, changes and deletes policies, and creates and deletes keysA person, never an agent

Changing policies and keys

Policies hold the approver lists that require_grant rules check, and keys are the credentials agents hold. Changing either changes who approves, so only a person may do it:

  • a person signed in to the console, or
  • a key that person created with the admin scope.

These calls are covered:

  • POST /v1/policies, PUT /v1/policies/{id} and DELETE /v1/policies/{id}
  • POST /v1/api-keys and DELETE /v1/api-keys/{id}

Any other key, including a default read,write key and an agent key, gets 403 with the code human_session_required:

json
{
  "detail": {
    "code": "human_session_required",
    "message": "This key cannot change policies, approvers or keys. Those changes need a person signed in to the console, or a key created there with the admin scope. Agent and default keys can ask for decisions but cannot change the rules that decide them."
  }
}

An admin key can be created only by a person signed in to the console. A key cannot create an admin key, even an admin key. Keep admin keys out of agent environments: an agent that can read one can rewrite the rule that gates it. Reading policies and keys is unchanged.

Rotate a key

  1. Create a replacement key in Settings → API Keys.
  2. Update the deployed secret.
  3. Confirm the workflow is using the replacement.
  4. Revoke the old key.

Errors

A missing, invalid, or revoked key returns 401. Check the key and its organisation before retrying. A valid key used for something its scope does not allow returns 403, with a code that names what is missing. A temporary request limit may return 429; use bounded exponential backoff rather than repeatedly sending the same request.

Next steps