@eco-incorp/sauce 0.99.6 → 0.99.8
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +58 -16
- package/actions/action-program.schema.json +480 -379
- package/actions/dist/abis.d.ts +19 -18
- package/actions/dist/abis.d.ts.map +1 -1
- package/actions/dist/abis.js +29 -29
- package/actions/dist/compile.d.ts +4 -4
- package/actions/dist/compile.d.ts.map +1 -1
- package/actions/dist/compile.js +3 -1
- package/actions/dist/compose.d.ts +63 -6
- package/actions/dist/compose.d.ts.map +1 -1
- package/actions/dist/compose.js +100 -16
- package/actions/dist/index.d.ts +1 -1
- package/actions/dist/index.d.ts.map +1 -1
- package/actions/dist/names.d.ts +88 -0
- package/actions/dist/names.d.ts.map +1 -0
- package/actions/dist/names.js +334 -0
- package/actions/dist/program.d.ts.map +1 -1
- package/actions/dist/program.js +115 -5
- package/actions/dist/registry.d.ts +10 -8
- package/actions/dist/registry.d.ts.map +1 -1
- package/actions/dist/registry.js +10 -8
- package/actions/dist/schema.d.ts.map +1 -1
- package/actions/dist/schema.js +99 -12
- package/actions/dist/semantics.d.ts +12 -2
- package/actions/dist/semantics.d.ts.map +1 -1
- package/actions/dist/semantics.js +78 -8
- package/actions/dist/spec.d.ts +30 -0
- package/actions/dist/spec.d.ts.map +1 -1
- package/actions/dist/spec.js +151 -138
- package/actions/dist/split-swap.d.ts +10 -5
- package/actions/dist/split-swap.d.ts.map +1 -1
- package/actions/dist/split-swap.js +48 -7
- package/actions/dist/to-quote.d.ts +14 -5
- package/actions/dist/to-quote.d.ts.map +1 -1
- package/actions/dist/to-quote.js +210 -244
- package/actions/dist/to-sauce.d.ts +18 -4
- package/actions/dist/to-sauce.d.ts.map +1 -1
- package/actions/dist/to-sauce.js +232 -205
- package/actions/dist/types.d.ts +245 -147
- package/actions/dist/types.d.ts.map +1 -1
- package/actions/dist/types.js +4 -0
- package/docs/README.md +38 -0
- package/docs/api/README.md +37 -23
- package/docs/api/compiler.md +53 -12
- package/docs/api/contracts.md +105 -0
- package/docs/api/coverage.md +96 -57
- package/docs/api/router.md +238 -0
- package/docs/api/routes.md +31 -22
- package/docs/concepts/architecture.md +26 -3
- package/docs/concepts/saucescript.md +35 -55
- package/docs/examples/README.md +21 -14
- package/docs/examples/action-program.ts +51 -35
- package/docs/examples/cross-chain-cascade.sauce.ts +4 -0
- package/docs/examples/cross-chain-intent.sauce.ts +2 -1
- package/docs/examples/evm-execution.ts +2 -4
- package/docs/examples/first-intent.ts +7 -2
- package/docs/examples/pot-router.ts +19 -0
- package/docs/examples/registry-names.ts +52 -0
- package/docs/examples/router-route.sauce.ts +31 -0
- package/docs/examples/router-route.ts +72 -0
- package/docs/examples/router-swap.sauce.ts +16 -0
- package/docs/examples/router-swap.ts +47 -0
- package/docs/examples/venue-where-deployed.sauce.ts +14 -0
- package/docs/guides/actions.md +230 -120
- package/docs/guides/builders-and-actions.md +20 -14
- package/docs/guides/cli.md +1446 -0
- package/docs/guides/compiling.md +19 -7
- package/docs/guides/intents.md +228 -15
- package/docs/guides/mcp.md +540 -0
- package/docs/guides/nested-intents.md +21 -6
- package/docs/guides/protocols-and-tokens.md +218 -39
- package/docs/guides/quick-start.md +5 -0
- package/docs/guides/solana.md +199 -52
- package/docs/guides/verification.md +2 -2
- package/mcp/dist/config.js +78 -0
- package/mcp/dist/config.js.map +1 -0
- package/mcp/dist/entry.js +112 -0
- package/mcp/dist/entry.js.map +1 -0
- package/mcp/dist/files.js +64 -0
- package/mcp/dist/files.js.map +1 -0
- package/mcp/dist/guard.js +262 -0
- package/mcp/dist/guard.js.map +1 -0
- package/mcp/dist/http.js +111 -0
- package/mcp/dist/http.js.map +1 -0
- package/mcp/dist/intents.js +579 -0
- package/mcp/dist/intents.js.map +1 -0
- package/mcp/dist/prompts.js +153 -0
- package/mcp/dist/prompts.js.map +1 -0
- package/mcp/dist/reach.js +98 -0
- package/mcp/dist/reach.js.map +1 -0
- package/mcp/dist/resources.js +154 -0
- package/mcp/dist/resources.js.map +1 -0
- package/mcp/dist/sdk.js +34 -0
- package/mcp/dist/sdk.js.map +1 -0
- package/mcp/dist/server.js +119 -0
- package/mcp/dist/server.js.map +1 -0
- package/mcp/dist/setup.js +189 -0
- package/mcp/dist/setup.js.map +1 -0
- package/mcp/dist/skilltools.js +520 -0
- package/mcp/dist/skilltools.js.map +1 -0
- package/mcp/dist/terms.js +93 -0
- package/mcp/dist/terms.js.map +1 -0
- package/mcp/dist/tools.js +1499 -0
- package/mcp/dist/tools.js.map +1 -0
- package/mcp/dist/wallets.js +168 -0
- package/mcp/dist/wallets.js.map +1 -0
- package/package.json +18 -13
- package/sdk/dist/artifacts/V12Deployments.json +3 -1
- package/sdk/dist/artifacts/V12EngineGate.json +1 -2
- package/sdk/dist/artifacts/V12KitchenProxy.json +1 -0
- package/sdk/dist/chains/canonical.d.ts +15 -24
- package/sdk/dist/chains/canonical.d.ts.map +1 -1
- package/sdk/dist/chains/canonical.js +18 -29
- package/sdk/dist/chains/canonical.js.map +1 -1
- package/sdk/dist/cli/actions.d.ts +29 -0
- package/sdk/dist/cli/actions.d.ts.map +1 -0
- package/sdk/dist/cli/actions.js +122 -0
- package/sdk/dist/cli/actions.js.map +1 -0
- package/sdk/dist/cli/args.d.ts +118 -0
- package/sdk/dist/cli/args.d.ts.map +1 -0
- package/sdk/dist/cli/args.js +354 -0
- package/sdk/dist/cli/args.js.map +1 -0
- package/sdk/dist/cli/assume.d.ts +51 -0
- package/sdk/dist/cli/assume.d.ts.map +1 -0
- package/sdk/dist/cli/assume.js +207 -0
- package/sdk/dist/cli/assume.js.map +1 -0
- package/sdk/dist/cli/chain.d.ts +173 -0
- package/sdk/dist/cli/chain.d.ts.map +1 -0
- package/sdk/dist/cli/chain.js +462 -0
- package/sdk/dist/cli/chain.js.map +1 -0
- package/sdk/dist/cli/commands.d.ts +226 -0
- package/sdk/dist/cli/commands.d.ts.map +1 -0
- package/sdk/dist/cli/commands.js +637 -0
- package/sdk/dist/cli/commands.js.map +1 -0
- package/sdk/dist/cli/create.d.ts +70 -0
- package/sdk/dist/cli/create.d.ts.map +1 -0
- package/sdk/dist/cli/create.js +483 -0
- package/sdk/dist/cli/create.js.map +1 -0
- package/sdk/dist/cli/diagnostics.d.ts +12 -0
- package/sdk/dist/cli/diagnostics.d.ts.map +1 -0
- package/sdk/dist/cli/diagnostics.js +225 -0
- package/sdk/dist/cli/diagnostics.js.map +1 -0
- package/sdk/dist/cli/effects.d.ts +71 -0
- package/sdk/dist/cli/effects.d.ts.map +1 -0
- package/sdk/dist/cli/effects.js +279 -0
- package/sdk/dist/cli/effects.js.map +1 -0
- package/sdk/dist/cli/fill.d.ts +83 -0
- package/sdk/dist/cli/fill.d.ts.map +1 -0
- package/sdk/dist/cli/fill.js +734 -0
- package/sdk/dist/cli/fill.js.map +1 -0
- package/sdk/dist/cli/funding.d.ts +126 -0
- package/sdk/dist/cli/funding.d.ts.map +1 -0
- package/sdk/dist/cli/funding.js +514 -0
- package/sdk/dist/cli/funding.js.map +1 -0
- package/sdk/dist/cli/globals.d.ts +16 -0
- package/sdk/dist/cli/globals.d.ts.map +1 -0
- package/sdk/dist/cli/globals.js +219 -0
- package/sdk/dist/cli/globals.js.map +1 -0
- package/sdk/dist/cli/init.d.ts +34 -0
- package/sdk/dist/cli/init.d.ts.map +1 -0
- package/sdk/dist/cli/init.js +181 -0
- package/sdk/dist/cli/init.js.map +1 -0
- package/sdk/dist/cli/inputs.d.ts +72 -0
- package/sdk/dist/cli/inputs.d.ts.map +1 -0
- package/sdk/dist/cli/inputs.js +152 -0
- package/sdk/dist/cli/inputs.js.map +1 -0
- package/sdk/dist/cli/inspect.d.ts +48 -0
- package/sdk/dist/cli/inspect.d.ts.map +1 -0
- package/sdk/dist/cli/inspect.js +536 -0
- package/sdk/dist/cli/inspect.js.map +1 -0
- package/sdk/dist/cli/intent-commands.d.ts +71 -0
- package/sdk/dist/cli/intent-commands.d.ts.map +1 -0
- package/sdk/dist/cli/intent-commands.js +698 -0
- package/sdk/dist/cli/intent-commands.js.map +1 -0
- package/sdk/dist/cli/intent-svm.d.ts +15 -0
- package/sdk/dist/cli/intent-svm.d.ts.map +1 -0
- package/sdk/dist/cli/intent-svm.js +222 -0
- package/sdk/dist/cli/intent-svm.js.map +1 -0
- package/sdk/dist/cli/intents.d.ts +43 -0
- package/sdk/dist/cli/intents.d.ts.map +1 -0
- package/sdk/dist/cli/intents.js +89 -0
- package/sdk/dist/cli/intents.js.map +1 -0
- package/sdk/dist/cli/interactive.d.ts +11 -0
- package/sdk/dist/cli/interactive.d.ts.map +1 -0
- package/sdk/dist/cli/interactive.js +161 -0
- package/sdk/dist/cli/interactive.js.map +1 -0
- package/sdk/dist/cli/lifecycle-svm.d.ts +109 -0
- package/sdk/dist/cli/lifecycle-svm.d.ts.map +1 -0
- package/sdk/dist/cli/lifecycle-svm.js +299 -0
- package/sdk/dist/cli/lifecycle-svm.js.map +1 -0
- package/sdk/dist/cli/lifecycle.d.ts +439 -0
- package/sdk/dist/cli/lifecycle.d.ts.map +1 -0
- package/sdk/dist/cli/lifecycle.js +1721 -0
- package/sdk/dist/cli/lifecycle.js.map +1 -0
- package/sdk/dist/cli/main.d.ts +3 -0
- package/sdk/dist/cli/main.d.ts.map +1 -0
- package/sdk/dist/cli/main.js +8 -0
- package/sdk/dist/cli/main.js.map +1 -0
- package/sdk/dist/cli/mcp.d.ts +66 -0
- package/sdk/dist/cli/mcp.d.ts.map +1 -0
- package/sdk/dist/cli/mcp.js +169 -0
- package/sdk/dist/cli/mcp.js.map +1 -0
- package/sdk/dist/cli/password.d.ts +54 -0
- package/sdk/dist/cli/password.d.ts.map +1 -0
- package/sdk/dist/cli/password.js +148 -0
- package/sdk/dist/cli/password.js.map +1 -0
- package/sdk/dist/cli/policy.d.ts +130 -0
- package/sdk/dist/cli/policy.d.ts.map +1 -0
- package/sdk/dist/cli/policy.js +702 -0
- package/sdk/dist/cli/policy.js.map +1 -0
- package/sdk/dist/cli/pools.d.ts +140 -0
- package/sdk/dist/cli/pools.d.ts.map +1 -0
- package/sdk/dist/cli/pools.js +658 -0
- package/sdk/dist/cli/pools.js.map +1 -0
- package/sdk/dist/cli/price.d.ts +74 -0
- package/sdk/dist/cli/price.d.ts.map +1 -0
- package/sdk/dist/cli/price.js +321 -0
- package/sdk/dist/cli/price.js.map +1 -0
- package/sdk/dist/cli/prompt.d.ts +30 -0
- package/sdk/dist/cli/prompt.d.ts.map +1 -0
- package/sdk/dist/cli/prompt.js +53 -0
- package/sdk/dist/cli/prompt.js.map +1 -0
- package/sdk/dist/cli/publish.d.ts +48 -0
- package/sdk/dist/cli/publish.d.ts.map +1 -0
- package/sdk/dist/cli/publish.js +480 -0
- package/sdk/dist/cli/publish.js.map +1 -0
- package/sdk/dist/cli/receipt.d.ts +35 -0
- package/sdk/dist/cli/receipt.d.ts.map +1 -0
- package/sdk/dist/cli/receipt.js +63 -0
- package/sdk/dist/cli/receipt.js.map +1 -0
- package/sdk/dist/cli/rehearse.d.ts +80 -0
- package/sdk/dist/cli/rehearse.d.ts.map +1 -0
- package/sdk/dist/cli/rehearse.js +265 -0
- package/sdk/dist/cli/rehearse.js.map +1 -0
- package/sdk/dist/cli/report.d.ts +69 -0
- package/sdk/dist/cli/report.d.ts.map +1 -0
- package/sdk/dist/cli/report.js +206 -0
- package/sdk/dist/cli/report.js.map +1 -0
- package/sdk/dist/cli/returned.d.ts +16 -0
- package/sdk/dist/cli/returned.d.ts.map +1 -0
- package/sdk/dist/cli/returned.js +111 -0
- package/sdk/dist/cli/returned.js.map +1 -0
- package/sdk/dist/cli/run.d.ts +40 -0
- package/sdk/dist/cli/run.d.ts.map +1 -0
- package/sdk/dist/cli/run.js +3163 -0
- package/sdk/dist/cli/run.js.map +1 -0
- package/sdk/dist/cli/signer.d.ts +72 -0
- package/sdk/dist/cli/signer.d.ts.map +1 -0
- package/sdk/dist/cli/signer.js +243 -0
- package/sdk/dist/cli/signer.js.map +1 -0
- package/sdk/dist/cli/simulate.d.ts +11 -0
- package/sdk/dist/cli/simulate.d.ts.map +1 -0
- package/sdk/dist/cli/simulate.js +246 -0
- package/sdk/dist/cli/simulate.js.map +1 -0
- package/sdk/dist/cli/skills.d.ts +77 -0
- package/sdk/dist/cli/skills.d.ts.map +1 -0
- package/sdk/dist/cli/skills.js +527 -0
- package/sdk/dist/cli/skills.js.map +1 -0
- package/sdk/dist/cli/solana.d.ts +184 -0
- package/sdk/dist/cli/solana.d.ts.map +1 -0
- package/sdk/dist/cli/solana.js +1370 -0
- package/sdk/dist/cli/solana.js.map +1 -0
- package/sdk/dist/cli/store.d.ts +60 -0
- package/sdk/dist/cli/store.d.ts.map +1 -0
- package/sdk/dist/cli/store.js +196 -0
- package/sdk/dist/cli/store.js.map +1 -0
- package/sdk/dist/cli/support.d.ts +144 -0
- package/sdk/dist/cli/support.d.ts.map +1 -0
- package/sdk/dist/cli/support.js +217 -0
- package/sdk/dist/cli/support.js.map +1 -0
- package/sdk/dist/cli/svm-effects.d.ts +50 -0
- package/sdk/dist/cli/svm-effects.d.ts.map +1 -0
- package/sdk/dist/cli/svm-effects.js +196 -0
- package/sdk/dist/cli/svm-effects.js.map +1 -0
- package/sdk/dist/cli/terminal.d.ts +42 -0
- package/sdk/dist/cli/terminal.d.ts.map +1 -0
- package/sdk/dist/cli/terminal.js +136 -0
- package/sdk/dist/cli/terminal.js.map +1 -0
- package/sdk/dist/cli/verify.d.ts +32 -0
- package/sdk/dist/cli/verify.d.ts.map +1 -0
- package/sdk/dist/cli/verify.js +185 -0
- package/sdk/dist/cli/verify.js.map +1 -0
- package/sdk/dist/cli/wallet-commands.d.ts +59 -0
- package/sdk/dist/cli/wallet-commands.d.ts.map +1 -0
- package/sdk/dist/cli/wallet-commands.js +222 -0
- package/sdk/dist/cli/wallet-commands.js.map +1 -0
- package/sdk/dist/cli/wallet-send.d.ts +38 -0
- package/sdk/dist/cli/wallet-send.d.ts.map +1 -0
- package/sdk/dist/cli/wallet-send.js +303 -0
- package/sdk/dist/cli/wallet-send.js.map +1 -0
- package/sdk/dist/cli/wallets.d.ts +79 -0
- package/sdk/dist/cli/wallets.d.ts.map +1 -0
- package/sdk/dist/cli/wallets.js +297 -0
- package/sdk/dist/cli/wallets.js.map +1 -0
- package/sdk/dist/deployments/index.d.ts +4 -62
- package/sdk/dist/deployments/index.d.ts.map +1 -1
- package/sdk/dist/deployments/index.js +4 -84
- package/sdk/dist/deployments/index.js.map +1 -1
- package/sdk/dist/deployments/pot.d.ts +17 -7
- package/sdk/dist/deployments/pot.d.ts.map +1 -1
- package/sdk/dist/deployments/pot.js +25 -10
- package/sdk/dist/deployments/pot.js.map +1 -1
- package/sdk/dist/deployments/releases.d.ts +36 -0
- package/sdk/dist/deployments/releases.d.ts.map +1 -0
- package/sdk/dist/deployments/releases.js +61 -0
- package/sdk/dist/deployments/releases.js.map +1 -0
- package/sdk/dist/deployments/releases.json +76 -0
- package/sdk/dist/deployments/v12-addresses.d.ts +13 -0
- package/sdk/dist/deployments/v12-addresses.d.ts.map +1 -1
- package/sdk/dist/deployments/v12-addresses.js +16 -3
- package/sdk/dist/deployments/v12-addresses.js.map +1 -1
- package/sdk/dist/deposit/index.d.ts +6 -6
- package/sdk/dist/deposit/index.d.ts.map +1 -1
- package/sdk/dist/deposit/index.js +1 -1
- package/sdk/dist/deposit/index.js.map +1 -1
- package/sdk/dist/deposit/params.d.ts +4 -4
- package/sdk/dist/deposit/params.d.ts.map +1 -1
- package/sdk/dist/deposit/params.js +7 -4
- package/sdk/dist/deposit/params.js.map +1 -1
- package/sdk/dist/deposit/source.d.ts +3 -30
- package/sdk/dist/deposit/source.d.ts.map +1 -1
- package/sdk/dist/deposit/source.js +7 -83
- package/sdk/dist/deposit/source.js.map +1 -1
- package/sdk/dist/deposit/templates.d.ts +1 -2
- package/sdk/dist/deposit/templates.d.ts.map +1 -1
- package/sdk/dist/deposit/templates.js +10 -2
- package/sdk/dist/deposit/templates.js.map +1 -1
- package/sdk/dist/deposit/types.d.ts +14 -12
- package/sdk/dist/deposit/types.d.ts.map +1 -1
- package/sdk/dist/deposit/types.js +6 -0
- package/sdk/dist/deposit/types.js.map +1 -1
- package/sdk/dist/descriptors/accessors.d.ts +38 -35
- package/sdk/dist/descriptors/accessors.d.ts.map +1 -1
- package/sdk/dist/descriptors/accessors.js +16 -0
- package/sdk/dist/descriptors/accessors.js.map +1 -1
- package/sdk/dist/descriptors/call.d.ts +66 -14
- package/sdk/dist/descriptors/call.d.ts.map +1 -1
- package/sdk/dist/descriptors/call.js +94 -13
- package/sdk/dist/descriptors/call.js.map +1 -1
- package/sdk/dist/descriptors/contracts.generated.d.ts +3393 -0
- package/sdk/dist/descriptors/contracts.generated.d.ts.map +1 -0
- package/sdk/dist/descriptors/contracts.generated.js +728 -0
- package/sdk/dist/descriptors/contracts.generated.js.map +1 -0
- package/sdk/dist/descriptors/derive.d.ts +20 -11
- package/sdk/dist/descriptors/derive.d.ts.map +1 -1
- package/sdk/dist/descriptors/derive.js +68 -30
- package/sdk/dist/descriptors/derive.js.map +1 -1
- package/sdk/dist/descriptors/index.d.ts +6 -7
- package/sdk/dist/descriptors/index.d.ts.map +1 -1
- package/sdk/dist/descriptors/index.js +2 -2
- package/sdk/dist/descriptors/index.js.map +1 -1
- package/sdk/dist/descriptors/links.d.ts +23 -214
- package/sdk/dist/descriptors/links.d.ts.map +1 -1
- package/sdk/dist/descriptors/links.js +1 -232
- package/sdk/dist/descriptors/links.js.map +1 -1
- package/sdk/dist/descriptors/query.d.ts +1 -1
- package/sdk/dist/descriptors/query.d.ts.map +1 -1
- package/sdk/dist/descriptors/query.js +1 -1
- package/sdk/dist/descriptors/query.js.map +1 -1
- package/sdk/dist/descriptors/registry.d.ts +2 -5
- package/sdk/dist/descriptors/registry.d.ts.map +1 -1
- package/sdk/dist/descriptors/registry.js +11 -66
- package/sdk/dist/descriptors/registry.js.map +1 -1
- package/sdk/dist/embedded/resolve.d.ts +4 -4
- package/sdk/dist/embedded/resolve.d.ts.map +1 -1
- package/sdk/dist/embedded/resolve.js +12 -8
- package/sdk/dist/embedded/resolve.js.map +1 -1
- package/sdk/dist/embedded/skills.generated.d.ts +1 -1
- package/sdk/dist/embedded/skills.generated.d.ts.map +1 -1
- package/sdk/dist/embedded/skills.generated.js +137 -136
- package/sdk/dist/embedded/skills.generated.js.map +1 -1
- package/sdk/dist/embedded/sources.generated.d.ts.map +1 -1
- package/sdk/dist/embedded/sources.generated.js +40 -6
- package/sdk/dist/embedded/sources.generated.js.map +1 -1
- package/sdk/dist/evm/engine.d.ts +813 -10
- package/sdk/dist/evm/engine.d.ts.map +1 -1
- package/sdk/dist/evm/engine.js +127 -8
- package/sdk/dist/evm/engine.js.map +1 -1
- package/sdk/dist/index.d.ts +3 -2
- package/sdk/dist/index.d.ts.map +1 -1
- package/sdk/dist/index.js +6 -2
- package/sdk/dist/index.js.map +1 -1
- package/sdk/dist/price.d.ts +40 -0
- package/sdk/dist/price.d.ts.map +1 -0
- package/sdk/dist/price.js +101 -0
- package/sdk/dist/price.js.map +1 -0
- package/sdk/dist/protocols/aerodrome/abis.d.ts +76 -0
- package/sdk/dist/protocols/aerodrome/abis.d.ts.map +1 -1
- package/sdk/dist/protocols/aerodrome/abis.js +61 -0
- package/sdk/dist/protocols/aerodrome/abis.js.map +1 -1
- package/sdk/dist/protocols/aerodrome-slipstream/abis.d.ts +70 -0
- package/sdk/dist/protocols/aerodrome-slipstream/abis.d.ts.map +1 -1
- package/sdk/dist/protocols/aerodrome-slipstream/abis.js +54 -0
- package/sdk/dist/protocols/aerodrome-slipstream/abis.js.map +1 -1
- package/sdk/dist/protocols/camelot/abis.d.ts +178 -0
- package/sdk/dist/protocols/camelot/abis.d.ts.map +1 -1
- package/sdk/dist/protocols/camelot/abis.js +139 -0
- package/sdk/dist/protocols/camelot/abis.js.map +1 -1
- package/sdk/dist/protocols/eco-routes/abis.d.ts +792 -50
- package/sdk/dist/protocols/eco-routes/abis.d.ts.map +1 -1
- package/sdk/dist/protocols/eco-routes/abis.js +1058 -49
- package/sdk/dist/protocols/eco-routes/abis.js.map +1 -1
- package/sdk/dist/protocols/eco-routes/addresses.generated.d.ts +44 -61
- package/sdk/dist/protocols/eco-routes/addresses.generated.d.ts.map +1 -1
- package/sdk/dist/protocols/eco-routes/addresses.generated.js +45 -62
- package/sdk/dist/protocols/eco-routes/addresses.generated.js.map +1 -1
- package/sdk/dist/protocols/eco-routes/lookup.d.ts +10 -0
- package/sdk/dist/protocols/eco-routes/lookup.d.ts.map +1 -1
- package/sdk/dist/protocols/eco-routes/lookup.js +16 -0
- package/sdk/dist/protocols/eco-routes/lookup.js.map +1 -1
- package/sdk/dist/protocols/maverick/abis.d.ts +77 -0
- package/sdk/dist/protocols/maverick/abis.d.ts.map +1 -1
- package/sdk/dist/protocols/maverick/abis.js +58 -0
- package/sdk/dist/protocols/maverick/abis.js.map +1 -1
- package/sdk/dist/protocols/maverick/addresses.d.ts.map +1 -1
- package/sdk/dist/protocols/maverick/addresses.js +4 -0
- package/sdk/dist/protocols/maverick/addresses.js.map +1 -1
- package/sdk/dist/protocols/pancakeswap-v2/abis.d.ts +52 -0
- package/sdk/dist/protocols/pancakeswap-v2/abis.d.ts.map +1 -1
- package/sdk/dist/protocols/pancakeswap-v2/abis.js +43 -0
- package/sdk/dist/protocols/pancakeswap-v2/abis.js.map +1 -1
- package/sdk/dist/protocols/pancakeswap-v3/abis.d.ts +73 -0
- package/sdk/dist/protocols/pancakeswap-v3/abis.d.ts.map +1 -1
- package/sdk/dist/protocols/pancakeswap-v3/abis.js +56 -0
- package/sdk/dist/protocols/pancakeswap-v3/abis.js.map +1 -1
- package/sdk/dist/protocols/permit2/abis.d.ts +113 -0
- package/sdk/dist/protocols/permit2/abis.d.ts.map +1 -1
- package/sdk/dist/protocols/permit2/abis.js +63 -0
- package/sdk/dist/protocols/permit2/abis.js.map +1 -1
- package/sdk/dist/protocols/quickswap/abis.d.ts +148 -0
- package/sdk/dist/protocols/quickswap/abis.d.ts.map +1 -1
- package/sdk/dist/protocols/quickswap/abis.js +119 -0
- package/sdk/dist/protocols/quickswap/abis.js.map +1 -1
- package/sdk/dist/protocols/sushiswap-v2/abis.d.ts +52 -0
- package/sdk/dist/protocols/sushiswap-v2/abis.d.ts.map +1 -1
- package/sdk/dist/protocols/sushiswap-v2/abis.js +42 -0
- package/sdk/dist/protocols/sushiswap-v2/abis.js.map +1 -1
- package/sdk/dist/protocols/synthra-v3/abis.d.ts +73 -0
- package/sdk/dist/protocols/synthra-v3/abis.d.ts.map +1 -1
- package/sdk/dist/protocols/synthra-v3/abis.js +55 -0
- package/sdk/dist/protocols/synthra-v3/abis.js.map +1 -1
- package/sdk/dist/protocols/trader-joe/abis.d.ts +133 -0
- package/sdk/dist/protocols/trader-joe/abis.d.ts.map +1 -1
- package/sdk/dist/protocols/trader-joe/abis.js +101 -0
- package/sdk/dist/protocols/trader-joe/abis.js.map +1 -1
- package/sdk/dist/protocols/trader-joe/addresses.d.ts.map +1 -1
- package/sdk/dist/protocols/trader-joe/addresses.js +5 -0
- package/sdk/dist/protocols/trader-joe/addresses.js.map +1 -1
- package/sdk/dist/protocols/uniswap-v2/abis.d.ts +52 -0
- package/sdk/dist/protocols/uniswap-v2/abis.d.ts.map +1 -1
- package/sdk/dist/protocols/uniswap-v2/abis.js +44 -0
- package/sdk/dist/protocols/uniswap-v2/abis.js.map +1 -1
- package/sdk/dist/protocols/uniswap-v3/abis.d.ts +73 -0
- package/sdk/dist/protocols/uniswap-v3/abis.d.ts.map +1 -1
- package/sdk/dist/protocols/uniswap-v3/abis.js +55 -0
- package/sdk/dist/protocols/uniswap-v3/abis.js.map +1 -1
- package/sdk/dist/protocols/uniswap-v4/abis.d.ts +247 -0
- package/sdk/dist/protocols/uniswap-v4/abis.d.ts.map +1 -1
- package/sdk/dist/protocols/uniswap-v4/abis.js +167 -0
- package/sdk/dist/protocols/uniswap-v4/abis.js.map +1 -1
- package/sdk/dist/protocols/uniswap-v4/addresses.d.ts.map +1 -1
- package/sdk/dist/protocols/uniswap-v4/addresses.js +50 -0
- package/sdk/dist/protocols/uniswap-v4/addresses.js.map +1 -1
- package/sdk/dist/protocols/unitflow-v3/abis.d.ts +73 -0
- package/sdk/dist/protocols/unitflow-v3/abis.d.ts.map +1 -1
- package/sdk/dist/protocols/unitflow-v3/abis.js +56 -0
- package/sdk/dist/protocols/unitflow-v3/abis.js.map +1 -1
- package/sdk/dist/protocols/velodrome/abis.d.ts +76 -0
- package/sdk/dist/protocols/velodrome/abis.d.ts.map +1 -1
- package/sdk/dist/protocols/velodrome/abis.js +61 -0
- package/sdk/dist/protocols/velodrome/abis.js.map +1 -1
- package/sdk/dist/recipes/cctp-split.sauce.ts +2 -2
- package/sdk/dist/recipes/plain-transfer.sauce.ts +2 -2
- package/sdk/dist/routes/accessor-index.d.ts +2 -2
- package/sdk/dist/routes/accessor-index.d.ts.map +1 -1
- package/sdk/dist/routes/accessor-index.js +4 -3
- package/sdk/dist/routes/accessor-index.js.map +1 -1
- package/sdk/dist/routes/ambient.d.ts +5 -0
- package/sdk/dist/routes/ambient.d.ts.map +1 -1
- package/sdk/dist/routes/ambient.js +20 -0
- package/sdk/dist/routes/ambient.js.map +1 -1
- package/sdk/dist/routes/ast-walk.d.ts +17 -3
- package/sdk/dist/routes/ast-walk.d.ts.map +1 -1
- package/sdk/dist/routes/ast-walk.js +24 -2
- package/sdk/dist/routes/ast-walk.js.map +1 -1
- package/sdk/dist/routes/available.d.ts +43 -0
- package/sdk/dist/routes/available.d.ts.map +1 -0
- package/sdk/dist/routes/available.js +230 -0
- package/sdk/dist/routes/available.js.map +1 -0
- package/sdk/dist/routes/builtins.generated.d.ts +180 -0
- package/sdk/dist/routes/builtins.generated.d.ts.map +1 -0
- package/sdk/dist/routes/builtins.generated.js +2 -0
- package/sdk/dist/routes/builtins.generated.js.map +1 -0
- package/sdk/dist/routes/chain-exports.generated.d.ts +13 -8
- package/sdk/dist/routes/chain-exports.generated.d.ts.map +1 -1
- package/sdk/dist/routes/chain-exports.generated.js.map +1 -1
- package/sdk/dist/routes/closure.d.ts.map +1 -1
- package/sdk/dist/routes/closure.js +13 -26
- package/sdk/dist/routes/closure.js.map +1 -1
- package/sdk/dist/routes/composed.d.ts.map +1 -1
- package/sdk/dist/routes/composed.js +20 -8
- package/sdk/dist/routes/composed.js.map +1 -1
- package/sdk/dist/routes/encode.d.ts +17 -0
- package/sdk/dist/routes/encode.d.ts.map +1 -1
- package/sdk/dist/routes/encode.js +14 -11
- package/sdk/dist/routes/encode.js.map +1 -1
- package/sdk/dist/routes/entry.d.ts +76 -0
- package/sdk/dist/routes/entry.d.ts.map +1 -0
- package/sdk/dist/routes/entry.js +478 -0
- package/sdk/dist/routes/entry.js.map +1 -0
- package/sdk/dist/routes/index.d.ts +19 -12
- package/sdk/dist/routes/index.d.ts.map +1 -1
- package/sdk/dist/routes/index.js +11 -8
- package/sdk/dist/routes/index.js.map +1 -1
- package/sdk/dist/routes/intent-body.d.ts +97 -0
- package/sdk/dist/routes/intent-body.d.ts.map +1 -0
- package/sdk/dist/routes/intent-body.js +441 -0
- package/sdk/dist/routes/intent-body.js.map +1 -0
- package/sdk/dist/routes/intent-dsl.d.ts +21 -6
- package/sdk/dist/routes/intent-dsl.d.ts.map +1 -1
- package/sdk/dist/routes/intent-dsl.js +34 -17
- package/sdk/dist/routes/intent-dsl.js.map +1 -1
- package/sdk/dist/routes/intent-sugar.d.ts +77 -4
- package/sdk/dist/routes/intent-sugar.d.ts.map +1 -1
- package/sdk/dist/routes/intent-sugar.js +318 -129
- package/sdk/dist/routes/intent-sugar.js.map +1 -1
- package/sdk/dist/routes/intent.d.ts +13 -1
- package/sdk/dist/routes/intent.d.ts.map +1 -1
- package/sdk/dist/routes/intent.js +37 -1
- package/sdk/dist/routes/intent.js.map +1 -1
- package/sdk/dist/routes/nest.d.ts +3 -2
- package/sdk/dist/routes/nest.d.ts.map +1 -1
- package/sdk/dist/routes/nest.js +5 -3
- package/sdk/dist/routes/nest.js.map +1 -1
- package/sdk/dist/routes/parse.d.ts +6 -0
- package/sdk/dist/routes/parse.d.ts.map +1 -0
- package/sdk/dist/routes/parse.js +39 -0
- package/sdk/dist/routes/parse.js.map +1 -0
- package/sdk/dist/routes/portal.d.ts +258 -4
- package/sdk/dist/routes/portal.d.ts.map +1 -1
- package/sdk/dist/routes/portal.js +588 -9
- package/sdk/dist/routes/portal.js.map +1 -1
- package/sdk/dist/routes/protocol-rewrite.d.ts +71 -1
- package/sdk/dist/routes/protocol-rewrite.d.ts.map +1 -1
- package/sdk/dist/routes/protocol-rewrite.js +178 -54
- package/sdk/dist/routes/protocol-rewrite.js.map +1 -1
- package/sdk/dist/routes/rs-compile.d.ts +25 -22
- package/sdk/dist/routes/rs-compile.d.ts.map +1 -1
- package/sdk/dist/routes/rs-compile.js +55 -49
- package/sdk/dist/routes/rs-compile.js.map +1 -1
- package/sdk/dist/routes/sauce-calls.d.ts +26 -12
- package/sdk/dist/routes/sauce-calls.d.ts.map +1 -1
- package/sdk/dist/routes/sauce-calls.js +16 -23
- package/sdk/dist/routes/sauce-calls.js.map +1 -1
- package/sdk/dist/routes/sauce-route.d.ts +74 -7
- package/sdk/dist/routes/sauce-route.d.ts.map +1 -1
- package/sdk/dist/routes/sauce-route.js +225 -75
- package/sdk/dist/routes/sauce-route.js.map +1 -1
- package/sdk/dist/routes/source-globals.d.ts +107 -0
- package/sdk/dist/routes/source-globals.d.ts.map +1 -0
- package/sdk/dist/routes/source-globals.generated.d.ts +5601 -933
- package/sdk/dist/routes/source-globals.generated.d.ts.map +1 -1
- package/sdk/dist/routes/source-globals.generated.js +3 -4
- package/sdk/dist/routes/source-globals.generated.js.map +1 -1
- package/sdk/dist/routes/source-globals.js +175 -0
- package/sdk/dist/routes/source-globals.js.map +1 -0
- package/sdk/dist/routes/stock-tokens.d.ts +89 -0
- package/sdk/dist/routes/stock-tokens.d.ts.map +1 -0
- package/sdk/dist/routes/stock-tokens.generated.d.ts +7 -0
- package/sdk/dist/routes/stock-tokens.generated.d.ts.map +1 -0
- package/sdk/dist/routes/stock-tokens.generated.js +3664 -0
- package/sdk/dist/routes/stock-tokens.generated.js.map +1 -0
- package/sdk/dist/routes/stock-tokens.js +89 -0
- package/sdk/dist/routes/stock-tokens.js.map +1 -0
- package/sdk/dist/routes/token-registry.d.ts +68 -8
- package/sdk/dist/routes/token-registry.d.ts.map +1 -1
- package/sdk/dist/routes/token-registry.js +218 -32
- package/sdk/dist/routes/token-registry.js.map +1 -1
- package/sdk/dist/routes/token-rewrite.d.ts +1 -1
- package/sdk/dist/routes/token-rewrite.d.ts.map +1 -1
- package/sdk/dist/routes/token-rewrite.js +5 -9
- package/sdk/dist/routes/token-rewrite.js.map +1 -1
- package/sdk/dist/routes/unknown-global.d.ts +32 -0
- package/sdk/dist/routes/unknown-global.d.ts.map +1 -0
- package/sdk/dist/routes/unknown-global.js +106 -0
- package/sdk/dist/routes/unknown-global.js.map +1 -0
- package/sdk/dist/routes/vault.d.ts +38 -8
- package/sdk/dist/routes/vault.d.ts.map +1 -1
- package/sdk/dist/routes/vault.js +47 -8
- package/sdk/dist/routes/vault.js.map +1 -1
- package/sdk/dist/sauce-script/builtins.d.ts +309 -0
- package/sdk/dist/sauce-script/declarations.d.ts +3 -0
- package/sdk/dist/sauce-script/declarations.d.ts.map +1 -0
- package/sdk/dist/sauce-script/declarations.js +229 -0
- package/sdk/dist/sauce-script/declarations.js.map +1 -0
- package/sdk/dist/sauce-script/index.d.ts +2714 -0
- package/sdk/dist/sauce-script/ts-plugin.cjs +85 -0
- package/sdk/dist/skills/loader.d.ts.map +1 -1
- package/sdk/dist/skills/loader.js +4 -3
- package/sdk/dist/skills/loader.js.map +1 -1
- package/sdk/dist/std/router/balancer-v2-vault.abi.json +78 -0
- package/sdk/dist/std/router/curve-cryptoswap.abi.json +29 -0
- package/sdk/dist/std/router/curve-stableswap.abi.json +29 -0
- package/sdk/dist/std/router/dodo-v2-pool.abi.json +39 -0
- package/sdk/dist/std/router/lb-pair.abi.json +55 -0
- package/sdk/dist/std/router/package.json +7 -0
- package/sdk/dist/std/router/router.evm.js +567 -0
- package/sdk/dist/std/router/sauce-router.abi.json +202 -0
- package/sdk/dist/std/router/uniswap-v2-pair.abi.json +49 -0
- package/sdk/dist/std/router/woo-pp-v2.abi.json +42 -0
- package/sdk/dist/std/token/permit2.abi.json +226 -0
- package/sdk/dist/std/token/token.evm.js +73 -0
- package/sdk/dist/std/token/token.svm.js +194 -41
- package/sdk/dist/svm/client.d.ts +62 -15
- package/sdk/dist/svm/client.d.ts.map +1 -1
- package/sdk/dist/svm/client.js +103 -42
- package/sdk/dist/svm/client.js.map +1 -1
- package/sdk/dist/svm/engine.d.ts +66 -5
- package/sdk/dist/svm/engine.d.ts.map +1 -1
- package/sdk/dist/svm/engine.js +73 -5
- package/sdk/dist/svm/engine.js.map +1 -1
- package/sdk/dist/svm/index.d.ts +2 -0
- package/sdk/dist/svm/index.d.ts.map +1 -1
- package/sdk/dist/svm/index.js +2 -0
- package/sdk/dist/svm/index.js.map +1 -1
- package/sdk/dist/svm/instructions.d.ts +72 -1
- package/sdk/dist/svm/instructions.d.ts.map +1 -1
- package/sdk/dist/svm/instructions.js +81 -2
- package/sdk/dist/svm/instructions.js.map +1 -1
- package/sdk/dist/svm/kitchen.d.ts +20 -1
- package/sdk/dist/svm/kitchen.d.ts.map +1 -1
- package/sdk/dist/svm/kitchen.js +47 -1
- package/sdk/dist/svm/kitchen.js.map +1 -1
- package/sdk/dist/svm/portal.d.ts +250 -0
- package/sdk/dist/svm/portal.d.ts.map +1 -0
- package/sdk/dist/svm/portal.js +462 -0
- package/sdk/dist/svm/portal.js.map +1 -0
- package/sdk/dist/svm/send.d.ts +18 -2
- package/sdk/dist/svm/send.d.ts.map +1 -1
- package/sdk/dist/svm/send.js +28 -3
- package/sdk/dist/svm/send.js.map +1 -1
- package/sdk/dist/svm/token-accounts.d.ts +49 -0
- package/sdk/dist/svm/token-accounts.d.ts.map +1 -0
- package/sdk/dist/svm/token-accounts.js +58 -0
- package/sdk/dist/svm/token-accounts.js.map +1 -0
- package/sdk/dist/svm/token-extensions.d.ts +18 -7
- package/sdk/dist/svm/token-extensions.d.ts.map +1 -1
- package/sdk/dist/svm/token-extensions.js +58 -5
- package/sdk/dist/svm/token-extensions.js.map +1 -1
- package/sdk/dist/token/evm.js +1 -1
- package/sdk/dist/token/index.d.ts +1 -1
- package/sdk/dist/token/index.js +1 -1
- package/sdk/dist/token/params.js +1 -1
- package/sdk/dist/token/source.js +3 -3
- package/sdk/dist/token/source.js.map +1 -1
- package/sdk/dist/token/types.d.ts +2 -2
- package/sdk/dist/token/types.js +2 -2
- package/sdk/src/protocols/aerodrome/AerodromePoolABI.json +105 -0
- package/sdk/src/protocols/aerodrome/abis.ts +62 -0
- package/sdk/src/protocols/aerodrome-slipstream/AerodromeSlipstreamPoolABI.json +96 -0
- package/sdk/src/protocols/aerodrome-slipstream/abis.ts +55 -0
- package/sdk/src/protocols/camelot/CamelotV2FactoryABI.json +25 -0
- package/sdk/src/protocols/camelot/CamelotV2PairABI.json +109 -0
- package/sdk/src/protocols/camelot/CamelotV3FactoryABI.json +25 -0
- package/sdk/src/protocols/camelot/CamelotV3PoolABI.json +92 -0
- package/sdk/src/protocols/camelot/abis.ts +143 -0
- package/sdk/src/protocols/eco-routes/PortalABI.json +1448 -0
- package/sdk/src/protocols/eco-routes/ProverABI.json +162 -0
- package/sdk/src/protocols/eco-routes/abis.ts +1060 -51
- package/sdk/src/protocols/eco-routes/addresses.generated.ts +45 -62
- package/sdk/src/protocols/eco-routes/lookup.ts +18 -0
- package/sdk/src/protocols/maverick/MaverickV2PoolABI.json +107 -0
- package/sdk/src/protocols/maverick/abis.ts +59 -0
- package/sdk/src/protocols/maverick/addresses.ts +4 -0
- package/sdk/src/protocols/pancakeswap-v2/PancakeSwapV2PairABI.json +72 -0
- package/sdk/src/protocols/pancakeswap-v2/abis.ts +44 -0
- package/sdk/src/protocols/pancakeswap-v3/PancakeSwapV3PoolABI.json +100 -0
- package/sdk/src/protocols/pancakeswap-v3/abis.ts +57 -0
- package/sdk/src/protocols/permit2/Permit2ABI.json +154 -0
- package/sdk/src/protocols/permit2/abis.ts +63 -0
- package/sdk/src/protocols/quickswap/QuickSwapV2FactoryABI.json +25 -0
- package/sdk/src/protocols/quickswap/QuickSwapV2PairABI.json +72 -0
- package/sdk/src/protocols/quickswap/QuickSwapV3FactoryABI.json +25 -0
- package/sdk/src/protocols/quickswap/QuickSwapV3PoolABI.json +88 -0
- package/sdk/src/protocols/quickswap/abis.ts +123 -0
- package/sdk/src/protocols/sushiswap-v2/SushiSwapV2PairABI.json +72 -0
- package/sdk/src/protocols/sushiswap-v2/abis.ts +43 -0
- package/sdk/src/protocols/synthra-v3/SynthraV3PoolABI.json +100 -0
- package/sdk/src/protocols/synthra-v3/abis.ts +56 -0
- package/sdk/src/protocols/trader-joe/LBPairABI.json +185 -0
- package/sdk/src/protocols/trader-joe/abis.ts +102 -0
- package/sdk/src/protocols/trader-joe/addresses.ts +5 -0
- package/sdk/src/protocols/uniswap-v2/UniswapV2PairABI.json +72 -0
- package/sdk/src/protocols/uniswap-v2/abis.ts +45 -0
- package/sdk/src/protocols/uniswap-v3/UniswapV3PoolABI.json +100 -0
- package/sdk/src/protocols/uniswap-v3/abis.ts +56 -0
- package/sdk/src/protocols/uniswap-v4/UniswapV4PoolManagerABI.json +38 -0
- package/sdk/src/protocols/uniswap-v4/UniswapV4StateViewABI.json +307 -0
- package/sdk/src/protocols/uniswap-v4/abis.ts +168 -0
- package/sdk/src/protocols/uniswap-v4/addresses.ts +50 -0
- package/sdk/src/protocols/unitflow-v3/UnitFlowV3PoolABI.json +100 -0
- package/sdk/src/protocols/unitflow-v3/abis.ts +57 -0
- package/sdk/src/protocols/velodrome/VelodromePoolABI.json +105 -0
- package/sdk/src/protocols/velodrome/abis.ts +62 -0
- package/skills/sauce-actions/SKILL.md +166 -0
- package/skills/sauce-actions/examples/swap-and-supply.json +24 -0
- package/skills/sauce-actions/examples/swap-by-key.json +15 -0
- package/skills/sauce-actions/references/actions.md +731 -0
- package/skills/sauce-chains/SKILL.md +137 -0
- package/skills/sauce-chains/examples/chains.sauce.ts +25 -0
- package/skills/sauce-chains/references/arbitrum.md +158 -0
- package/skills/sauce-chains/references/arc.md +107 -0
- package/skills/sauce-chains/references/aurora.md +33 -0
- package/skills/sauce-chains/references/avalanche.md +106 -0
- package/skills/sauce-chains/references/base-stocks.md +77 -0
- package/skills/sauce-chains/references/base.md +141 -0
- package/skills/sauce-chains/references/berachain.md +33 -0
- package/skills/sauce-chains/references/blast.md +60 -0
- package/skills/sauce-chains/references/boba.md +33 -0
- package/skills/sauce-chains/references/bsc.md +97 -0
- package/skills/sauce-chains/references/celo.md +57 -0
- package/skills/sauce-chains/references/core.md +33 -0
- package/skills/sauce-chains/references/cronos.md +33 -0
- package/skills/sauce-chains/references/ethereum-stocks.md +1741 -0
- package/skills/sauce-chains/references/ethereum.md +255 -0
- package/skills/sauce-chains/references/evmos.md +33 -0
- package/skills/sauce-chains/references/fantom.md +61 -0
- package/skills/sauce-chains/references/fuse.md +33 -0
- package/skills/sauce-chains/references/gnosis.md +57 -0
- package/skills/sauce-chains/references/index.md +58 -0
- package/skills/sauce-chains/references/ink.md +55 -0
- package/skills/sauce-chains/references/kava.md +33 -0
- package/skills/sauce-chains/references/klaytn.md +33 -0
- package/skills/sauce-chains/references/linea.md +65 -0
- package/skills/sauce-chains/references/manta.md +33 -0
- package/skills/sauce-chains/references/mantle.md +33 -0
- package/skills/sauce-chains/references/metis.md +54 -0
- package/skills/sauce-chains/references/mode.md +55 -0
- package/skills/sauce-chains/references/monad.md +79 -0
- package/skills/sauce-chains/references/moonbeam.md +33 -0
- package/skills/sauce-chains/references/opbnb.md +55 -0
- package/skills/sauce-chains/references/optimism.md +123 -0
- package/skills/sauce-chains/references/plasma.md +35 -0
- package/skills/sauce-chains/references/polygon.md +123 -0
- package/skills/sauce-chains/references/pulsechain.md +33 -0
- package/skills/sauce-chains/references/ronin.md +35 -0
- package/skills/sauce-chains/references/scroll.md +62 -0
- package/skills/sauce-chains/references/sei.md +55 -0
- package/skills/sauce-chains/references/solana-stocks.md +1812 -0
- package/skills/sauce-chains/references/solana.md +56 -0
- package/skills/sauce-chains/references/sonic.md +57 -0
- package/skills/sauce-chains/references/unichain.md +61 -0
- package/skills/sauce-chains/references/zetachain.md +33 -0
- package/skills/sauce-chains/references/zksync.md +59 -0
- package/skills/sauce-chains/references/zora.md +57 -0
- package/skills/sauce-cli/SKILL.md +366 -0
- package/skills/sauce-cli/examples/pay.sauce.ts +23 -0
- package/skills/sauce-cli/examples/split.sauce.ts +30 -0
- package/skills/sauce-distributed-swap/SKILL.md +392 -0
- package/skills/sauce-distributed-swap/examples/distributed-swap.mts +251 -0
- package/skills/sauce-distributed-swap/examples/distributed-swap.sauce.ts +115 -0
- package/skills/sauce-examples/SKILL.md +96 -0
- package/skills/sauce-globals/SKILL.md +213 -0
- package/skills/sauce-globals/examples/globals.mts +111 -0
- package/skills/sauce-globals/examples/globals.sauce.ts +47 -0
- package/skills/sauce-globals/references/chains.md +53 -0
- package/skills/sauce-globals/references/protocols.md +405 -0
- package/skills/sauce-globals/references/stocks.md +3635 -0
- package/skills/sauce-globals/references/tokens.md +53 -0
- package/skills/sauce-intents/SKILL.md +505 -0
- package/skills/sauce-intents/examples/cross-chain.sauce.ts +37 -0
- package/skills/sauce-intents/examples/fund-by-transfer.sauce.ts +54 -0
- package/skills/sauce-intents/examples/intents.mts +343 -0
- package/skills/sauce-intents/examples/swap-on-base.sauce.ts +135 -0
- package/skills/sauce-intents/references/portal.md +77 -0
- package/skills/sauce-overview/SKILL.md +161 -0
- package/skills/sauce-protocols/SKILL.md +118 -0
- package/skills/sauce-protocols/examples/protocols.mts +77 -0
- package/skills/sauce-protocols/examples/protocols.sauce.ts +27 -0
- package/{sdk/src/skills → skills/sauce-protocols/references}/aave-v2.md +35 -17
- package/skills/sauce-protocols/references/aave-v3.md +144 -0
- package/skills/sauce-protocols/references/aave-v4.md +50 -0
- package/skills/sauce-protocols/references/abracadabra.md +72 -0
- package/skills/sauce-protocols/references/across.md +73 -0
- package/skills/sauce-protocols/references/aerodrome-slipstream.md +50 -0
- package/{sdk/src/skills → skills/sauce-protocols/references}/aerodrome.md +43 -24
- package/skills/sauce-protocols/references/aevo.md +49 -0
- package/{sdk/src/skills → skills/sauce-protocols/references}/alchemix.md +10 -25
- package/{sdk/src/skills → skills/sauce-protocols/references}/ambient.md +14 -21
- package/{sdk/src/skills → skills/sauce-protocols/references}/arbitrum-bridge.md +11 -14
- package/{sdk/src/skills → skills/sauce-protocols/references}/arrakis.md +10 -26
- package/skills/sauce-protocols/references/axelar.md +56 -0
- package/{sdk/src/skills → skills/sauce-protocols/references}/balancer-v2.md +13 -29
- package/{sdk/src/skills → skills/sauce-protocols/references}/base-bridge.md +11 -16
- package/{sdk/src/skills → skills/sauce-protocols/references}/baseswap.md +12 -19
- package/{sdk/src/skills → skills/sauce-protocols/references}/beefy.md +10 -30
- package/{sdk/src/skills → skills/sauce-protocols/references}/benqi.md +11 -21
- package/{sdk/src/skills → skills/sauce-protocols/references}/camelot.md +13 -27
- package/{sdk/src/skills → skills/sauce-protocols/references}/cbeth.md +10 -22
- package/skills/sauce-protocols/references/cctp.md +47 -0
- package/{sdk/src/skills → skills/sauce-protocols/references}/celer.md +11 -18
- package/{sdk/src/skills → skills/sauce-protocols/references}/chainlink-ccip.md +11 -21
- package/skills/sauce-protocols/references/chainlink.md +47 -0
- package/{sdk/src/skills → skills/sauce-protocols/references}/circle-gateway.md +12 -38
- package/{sdk/src/skills → skills/sauce-protocols/references}/compound-v2.md +11 -25
- package/{sdk/src/skills → skills/sauce-protocols/references}/compound-v3.md +43 -27
- package/{sdk/src/skills → skills/sauce-protocols/references}/connext.md +11 -15
- package/{sdk/src/skills → skills/sauce-protocols/references}/convex.md +10 -28
- package/{sdk/src/skills → skills/sauce-protocols/references}/cowswap.md +12 -19
- package/{sdk/src/skills → skills/sauce-protocols/references}/crvusd.md +10 -19
- package/skills/sauce-protocols/references/curve.md +98 -0
- package/{sdk/src/skills → skills/sauce-protocols/references}/debridge.md +11 -33
- package/{sdk/src/skills → skills/sauce-protocols/references}/dodo.md +13 -18
- package/skills/sauce-protocols/references/eigenlayer.md +48 -0
- package/{sdk/src/skills → skills/sauce-protocols/references}/ens.md +10 -26
- package/{sdk/src/skills → skills/sauce-protocols/references}/erc20.md +10 -24
- package/{sdk/src/skills → skills/sauce-protocols/references}/erc3156.md +10 -13
- package/{sdk/src/skills → skills/sauce-protocols/references}/erc4626.md +11 -27
- package/{sdk/src/skills → skills/sauce-protocols/references}/ethena.md +10 -27
- package/{sdk/src/skills → skills/sauce-protocols/references}/etherfi.md +10 -32
- package/{sdk/src/skills → skills/sauce-protocols/references}/euler-v2.md +11 -21
- package/{sdk/src/skills → skills/sauce-protocols/references}/fenix.md +12 -18
- package/{sdk/src/skills → skills/sauce-protocols/references}/fluid.md +11 -20
- package/{sdk/src/skills → skills/sauce-protocols/references}/frax-ether.md +10 -26
- package/{sdk/src/skills → skills/sauce-protocols/references}/frax.md +10 -19
- package/{sdk/src/skills → skills/sauce-protocols/references}/gains-network.md +11 -28
- package/skills/sauce-protocols/references/gamma.md +57 -0
- package/{sdk/src/skills → skills/sauce-protocols/references}/gelato.md +12 -20
- package/{sdk/src/skills → skills/sauce-protocols/references}/gho.md +10 -19
- package/{sdk/src/skills → skills/sauce-protocols/references}/gmx-v1.md +12 -34
- package/{sdk/src/skills → skills/sauce-protocols/references}/gmx-v2.md +15 -28
- package/skills/sauce-protocols/references/harvest.md +41 -0
- package/{sdk/src/skills → skills/sauce-protocols/references}/hegic.md +10 -18
- package/{sdk/src/skills → skills/sauce-protocols/references}/hop.md +11 -21
- package/{sdk/src/skills → skills/sauce-protocols/references}/hyperlane.md +11 -21
- package/skills/sauce-protocols/references/index.md +355 -0
- package/{sdk/src/skills → skills/sauce-protocols/references}/instadapp.md +10 -18
- package/skills/sauce-protocols/references/kelp.md +46 -0
- package/{sdk/src/skills → skills/sauce-protocols/references}/kim.md +12 -18
- package/{sdk/src/skills → skills/sauce-protocols/references}/kyberswap-aggregator.md +12 -35
- package/skills/sauce-protocols/references/kyberswap.md +72 -0
- package/{sdk/src/skills → skills/sauce-protocols/references}/layerbank.md +11 -26
- package/{sdk/src/skills → skills/sauce-protocols/references}/layerzero.md +11 -25
- package/{sdk/src/skills → skills/sauce-protocols/references}/level-finance.md +10 -24
- package/{sdk/src/skills → skills/sauce-protocols/references}/lido.md +10 -28
- package/{sdk/src/skills → skills/sauce-protocols/references}/lifi.md +11 -25
- package/{sdk/src/skills → skills/sauce-protocols/references}/linea-bridge.md +11 -14
- package/{sdk/src/skills → skills/sauce-protocols/references}/liquity-v1.md +10 -21
- package/{sdk/src/skills → skills/sauce-protocols/references}/liquity-v2.md +10 -19
- package/{sdk/src/skills → skills/sauce-protocols/references}/lynex.md +12 -18
- package/skills/sauce-protocols/references/maker.md +57 -0
- package/skills/sauce-protocols/references/mantle-meth.md +43 -0
- package/{sdk/src/skills → skills/sauce-protocols/references}/maverick.md +13 -25
- package/{sdk/src/skills → skills/sauce-protocols/references}/moonwell.md +11 -21
- package/{sdk/src/skills → skills/sauce-protocols/references}/morpho-blue.md +44 -21
- package/{sdk/src/skills → skills/sauce-protocols/references}/mux-protocol.md +10 -30
- package/skills/sauce-protocols/references/olympus.md +39 -0
- package/skills/sauce-protocols/references/oneinch.md +81 -0
- package/skills/sauce-protocols/references/openocean.md +69 -0
- package/{sdk/src/skills → skills/sauce-protocols/references}/optimism-bridge.md +11 -16
- package/{sdk/src/skills → skills/sauce-protocols/references}/opyn.md +10 -21
- package/{sdk/src/skills → skills/sauce-protocols/references}/pancakeswap-v2.md +39 -41
- package/skills/sauce-protocols/references/pancakeswap-v3.md +72 -0
- package/skills/sauce-protocols/references/paraswap.md +39 -0
- package/{sdk/src/skills → skills/sauce-protocols/references}/pendle.md +47 -29
- package/skills/sauce-protocols/references/permit2.md +101 -0
- package/skills/sauce-protocols/references/perpetual-protocol.md +53 -0
- package/{sdk/src/skills → skills/sauce-protocols/references}/polygon-bridge.md +11 -17
- package/{sdk/src/skills → skills/sauce-protocols/references}/premia.md +10 -19
- package/{sdk/src/skills → skills/sauce-protocols/references}/puffer.md +10 -21
- package/skills/sauce-protocols/references/pyth.md +45 -0
- package/{sdk/src/skills → skills/sauce-protocols/references}/quickswap.md +13 -27
- package/{sdk/src/skills → skills/sauce-protocols/references}/radiant.md +11 -15
- package/{sdk/src/skills → skills/sauce-protocols/references}/ramses.md +12 -18
- package/skills/sauce-protocols/references/reflexer.md +52 -0
- package/skills/sauce-protocols/references/registry/aave-v2.md +43 -0
- package/skills/sauce-protocols/references/registry/aave-v3.md +62 -0
- package/skills/sauce-protocols/references/registry/aave-v4.md +80 -0
- package/skills/sauce-protocols/references/registry/abracadabra.md +54 -0
- package/skills/sauce-protocols/references/registry/across.md +57 -0
- package/skills/sauce-protocols/references/registry/aerodrome-slipstream.md +72 -0
- package/skills/sauce-protocols/references/registry/aerodrome.md +58 -0
- package/skills/sauce-protocols/references/registry/aevo.md +39 -0
- package/skills/sauce-protocols/references/registry/alchemix.md +46 -0
- package/skills/sauce-protocols/references/registry/ambient.md +40 -0
- package/skills/sauce-protocols/references/registry/arbitrum-bridge.md +40 -0
- package/skills/sauce-protocols/references/registry/arrakis.md +49 -0
- package/skills/sauce-protocols/references/registry/axelar.md +65 -0
- package/skills/sauce-protocols/references/registry/balancer-v2.md +50 -0
- package/skills/sauce-protocols/references/registry/base-bridge.md +42 -0
- package/skills/sauce-protocols/references/registry/baseswap.md +40 -0
- package/skills/sauce-protocols/references/registry/beefy.md +51 -0
- package/skills/sauce-protocols/references/registry/benqi.md +49 -0
- package/skills/sauce-protocols/references/registry/camelot.md +82 -0
- package/skills/sauce-protocols/references/registry/cbeth.md +43 -0
- package/skills/sauce-protocols/references/registry/cctp.md +48 -0
- package/skills/sauce-protocols/references/registry/celer.md +44 -0
- package/skills/sauce-protocols/references/registry/chainlink-ccip.md +45 -0
- package/skills/sauce-protocols/references/registry/chainlink.md +49 -0
- package/skills/sauce-protocols/references/registry/circle-gateway.md +70 -0
- package/skills/sauce-protocols/references/registry/compound-v2.md +53 -0
- package/skills/sauce-protocols/references/registry/compound-v3.md +52 -0
- package/skills/sauce-protocols/references/registry/connext.md +41 -0
- package/skills/sauce-protocols/references/registry/convex.md +51 -0
- package/skills/sauce-protocols/references/registry/cowswap.md +40 -0
- package/skills/sauce-protocols/references/registry/crvusd.md +40 -0
- package/skills/sauce-protocols/references/registry/curve.md +81 -0
- package/skills/sauce-protocols/references/registry/debridge.md +59 -0
- package/skills/sauce-protocols/references/registry/dodo.md +39 -0
- package/skills/sauce-protocols/references/registry/eco-routes.md +65 -0
- package/skills/sauce-protocols/references/registry/eigenlayer.md +58 -0
- package/skills/sauce-protocols/references/registry/ens.md +49 -0
- package/skills/sauce-protocols/references/registry/erc20.md +44 -0
- package/skills/sauce-protocols/references/registry/erc3156.md +38 -0
- package/skills/sauce-protocols/references/registry/erc4626.md +51 -0
- package/skills/sauce-protocols/references/registry/ethena.md +50 -0
- package/skills/sauce-protocols/references/registry/etherfi.md +57 -0
- package/skills/sauce-protocols/references/registry/euler-v2.md +49 -0
- package/skills/sauce-protocols/references/registry/fenix.md +39 -0
- package/skills/sauce-protocols/references/registry/fluid.md +48 -0
- package/skills/sauce-protocols/references/registry/frax-ether.md +49 -0
- package/skills/sauce-protocols/references/registry/frax.md +40 -0
- package/skills/sauce-protocols/references/registry/gains-network.md +43 -0
- package/skills/sauce-protocols/references/registry/gamma.md +56 -0
- package/skills/sauce-protocols/references/registry/gelato.md +45 -0
- package/skills/sauce-protocols/references/registry/gho.md +40 -0
- package/skills/sauce-protocols/references/registry/gmx-v1.md +59 -0
- package/skills/sauce-protocols/references/registry/gmx-v2.md +41 -0
- package/skills/sauce-protocols/references/registry/harvest.md +44 -0
- package/skills/sauce-protocols/references/registry/hegic.md +39 -0
- package/skills/sauce-protocols/references/registry/hop.md +49 -0
- package/skills/sauce-protocols/references/registry/hyperlane.md +48 -0
- package/skills/sauce-protocols/references/registry/instadapp.md +39 -0
- package/skills/sauce-protocols/references/registry/kelp.md +47 -0
- package/skills/sauce-protocols/references/registry/kim.md +39 -0
- package/skills/sauce-protocols/references/registry/kyberswap-aggregator.md +49 -0
- package/skills/sauce-protocols/references/registry/kyberswap.md +63 -0
- package/skills/sauce-protocols/references/registry/layerbank.md +54 -0
- package/skills/sauce-protocols/references/registry/layerzero.md +49 -0
- package/skills/sauce-protocols/references/registry/level-finance.md +41 -0
- package/skills/sauce-protocols/references/registry/lido.md +51 -0
- package/skills/sauce-protocols/references/registry/lifi.md +48 -0
- package/skills/sauce-protocols/references/registry/linea-bridge.md +40 -0
- package/skills/sauce-protocols/references/registry/liquity-v1.md +42 -0
- package/skills/sauce-protocols/references/registry/liquity-v2.md +40 -0
- package/skills/sauce-protocols/references/registry/lynex.md +39 -0
- package/skills/sauce-protocols/references/registry/maker.md +55 -0
- package/skills/sauce-protocols/references/registry/mantle-meth.md +48 -0
- package/skills/sauce-protocols/references/registry/maverick.md +60 -0
- package/skills/sauce-protocols/references/registry/moonwell.md +49 -0
- package/skills/sauce-protocols/references/registry/morpho-blue.md +47 -0
- package/skills/sauce-protocols/references/registry/mux-protocol.md +49 -0
- package/skills/sauce-protocols/references/registry/olympus.md +42 -0
- package/skills/sauce-protocols/references/registry/oneinch.md +45 -0
- package/skills/sauce-protocols/references/registry/openocean.md +44 -0
- package/skills/sauce-protocols/references/registry/optimism-bridge.md +42 -0
- package/skills/sauce-protocols/references/registry/opyn.md +42 -0
- package/skills/sauce-protocols/references/registry/pancakeswap-v2.md +71 -0
- package/skills/sauce-protocols/references/registry/pancakeswap-v3.md +76 -0
- package/skills/sauce-protocols/references/registry/paraswap.md +51 -0
- package/skills/sauce-protocols/references/registry/pendle.md +43 -0
- package/skills/sauce-protocols/references/registry/permit2.md +50 -0
- package/skills/sauce-protocols/references/registry/perpetual-protocol.md +49 -0
- package/skills/sauce-protocols/references/registry/polygon-bridge.md +43 -0
- package/skills/sauce-protocols/references/registry/premia.md +40 -0
- package/skills/sauce-protocols/references/registry/puffer.md +43 -0
- package/skills/sauce-protocols/references/registry/pyth.md +40 -0
- package/skills/sauce-protocols/references/registry/quickswap.md +80 -0
- package/skills/sauce-protocols/references/registry/radiant.md +41 -0
- package/skills/sauce-protocols/references/registry/ramses.md +39 -0
- package/skills/sauce-protocols/references/registry/reflexer.md +56 -0
- package/skills/sauce-protocols/references/registry/renzo.md +47 -0
- package/skills/sauce-protocols/references/registry/rocket-pool.md +49 -0
- package/skills/sauce-protocols/references/registry/sablier.md +40 -0
- package/skills/sauce-protocols/references/registry/safe.md +47 -0
- package/skills/sauce-protocols/references/registry/scroll-bridge.md +48 -0
- package/skills/sauce-protocols/references/registry/seamless.md +42 -0
- package/skills/sauce-protocols/references/registry/seaport.md +44 -0
- package/skills/sauce-protocols/references/registry/silo.md +48 -0
- package/skills/sauce-protocols/references/registry/socket.md +44 -0
- package/skills/sauce-protocols/references/registry/sommelier.md +43 -0
- package/skills/sauce-protocols/references/registry/spark.md +42 -0
- package/skills/sauce-protocols/references/registry/spookyswap.md +40 -0
- package/skills/sauce-protocols/references/registry/squid.md +45 -0
- package/skills/sauce-protocols/references/registry/stader.md +47 -0
- package/skills/sauce-protocols/references/registry/stargate.md +45 -0
- package/skills/sauce-protocols/references/registry/superfluid.md +49 -0
- package/skills/sauce-protocols/references/registry/sushiswap-v2.md +71 -0
- package/skills/sauce-protocols/references/registry/swell.md +49 -0
- package/skills/sauce-protocols/references/registry/synapse.md +46 -0
- package/skills/sauce-protocols/references/registry/syncswap.md +38 -0
- package/skills/sauce-protocols/references/registry/synthetix-v3.md +48 -0
- package/skills/sauce-protocols/references/registry/synthra-v3.md +77 -0
- package/skills/sauce-protocols/references/registry/thales.md +51 -0
- package/skills/sauce-protocols/references/registry/thena.md +39 -0
- package/skills/sauce-protocols/references/registry/thruster.md +38 -0
- package/skills/sauce-protocols/references/registry/tokemak.md +45 -0
- package/skills/sauce-protocols/references/registry/trader-joe.md +66 -0
- package/skills/sauce-protocols/references/registry/uniswap-v2.md +77 -0
- package/skills/sauce-protocols/references/registry/uniswap-v3.md +113 -0
- package/skills/sauce-protocols/references/registry/uniswap-v4.md +117 -0
- package/skills/sauce-protocols/references/registry/unitflow-v3.md +65 -0
- package/skills/sauce-protocols/references/registry/velodrome.md +58 -0
- package/skills/sauce-protocols/references/registry/venus.md +62 -0
- package/skills/sauce-protocols/references/registry/vertex.md +46 -0
- package/skills/sauce-protocols/references/registry/wormhole.md +59 -0
- package/skills/sauce-protocols/references/registry/yearn-v3.md +46 -0
- package/skills/sauce-protocols/references/registry/zerolend.md +41 -0
- package/skills/sauce-protocols/references/registry/zerox.md +44 -0
- package/skills/sauce-protocols/references/registry/zksync-bridge.md +40 -0
- package/{sdk/src/skills → skills/sauce-protocols/references}/renzo.md +10 -24
- package/{sdk/src/skills → skills/sauce-protocols/references}/rocket-pool.md +10 -26
- package/{sdk/src/skills → skills/sauce-protocols/references}/sablier.md +10 -27
- package/skills/sauce-protocols/references/safe.md +42 -0
- package/{sdk/src/skills → skills/sauce-protocols/references}/scroll-bridge.md +11 -20
- package/{sdk/src/skills → skills/sauce-protocols/references}/seamless.md +11 -16
- package/skills/sauce-protocols/references/seaport.md +38 -0
- package/{sdk/src/skills → skills/sauce-protocols/references}/silo.md +11 -20
- package/{sdk/src/skills → skills/sauce-protocols/references}/socket.md +11 -18
- package/skills/sauce-protocols/references/sommelier.md +40 -0
- package/{sdk/src/skills → skills/sauce-protocols/references}/spark.md +11 -16
- package/{sdk/src/skills → skills/sauce-protocols/references}/spookyswap.md +12 -19
- package/{sdk/src/skills → skills/sauce-protocols/references}/squid.md +11 -21
- package/skills/sauce-protocols/references/stader.md +39 -0
- package/{sdk/src/skills → skills/sauce-protocols/references}/stargate.md +11 -22
- package/{sdk/src/skills → skills/sauce-protocols/references}/superfluid.md +10 -28
- package/{sdk/src/skills → skills/sauce-protocols/references}/sushiswap-v2.md +38 -43
- package/skills/sauce-protocols/references/swell.md +49 -0
- package/skills/sauce-protocols/references/synapse.md +54 -0
- package/{sdk/src/skills → skills/sauce-protocols/references}/syncswap.md +12 -17
- package/{sdk/src/skills → skills/sauce-protocols/references}/synthetix-v3.md +10 -29
- package/skills/sauce-protocols/references/synthra-v3.md +63 -0
- package/skills/sauce-protocols/references/thales.md +58 -0
- package/{sdk/src/skills → skills/sauce-protocols/references}/thena.md +12 -18
- package/{sdk/src/skills → skills/sauce-protocols/references}/thruster.md +13 -18
- package/skills/sauce-protocols/references/tokemak.md +40 -0
- package/{sdk/src/skills → skills/sauce-protocols/references}/trader-joe.md +13 -26
- package/{sdk/src/skills → skills/sauce-protocols/references}/uniswap-v2.md +46 -44
- package/skills/sauce-protocols/references/uniswap-v3.md +188 -0
- package/skills/sauce-protocols/references/uniswap-v4.md +155 -0
- package/skills/sauce-protocols/references/unitflow-v3.md +63 -0
- package/{sdk/src/skills → skills/sauce-protocols/references}/velodrome.md +12 -24
- package/{sdk/src/skills → skills/sauce-protocols/references}/venus.md +12 -31
- package/skills/sauce-protocols/references/vertex.md +42 -0
- package/skills/sauce-protocols/references/wormhole.md +57 -0
- package/{sdk/src/skills → skills/sauce-protocols/references}/yearn-v3.md +10 -25
- package/{sdk/src/skills → skills/sauce-protocols/references}/zerolend.md +11 -15
- package/skills/sauce-protocols/references/zerox.md +39 -0
- package/{sdk/src/skills → skills/sauce-protocols/references}/zksync-bridge.md +11 -14
- package/skills/sauce-script/SKILL.md +407 -0
- package/skills/sauce-script/examples/IOracle.json +12 -0
- package/skills/sauce-script/examples/saucescript.mts +167 -0
- package/skills/sauce-script/examples/twap.sauce.ts +29 -0
- package/skills/sauce-script/references/builtins.json +823 -0
- package/skills/sauce-script/references/builtins.md +674 -0
- package/skills/sauce-solana/SKILL.md +324 -0
- package/skills/sauce-solana/examples/solana.mts +166 -0
- package/skills/sauce-solana/examples/solana.sauce.ts +45 -0
- package/skills/sauce-solana/examples/token-2022.sauce.ts +38 -0
- package/skills/sauce-swaps/SKILL.md +200 -0
- package/skills/sauce-swaps/examples/swap-leg.sauce.ts +50 -0
- package/skills/sauce-swaps/examples/swaps.mts +124 -0
- package/skills/sauce-typescript/SKILL.md +178 -0
- package/skills/sauce-typescript/examples/actions.mts +100 -0
- package/skills/sauce-typescript/examples/compiler.mts +69 -0
- package/skills/sauce-typescript/examples/cook.mts +65 -0
- package/skills/sauce-typescript/examples/verify.mts +104 -0
- package/dev-tools/README.md +0 -16
- package/dev-tools/artifacts/IERC20.json +0 -1
- package/dev-tools/artifacts/ISauceRouter.json +0 -1
- package/dev-tools/artifacts/IUniswapV3Pool.json +0 -1
- package/dev-tools/artifacts/Router.json +0 -1
- package/dev-tools/hardhat.config.cjs +0 -18
- package/dev-tools/sauce/js/add.js +0 -4
- package/dev-tools/sauce/js/call.js +0 -8
- package/dev-tools/sauce/js/erc20.js +0 -18
- package/dev-tools/sauce/js/example.js +0 -6
- package/dev-tools/sauce/js/fibonacci.js +0 -13
- package/dev-tools/sauce/ts/add.ts +0 -4
- package/dev-tools/sauce/ts/call.ts +0 -8
- package/dev-tools/sauce/ts/erc20.ts +0 -18
- package/dev-tools/sauce/ts/example.ts +0 -6
- package/dev-tools/sauce/ts/fibonacci.ts +0 -13
- package/dev-tools/sauce/ts/saucescript.d.ts +0 -1
- package/dev-tools/sauce/ts/tsconfig.json +0 -12
- package/dev-tools/scripts/deploy.ts +0 -107
- package/dev-tools/scripts/init.js +0 -132
- package/dev-tools/scripts/run.ts +0 -67
- package/dev-tools/scripts/start-fork.sh +0 -92
- package/dev-tools/scripts/start-local.sh +0 -120
- package/dev-tools/scripts/stop-local.sh +0 -40
- package/dev-tools/scripts/sync-artifacts.js +0 -46
- package/dev-tools/scripts/sync-price.ts +0 -58
- package/dev-tools/src/contracts.ts +0 -59
- package/dev-tools/src/runner.ts +0 -355
- package/dev-tools/src/svm-local.ts +0 -305
- package/dev-tools/src/sync-price.ts +0 -217
- package/sdk/dist/deployments/v12.generated.d.ts +0 -95
- package/sdk/dist/deployments/v12.generated.d.ts.map +0 -1
- package/sdk/dist/deployments/v12.generated.js +0 -50
- package/sdk/dist/deployments/v12.generated.js.map +0 -1
- package/sdk/dist/swap/index.d.ts +0 -29
- package/sdk/dist/swap/index.d.ts.map +0 -1
- package/sdk/dist/swap/index.js +0 -27
- package/sdk/dist/swap/index.js.map +0 -1
- package/sdk/dist/swap/params.d.ts +0 -29
- package/sdk/dist/swap/params.d.ts.map +0 -1
- package/sdk/dist/swap/params.js +0 -123
- package/sdk/dist/swap/params.js.map +0 -1
- package/sdk/dist/swap/source.d.ts +0 -30
- package/sdk/dist/swap/source.d.ts.map +0 -1
- package/sdk/dist/swap/source.js +0 -101
- package/sdk/dist/swap/source.js.map +0 -1
- package/sdk/dist/swap/types.d.ts +0 -160
- package/sdk/dist/swap/types.d.ts.map +0 -1
- package/sdk/dist/swap/types.js +0 -106
- package/sdk/dist/swap/types.js.map +0 -1
- package/sdk/src/skills/aave-v3.md +0 -134
- package/sdk/src/skills/aave-v4.md +0 -91
- package/sdk/src/skills/abracadabra.md +0 -93
- package/sdk/src/skills/across.md +0 -90
- package/sdk/src/skills/aerodrome-slipstream.md +0 -57
- package/sdk/src/skills/aevo.md +0 -58
- package/sdk/src/skills/axelar.md +0 -80
- package/sdk/src/skills/chainlink.md +0 -62
- package/sdk/src/skills/curve.md +0 -141
- package/sdk/src/skills/eigenlayer.md +0 -71
- package/sdk/src/skills/gamma.md +0 -79
- package/sdk/src/skills/harvest.md +0 -49
- package/sdk/src/skills/index.md +0 -299
- package/sdk/src/skills/kelp.md +0 -60
- package/sdk/src/skills/kyberswap.md +0 -100
- package/sdk/src/skills/loader.ts +0 -46
- package/sdk/src/skills/maker.md +0 -79
- package/sdk/src/skills/mantle-meth.md +0 -60
- package/sdk/src/skills/olympus.md +0 -46
- package/sdk/src/skills/oneinch.md +0 -64
- package/sdk/src/skills/openocean.md +0 -86
- package/sdk/src/skills/pancakeswap-v3.md +0 -104
- package/sdk/src/skills/paraswap.md +0 -67
- package/sdk/src/skills/permit2.md +0 -73
- package/sdk/src/skills/perpetual-protocol.md +0 -73
- package/sdk/src/skills/pyth.md +0 -58
- package/sdk/src/skills/reflexer.md +0 -73
- package/sdk/src/skills/safe.md +0 -56
- package/sdk/src/skills/seaport.md +0 -65
- package/sdk/src/skills/sommelier.md +0 -47
- package/sdk/src/skills/stader.md +0 -53
- package/sdk/src/skills/swell.md +0 -65
- package/sdk/src/skills/synapse.md +0 -63
- package/sdk/src/skills/synthra-v3.md +0 -57
- package/sdk/src/skills/thales.md +0 -74
- package/sdk/src/skills/tokemak.md +0 -48
- package/sdk/src/skills/uniswap-v3.md +0 -202
- package/sdk/src/skills/uniswap-v4.md +0 -125
- package/sdk/src/skills/unitflow-v3.md +0 -62
- package/sdk/src/skills/vertex.md +0 -55
- package/sdk/src/skills/wormhole.md +0 -76
- package/sdk/src/skills/zerox.md +0 -51
|
@@ -0,0 +1,540 @@
|
|
|
1
|
+
# The Sauce MCP server
|
|
2
|
+
|
|
3
|
+
[Documentation](../README.md) · [The sauce command](cli.md) · [Agent skills](cli.md#agent-skills)
|
|
4
|
+
|
|
5
|
+
`sauce mcp` runs a [Model Context Protocol](https://modelcontextprotocol.io) server. A coding agent
|
|
6
|
+
gets the building half of the [`sauce` command](cli.md) as tools, and the package's agent skills
|
|
7
|
+
as tools and resources. The server compiles programs and action documents and lists a chain's
|
|
8
|
+
names. It builds unsigned transactions: the cook, the Pot's deployment, an intent's publish
|
|
9
|
+
transactions and each step of its life after. It also rehearses a cook and takes calls apart.
|
|
10
|
+
|
|
11
|
+
For the initial release it builds transactions only on **Ethereum**, **Base** and **Solana**. Every
|
|
12
|
+
other chain is a [preview chain](#supported-and-preview-chains): an agent can compile, simulate and
|
|
13
|
+
rehearse any protocol on it, and the tools that would return a transaction there return `refused`
|
|
14
|
+
instead, with how to request the chain.
|
|
15
|
+
|
|
16
|
+
**The local stdio server signs only with wallets in its wallet directory, unlocked by the password
|
|
17
|
+
source it was started with; the HTTP server never signs.** Neither ever asks for a key or a
|
|
18
|
+
password. Without [agent wallets](#agent-wallets), every transaction comes back unsigned, for a
|
|
19
|
+
wallet the user holds. That lets the server run anywhere: on the agent's machine over stdio, or on
|
|
20
|
+
a host of your own over Streamable HTTP. Transactions it does not send are signed and sent by local
|
|
21
|
+
means: a wallet, `cast send`, or `sauce run` with the user's own keystore.
|
|
22
|
+
|
|
23
|
+
## Run it
|
|
24
|
+
|
|
25
|
+
One command, through npx. Node.js 24 or newer:
|
|
26
|
+
|
|
27
|
+
```sh
|
|
28
|
+
npx -y @eco-incorp/sauce mcp # stdio: what an agent launches
|
|
29
|
+
npx -y @eco-incorp/sauce mcp --wallets --password-env SAUCE_WALLET_PASSWORD # stdio, signing
|
|
30
|
+
npx -y @eco-incorp/sauce mcp --http 3000 --config rpc.json # self-hosted, Streamable HTTP
|
|
31
|
+
```
|
|
32
|
+
|
|
33
|
+
In a project that depends on the package, `npx sauce mcp` runs the project's own version.
|
|
34
|
+
`npx sauce mcp --help` lists every flag. The server is loaded only when `sauce mcp` runs, so no
|
|
35
|
+
other command pays for it.
|
|
36
|
+
|
|
37
|
+
Over stdio the server writes nothing but the protocol to stdout. A message larger than `--max-body`
|
|
38
|
+
(2 MiB by default) closes the connection.
|
|
39
|
+
|
|
40
|
+
## Endpoints
|
|
41
|
+
|
|
42
|
+
A tool that reads a chain takes **`rpcUrl`**, an endpoint for that one call. It looks for an
|
|
43
|
+
endpoint in this order:
|
|
44
|
+
|
|
45
|
+
1. the call's own `rpcUrl`;
|
|
46
|
+
2. the server's endpoint for the chain, from `--config <file>` (the
|
|
47
|
+
[`sauce` command's format](cli.md#endpoints-and-signers)):
|
|
48
|
+
|
|
49
|
+
```json
|
|
50
|
+
{ "rpcUrls": { "1": "https://…", "8453": "https://…", "1399811149": "https://…" } }
|
|
51
|
+
```
|
|
52
|
+
|
|
53
|
+
3. if neither has one, a plain error naming the chain and saying to pass `rpcUrl`.
|
|
54
|
+
|
|
55
|
+
The server ships no endpoint and reads no environment variable.
|
|
56
|
+
|
|
57
|
+
A provider URL usually carries a key, so no URL is ever returned, logged or quoted, from the call
|
|
58
|
+
or from the file. That covers results and errors, including an upstream error that repeats the URL.
|
|
59
|
+
The file's path is never shown either. The file is checked when the server starts: a malformed
|
|
60
|
+
entry, a `<…>` placeholder or a URL that is not http(s) stops it there. `sauce_chains` says which
|
|
61
|
+
chains have a server endpoint.
|
|
62
|
+
|
|
63
|
+
**A server someone else runs sees every `rpcUrl` you pass it.** Pass only keys you are willing to
|
|
64
|
+
share with its operator. Otherwise run the server yourself with `npx -y @eco-incorp/sauce mcp`,
|
|
65
|
+
where your URL never leaves your machine.
|
|
66
|
+
|
|
67
|
+
What works with no endpoint at all:
|
|
68
|
+
|
|
69
|
+
- compiling a program or an action document;
|
|
70
|
+
- a chain's names and a price conversion;
|
|
71
|
+
- the EVM cook, given its `value`, on a supported chain;
|
|
72
|
+
- the Pot's address, and on a supported chain its deployment and an intent's publish transactions;
|
|
73
|
+
- taking calldata apart, and reading the skills.
|
|
74
|
+
|
|
75
|
+
What needs one: `sauce_simulate`, a publish dry run, anything given a transaction hash, a Solana cook
|
|
76
|
+
(its blockhash and fee), and reading the Kitchen's fee or whether a Pot exists.
|
|
77
|
+
|
|
78
|
+
## Add it to a coding agent
|
|
79
|
+
|
|
80
|
+
`sauce mcp setup` writes the project configuration each agent documents. The server it configures
|
|
81
|
+
is launched as `npx -y @eco-incorp/sauce@<this version> mcp`:
|
|
82
|
+
|
|
83
|
+
```sh
|
|
84
|
+
npx sauce mcp setup # every agent below
|
|
85
|
+
npx sauce mcp setup --agent claude,cursor # only these
|
|
86
|
+
npx sauce mcp setup --config rpc.json # launch it with --config
|
|
87
|
+
```
|
|
88
|
+
|
|
89
|
+
| Agent | File | Under | Documentation |
|
|
90
|
+
| ------------------------ | ----------------------- | --------------------- | --------------------------------------------------------------------------------- |
|
|
91
|
+
| Claude Code | `.mcp.json` | `mcpServers` | [MCP](https://code.claude.com/docs/en/mcp) |
|
|
92
|
+
| OpenAI Codex | `.codex/config.toml` | `[mcp_servers.sauce]` | [MCP](https://learn.chatgpt.com/docs/extend/mcp?surface=cli) |
|
|
93
|
+
| Cursor | `.cursor/mcp.json` | `mcpServers` | [MCP](https://cursor.com/docs/mcp) |
|
|
94
|
+
| GitHub Copilot (VS Code) | `.vscode/mcp.json` | `servers` | [MCP servers](https://code.visualstudio.com/docs/agent-customization/mcp-servers) |
|
|
95
|
+
| Gemini CLI | `.gemini/settings.json` | `mcpServers` | [MCP servers](https://geminicli.com/docs/tools/mcp-server/) |
|
|
96
|
+
|
|
97
|
+
How setup treats files that already exist:
|
|
98
|
+
|
|
99
|
+
- It keeps everything else in a file.
|
|
100
|
+
- It writes nothing when the entry is already there.
|
|
101
|
+
- It leaves a `sauce` entry that differs alone, unless you pass `--force`.
|
|
102
|
+
- It leaves a file that is not plain JSON (one with comments) alone too, and prints the entry to
|
|
103
|
+
add.
|
|
104
|
+
|
|
105
|
+
Each agent asks before it runs a server a project names:
|
|
106
|
+
|
|
107
|
+
- Claude Code asks you to approve a project server.
|
|
108
|
+
- Codex reads `.codex/config.toml` only in a project it trusts.
|
|
109
|
+
- VS Code applies Workspace Trust.
|
|
110
|
+
- Gemini CLI, with its Trusted Folders setting on, ignores an untrusted folder's settings.
|
|
111
|
+
|
|
112
|
+
Or add it by hand, with each agent's own command, per its documentation:
|
|
113
|
+
|
|
114
|
+
```sh
|
|
115
|
+
claude mcp add --scope project sauce -- npx -y @eco-incorp/sauce mcp
|
|
116
|
+
codex mcp add sauce -- npx -y @eco-incorp/sauce mcp
|
|
117
|
+
copilot mcp add sauce -- npx -y @eco-incorp/sauce mcp
|
|
118
|
+
```
|
|
119
|
+
|
|
120
|
+
`codex mcp add` and `copilot mcp add` (the Copilot CLI) write the user's configuration, not the
|
|
121
|
+
project's. Cursor has no add command, so write `.cursor/mcp.json`. The entry, for a stdio server:
|
|
122
|
+
|
|
123
|
+
```json
|
|
124
|
+
{
|
|
125
|
+
"mcpServers": {
|
|
126
|
+
"sauce": { "type": "stdio", "command": "npx", "args": ["-y", "@eco-incorp/sauce", "mcp"] }
|
|
127
|
+
}
|
|
128
|
+
}
|
|
129
|
+
```
|
|
130
|
+
|
|
131
|
+
```toml
|
|
132
|
+
[mcp_servers.sauce]
|
|
133
|
+
command = "npx"
|
|
134
|
+
args = ["-y", "@eco-incorp/sauce", "mcp"]
|
|
135
|
+
```
|
|
136
|
+
|
|
137
|
+
VS Code's `.vscode/mcp.json` has the same entry under `servers`. Gemini CLI's
|
|
138
|
+
`.gemini/settings.json` has it under `mcpServers`, without `type`. An agent can also ask the
|
|
139
|
+
server itself: `sauce_install_skills` returns these for the agent it names.
|
|
140
|
+
|
|
141
|
+
### A remote server
|
|
142
|
+
|
|
143
|
+
For a server someone runs at `https://<host>/mcp`, behind a token:
|
|
144
|
+
|
|
145
|
+
```sh
|
|
146
|
+
claude mcp add --transport http sauce https://<host>/mcp --header "Authorization: Bearer <token>"
|
|
147
|
+
codex mcp add sauce --url https://<host>/mcp --bearer-token-env-var SAUCE_MCP_TOKEN
|
|
148
|
+
copilot mcp add --transport http --header "Authorization: Bearer <token>" sauce https://<host>/mcp
|
|
149
|
+
```
|
|
150
|
+
|
|
151
|
+
The same in each agent's file:
|
|
152
|
+
|
|
153
|
+
- **Claude Code:** `{ "type": "http", "url": …, "headers": { … } }` in `.mcp.json`.
|
|
154
|
+
- **Cursor:** `{ "url": …, "headers": { "Authorization": "Bearer ${env:SAUCE_MCP_TOKEN}" } }`.
|
|
155
|
+
- **VS Code:** `{ "type": "http", "url": …, "headers": { … } }` under `servers`.
|
|
156
|
+
- **Gemini CLI:** `{ "httpUrl": …, "headers": { … } }`. Its `url` means SSE, which this server
|
|
157
|
+
does not serve.
|
|
158
|
+
|
|
159
|
+
## Tools
|
|
160
|
+
|
|
161
|
+
Each tool is the `sauce` command named beside it, called with the same inputs: the server calls the
|
|
162
|
+
very functions the command does. Each returns its JSON as the tool's structured content, with the
|
|
163
|
+
same JSON as text. Where there are `notes`, they say what must be true for a transaction to land.
|
|
164
|
+
|
|
165
|
+
| Tool | Like | Returns |
|
|
166
|
+
| ---------------------- | ---------------------- | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
|
|
167
|
+
| `sauce_skills` | — | Every agent skill with when to use it and its files' sizes, and the package version |
|
|
168
|
+
| `sauce_skill` | — | One skill's `SKILL.md`, or a file under its `references/` or `examples/`; with `section` or `query`, only that part |
|
|
169
|
+
| `sauce_dev` | — | For TypeScript against the SDK: the TypeScript skill and the package's guides, API pages and examples for a topic or a question |
|
|
170
|
+
| `sauce_install_skills` | `sauce skills` | For one agent, pinned to the server's version: the commands that add the package and install, update and check the skills, where it reads them, and its MCP configuration |
|
|
171
|
+
| `sauce_chains` | — | Every chain: slug, id, name, kind, aliases, `support` (`supported` or `preview`) and whether the server has its own endpoint for it; `supported`, the supported slugs; `requestChain`, the chain-support request form |
|
|
172
|
+
| `sauce_globals` | `sauce globals` | The chain's token symbols, protocol namespaces and contracts (with `protocol`, its methods), chain names, defines and `@sauce/token` functions; `stocks` and `search` for its tokenized stocks, 200 tokens a page (`offset`) |
|
|
173
|
+
| `sauce_price` | `sauce price` | A pair's price as the pool's `sqrtPriceX96` (also the swap's limit) and each direction's `minAvgPrice`; from `price`, `sqrtPriceX96` or a `pool` read now; with `slippageBps`, the `limits` |
|
|
174
|
+
| `sauce_pools` | `sauce pools` | Every price-limit pool of a pair on the chain, deepest first: venue, contract, address or V4 key, fee, liquidity, `sqrtPriceX96`, and each direction's price before and with the fee, the distributed swap's `maxPrice` and the depth to a 1% move; `empty`, the pools with no liquidity |
|
|
175
|
+
| `sauce_compile` | `sauce compile` | `bytecode`, `size`, `entryParams`, `entryEncoding`, `entrySchema`, each define it reads and where it came from, the `contracts` it calls, `compiler`, `engine`, on Solana the `manifest`; with `args` the `payload`, and with `rpcUrls` each intent's Pot checked |
|
|
176
|
+
| `sauce_actions` | `sauce actions` | An actions document (JSON) compiled for a chain: `sauce_compile`'s report with the generated `source`, its `parameters` and bindings, and, given a Pot, the unsigned cook `transaction` (on a preview chain, `refused` instead) |
|
|
177
|
+
| `sauce_tx` | `sauce tx` | EVM `{ chainId, to, data, value }`, the cook on the Pot, with `from` (who signs) and the `kitchenFee` read; Solana `{ chain, via, feePayer, pot, fee, maxExecutionFee, transaction }`, base64 and signed by no one |
|
|
178
|
+
| `sauce_pot` | `sauce pot` | The Pot's address, its unsigned deployment (EVM `Kitchen.deployPot`; Solana `create_pot`; on a preview chain, `refused` instead), `deployed` (null with no endpoint), and with an endpoint what it holds and the Kitchen's fee |
|
|
179
|
+
| `sauce_simulate` | `sauce simulate` | `ok`, the `path` taken, gas, what `main` returns, transfers, approvals and net balance changes; or the `stage` and `reason` it reverts |
|
|
180
|
+
| `sauce_intent_publish` | `sauce intent publish` | Each fixed intent's `intentHash`, its `vault`, its `record` (what the other intent tools take) and its unsigned `transactions` (transfers into the vault, then `Portal.publish`; with `intentFundVia: "publishAndFund"`, approvals then `Portal.publishAndFund`); with `dryRun`, their status and `funded` |
|
|
181
|
+
| `sauce_intent_fill` | `sauce intent fill` | For the solver `from`, its unsigned fill on the destination: approvals, then `fulfillAndProve` (the prover's fee in its value) or `fulfill`; with `dryRun`, the fill rehearsed: the calls and gas, what moved, or the decoded `reason` |
|
|
182
|
+
| `sauce_intent_import` | `sauce intent import` | The intents a source transaction published, each its `record`, vault, block and whether it was funded |
|
|
183
|
+
| `sauce_intent_status` | `sauce intent status` | `state`, both sides as read, the deadlines, the prover, and `can`: whether fill, prove, claim, refund and cancel can happen now, why not, and from when |
|
|
184
|
+
| `sauce_intent_prove` | `sauce intent prove` | The unsigned `Portal.prove` for one or more fills or cancellations, its bridge fee in its value |
|
|
185
|
+
| `sauce_intent_claim` | `sauce intent claim` | The unsigned `withdraw` (`batchWithdraw` for several) that pays each proven intent's claimant |
|
|
186
|
+
| `sauce_intent_refund` | `sauce intent refund` | The unsigned `refund` that returns the reward to its creator |
|
|
187
|
+
| `sauce_intent_cancel` | `sauce intent cancel` | The unsigned `cancel` (or, with `prove`, `cancelAndProve`) that stops an unfilled intent after its route's deadline |
|
|
188
|
+
| `sauce_inspect` | `sauce inspect` | A cook, Kitchen, Portal or ERC-20 call, or a program, taken apart; with `source`, the arguments decoded against `main` |
|
|
189
|
+
| `sauce_verify` | `sauce verify` | `valid` with the settle's tokens, `minOut` and recipient, or `valid: false` with the rejection `code` |
|
|
190
|
+
| `sauce_wallet_create` | `sauce wallet new` | Over stdio with `--wallets` only: a new wallet's `name`, `kind` (`evm` or `solana`), `address` and `policy` (null: none), never its key |
|
|
191
|
+
| `sauce_wallet_list` | `sauce wallet list` | Over stdio with `--wallets` only: each wallet's name, kind, address and policy |
|
|
192
|
+
| `sauce_wallet_send` | — | Over stdio with `--wallets` only: another tool's result (or a transaction, or a list) rehearsed, held to the wallet's policy, signed and sent; each one's `hash` and `status`, or the refusal |
|
|
193
|
+
|
|
194
|
+
### Supported and preview chains
|
|
195
|
+
|
|
196
|
+
For the initial release the server builds transactions only on the chains the release supports:
|
|
197
|
+
Ethereum, Base and Solana ([Supported chains](../README.md#supported-chains)). Every other chain is a
|
|
198
|
+
preview chain. `sauce_chains` gives each chain's `support`, `"supported"` or `"preview"`.
|
|
199
|
+
|
|
200
|
+
On a preview chain these work as they do everywhere: `sauce_compile`, `sauce_actions`' report,
|
|
201
|
+
`sauce_simulate`, `sauce_globals`, `sauce_price`, `sauce_pools`, `sauce_inspect`, `sauce_verify`,
|
|
202
|
+
the dry runs (`sauce_intent_publish` and `sauce_intent_fill` with `dryRun`), `sauce_pot`'s
|
|
203
|
+
prediction and reads, `sauce_intent_status` and `sauce_intent_import`. So an agent can prototype
|
|
204
|
+
any protocol on any chain.
|
|
205
|
+
|
|
206
|
+
These are refused there, before any endpoint is reached:
|
|
207
|
+
|
|
208
|
+
- `sauce_tx`, when the program's chain, or the destination of any intent it opens, is a preview
|
|
209
|
+
chain;
|
|
210
|
+
- `sauce_intent_publish` without `dryRun`, unless its source and every destination it opens are
|
|
211
|
+
supported (a cascade's later levels are not checked: keep them on supported chains);
|
|
212
|
+
- `sauce_intent_fill` without `dryRun`, `sauce_intent_prove` and `sauce_intent_cancel`, by the
|
|
213
|
+
intent's destination; `sauce_intent_claim` and `sauce_intent_refund`, by its source. An intent
|
|
214
|
+
named by `txHash` is read from its source first, then refused by its destination where that is
|
|
215
|
+
the chain the step is sent on.
|
|
216
|
+
|
|
217
|
+
A refused call is an error result (`isError: true`) whose structured content is the refusal, also
|
|
218
|
+
given as its text:
|
|
219
|
+
|
|
220
|
+
```json
|
|
221
|
+
{
|
|
222
|
+
"refused": {
|
|
223
|
+
"code": "preview-chain",
|
|
224
|
+
"action": "building the cook transaction",
|
|
225
|
+
"message": "building the cook transaction is refused: it involves arbitrum (Arbitrum One, chain id 42161), a preview chain. …",
|
|
226
|
+
"supportedChains": [
|
|
227
|
+
{ "slug": "ethereum", "id": 1, "name": "Ethereum" },
|
|
228
|
+
{ "slug": "base", "id": 8453, "name": "Base" },
|
|
229
|
+
{ "slug": "solana", "id": 1399811149, "name": "Solana" }
|
|
230
|
+
],
|
|
231
|
+
"previewChains": [
|
|
232
|
+
{
|
|
233
|
+
"slug": "arbitrum",
|
|
234
|
+
"id": 42161,
|
|
235
|
+
"name": "Arbitrum One",
|
|
236
|
+
"request": {
|
|
237
|
+
"chain": { "name": "Arbitrum One", "id": 42161, "slug": "arbitrum" },
|
|
238
|
+
"title": "Chain support: Arbitrum One (42161)",
|
|
239
|
+
"searchUrl": "https://github.com/eco-incorp/sauce/issues?q=is%3Aissue+label%3Achain-support+%22Arbitrum+One%22",
|
|
240
|
+
"newIssueUrl": "https://github.com/eco-incorp/sauce/issues/new?template=chain-support.yml&title=Chain+support%3A+Arbitrum+One+%2842161%29&chain=Arbitrum+One&chain-id=42161",
|
|
241
|
+
"body": "### Chain\n\nArbitrum One\n\n### Chain id\n\n42161\n\n### What you want to run there\n\n…",
|
|
242
|
+
"comment": "Another use case for Arbitrum One (42161):\n\n- What you want to run there: …"
|
|
243
|
+
}
|
|
244
|
+
}
|
|
245
|
+
]
|
|
246
|
+
}
|
|
247
|
+
}
|
|
248
|
+
```
|
|
249
|
+
|
|
250
|
+
`searchUrl` finds the chain-support requests already filed for the chain; `newIssueUrl` opens the
|
|
251
|
+
issue form with its title and chain filled in. `body` is the issue as the form would write it, and
|
|
252
|
+
`comment` adds one use case to an existing request, each with `<placeholders>` for what the agent
|
|
253
|
+
does not know, to post through the user's own GitHub access. The server's instructions tell an
|
|
254
|
+
agent to tell the user, offer to find or open that request, and not to build the transaction
|
|
255
|
+
another way.
|
|
256
|
+
|
|
257
|
+
`sauce_pot` on a preview chain returns its prediction (and, with an endpoint, its reads) with
|
|
258
|
+
`refused` in place of the deployment's `to`, `data` and `value`. `sauce_actions` given a Pot on a
|
|
259
|
+
preview chain returns its report with `refused` in place of `transaction`. Neither is an error.
|
|
260
|
+
|
|
261
|
+
A revert and a rejected settle are results (`ok: false`, `valid: false`), not errors. An error is a
|
|
262
|
+
call that could not be answered: a program that does not compile, an input that is wrong, a chain
|
|
263
|
+
that cannot be read. Every input is described in the tool's schema, which `tools/list` returns. An
|
|
264
|
+
unknown field is refused, which is how a misspelt one is caught.
|
|
265
|
+
|
|
266
|
+
The compiling tools take the program as text:
|
|
267
|
+
|
|
268
|
+
| Input | Meaning |
|
|
269
|
+
| ------------------------------------------------------- | ---------------------------------------------------------------------------------------------------------------------------------- |
|
|
270
|
+
| `source` | The program, the whole text of a `.sauce.ts` file (at most 256 KiB) |
|
|
271
|
+
| `file` | Its name, for messages and relative imports (default `program.sauce.ts`) |
|
|
272
|
+
| `modules` | Files it imports by relative path, as path → text from the directory of `file`. Nothing is read from the server's disk |
|
|
273
|
+
| `chain`, `target` | The chain, by slug, alias or id; or a `// @chain` header line in the program. `target: "svm"` alone is Solana |
|
|
274
|
+
| `defines` | Compile-time values by name: an integer in base units (decimal or `0x` hex), an address, `true` or `false`; a base58 key on Solana |
|
|
275
|
+
| `compactArgs` | Encode `main`'s arguments as compact-v1 |
|
|
276
|
+
| `intentDeadline`, `intentCreator`, `intentExecutionFee` | For intents the program opens: Unix seconds, a `0x` address, wei |
|
|
277
|
+
| `intentFundVia` | How their reward reaches the vault: `transfer` (default: paid into it, then `publish`) or `publishAndFund` |
|
|
278
|
+
|
|
279
|
+
`sauce_compile` also takes a cook's `args` and `accounts`, to size the payload and, on Solana, the
|
|
280
|
+
cook's transaction (with `via`, the Kitchen's or the engine's direct one); and `rpcUrls`, each intent destination's endpoint by chain, to check that the
|
|
281
|
+
Pot an intent's cook runs on is deployed there.
|
|
282
|
+
|
|
283
|
+
A cook (`sauce_tx`, `sauce_simulate`, `sauce_actions`) adds these inputs:
|
|
284
|
+
|
|
285
|
+
- the Pot: `owner` and `salt` (a label, hashed) or `saltHex` (the salt itself). On an EVM chain the
|
|
286
|
+
Pot can be named by its address as `pot` instead.
|
|
287
|
+
- `value` in wei, on an EVM chain. The default is the Kitchen's fee, read from the chain.
|
|
288
|
+
- `args`: `main`'s arguments as JSON values, in order. Integers are in base units, as decimal
|
|
289
|
+
strings.
|
|
290
|
+
- `accounts`, on Solana: each account `main` takes, by name. Each is an address, `pot` or `owner`.
|
|
291
|
+
- `via`, on Solana: `kitchen` (the default), the Kitchen's cook on the owner's Pot, or `engine`,
|
|
292
|
+
the engine's own paid cook with no Kitchen and no Pot: the owner signs as the authority the
|
|
293
|
+
program acts with and pays the fee, and the program's own calls get one more level of CPI depth
|
|
294
|
+
([Solana guide](solana.md#two-ways-to-run-a-program)).
|
|
295
|
+
- `maxExecutionFee` in lamports, on Solana: a cook whose execution fee, read from the cluster, is
|
|
296
|
+
above it is refused before anything is built.
|
|
297
|
+
- `rpcUrl`.
|
|
298
|
+
|
|
299
|
+
`sauce_simulate` also takes:
|
|
300
|
+
|
|
301
|
+
- `assumeBalance`, such as `["USDC:2", "ETH:0.1"]`: balances the Pot holds for the rehearsal only;
|
|
302
|
+
- `fund`, `fundMode` and `sweep`, which rehearse [`sauce run --fund`](cli.md#funding-a-run---fund).
|
|
303
|
+
The Pot is credited what the pulls would bring.
|
|
304
|
+
|
|
305
|
+
A token amount is whole units (`USDC:1.5`) or base units ending in `n` (`USDC:1500000n`).
|
|
306
|
+
|
|
307
|
+
`sauce_pot` with an endpoint reads what a cook needs: on an EVM chain the Kitchen's fee (the least
|
|
308
|
+
a cook's `value` can be) and the Pot's balance of the native currency and of each token the chain
|
|
309
|
+
registers but its tokenized stocks (`null` where a token cannot be read there); on Solana the Pot's
|
|
310
|
+
associated token account for each registered mint but the tokenized stocks, whether it exists, and
|
|
311
|
+
its balance. `balances: false` skips those reads.
|
|
312
|
+
|
|
313
|
+
`sauce_price` takes the price one of three ways: `price` (a decimal), `sqrtPriceX96`, or `pool`, a
|
|
314
|
+
Uniswap V3-style pool of the pair read through an endpoint (its `slot0` price, liquidity and fee).
|
|
315
|
+
With `slippageBps`, `limits` gives each direction's `sqrtPriceLimitX96` that far from the price,
|
|
316
|
+
and a `minAvgPrice` that also pays the pool's fee (`feePpm`, or the pool's own). A token the chain
|
|
317
|
+
does not register is `<address>:<decimals>`, or with an endpoint the address alone: its decimals
|
|
318
|
+
are read from the token.
|
|
319
|
+
|
|
320
|
+
`sauce_pools` takes `chain`, `tokenA` and `tokenB` (each a registered symbol or an address, whose
|
|
321
|
+
decimals and symbol are then read from the token), `v4Pools` (more hookless Uniswap V4 keys to
|
|
322
|
+
try, each `"<fee>:<tickSpacing>"`), and `rpcUrl`; it needs an endpoint. It returns what
|
|
323
|
+
[`sauce pools --json`](cli.md#sauce-pools) prints: `pools`, the ones with liquidity, deepest first,
|
|
324
|
+
each with two `sides` (paying `tokenA` for `tokenB`, then the reverse); `empty`; and `checked`,
|
|
325
|
+
the tiers, tick spacings and keys each venue was asked for.
|
|
326
|
+
|
|
327
|
+
`sauce_intent_publish` takes `from` (the wallet that funds the reward), `dryRun`, `assumeBalance`,
|
|
328
|
+
`rpcUrl`, and the program inputs, `intentFundVia` among them. The program inputs also take the
|
|
329
|
+
reward's deadline and prover: `intentRewardDeadline`
|
|
330
|
+
(Unix seconds; the intent's deadline by default) and `intentProver` (the registry's for the pair by
|
|
331
|
+
default).
|
|
332
|
+
|
|
333
|
+
### An intent's life
|
|
334
|
+
|
|
335
|
+
The server keeps no intents: each call names one, by its `record` — the JSON
|
|
336
|
+
`sauce_intent_publish`, `sauce_intent_import` and `sauce_intent_status` return, checked against its
|
|
337
|
+
own hash before anything is built from it — or by the transaction that published it, `txHash` with
|
|
338
|
+
its source `chain` (and `index` when it published several). `sauce_intent_fill` also takes the
|
|
339
|
+
program itself, with the same inputs as `sauce_intent_publish`.
|
|
340
|
+
|
|
341
|
+
1. `sauce_intent_publish`: the creator's transactions on the source chain. Or `sauce_intent_import`
|
|
342
|
+
for an intent published elsewhere.
|
|
343
|
+
2. `sauce_intent_status`: where it stands, and `can`, what can happen next and from when.
|
|
344
|
+
3. `sauce_intent_fill` with `from`, the solver: its transactions on the destination. With `dryRun`,
|
|
345
|
+
the same fill rehearsed, from any solver. A fill that proves itself (`fulfillAndProve`) needs no
|
|
346
|
+
step 4.
|
|
347
|
+
4. `sauce_intent_prove`: the proof of fills or cancellations, sent from the destination; the
|
|
348
|
+
bridge delivers it to the source's prover.
|
|
349
|
+
5. `sauce_intent_claim`: the reward paid to each proven fill's claimant, on the source.
|
|
350
|
+
|
|
351
|
+
The creator's way back:
|
|
352
|
+
|
|
353
|
+
- `sauce_intent_refund` returns the reward from the reward's deadline when no one proved a fill, or
|
|
354
|
+
earlier once a proven cancellation is recorded on the source. A source Portal that cannot refuse
|
|
355
|
+
to pay a cancellation is never refunded early.
|
|
356
|
+
- `sauce_intent_cancel` stops an unfilled intent after its route's deadline. Anyone may send it,
|
|
357
|
+
and only a destination Portal that can cancel takes it. Prove the cancellation with
|
|
358
|
+
`sauce_intent_prove` once the block it landed in is final (give that block in `cancelledIn`), then
|
|
359
|
+
refund. `prove: true` sends the proof at once, before finality, and the result warns.
|
|
360
|
+
|
|
361
|
+
For an intent to Solana, the destination's steps — fill, prove and cancel — come back as Solana
|
|
362
|
+
transactions: `feePayer` and `transaction`, a base64 wire transaction with every signature in but
|
|
363
|
+
the fee payer's. Pass the Solana key that pays and signs as `from`; a fill also needs `claimant`,
|
|
364
|
+
the address on the EVM source the reward pays. Sign each with that key, last, and send it within
|
|
365
|
+
about a minute, before its blockhash expires. `dryRun` rehearses an EVM destination's fill only;
|
|
366
|
+
a Solana fill is rehearsed as it is built. Claim and refund stay on the EVM source.
|
|
367
|
+
|
|
368
|
+
A step that cannot happen yet is a result, `ready: false` with `why`, not an error. Each tool reads
|
|
369
|
+
the chains it needs through `rpcUrls`, each chain's endpoint by slug or id; `rpcUrl` is the endpoint
|
|
370
|
+
of the chain the tool names (the source for import, claim and refund, the destination for fill,
|
|
371
|
+
prove and cancel). The server's own endpoints fill the gaps.
|
|
372
|
+
|
|
373
|
+
`sauce_actions` takes the document as `program`, an object or its JSON text, validated against the
|
|
374
|
+
[action-program schema](../../actions/action-program.schema.json), also served as
|
|
375
|
+
`sauce://actions/schema.json`, and `chain` for a document without a `chainId`. It calls the
|
|
376
|
+
function `sauce actions` runs, so its names (tokens by symbol, contracts by namespace) resolve on
|
|
377
|
+
that chain as they do for the command.
|
|
378
|
+
|
|
379
|
+
Error messages and notes are the `sauce` command's, in the tools' words: a flag is named as the
|
|
380
|
+
tool input (`--salt-hex` as `saltHex`, `--args` as `args`), and a command line as the tool
|
|
381
|
+
(`sauce pot --deploy …` as `sauce_pot`).
|
|
382
|
+
|
|
383
|
+
### Signing what it builds
|
|
384
|
+
|
|
385
|
+
The server's transactions are for the user's own wallet, or, on a server started with
|
|
386
|
+
`--wallets`, for [`sauce_wallet_send`](#agent-wallets). On an EVM chain, `sauce_tx` returns what
|
|
387
|
+
any wallet signs. Send it from the Pot's owner, since `cook()` is the owner's alone. From a terminal:
|
|
388
|
+
|
|
389
|
+
```sh
|
|
390
|
+
cast send <to> <data> --value <value> --rpc-url <url> --keystore <keystore>
|
|
391
|
+
```
|
|
392
|
+
|
|
393
|
+
The other transactions:
|
|
394
|
+
|
|
395
|
+
- `sauce_pot`'s deployment can be sent from any account.
|
|
396
|
+
- `sauce_intent_publish`'s transactions go in order, from the wallet that funds the reward: the
|
|
397
|
+
transfers into the vault first, then `publish` once they have landed.
|
|
398
|
+
- `sauce_intent_fill`'s go in order from the solver it names (`from`): the Portal pulls what the
|
|
399
|
+
route delivers from the account that calls `fulfill`.
|
|
400
|
+
- On Solana, each transaction is signed last by its `feePayer`, the `from` the call named.
|
|
401
|
+
- The proof, claim, refund and cancellation can be sent from any account. Each `transactions`
|
|
402
|
+
entry names its `chainId`; the sender pays the gas and the value, and the reward goes to the
|
|
403
|
+
claimant or the creator, never the sender.
|
|
404
|
+
- On Solana, `sauce_tx`'s `transaction` is base64, for the owner to sign and send. Its blockhash
|
|
405
|
+
expires in about a minute.
|
|
406
|
+
|
|
407
|
+
## Agent wallets
|
|
408
|
+
|
|
409
|
+
Over stdio, the server can send what it builds, from wallets of its own. Start it with the wallet
|
|
410
|
+
directory, `--wallets [<dir>]` (`~/.sauce/wallets` when no directory is given), and the source of
|
|
411
|
+
their password, as [`sauce wallet`](cli.md#agent-wallets) takes one: `--password-env <NAME>`,
|
|
412
|
+
`--password-file <path>` or `--password-command "<command>"`. There is no prompt: over stdio,
|
|
413
|
+
stdin is the protocol's. The server reads the password once, before it serves anything, so a
|
|
414
|
+
source that does not work stops it at start. The password is never a tool's input and never in a
|
|
415
|
+
result, so it stays out of the model's context.
|
|
416
|
+
|
|
417
|
+
The agent's password lives in its `.env` or its secret store, and the client's configuration passes
|
|
418
|
+
it to the server in the entry's `env` block, by reference, never by value:
|
|
419
|
+
|
|
420
|
+
```json
|
|
421
|
+
{
|
|
422
|
+
"mcpServers": {
|
|
423
|
+
"sauce": {
|
|
424
|
+
"type": "stdio",
|
|
425
|
+
"command": "npx",
|
|
426
|
+
"args": [
|
|
427
|
+
"-y",
|
|
428
|
+
"@eco-incorp/sauce",
|
|
429
|
+
"mcp",
|
|
430
|
+
"--wallets",
|
|
431
|
+
"--password-env",
|
|
432
|
+
"SAUCE_WALLET_PASSWORD"
|
|
433
|
+
],
|
|
434
|
+
"env": { "SAUCE_WALLET_PASSWORD": "${SAUCE_WALLET_PASSWORD}" }
|
|
435
|
+
}
|
|
436
|
+
}
|
|
437
|
+
}
|
|
438
|
+
```
|
|
439
|
+
|
|
440
|
+
Each client fills that reference its own way: Claude Code expands `${SAUCE_WALLET_PASSWORD}` from
|
|
441
|
+
the environment it runs in, and VS Code also reads an `envFile` (the project's `.env`). Keep the
|
|
442
|
+
`.env` out of git.
|
|
443
|
+
|
|
444
|
+
The wallet tools, besides every other tool:
|
|
445
|
+
|
|
446
|
+
- `sauce_wallet_create` `{ name, kind }` makes a wallet (`kind` `evm`, the default, or `solana`),
|
|
447
|
+
encrypted under the server's password (8 characters at least, as for `sauce wallet new`), and
|
|
448
|
+
returns its address. Its key never leaves the wallet's file except to sign, in the server's
|
|
449
|
+
process.
|
|
450
|
+
- `sauce_wallet_list` names each wallet with its kind, address and policy.
|
|
451
|
+
- `sauce_wallet_send` `{ wallet, transaction, chain?, rpcUrl? }` sends. `transaction` is the
|
|
452
|
+
whole result of `sauce_tx`, `sauce_pot`, `sauce_actions` (with an owner), `sauce_intent_publish`
|
|
453
|
+
or any `sauce_intent_*` step, or a transaction, or a list of them. It rehearses them first: on an
|
|
454
|
+
EVM chain all together in one `eth_simulateV1` block from the wallet, on Solana each as signed.
|
|
455
|
+
If any would revert, it refuses and sends nothing. It holds them to the wallet's
|
|
456
|
+
[policy](cli.md#a-wallets-policy) and refuses, naming the limit, what the policy does not allow.
|
|
457
|
+
Then it sends each in order, through the same path `sauce run` uses, and stops at the first that
|
|
458
|
+
does not succeed. It returns each one's `hash` (on Solana, its signature) and `status`.
|
|
459
|
+
|
|
460
|
+
So an agent goes: `sauce_wallet_create`, fund the address, build with the wallet's address as
|
|
461
|
+
`owner` or `from` (`sauce_pot`, `sauce_tx`, `sauce_intent_fill`, …), rehearse with
|
|
462
|
+
`sauce_simulate`, and pass the building tool's result to `sauce_wallet_send`. Each tool that builds
|
|
463
|
+
a transaction says, on a server with wallets, that `sauce_wallet_send` sends it. There is no export
|
|
464
|
+
tool: `sauce wallet export` shows a key only at a terminal.
|
|
465
|
+
|
|
466
|
+
These are hot wallets: keep small balances in them, and give each a policy. Wallet sends hold to
|
|
467
|
+
the [supported chains](#supported-and-preview-chains) too. Over HTTP there are no wallets:
|
|
468
|
+
`--wallets` is refused, and the wallet tools are not registered.
|
|
469
|
+
|
|
470
|
+
## Skills, documents and prompts
|
|
471
|
+
|
|
472
|
+
The [agent skills](cli.md#agent-skills) the package ships are the same files `sauce skills install`
|
|
473
|
+
copies into a project. They are served two ways, because many clients call tools but never read
|
|
474
|
+
resources:
|
|
475
|
+
|
|
476
|
+
- as tools. `sauce_skills` lists them. `sauce_skill` returns a `SKILL.md`, or a file it links, by
|
|
477
|
+
skill and path; only shipped files are served. `sauce_dev` returns the TypeScript skill and the
|
|
478
|
+
package's own guides, API pages and examples for a topic or a free-text question.
|
|
479
|
+
`sauce_install_skills` says how to install the skills locally for an agent, at the server's
|
|
480
|
+
own version.
|
|
481
|
+
- as resources. `sauce://skills/index` lists every skill and its files.
|
|
482
|
+
`sauce://skills/<skill>/SKILL.md` is a skill, and its `references/…` and `examples/…` sit beside
|
|
483
|
+
it.
|
|
484
|
+
|
|
485
|
+
When a client connects, the server's instructions tell it five things: whether the server signs
|
|
486
|
+
(only with its wallets, over stdio with `--wallets`), start from `sauce_skills`, the steps from `sauce_globals` to `sauce_tx`, which chains it builds
|
|
487
|
+
transactions on and what to do with a refusal, and how `rpcUrl` works. Two prompts walk the main tasks through the
|
|
488
|
+
tools, with the skill they start from embedded:
|
|
489
|
+
|
|
490
|
+
- `sauce_write_program` (`task`, `chain`) writes, compiles, rehearses and builds a program.
|
|
491
|
+
- `sauce_open_intent` (`task`, `source`, `destination`) opens a cross-chain intent and builds its
|
|
492
|
+
publish transactions.
|
|
493
|
+
|
|
494
|
+
## Self-hosting
|
|
495
|
+
|
|
496
|
+
```sh
|
|
497
|
+
npx -y @eco-incorp/sauce mcp --http 3000 --config rpc.json
|
|
498
|
+
```
|
|
499
|
+
|
|
500
|
+
This serves Streamable HTTP at `http://127.0.0.1:3000/mcp`. The server is stateless: every POST
|
|
501
|
+
gets a server of its own, answered as JSON, with no session, so any replica can answer any request.
|
|
502
|
+
A GET or DELETE is refused (405).
|
|
503
|
+
|
|
504
|
+
- **No environment, and no key.** The server reads no environment variable. Its RPC endpoints are
|
|
505
|
+
the `--config` file's alone, and it holds no key: nothing it builds is signed. `--wallets` is
|
|
506
|
+
refused over HTTP, and the wallet tools are not registered there.
|
|
507
|
+
- **It authenticates no one.** Bound to loopback, the default, it answers only requests whose
|
|
508
|
+
`Host`, and `Origin` when one is sent, is a loopback name. That keeps a web page from reaching it
|
|
509
|
+
through DNS rebinding.
|
|
510
|
+
- **Off loopback it needs `--allowed-host`.** For a deployment others reach, bind it with `--host`
|
|
511
|
+
and name the host it is served as with `--allowed-host` (repeatable). It refuses to start
|
|
512
|
+
without one. `--allowed-host '*'` answers any `Host`, for a proxy that checks it itself.
|
|
513
|
+
- **Put your own authentication in front.** Use a reverse proxy that checks a token (or OAuth)
|
|
514
|
+
before forwarding to it, and that rate-limits, since every chain read spends your endpoints'
|
|
515
|
+
quota.
|
|
516
|
+
|
|
517
|
+
```sh
|
|
518
|
+
npx -y @eco-incorp/sauce mcp --http 3000 --host 0.0.0.0 --allowed-host mcp.example.com \
|
|
519
|
+
--config rpc.json
|
|
520
|
+
```
|
|
521
|
+
|
|
522
|
+
**Callers' endpoints are guarded.** Over HTTP, a caller's `rpcUrl` is chosen by whoever calls, so
|
|
523
|
+
the server reaches it only through a guard:
|
|
524
|
+
|
|
525
|
+
- It takes `https:` only.
|
|
526
|
+
- It resolves the host and refuses any address that is loopback, private (RFC 1918, ULA),
|
|
527
|
+
link-local, CGNAT, reserved or a cloud metadata service.
|
|
528
|
+
- It resolves and checks the host again at every connection, so a name that changes to a private
|
|
529
|
+
address after the check (DNS rebinding) is refused when used.
|
|
530
|
+
- It follows no redirect, and times out.
|
|
531
|
+
- It bounds what it sends and what it reads back.
|
|
532
|
+
|
|
533
|
+
`--allow-private-rpc` lets callers reach `http:` and private addresses, for a deployment inside a
|
|
534
|
+
private network. Link-local and metadata addresses stay refused. Over stdio there is no guard: the
|
|
535
|
+
server is the user's own process, reached by the user's own agent, so an endpoint it names (a local
|
|
536
|
+
node included) is one the user can already reach.
|
|
537
|
+
|
|
538
|
+
A request body over `--max-body` bytes (2 MiB by default) is refused with 413 before it is read.
|
|
539
|
+
Each tool bounds its own inputs as well: 256 KiB of program, 32 modules, 64 arguments, defines or
|
|
540
|
+
accounts, and 1 MiB of hex.
|
|
@@ -4,6 +4,12 @@
|
|
|
4
4
|
|
|
5
5
|
`.nest(...)` adds a child intent whose source is the parent's destination. When the parent fulfills, its route funds the child's reward. A solver can fulfill that child in a later transaction on the child's destination chain. Each leg is a separate intent; a failure on a later chain does not roll back a completed parent.
|
|
6
6
|
|
|
7
|
+
The examples here hop through Arbitrum and Optimism, which are preview chains for the initial
|
|
8
|
+
release: the SDK builds them as shown, at your own risk, while the `sauce` command and the MCP server
|
|
9
|
+
publish an intent only when its source and destination are Ethereum, Base or Solana
|
|
10
|
+
([Supported chains](../README.md#supported-chains)). They check the first level only, so keep every
|
|
11
|
+
later level of a cascade on a supported chain too.
|
|
12
|
+
|
|
7
13
|
Use the thunk form to receive the parent's destination as the child's source:
|
|
8
14
|
|
|
9
15
|
```ts
|
|
@@ -17,10 +23,10 @@ export function buildCascade(
|
|
|
17
23
|
childReward: Omit<routes.SauceRewardSpec, "source">,
|
|
18
24
|
executionFee: bigint,
|
|
19
25
|
) {
|
|
20
|
-
return Base("return 1n;", parentOptions)
|
|
26
|
+
return Base("function main() { return 1n; }", parentOptions)
|
|
21
27
|
.nest(
|
|
22
28
|
(on) =>
|
|
23
|
-
Arbitrum("return 1n;", childOptions).reward({
|
|
29
|
+
Arbitrum("function main() { return 1n; }", childOptions).reward({
|
|
24
30
|
...childReward,
|
|
25
31
|
source: on,
|
|
26
32
|
}),
|
|
@@ -51,9 +57,9 @@ With default `requireCap: false`, a short Pot balance can leave the child underf
|
|
|
51
57
|
|
|
52
58
|
Read the current Kitchen fee and supply `executionFee` for every transfer child. Children merged into one position share one fee and must specify the same value; separate `"before"` and `"after"` cooks each pay. The generated call adds this fee to any `fundNativeFromRoute` reward amounts, so the fee does not reduce the child's funding. Zero works only on a fee-free Kitchen. When a nonzero fee is supplied, the builder checks that `nativeAmount` covers the calls' combined value, excluding publication funding explicitly marked `fundedByBody`.
|
|
53
59
|
|
|
54
|
-
The default vault resolution calls the Portal from the generated program. Alternatively, pass `vault` after verifying it with `child.vaultCall()`, or pass `vaultConfig`
|
|
60
|
+
The default vault resolution calls the Portal from the generated program. Alternatively, pass `vault` after verifying it with `child.vaultCall()`, or pass `vaultConfig` for an offline prediction: `routes.ecoRoutesVaultConfig(portal)` is the configuration of an eco-routes Portal, the one `child.predictVault()` uses. Explicit `vault` takes precedence over `vaultConfig`.
|
|
55
61
|
|
|
56
|
-
Transfer funding does not emit a child `IntentPublished` event. Share the built child with your solver or intent-distribution system; an indexer relying only on publication events cannot discover it from such an event.
|
|
62
|
+
Transfer funding does not emit a child `IntentPublished` event. Share the built child with your solver or intent-distribution system; an indexer relying only on publication events cannot discover it from such an event. That is the one difference from an intent a program opens with `Chain(() => …).reward(…)`, which is also funded by transfer to its vault by default but is then published, in the same transaction — see [intents](intents.md#how-the-reward-is-funded).
|
|
57
63
|
|
|
58
64
|
## Opt in to publication and Portal funding
|
|
59
65
|
|
|
@@ -74,7 +80,7 @@ import { Arbitrum, Base, routes } from "@eco-incorp/sauce";
|
|
|
74
80
|
|
|
75
81
|
const { AMOUNT_IN_PLACEHOLDER, AMOUNT_OUT_PLACEHOLDER } = routes;
|
|
76
82
|
|
|
77
|
-
const child = Arbitrum("return 1n;", {
|
|
83
|
+
const child = Arbitrum("function main() { return 1n; }", {
|
|
78
84
|
...childOptions,
|
|
79
85
|
tokens: [{ token: USDC_ARBITRUM, amount: AMOUNT_OUT_PLACEHOLDER }],
|
|
80
86
|
}).reward({ ...childReward, tokens: [{ token: USDC_BASE, amount: AMOUNT_IN_PLACEHOLDER }] });
|
|
@@ -129,6 +135,10 @@ The shortest way to chain hops is to write them inside the program, one intent o
|
|
|
129
135
|
//
|
|
130
136
|
// The middle body is more than token writes, so it compiles to a program and runs on Arbitrum's
|
|
131
137
|
// Pot; its second argument names what a solver must deliver for it to have something to measure.
|
|
138
|
+
//
|
|
139
|
+
// Every `USDC` is the USDC of the chain where that part runs. Each body's is its destination's. Each
|
|
140
|
+
// reward is escrowed by the program offering it, so the Arbitrum hop's reward is the first chain's
|
|
141
|
+
// USDC and the Optimism hop's is Arbitrum's.
|
|
132
142
|
function main() {
|
|
133
143
|
const amount = USDC.balanceOf(ctx.self());
|
|
134
144
|
Arbitrum(
|
|
@@ -148,6 +158,11 @@ first chain. `swapped` is measured on Arbitrum, while that hop is being fulfille
|
|
|
148
158
|
middle braces compiled to — and it is the reward of the third. Each level's numbers are filled in by
|
|
149
159
|
the level above it, at that level's own execution time.
|
|
150
160
|
|
|
161
|
+
Each hop is funded on the chain whose program offers it. The Arbitrum hop's reward is the first
|
|
162
|
+
chain's USDC, escrowed and approved there. The Optimism hop's reward is Arbitrum's USDC, out of what
|
|
163
|
+
the solver delivered to Arbitrum's Pot, and its body pays in Optimism's. See
|
|
164
|
+
[names resolve per chain](intents.md#names-resolve-per-chain).
|
|
165
|
+
|
|
151
166
|
Nesting is recursive rather than special-cased: the middle body is compiled by re-entering the same
|
|
152
167
|
pipeline, so the same lowering runs inside it at any depth. [Create an intent from inside a
|
|
153
168
|
program](intents.md#create-an-intent-from-inside-a-program) covers what may be captured, the two
|
|
@@ -171,7 +186,7 @@ const placeholders = [
|
|
|
171
186
|
{ value: AMOUNT_OUT_PLACEHOLDER, source: "amountOut", occurrences: 1 },
|
|
172
187
|
] as const;
|
|
173
188
|
|
|
174
|
-
const grandchild = Optimism("return 1n;", {
|
|
189
|
+
const grandchild = Optimism("function main() { return 1n; }", {
|
|
175
190
|
...grandchildOptions,
|
|
176
191
|
tokens: [{ token: USDC_OPTIMISM, amount: AMOUNT_OUT_PLACEHOLDER }],
|
|
177
192
|
}).reward({
|