Introduction
Give each of your users an AI agent, through one API.
01Your app02Fin API03Agent run04Results
Fin gives each of your users an AI agent that can chat, run tasks on its own and, with the user's signed approval, hold and trade funds. Your backend talks to Fin's REST API; your app keeps its own interface, login and users.
How an integration works
- Create the user with your own
userId, using your API key. - Sign them in. After your login verifies the user, your backend opens a Fin session naming the wallet or passkey they signed in with. Apps without a login can have the user sign a message instead.
- Chat. Send the user's message to start a run in their main conversation, and follow the agent's reply on the event stream or by reading the run.
- Approve actions. When the agent wants to do something that needs the user's OK, the run pauses; show the user the approval and send their decision. Anything that moves money also needs their wallet's signature on a message the API gives you.
- Fund the agent. The user creates the agent's wallet with one signature, deposits to it, and withdraws from it with a signed quote.
The quickstart walks through steps 1–3 with a real request for each.
Who owns what
| Resource | What it is |
|---|---|
| Partner | Your company: its API keys, usage and limits. |
| User | Your customer, named by your userId. |
| Agent | The user's agent, created with them, with its own wallet. |
| Session | Up to an hour of access to one user, opened by your backend. |
| Conversation | A chat thread. Every user has a main one. |
| Run | The agent working on one message. |
| Automation | A task the agent runs on its own. |
Your app and Fin
| Your app does | Fin does |
|---|---|
| Log users in and show the interface | Run the agent and keep every conversation |
| Keep the API key and session tokens on its server | Check sessions and signatures |
| Show the user what they're approving and collect their signature | Hand you the message to sign and enforce exactly what was signed |
| Send deposits from the user's own wallet | Give deposit addresses, send withdrawals and record receipts |
Requests and responses are JSON, errors are problem details, lists are paged with a cursor, and live updates arrive as server-sent events.
Next
- Quickstart: your first agent reply.
- Authentication: API keys, sessions, wallets and the security model.
- Deposits, withdrawals and trades: moving money.
- Usage and limits: what your account can do at once.