Setup & Installation
Or with the ClawHub CLI, for registry-managed skill folders outside a full OpenClaw workspace:
Version History
zyfai-sdk 1.0.9 Changelog - Updated documentation to clarify that subaccounts (Safe smart wallets) are now deterministic. - Minor text edits for clearer explanations and improved flow in the SKILL.md. - No code or file changes—documentation update only.
What This Skill Does
Zyfai lets any Ethereum wallet earn yield on Base, Arbitrum, and Plasma by deploying a non-custodial Safe smart wallet linked to the user's EOA. Deposited funds are automatically rebalanced across DeFi protocols. The user retains ownership and can withdraw anytime.
It sets up a non-custodial yield-earning subaccount with automated rebalancing in a few SDK calls, without the user manually tracking or interacting with individual DeFi protocols.
When to use it
- Earning passive yield on idle USDC without using a centralized exchange
- Automating DeFi yield for an AI agent's on-chain treasury
- Comparing conservative vs aggressive strategy APYs before committing funds
- Withdrawing a partial amount while keeping the remainder in yield
- Registering an agent smart wallet on the ERC-8004 Identity Registry
Example Workflow
Here's how your AI assistant might use this skill in practice.
User asks: Set up yield earning on my wallet 0x123... on Base with a conservative strategy and deposit 100 USDC
- 1Creates a ZyfaiSDK instance using the API key and connects the wallet to Base (chain ID 8453)
- 2Checks whether a subaccount already exists for the EOA via getSmartWalletAddress
- 3Deploys a Safe subaccount with the conservative strategy if not yet deployed
- 4Calls createSessionKey and verifies hasActiveSessionKey is true before proceeding
- 5Deposits 100 USDC (100000000 in 6-decimal format) to the subaccount via depositFunds
Subaccount deployed and 100 USDC deposited; funds are earning yield automatically on Base
Requirements
Accounts, API keys, or tools you or your AI assistant may need to set up while using this skill.