Skip to main content
This guide shows you how to point your AI agent at Encrata’s auth.md and configure it for autonomous operation. Whether you’re building a custom agent, using an orchestration framework, or configuring an AI coding tool, the setup is the same.

Quick start

  1. Create an API key in the dashboard, or create another with POST /api/account/keys using an existing key
  2. Point your agent at https://developer.encrata.com/auth.md
  3. Provide the API key to your agent’s configuration, for example as ENCRATA_API_KEY
The agent reads the file, verifies the key with the free GET /api/account/credits call, and follows the docs index to find endpoints.

Provide the API key directly

If you already have an API key, just configure your agent with it:

Give the agent the API contract

Point your agent at auth.md and provide the API key through its secret or environment configuration. Never give the agent your Encrata password.

System prompt example

Framework integration

LangChain

CrewAI

Custom agent

Key management best practices

Give each agent its own named key so you can revoke individually without disrupting other agents:
Encrata keys don’t expire. A key works until you disable or revoke it, so rotating periodically limits blast radius if one is compromised.
All keys share the account’s credits. Set an optional credit cap on each key so one agent can’t drain the balance. Once a key reaches its cap, its requests return 402.
Use environment variables or secret managers:
Set up alerts when credits drop below a threshold. Your agent should check GET /api/account/credits before batch operations.

Rate limits

Requests are limited to 200 per minute per account, shared by every key. Every response includes X-Ratelimit-Limit, X-Ratelimit-Remaining, and X-Ratelimit-Reset. On a 429, wait X-Ratelimit-Reset seconds, then retry, up to 3 attempts. 429 responses don’t include a Retry-After header. See Rate limits for the current limit, headers, and retry guidance.

Monitoring agent activity

All API calls made with your key are logged in your dashboard. You can:
  • See which endpoints your agent called
  • Track credit consumption over time
  • Identify unusual patterns
  • Revoke a key instantly if needed