Skip to content
Anlyon
Esc
↑↓navigate↵open⌘Jpreview
On this page

Let your agent act for your users in their own accounts

Let your AI agent act for your users in their own accounts, with a limit for each user, the user's approval on risky steps and a graded receipt for every write, while the agent never holds a key.

Anlyon lets your AI agent act for your users in their own accounts, safely.

Know why you need it

Your product has an AI agent, and to be useful it has to act in each user’s Gmail, Calendar, CRM or Slack. An agent that writes there can send the wrong email, refund an order twice, delete a record or leak a key. The customer holds you responsible, not the model.

See what changes

What can no longer happen

  • A loop can’t run past a user’s limit. Set one rule, such as 20 emails a day, and Anlyon counts it for each user before the call. See Impact limits.
  • A risky step can’t run without the user’s yes. The user approves the exact request in your app, and that exact request is what runs. See Workspace connections and end-user connections.
  • The agent can’t leak a key it never holds. Anlyon adds the user’s token at the moment of the call. See Secrets.
  • A prompt can’t switch users. Your server names the user. The tools the model sees have no user field.
  • You always know what happened. Every write returns a receipt with a grade. confirmed means a read-back of the provider’s own record matched. See Receipts and grades.
  • A user who leaves is gone in one call. Erasing a user removes their connections and limit counters and cancels their pending approvals.

What it saves you

  • No runaway refunds or email floods to clean up. A call over the limit, or one the user denies, never reaches the provider.
  • No digging through logs to find out what the agent did. The calls, approvals and receipts are filed under each user.

What you don’t build

  • OAuth for each user: consent, token storage, refresh and revocation.
  • A limit counter per user, and an approval backend your app can call.
  • A record of every write, and a way to erase a user when they leave.

That is weeks of work, and none of it is your product. Read Why Anlyon for the longer version.

Start with a few lines on your server

Bind the user on your server, invoke an action by name, and send the user a connect link when they have not connected yet. The quickstart runs this loop end to end, approval included.

import { Client, EndUserNotConnectedError } from '@anlyonhq/sdk';

const anlyon = new Client({ apiKey: process.env.ANLYON_API_KEY! });

// Your server names the user. The model never does.
const user = anlyon.forUser(session.user.id);

try {
  const { data } = await user.actions.invoke('gmail-send', { raw });
  if (data!.pendingApproval) return { status: 'awaiting_user', approvalId: data!.approvalId };
  return { status: 'sent', grade: data!.grade };
} catch (error) {
  // Not connected yet: show a Connect Gmail button with this link.
  if (error instanceof EndUserNotConnectedError) return { status: 'connect_required', url: error.connectUrl };
  throw error;
}

Use your company’s own accounts the same way

Anlyon also governs the calls your agent makes with your company’s own accounts. Every agent, session and key in an environment draws from the same limit, a person approves the exact change, and each call returns a receipt.

  • A shared limit. Every agent, session and key in the environment draws from the same limit, reserved before dispatch. A new session or key does not get a new allowance. See Impact limits.
  • A bound approval. The human approves the exact change, and that exact change is what runs. See Bound approvals.
  • A receipt with a grade. Confirmed means a read-back matched. Acknowledged means the provider accepted the request and nothing read it back. Unknown means no usable response. Anlyon does not send it again. It stays unknown until a read-back or an operator settles it. Failed, refused and denied mean it did not run. See Receipts and grades.

Govern any HTTPS API

Put any HTTP API your agent calls under a limit, an exact approval and a graded receipt. Declare it as an action over HTTPS. Stripe refunds, GitHub file updates and Resend email sends come with read-back built in, and a verify rule adds it to anything else.

Action What it covers
Stripe refunds A refund of an explicit amount on a payment intent, counted in the action’s currency.
GitHub file updates One existing text file, on a branch you name that is not the default branch.
Resend email sends A limit counted in emails, one per recipient. Confirmed is Resend’s record of the send, not inbox delivery.
Any HTTPS API A declared action. You state what one call changes and how to read the result back.

Know how it behaves

  • Anlyon governs the calls routed through an action. Keep the provider credential with Anlyon, as a connection or in the vault, so the action is the path to the provider.
  • A limit and a grade apply to a governed action. A governed action has an adapter or a declaration.
  • A limit belongs to one environment. It counts the whole environment, or each end user on their own.
  • A declared action grades confirmed when its read-back rule matches. With no read-back rule it grades acknowledged.
  • A receipt is a database record with provider evidence.

Learn the concepts

Handle what goes wrong

Build and operate

For AI agents

If you are an AI agent reading this site, use these instead of scraping HTML. For AI agents has the details.

What Where
Page index with one-line summaries https://docs.anlyon.com/llms.txt
Every page’s Markdown in one file https://docs.anlyon.com/llms-full.txt
One page as Markdown Append .md to its URL, for example https://docs.anlyon.com/quickstart.md
The Anlyon API’s OpenAPI spec https://docs.anlyon.com/api-reference/openapi.json
The Anlyon MCP server https://api.anlyon.com/mcp
How to authenticate Authorization: Bearer anlyon_live_... on https://api.anlyon.com/api/v2/*, plus Anlyon-End-User: <id> to act for one of your users. MCP clients can sign in with OAuth instead.

Was this page helpful?