Resources
Yield.xyz AgentKit
GitHub repository for the Yield.xyz AgentKit MCP server.
Yield.xyz AgentKit docs
Official documentation for the Yield.xyz AgentKit.
Privy agentic wallets
Set up Privy server wallets for autonomous agents.
Privy manual approvals
Intents API reference for semi-autonomous workflows.
What is Yield.xyz AgentKit?
Yield.xyz AgentKit is an MCP server that provides AI agents with tools to search yield opportunities, build deposit/withdraw/claim transactions, and check balances across 80+ networks. All yield operations go through MCP tools — agents never call the Yield.xyz REST API directly.| Tool | Purpose |
|---|---|
yields_get_all | Search and filter yields by network, token, type, or provider |
yields_get | Retrieve full metadata for a specific yield |
yields_get_validators | Fetch validator options for delegation-based yields |
yields_get_balances | Check balances and pending actions |
actions_enter | Build transactions to deposit or stake into a yield |
actions_exit | Build transactions to withdraw or unstake from a yield |
actions_manage | Build transactions for pending actions (claim rewards, restake) |
Yield.xyz AgentKit is maintained by the Yield.xyz team. For AgentKit-specific issues, refer to
their GitHub repository.
Prerequisites
- A Privy account with API credentials (dashboard.privy.io)
PRIVY_APP_IDandPRIVY_APP_SECRETset as environment variables- Optionally
PRIVY_WALLET_IDif a wallet already exists - Claude Code installed
- Privy Enterprise plan (required for the semi-autonomous workflow only)
Installation
Install the Yield.xyz AgentKit skill:yield-agentkit-privy) and an agent choice (Claude Code, Cursor, or Codex CLI). Once complete, the skill is symlinked into the project at .agents/skills/yield-agentkit-privy.
Open the agent in the project directory and run:
Workflows
Privy supports two control models depending on approval requirements.Autonomous
The agent signs and broadcasts transactions directly via Privy’s wallet RPC endpoint. Policies are enforced automatically within the TEE. No manual approval is required. Available on any Privy plan.Verify credentials
The skill checks that
PRIVY_APP_ID, PRIVY_APP_SECRET, and optionally PRIVY_WALLET_ID are
present.Configure a policy (optional)
The skill offers to attach a policy (conservative, balanced, or skip). Policies restrict
per-transaction spend, allowed chains, or allowlisted protocols. All enforcement happens inside
the TEE.
Semi-autonomous (Enterprise)
Every transaction is submitted as an intent via Privy’s Intents API. A designated approver must review and approve each transaction on the Privy dashboard before it executes. Intents expire after 72 hours if not approved. Intent statuses:pending (awaiting approval), executed (broadcast), failed (execution error), expired (72h elapsed), rejected (cancelled), dismissed (resource changed).
Complete autonomous setup steps 1–3
Follow the credential verification, MCP registration, and policy configuration steps from the
autonomous workflow above.
Confirm Enterprise prerequisites
Verify the Enterprise plan is active and the approver has been invited and completed MFA.
Create a key quorum
Create a key quorum in the Privy dashboard under Wallet
Infrastructure → Authorization → New Key → Register Key Quorum Instead. Copy the Quorum ID and
provide it to the agent. The agent verifies it via
GET /v1/key_quorums/{id}.Set up webhooks (optional)
Register an HTTPS endpoint under Configuration → Webhooks in the Privy dashboard and enable
all four intent events:
intent.created, intent.authorized, intent.executed, and
intent.failed. See Privy intent webhooks.For testing without a backend, use webhook.site.executed → reads hash.
Transaction flow
Every yield action — enter, exit, or manage — follows the same sequence:- Call
yields_getto inspect the yield schema - Call
actions_enter,actions_exit, oractions_manageto build unsigned transactions - MCP returns an array of transactions with
stepIndex,type, andunsignedTransaction - For each transaction in
stepIndexorder:- Autonomous:
POST /v1/wallets/{id}/rpc→ immediate hash - Semi-autonomous:
POST /v1/intents/wallets/{id}/rpc→ poll untilexecuted
- Autonomous:
- Report results with on-chain confirmation hashes
EVM transactions
Extract only the fields Privy accepts from the unsigned transaction:Solana transactions
Convert hex to base64 before submitting:Multi-transaction ordering
Transactions are processed sequentially instepIndex order. For EVM chains, the nonce increments for each subsequent transaction. If any transaction fails, execution stops immediately and the failure is returned.
The skill never modifies values inside an
unsignedTransaction. Amounts, recipient addresses,
fees, and calldata are passed through exactly as returned by the MCP. Only structural fields are
adjusted for Privy’s signing format.Error handling
| Error | Cause | Action |
|---|---|---|
POLICY_VIOLATION | Transaction exceeds policy limits | Report which rule triggered. Do not retry without user instruction. |
INSUFFICIENT_FUNDS | Wallet lacks gas | Ask the user to add native token to the wallet address. |
FAILED | Transaction failed on-chain | Provide the hash for block explorer inspection. Stop all subsequent transactions. |
What cannot be automated
| Action | Reason |
|---|---|
| Fund the agent wallet | Requires an existing external wallet |
| Invite approver to Privy app | Tied to authenticated user account |
| Complete MFA | Device-bound |
| Create key quorum | API requires user ID input — kept manual for better UX |
| Approve pending intent | By design — this is the point of the workflow |
| Upgrade to Enterprise | Billing — done on the Privy dashboard |
| Webhook setup | No API available — done in Configuration → Webhooks in the dashboard |
Learn more
Yield.xyz AgentKit
Skill repository and MCP server source.
Yield.xyz AgentKit docs
AgentKit reference documentation.
Privy agentic wallets
Wallet setup guide for autonomous agents.
Privy manual approvals
Intents API reference.
Privy webhooks
Webhooks overview for transaction events.
Privy dashboard
Wallet and policy management.

