Skip to main content
Short task-oriented recipes. Each one solves a single problem end-to-end with both cURL and Node SDK examples where applicable. If a recipe’s not here, it’s probably a longer walkthrough in Guides or a protocol-level pattern in Protocols.

Categories

Transfers & refunds

Cross-border transfers, batch payouts, retries, refunds, scheduled transfers, CSV export.

Agents & auth

Migrate from agent_* to sess_*, rotate keys, freeze an agent, approve spends, check KYA tier.

Protocols

Handle 402 automatically, open a hosted checkout, execute a mandate, send an A2A task, open an MPP session.

Webhooks & events

Verify signatures in Node / Python / Go, dedupe events, replay from DLQ, tunnel to localhost.

Conventions used

All recipes assume:
export SLY_API_KEY=pk_test_...        # sandbox key
# or
export SLY_API_KEY=pk_live_...        # live key
Replace <uuid> placeholders with real IDs from your tenant. Idempotency keys should be generated fresh per operation — most recipes use $(uuidgen) for simplicity.

Getting the SDK

npm install @sly_ai/sdk
All Node examples assume:
import { Sly } from '@sly_ai/sdk';
const sly = new Sly({ apiKey: process.env.SLY_API_KEY });

Requesting a new recipe

Missing something? Open an issue on GitHub or mention it in #docs-feedback in our Slack. Recipe requests are the easiest contribution to accept.