Skip to main content

Overview

The Intelligence Layer gives you access to the Zyfai yield engine without managing a Smart Wallet or executing any transaction.

Both APIs in this section are read-only and require only your SDK API key — no wallet connection, no signing, no gas.

What it is

The Smart Wallet API handles the full lifecycle of a user's position: deploying the Safe, funding it, rebalancing it, and withdrawing from it. The Intelligence Layer is a separate, lighter surface that exposes the underlying engine's decisions as data you can consume in your own product.

Use it to:

  • Show users what they would earn before they commit any funds
  • Build yield calculators and allocation previews without any on-chain dependency
  • Monitor live risk signals (depegs, liquidity drops, new collateral) from the Zyfai risk engine and surface them in your own UI or alerting system

APIs

simulateBestPositions

Simulates the optimal yield split for a given amount, token, chain(s), and strategy. Returns the pools the engine would route into, the blended APY, and ready-to-use transaction calldata — all without touching the chain.

A good fit for: calculators, "what would I earn" dashboards, pre-deposit previews.

subscribeToEvents

Opens a live WebSocket to the Zyfai risk engine and fires callbacks when something changes — a stablecoin drifting off peg, a pool losing liquidity, or a new collateral type appearing in a vault.

A good fit for: dashboards, risk alerting, monitoring pipelines that run independently of user sessions.

What it is not

The Intelligence Layer does not execute anything. It does not deploy Safes, does not move funds, and does not interact with any smart contract on behalf of a user. For execution, use the Smart Wallet API.