Turnkey agent skills
Agent Skills let you operate on Turnkey directly through an AI assistant, no application code required. The agent provisioning workflow skill lets you quickly create a wallet scoped for agent usage through your AI assistant. You can then equip your agent with skills so it can autonomously operate within the boundaries you’ve configured.Agent personas
Turnkey supports different agent roles through policy composition:
These personas can be composed for multi-agent systems. For example, a worker agent proposes trades, an approver agent validates them against risk models, and a human admin retains override authority for high-value actions.
Key implementation decisions
Example: autonomous trading agent
An AI agent that analyzes market data and executes trades on a DEX needs scoped signing authority: it should only be able to call specific router functions on approved contracts, with spending limits and human oversight for large trades.Implementation steps
This guide assumes you’ve completed the Quickstart and have a Turnkey client initialized with your root credentials. The agent will get its own separate credentials.
1
Create a wallet for the agent
Create a dedicated wallet scoped to the agent’s needs. Always check for existing wallets first to avoid creating duplicates.
2
Create a non-root agent user
The agent gets its own user with an API key pair. This user is non-root by default, meaning it has zero permissions until you explicitly create policies.Generate a key pair for the agent (the private key never touches Turnkey):Then create a user tag and the agent user.
userTags takes tag IDs (UUIDs), not string labels, so create the tag first:3
Define scoped policies
With the agent user and wallet created, define policies that scope exactly what the agent can do. Turnkey is default-deny: without an ALLOW policy, the agent cannot sign anything.Base signing policy (scoped to the agent’s wallet):Destination allowlist (restrict to a specific DEX router):Spending cap (limit per-transaction value):Multi-party consensus for large trades:
4
Verify and deploy
Test the agent’s credentials by initializing a client with the agent’s key pair and verifying access:Store the agent’s credentials in your secrets manager: