API Quickstart
This is a minimal REST flow for creating an account, creating an agent, and reading its state. Use the interactive API reference for the complete schemas and current operation details.
1. Authenticate the wallet
Section titled “1. Authenticate the wallet”Create a SIWE message, have the user’s wallet sign it, and encode the message/signature pair as the signature token described in API authentication.
2. Create or find the user
Section titled “2. Create or find the user”Create an account if the wallet is new, or call the login flow when it already has an account.
POST /v1/usersContent-Type: application/jsonAuthorization: Signature <signature-token>Use the request and response schemas in Scalar; do not rely on this abbreviated example as the complete contract.
3. Create an agent
Section titled “3. Create an agent”POST /v1/users/{userId}/agentsContent-Type: application/jsonAuthorization: Signature <signature-token>The request selects the chain, base asset, agent type, name, and optional type-specific configuration. See Creating an agent via API.
4. Fund and activate it
Section titled “4. Fund and activate it”The funding and activation calls depend on the agent type. For the current Vault Agent, follow Vault Agent API integration.
5. Read state
Section titled “5. Read state”Use the type’s balance, position, activity, and statistics operations to verify the agent’s state after each lifecycle step.
Safe client behavior
Section titled “Safe client behavior”- Validate the response before moving to the next step.
- Preserve transaction hashes and request IDs for support.
- Do not blindly retry mutations.
- Treat unsupported type/asset combinations as configuration errors.
- Keep signature tokens and API keys out of logs.