Skip to main content
auth.md is a single Markdown file that Encrata publishes to tell agents how to authenticate. This page covers where to find it, the sections it contains, and how agents are expected to parse it.

Where to find it

The file is served from the API host:
Agents discover it by:
  • Reading documentation or SDK pointers
  • Fetching the canonical URL directly
  • Following links from AI tool configurations (Cursor, Claude Code, Windsurf)
The file carries a Last updated date and its canonical URL at the top, so an agent can tell whether a cached copy is stale.

Sections in order

The file is a numbered walkthrough an agent follows top to bottom.

Title and summary table

A one-line title (# auth.md), a short preamble addressed to the agent, and a table of the facts an agent needs before anything else: The file doesn’t list every endpoint. It points agents to the docs index and the endpoint list instead.

1. Get a key

Tells the agent to ask the user for their API key. The user signs in at https://app.encrata.com, opens API Keys, clicks Create API key, and pastes the key (it starts with enc_). The agent must never ask for the user’s password or sign in on the user’s behalf. Encrata has no password-login endpoint for agents. The agent stores the key in an environment variable such as ENCRATA_API_KEY, and never writes it to logs, chat transcripts, URLs, or version control.

2. Use the key

Shows the key sent as a Bearer token on every request:
The key never goes in a query string.

3. Verify the key

Before running a batch, the agent confirms the key works with a free call:
A 200 means the key is valid. credits_remaining is the account balance.

4. Key facts

5. Errors

Errors are JSON. On authentication and rate-limit failures the body looks like this:
Agents branch on the HTTP status, then on result.code, and never on message. They include request_id when reporting a problem. See Errors for the full list.

6. Rate limits

  • 200 requests per minute per account, shared by every key.
  • Every API response includes:
    • X-Ratelimit-Limit: the limit (200)
    • X-Ratelimit-Remaining: requests left in the current window
    • X-Ratelimit-Reset: seconds until the window resets (not a timestamp)
  • 429 responses don’t include a Retry-After header. Use X-Ratelimit-Reset.

7. Rules for agents

  1. Use only https://developer.encrata.com. encrata.com and app.encrata.com are the website and dashboard, not the API.
  2. Never request, store, or send the user’s password.
  3. Keep the key out of URLs, logs, and anything echoed back to the user.
  4. Verify the key with /api/account/credits before spending credits.
  5. Stop on 401, 402, and 403. Back off on 429 and 5xx.

How agents parse it

Agents treat auth.md as both prose and structured data:
  • Read the summary table first to learn the host, header, and key format
  • Follow the numbered steps in order: get a key, use it, verify it
  • Extract code blocks as templates for HTTP requests. Fenced blocks with language hints (http, json) let agents identify request shapes without ambiguity
  • Branch on status and result.code using the errors table
  • Follow the docs index to find endpoints beyond the examples
Keep the file short and high in signal. Anything an agent doesn’t need to authenticate belongs in the main documentation, not in auth.md.