Source a flow input by borrowing the amount from a flashloan provider, repaid within the same transaction.
Not available on production. The flashloan materialiser and the lifi.flashloanRepay op are disabled on https://composer.li.quest, and the published @lifi/composer-sdk doesn’t export materialisers.flashloan. A compile that uses them is rejected. Contact us if you need early access.
flashloan sources a flow input by borrowing the amount from a flashloan provider instead of pulling it from the signer. The borrowed amount is made available to the flow as its input, so the rest of the flow can spend capital the user doesn’t hold upfront.Because a flashloan must be repaid in the same transaction, a flow that borrows via this materialiser must settle the loan (principal plus the provider’s fee) before it ends, with one or more lifi.flashloanRepay ops. If the loan isn’t repaid, simulation reverts.Config:
The shape of a flow that borrows USDC through an Aave V3 flashloan. It needs an early-access build of the SDK that exports materialisers.flashloan:
const builder = sdk.flow(8453, { name: 'flashloan-borrow', inputs: { borrowed: resources.erc20(USDC, 8453), },});// ... spend `builder.inputs.borrowed` across ops, then repay the loan// (principal + fee) with `lifi.flashloanRepay` before the flow ends ...const request = sdk.request(builder.build(), { signer: OWNER, inputs: { borrowed: materialisers.flashloan({ providerKind: 'aave-v3', amount: '1000000000', // 1,000 USDC (6 decimals) }), },});
{"docsConfig":{"theme":"mint","$schema":"https://mintlify.com/docs.json","name":"LI.FI","description":"Get the best price execution for any swaps and bridging across EVM chains, Solana, Bitcoin and alt-VMs. Enable trading across all DEX aggregators, bridges, and intent-systems and save hundreds of developer hours.","colors":{"primary":"#5C67FF","light":"#fab6f4","dark":"#5C67FF"},"logo":{"light":"https://mintcdn.com/lifi/EmProAEgMrruLUbI/logo/light.png?fit=max\u0026auto=format\u0026n=EmProAEgMrruLUbI\u0026q=85\u0026s=f435348680e682acea6e3b9af339ed7a","dark":"https://mintcdn.com/lifi/EmProAEgMrruLUbI/logo/dark.png?fit=max\u0026auto=format\u0026n=EmProAEgMrruLUbI\u0026q=85\u0026s=d02539147db168291d7c711beb45d10b"},"favicon":"https://mintcdn.com/lifi/jEGN0oG6bNsdv0a3/logo/favicon.svg?fit=max\u0026auto=format\u0026n=jEGN0oG6bNsdv0a3\u0026q=85\u0026s=35fb6353ca8815e24daf1025135fef38","api":{"openapi":"openapi.yaml"},"appearance":{"default":"dark"},"background":{"color":{"light":"#FAFAFF","dark":"#000B29"}},"navbar":{"links":[{"href":"https://lifihelp.zendesk.com/hc/en-us","label":"Support"}],"primary":{"type":"button","label":"Get Started","href":"https://portal.li.fi/signup"}},"footer":{"socials":{"x":"https://x.com/lifiprotocol","github":"https://github.com/lifinance","website":"https://li.fi/"},"links":[{"header":"Company","items":[{"label":"Careers","href":"https://li.fi/careers"},{"label":"Brand Assets","href":"https://li.fi/brand-assets"},{"label":"About","href":"https://li.fi/"}]},{"header":"Tools","items":[{"label":"LI.FI Explorer","href":"https://explorer.li.fi/?utm_source=lifi\u0026utm_medium=footer_link_tools\u0026utm_campaign=lifi_to_explorer"}]},{"header":"Legal","items":[{"label":"Privacy Policy","href":"https://li.fi/legal/privacy-policy"},{"label":"Terms of Service","href":"https://li.fi/legal/terms-and-conditions"},{"label":"Imprint","href":"https://li.fi/legal/imprint"}]}]},"styling":{"eyebrows":"section","codeblocks":"system","latex":false},"integrations":{"ga4":{"measurementId":"G-NTE1P73M4Q"}},"contextual":{"options":["copy","view","chatgpt","claude"],"display":"header"},"navigation":{"languages":[{"language":"en","href":"introduction/introduction"},{"language":"zh-Hans","href":"zh-Hans/introduction/introduction"}]}},"deployment":{"deploymentMetadataValue":{"subdomain":"lifi","hasAudioNarration":false,"actualSubdomain":"lifi","customDomains":["docs.li.fi"],"gitSource":{"type":"github","owner":"lifinance","repo":"public-docs","deployBranch":"main","contentDirectory":"","isPrivate":true,"mountPath":"","label":""},"entitlements":{"AI_CHAT":{"status":"ENABLED"},"WEB_MCP":{"status":"ENABLED"},"NARRATION":{"status":"ENABLED"}},"buildId":"6af5d4d39aa4e2cefacb2dc5","clientVersion":"0.0.4111","searchFilterCounts":[{"language":"en","tag":"Composer","count":56},{"language":"en","tag":"Overview","count":48},{"language":"zh-Hans","tag":"概述","count":44},{"language":"zh-Hans","tag":"Composer","count":44},{"language":"en","tag":"Integrate via Composer API","count":40},{"language":"en","tag":"API Reference","count":35},{"language":"en","tag":"Intents \u0026 Solvers","count":32},{"language":"zh-Hans","tag":"意图与求解器","count":32},{"language":"zh-Hans","tag":"API 参考","count":30},{"language":"en","tag":"Reference","count":28},{"language":"zh-Hans","tag":"通过 Composer API 集成","count":28},{"language":"en","tag":"For Agents","count":21},{"language":"en","tag":"Widget","count":20},{"language":"zh-Hans","tag":"Widget","count":20},{"language":"zh-Hans","tag":"参考文档","count":18},{"language":"en","tag":"Getting Started","count":16},{"language":"en","tag":"General API","count":16},{"language":"zh-Hans","tag":"通用 API","count":16},{"language":"zh-Hans","tag":"企业级功能","count":15},{"language":"zh-Hans","tag":"入门","count":14}]},"assistantConfig":{},"basePath":"","hasChatPermissions":true,"hasWebMcpPermissions":true,"toggles":[{"name":"kill-isr","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"custom-rbac-roles","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"agent-mintlify-slack","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"agent-integrations-settings","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"rbac-expansion","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"automations-pr-grouping","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"custom-prefix","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"analytics-v7","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"user-flows-analytics","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"no-publish-flow","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"workos-onboarding","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"llms-txt-v2","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"snapshot-serving-live","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"stripTemperatureMiddleware","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"support-platform-pylon-zendesk","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"snapshot-serving","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"instant-rollback","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"granular-notifications-server","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"granular-notifications","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"automations-fable","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"fixed-ai-action-pricing","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"automation-resolve-merge-conflict","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"scoped-publishing","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"mintql","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"page-level-analytics","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"editor-version-history-v2","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"billing-page-v2","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"full-page-search","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"workspace-projects","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"assistant-v5","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"fork-pr-previews","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"revalidation-jwt","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"workos-sso-scim","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"hobby-abuse-scan","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"dashboard-inbox","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"workos-signup","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"turbopuffer-dual-write","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"workos-enabled","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"approve-review-flow","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"editor-metadata","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"sso-setup-deadline-banner","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"turbopuffer-serve","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"live-agents","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false}],"googleFontsInlined":false},"customCss":[],"page":{"pagePath":"composer/composer-api/materialisers/flashloan","slug":"/composer/composer-api/materialisers/flashloan","pageMetadata":{"title":"flashloan","description":"Source a flow input by borrowing the amount from a flashloan provider, repaid within the same transaction.","href":"/composer/composer-api/materialisers/flashloan"},"description":{"compiledSource":"\"use strict\";\nconst {jsx: _jsx} = arguments[0];\nconst {useMDXComponents: _provideComponents} = arguments[0];\nfunction _createMdxContent(props) {\n const _components = {\n p: \"p\",\n ..._provideComponents(),\n ...props.components\n };\n return _jsx(_components.p, {\n children: \"Source a flow input by borrowing the amount from a flashloan provider, repaid within the same transaction.\"\n });\n}\nfunction MDXContent(props = {}) {\n const {wrapper: MDXLayout} = {\n ..._provideComponents(),\n ...props.components\n };\n return MDXLayout ? _jsx(MDXLayout, {\n ...props,\n children: _jsx(_createMdxContent, {\n ...props\n })\n }) : _createMdxContent(props);\n}\nreturn {\n default: MDXContent\n};\n","frontmatter":{},"scope":{}},"pageType":"default","mdx":{"mdxSource":{"compiledSource":"\"use strict\";const{Fragment:_Fragment,jsx:_jsx,jsxs:_jsxs}=arguments[0];const{useMDXComponents:_provideComponents}=arguments[0];function _createMdxContent(props){const _components={code:`code`,p:`p`,pre:`pre`,span:`span`,strong:`strong`,tbody:`tbody`,td:`td`,th:`th`,thead:`thead`,tr:`tr`,..._provideComponents(),...props.components},{CodeBlock,Heading,Table,Warning}=_components;if(!CodeBlock)_missingMdxReference(`CodeBlock`,true);if(!Heading)_missingMdxReference(`Heading`,true);if(!Table)_missingMdxReference(`Table`,true);if(!Warning)_missingMdxReference(`Warning`,true);return _jsxs(_Fragment,{children:[_jsx(Warning,{children:_jsxs(_components.p,{children:[_jsx(_components.strong,{children:`Not available on production.`}),` The `,_jsx(_components.code,{children:`flashloan`}),` materialiser and the `,_jsx(_components.code,{children:`lifi.flashloanRepay`}),` op are disabled on `,_jsx(_components.code,{children:`https://composer.li.quest`}),`, and the published `,_jsx(_components.code,{children:`@lifi/composer-sdk`}),` doesn’t export `,_jsx(_components.code,{children:`materialisers.flashloan`}),`. A compile that uses them is rejected. Contact us if you need early access.`]})}),`\n`,_jsxs(_components.p,{children:[_jsx(_components.code,{children:`flashloan`}),` sources a flow input by `,_jsx(_components.strong,{children:`borrowing`}),` the amount from a flashloan provider instead of pulling it from the signer. The borrowed amount is made available to the flow as its input, so the rest of the flow can spend capital the user doesn’t hold upfront.`]}),`\n`,_jsxs(_components.p,{children:[`Because a flashloan must be repaid in the same transaction, a flow that borrows via this materialiser `,_jsx(_components.strong,{children:`must`}),` settle the loan (principal plus the provider’s fee) before it ends, with one or more `,_jsx(_components.code,{children:`lifi.flashloanRepay`}),` ops. If the loan isn’t repaid, simulation reverts.`]}),`\n`,_jsx(_components.p,{children:`Config:`}),`\n`,_jsxs(Table,{children:[_jsx(_components.thead,{children:_jsxs(_components.tr,{children:[_jsx(_components.th,{children:`Field`}),_jsx(_components.th,{children:`Type`}),_jsx(_components.th,{children:`Notes`})]})}),_jsxs(_components.tbody,{children:[_jsxs(_components.tr,{children:[_jsx(_components.td,{children:_jsx(_components.code,{children:`providerKind`})}),_jsx(_components.td,{children:_jsx(_components.code,{children:`'aave-v3' | 'erc3156' | 'balancer-v2' | 'morpho-blue'`})}),_jsx(_components.td,{children:`Which flashloan provider to borrow from. Fees vary by provider (e.g. Aave V3 charges 5 bps; Balancer V2 charges none).`})]}),_jsxs(_components.tr,{children:[_jsx(_components.td,{children:_jsx(_components.code,{children:`amount`})}),_jsx(_components.td,{children:`integer string`}),_jsx(_components.td,{children:`The amount to borrow, in the token’s smallest units.`})]})]})]}),`\n`,_jsx(Heading,{level:`2`,id:`example`,children:`Example`}),`\n`,_jsxs(_components.p,{children:[`The shape of a flow that borrows USDC through an Aave V3 flashloan. It needs an early-access build of the SDK that exports `,_jsx(_components.code,{children:`materialisers.flashloan`}),`:`]}),`\n`,_jsx(CodeBlock,{filename:``,numberOfLines:`19`,language:`typescript`,children:_jsx(_components.pre,{className:`shiki shiki-themes github-light-default dark-plus`,style:{backgroundColor:`#ffffff`,\"--shiki-dark-bg\":`#0B0C0E`,color:`#1f2328`,\"--shiki-dark\":`#D4D4D4`},language:`typescript`,children:_jsxs(_components.code,{language:`typescript`,numberOfLines:`19`,children:[_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#569CD6`},children:`const`}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#4FC1FF`},children:` builder`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#D4D4D4`},children:` =`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:` sdk`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`.`}),_jsx(_components.span,{style:{color:`#8250DF`,\"--shiki-dark\":`#DCDCAA`},children:`flow`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`(`}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#B5CEA8`},children:`8453`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`, {`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:` name:`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` 'flashloan-borrow'`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:` inputs:`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` {`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:` borrowed:`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:` resources`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`.`}),_jsx(_components.span,{style:{color:`#8250DF`,\"--shiki-dark\":`#DCDCAA`},children:`erc20`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`(`}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#4FC1FF`},children:`USDC`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`, `}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#B5CEA8`},children:`8453`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`),`})]}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` },`})}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`});`})}),`\n`,_jsx(_components.span,{className:`line`}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#6E7781`,\"--shiki-dark\":`#6A9955`},children:\"// ... spend `builder.inputs.borrowed` across ops, then repay the loan\"})}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#6E7781`,\"--shiki-dark\":`#6A9955`},children:\"// (principal + fee) with `lifi.flashloanRepay` before the flow ends ...\"})}),`\n`,_jsx(_components.span,{className:`line`}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#569CD6`},children:`const`}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#4FC1FF`},children:` request`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#D4D4D4`},children:` =`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:` sdk`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`.`}),_jsx(_components.span,{style:{color:`#8250DF`,\"--shiki-dark\":`#DCDCAA`},children:`request`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`(`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:`builder`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`.`}),_jsx(_components.span,{style:{color:`#8250DF`,\"--shiki-dark\":`#DCDCAA`},children:`build`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`(), {`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:` signer:`}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#4FC1FF`},children:` OWNER`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:` inputs:`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` {`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:` borrowed:`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:` materialisers`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`.`}),_jsx(_components.span,{style:{color:`#8250DF`,\"--shiki-dark\":`#DCDCAA`},children:`flashloan`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`({`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:` providerKind:`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` 'aave-v3'`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:` amount:`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` '1000000000'`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`, `}),_jsx(_components.span,{style:{color:`#6E7781`,\"--shiki-dark\":`#6A9955`},children:`// 1,000 USDC (6 decimals)`})]}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` }),`})}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` },`})}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`});`})}),`\n`]})})})]})}function MDXContent(props={}){const{wrapper:MDXLayout}={..._provideComponents(),...props.components};return MDXLayout?_jsx(MDXLayout,{...props,children:_jsx(_createMdxContent,{...props})}):_createMdxContent(props)}return{default:MDXContent};function _missingMdxReference(id,component){throw new Error(`Expected `+(component?`component`:`object`)+\" `\"+id+\"` to be defined: you likely forgot to import, pass, or provide it.\")}","frontmatter":{},"scope":{"codeStyling":"system","config":{},"pageMetadata":{"title":"flashloan","description":"Source a flow input by borrowing the amount from a flashloan provider, repaid within the same transaction.","href":"/composer/composer-api/materialisers/flashloan"}}},"mdxSourceWithNoJs":null},"mdxExtracts":{"tableOfContents":[{"title":"Example","slug":"example","depth":2,"children":[]}],"codeExamples":{}},"jsLinks":["/_mintlify/custom/lifi/951d8dd0c2dbce84/plausible.js","/_mintlify/custom/lifi/8e3c41579c236ea7/scripts/translate-docs.js","/_mintlify/custom/lifi/b34903975490ec23/scripts/generate-md-redirects.js","/_mintlify/custom/lifi/516472b23ab068ad/scripts/check-links.js","/_mintlify/custom/lifi/70364f7a7384bb43/scripts/markdown-chunker.js","/_mintlify/custom/lifi/faea2bc1c5ee8be7/scripts/translation-config.js","/_mintlify/custom/lifi/8f88293865b45873/scripts/verify-translation-coverage.js"],"subdomain":"lifi","siteName":"LI.FI","title":"flashloan - LI.FI","navMaps":{"firstHrefInVersion":{},"firstHrefInLanguage":{"en":{"href":"/composer/composer-api/materialisers/flashloan","matchLevel":0},"zh-Hans":{"href":"/zh-Hans/introduction/introduction","matchLevel":4}}},"lastModified":"2026-11-12T15:02:05.809Z","originalFileLocation":"composer/composer-api/materialisers/flashloan.mdx","locale":"en"},"headHtml":"\u003cscript data-mint-head>(function(){var d=document.documentElement,p=null;if(!p){try{p=localStorage.getItem(\"isDarkMode\")}catch(e){}if(p==='true')p='dark';else if(p==='false')p='light';if(p!=='light'\u0026\u0026p!=='dark'\u0026\u0026p!=='system')p=\"dark\"}var r=p==='system'?(matchMedia(\"(prefers-color-scheme: dark)\").matches?'dark':'light'):p;d.classList.remove(r==='dark'?'light':'dark');d.classList.add(r);d.setAttribute(\"data-theme-preference\",p)})();\u003c/script>\u003cmeta data-mint-head name=\"description\" content=\"Source a flow input by borrowing the amount from a flashloan provider, repaid within the same transaction.\">\u003cmeta data-mint-head name=\"application-name\" content=\"LI.FI\">\u003cmeta data-mint-head name=\"generator\" content=\"Mintlify\">\u003clink data-mint-head rel=\"icon\" type=\"image/png\" sizes=\"192x192\" href=\"/mintlify-assets/_mintlify/favicons/lifi/uhSlA1vHRUBoEVMw/_generated/favicon/android-chrome-192x192.png\" media=\"(prefers-color-scheme: light)\">\u003clink data-mint-head rel=\"apple-touch-icon\" type=\"image/png\" sizes=\"180x180\" href=\"/mintlify-assets/_mintlify/favicons/lifi/uhSlA1vHRUBoEVMw/_generated/favicon/apple-touch-icon.png\">\u003clink data-mint-head rel=\"icon\" type=\"image/png\" sizes=\"16x16\" href=\"/mintlify-assets/_mintlify/favicons/lifi/uhSlA1vHRUBoEVMw/_generated/favicon/favicon-16x16.png\" media=\"(prefers-color-scheme: light)\">\u003clink data-mint-head rel=\"icon\" type=\"image/png\" sizes=\"32x32\" href=\"/mintlify-assets/_mintlify/favicons/lifi/uhSlA1vHRUBoEVMw/_generated/favicon/favicon-32x32.png\" media=\"(prefers-color-scheme: light)\">\u003clink data-mint-head rel=\"shortcut icon\" type=\"image/x-icon\" href=\"/mintlify-assets/_mintlify/favicons/lifi/uhSlA1vHRUBoEVMw/_generated/favicon/favicon.ico\" media=\"(prefers-color-scheme: light)\">\u003clink data-mint-head rel=\"icon\" type=\"image/png\" sizes=\"192x192\" href=\"/mintlify-assets/_mintlify/favicons/lifi/uhSlA1vHRUBoEVMw/_generated/favicon-dark/android-chrome-192x192.png\" media=\"(prefers-color-scheme: dark)\">\u003clink data-mint-head rel=\"icon\" type=\"image/png\" sizes=\"16x16\" href=\"/mintlify-assets/_mintlify/favicons/lifi/uhSlA1vHRUBoEVMw/_generated/favicon-dark/favicon-16x16.png\" media=\"(prefers-color-scheme: dark)\">\u003clink data-mint-head rel=\"icon\" type=\"image/png\" sizes=\"32x32\" href=\"/mintlify-assets/_mintlify/favicons/lifi/uhSlA1vHRUBoEVMw/_generated/favicon-dark/favicon-32x32.png\" media=\"(prefers-color-scheme: dark)\">\u003clink data-mint-head rel=\"shortcut icon\" type=\"image/x-icon\" href=\"/mintlify-assets/_mintlify/favicons/lifi/uhSlA1vHRUBoEVMw/_generated/favicon-dark/favicon.ico\" media=\"(prefers-color-scheme: dark)\">\u003cmeta data-mint-head property=\"og:title\" content=\"flashloan - LI.FI\">\u003cmeta data-mint-head property=\"og:description\" content=\"Source a flow input by borrowing the amount from a flashloan provider, repaid within the same transaction.\">\u003cmeta data-mint-head property=\"og:site_name\" content=\"LI.FI\">\u003cmeta data-mint-head property=\"og:url\" content=\"https://docs.li.fi/composer/composer-api/materialisers/flashloan\">\u003cmeta data-mint-head property=\"og:type\" content=\"website\">\u003cmeta data-mint-head property=\"og:image\" content=\"https://lifi.mintlify.site/_mintlify/api/og/v2?division=Documentation\u0026amp;title=flashloan\u0026amp;description=Source+a+flow+input+by+borrowing+the+amount+from+a+flashloan+provider%2C+repaid+within+the+same+transaction.\u0026amp;theme=d2a96653fbdd3b58627ba1f7\u0026amp;signature=b6a478445ee273d91c53fb3259496d6e0cc6a01cd9f418062f305af1059d979c\">\u003cmeta data-mint-head property=\"og:image:width\" content=\"1200\">\u003cmeta data-mint-head property=\"og:image:height\" content=\"630\">\u003cmeta data-mint-head name=\"twitter:card\" content=\"summary_large_image\">\u003cmeta data-mint-head name=\"twitter:title\" content=\"flashloan - LI.FI\">\u003cmeta data-mint-head name=\"twitter:description\" content=\"Source a flow input by borrowing the amount from a flashloan provider, repaid within the same transaction.\">\u003cmeta data-mint-head name=\"twitter:image\" content=\"https://lifi.mintlify.site/_mintlify/api/og/v2?division=Documentation\u0026amp;title=flashloan\u0026amp;description=Source+a+flow+input+by+borrowing+the+amount+from+a+flashloan+provider%2C+repaid+within+the+same+transaction.\u0026amp;theme=d2a96653fbdd3b58627ba1f7\u0026amp;signature=b6a478445ee273d91c53fb3259496d6e0cc6a01cd9f418062f305af1059d979c\">\u003cmeta data-mint-head name=\"twitter:image:width\" content=\"1200\">\u003cmeta data-mint-head name=\"twitter:image:height\" content=\"630\">\u003cmeta data-mint-head name=\"msapplication-config\" content=\"/mintlify-assets/_mintlify/favicons/lifi/uhSlA1vHRUBoEVMw/_generated/favicon/browserconfig.xml\">\u003cmeta data-mint-head name=\"apple-mobile-web-app-title\" content=\"LI.FI\">\u003cmeta data-mint-head name=\"msapplication-TileColor\" content=\"#5C67FF\">\u003clink data-mint-head rel=\"canonical\" href=\"https://docs.li.fi/composer/composer-api/materialisers/flashloan\">\u003clink data-mint-head rel=\"alternate\" type=\"application/xml\" href=\"/sitemap.xml\">\u003clink data-mint-head rel=\"alternate\" type=\"text/markdown\" href=\"/composer/composer-api/materialisers/flashloan.md\">\u003cscript data-mint-head type=\"application/ld+json\">{\"@context\":\"https://schema.org\",\"@type\":\"WebSite\",\"name\":\"LI.FI\",\"publisher\":{\"@type\":\"Organization\",\"name\":\"LI.FI\"},\"provider\":{\"@type\":\"Organization\",\"name\":\"Mintlify\",\"url\":\"https://mintlify.com\"}}\u003c/script>","agentPointerHref":"/composer/composer-api/materialisers/flashloan.md","siteName":"LI.FI","nav":{"global":null,"languages":[{"language":"en","tabs":[{"tab":"Overview","groups":[{"group":"Learn About LI.FI","pages":[{"title":"Universal Market Access for Digital Assets","href":"/introduction/introduction"},{"title":"Product Stack","href":"/introduction/product-stack"},{"title":"Security and Audits","href":"/introduction/learn-more/security-and-audits"},{"title":"Token risk screening with Hypernative","href":"/introduction/learn-more/hypernative-token-screening"},{"title":"Monetizing the integration","href":"/introduction/integrating-lifi/monetizing-integration"},{"title":"Partnership Requests","href":"/introduction/integrating-lifi/partnership-opportunities"}]},{"group":"LI.FI for your use case","pages":[{"title":"Every Customer Can Fund an Account, Whatever They Hold","sidebarTitle":"Neobanks","icon":"building-columns","href":"/introduction/use-cases/neobanks"},{"title":"Stop Reconciling Payments by Hand","sidebarTitle":"Payments","icon":"credit-card","href":"/introduction/use-cases/payments"},{"title":"One Swap Surface for Every Chain You Support","sidebarTitle":"Wallets","icon":"wallet","href":"/introduction/use-cases/wallets"},{"title":"Offer Swaps Without Widening Your Signing Path","sidebarTitle":"Exchanges","icon":"building-lock","href":"/introduction/use-cases/exchanges"},{"title":"Stop Paying Pool Depth on Every Dollar You Move","sidebarTitle":"Stablecoins","icon":"dollar-sign","href":"/introduction/use-cases/stablecoins"},{"title":"Offer Tokenized Equities Without a Licensing Desk","sidebarTitle":"Tokenized Assets","icon":"landmark","href":"/introduction/use-cases/tokenized-assets"},{"title":"A Deposit Button That Works for Every Customer","sidebarTitle":"Yield Products","icon":"chart-line","href":"/introduction/use-cases/yield-products"},{"title":"Quote the Number You Will Actually Deliver","sidebarTitle":"Intent-Based Apps","icon":"bullseye","href":"/introduction/use-cases/intent-based-apps"},{"title":"Ship Agent Execution Without Handing Over a Signer","sidebarTitle":"AI Agents","icon":"robot","href":"/introduction/use-cases/ai-agents"},{"title":"Reach the Apps That Already Integrated LI.FI","sidebarTitle":"Issuers and New Chains","icon":"share-nodes","href":"/introduction/use-cases/issuers-and-chains"}]},{"group":"Supported Systems","pages":[{"title":"Chain Overview","href":"/introduction/chains"},{"title":"EVM Providers","href":"/introduction/tools"},{"title":"Solana Ecosystem Coverage","href":"/introduction/solana-ecosystem"},{"title":"TRON Ecosystem Coverage","href":"/introduction/tron-ecosystem"},{"title":"Stellar Ecosystem Coverage","href":"/introduction/stellar-ecosystem"},{"title":"Zcash Ecosystem Coverage","href":"/introduction/zcash-ecosystem"},{"title":"Solana Providers","href":"/introduction/lifi-architecture/solana-overview"},{"title":"Bitcoin Providers","href":"/introduction/lifi-architecture/bitcoin-overview"},{"title":"Sui Providers","href":"/introduction/lifi-architecture/sui-overview"},{"title":"Tron Providers","href":"/introduction/lifi-architecture/tron-overview"},{"title":"Stellar Providers","href":"/introduction/lifi-architecture/stellar-overview"},{"title":"Zcash Providers","href":"/introduction/lifi-architecture/zcash-overview"}]},{"group":"LI.FI Architecture","pages":[{"title":"System Overview","href":"/introduction/lifi-architecture/system-overview"},{"title":"Smart Contract Architecture","href":"/introduction/lifi-architecture/smart-contract-overview"},{"title":"Smart Contract Addresses","href":"/introduction/lifi-architecture/smart-contract-addresses"},{"title":"API latency and optimization","href":"/guides/latency"}]},{"group":"User Flows and Examples","pages":[{"title":"End-to-end Transaction Example","href":"/introduction/user-flows-and-examples/end-to-end-example"},{"title":"Fetching a Quote/Route","href":"/introduction/user-flows-and-examples/requesting-route-fetching-quote"},{"title":"Quote vs Route","href":"/introduction/user-flows-and-examples/difference-between-quote-and-route"},{"title":"Permit \u0026 Permit2 Approval Flow","href":"/introduction/user-flows-and-examples/permit2-approval-flow"},{"title":"LI.FI Composer","href":"/introduction/user-flows-and-examples/lifi-composer"},{"title":"Messaging flow","href":"/introduction/user-flows-and-examples/messaging-flow"},{"title":"Solana Transaction Example","href":"/introduction/user-flows-and-examples/solana-tx-execution"},{"title":"Bitcoin Transaction Example","href":"/introduction/user-flows-and-examples/bitcoin-tx-example"},{"title":"Transaction Status Tracking","href":"/introduction/user-flows-and-examples/status-tracking"}]},{"group":"Learn More","pages":[{"group":"How to get integrated by LI.FI","pages":[{"title":"Getting Integrated by LI.FI","href":"/introduction/learn-more/getting-integrated-by-lifi"},{"title":"For DEXs/Aggregators/Solvers","href":"/introduction/learn-more/for-dexs"},{"title":"For Bridges","href":"/introduction/learn-more/for-bridges"}]}]},{"group":"Changelog","pages":[{"title":"Monthly Updates","href":"/changelog/monthly-updates"},{"title":"Core","href":"/changelog/backend"},{"title":"SDK","href":"/changelog/sdk"},{"title":"Widget","href":"/changelog/widget"},{"title":"Partner Portal","href":"/changelog/partner-portal"}]}]},{"tab":"Enterprise (New)","groups":[{"group":"Enterprise Features","pages":[{"title":"Overview","href":"/enterprise/overview"},{"title":"Quote Simulation","href":"/enterprise/quote-simulation"},{"title":"Smart Slippage","href":"/enterprise/smart-slippage"},{"title":"Smart Deposit Addresses","href":"/enterprise/smart-deposit-address"},{"title":"Stablecoin 1:1","href":"/enterprise/stablecoin-1-1"},{"title":"Real World Assets (RWA)","href":"/enterprise/real-world-assets"},{"title":"Dynamic Pricing","href":"/enterprise/dynamic-pricing"}]},{"group":"Partner Portal","pages":[{"title":"Single sign-on","href":"/enterprise/partner-portal/sso"}]}]},{"tab":"API Reference","groups":[{"group":"About APIs","pages":[{"title":"Overview","href":"/api-reference/introduction"},{"title":"OpenAPI Specification","href":"/api-reference/openapi-spec"},{"title":"Rate Limits and API Authentication","href":"/api-reference/rate-limits"},{"title":"API Key Security","href":"/api-reference/api-key-security"},{"title":"Authentication","href":"/api-reference/authentication"},{"title":"Error Codes","href":"/api-reference/error-codes"}]},{"group":"General API","pages":[{"group":"Chains","pages":[{"openapi":"openapi.yaml GET /v1/chains","title":"Get information about all currently supported chains","href":"/api-reference/get-information-about-all-currently-supported-chains"}]},{"group":"Tokens","pages":[{"title":"Fetch all known tokens","openapi":"get /v1/tokens","href":"/api-reference/fetch-all-known-tokens"},{"openapi":"get /v1/token","title":"Fetch information about a Token","href":"/api-reference/fetch-information-about-a-token"}]},{"group":"Tools","pages":[{"openapi":"get /v1/tools","title":"Get available bridges and exchanges","href":"/api-reference/get-available-bridges-and-exchanges"}]},{"group":"Connections","pages":[{"openapi":"get /v1/connections","title":"Returns all possible connections between two chains.","href":"/api-reference/returns-all-possible-connections-based-on-a-from-or-tochain"}]},{"group":"Gas endpoints","pages":[{"openapi":"get /v1/gas/prices/{chainId}","title":"Get gas price for the specified chainId","href":"/api-reference/gas/get-gas-price-for-the-specified-chainid"},{"openapi":"get /v1/gas/prices","title":"Get gas prices for enabled chains","href":"/api-reference/gas/get-gas-prices-for-enabled-chains"},{"openapi":"get /v1/gas/suggestion/{chain}","title":"Get a gas suggestion for the specified chain","href":"/api-reference/get-a-gas-suggestion-for-the-specified-chain"},{"openapi":"get /v1/gas/status","title":"Get status information about a lifuel transaction","href":"/api-reference/get-status-information-about-a-lifuel-transaction"},{"openapi":"get /v1/gas/refetch","title":"In case a transaction was missed by a relayer, this endpoint can be used to force a tx to be re-fetched.","href":"/api-reference/in-case-a-transaction-was-missed-by-a-relayer-this-endpoint-can-be-used-to-force-a-tx-to-be-re-fetched"}]},{"group":"Transaction status","pages":[{"openapi":"get /v1/status","title":"Check the status of a cross chain transfer","href":"/api-reference/check-the-status-of-a-cross-chain-transfer"}]},{"group":"Integrator fee information","pages":[{"openapi":"get /v1/integrators/{integratorId}/withdraw/{chainId}","title":"Get transaction request for withdrawing collected integrator's fees by chain","href":"/api-reference/get-transaction-request-for-withdrawing-collected-integrators-fees-by-chain"},{"openapi":"get /v1/integrators/{integratorId}","title":"Get integrator's collected fees data for all supported chains","href":"/api-reference/get-integrators-collected-fees-data-for-all-supported-chains"}]},{"group":"Analytics","pages":[{"openapi":"get /v1/analytics/transfers/summary","title":"Get the total amount of a token received on a specific chain, for cross-chain transfers.","href":"/api-reference/get-the-total-amount-of-a-token-received-on-a-specific-chain-for-cross-chain-transfers"},{"openapi":"get /v1/analytics/transfers","title":"Get a list of filtered transfers","href":"/api-reference/get-a-list-of-filtered-transfers"},{"openapi":"get /v2/analytics/transfers","title":"Get a paginated list of filtered transfers","href":"/api-reference/get-a-paginated-list-of-filtered-transfers"}]}]},{"group":"Requesting a quote","pages":[{"group":"API presets","pages":[{"title":"API Presets","href":"/api-reference/presets/overview"},{"title":"Stablecoin preset","href":"/api-reference/presets/stablecoin"}]},{"group":"Single-step quote","pages":[{"openapi":"get /v1/quote","title":"Get a quote for a token transfer","href":"/api-reference/get-a-quote-for-a-token-transfer"},{"openapi":"get /v1/quote/toAmount","title":"Get a quote for a token transfer","href":"/api-reference/get-a-quote-for-a-token-transfer-1"},{"openapi":"post /v1/quote/contractCalls","title":"Perform multiple contract calls across blockchains (BETA)","href":"/api-reference/perform-multiple-contract-calls-across-blockchains-beta"}]},{"group":"Advanced routes","pages":[{"openapi":"post /v1/advanced/routes","title":"Get a set of routes for a request that describes a transfer of tokens","href":"/api-reference/advanced/get-a-set-of-routes-for-a-request-that-describes-a-transfer-of-tokens"},{"openapi":"post /v1/advanced/stepTransaction","title":"Populate a step with transaction data","href":"/api-reference/advanced/populate-a-step-with-transaction-data"}]},{"group":"Parse transaction call data","pages":[{"openapi":"get /v1/calldata/parse","title":"Parse transaction call data (BETA)","href":"/api-reference/parse-transaction-call-data-beta"}]}]}]},{"tab":"SDK","groups":[{"group":"Getting Started","pages":[{"title":"LI.FI SDK Overview","href":"/sdk/overview"},{"title":"Install LI.FI SDK","href":"/sdk/installing-the-sdk"},{"title":"Configure SDK","href":"/sdk/configure-sdk"},{"title":"Multi-VM Support","href":"/sdk/configure-sdk-providers"},{"title":"Monetize SDK","href":"/sdk/monetize-sdk"}]},{"group":"Using the SDK","pages":[{"title":"Request Routes/Quotes","href":"/sdk/request-routes"},{"title":"Execute Routes/Quotes","href":"/sdk/execute-routes"},{"title":"Chains and Tools","href":"/sdk/chains-tools"},{"title":"Token Management","href":"/sdk/token-management"}]},{"group":"Misc.","pages":[{"title":"Testing Integration","href":"/sdk/testing-integration"},{"title":"Migrate from v2 to v3","href":"/sdk/migrate-v2-to-v3"},{"title":"Migrate from v3 to v4","href":"/sdk/migrate-v3-to-v4"}]}]},{"tab":"Widget","groups":[{"group":"Getting Started","pages":[{"title":"LI.FI Widget Overview","href":"/widget/overview"}]},{"group":"Basic Setup","pages":[{"title":"Install Widget","href":"/widget/install-widget"},{"title":"Select Widget Layout","href":"/widget/select-widget-layout"},{"title":"Configure Widget","href":"/widget/configure-widget"},{"title":"Customize Widget","href":"/widget/customize-widget"},{"title":"Monetize Widget","href":"/widget/monetize-widget"}]},{"group":"Advanced","pages":[{"title":"Widget Events","href":"/widget/widget-events"},{"title":"Wallet Management","href":"/widget/wallet-management"},{"title":"Internationalization","href":"/widget/internationalization"},{"title":"Widget API Reference","href":"/widget/widget-api-reference"}]},{"group":"Widget Light (iframe)","pages":[{"title":"Widget Light Overview","href":"/widget/widget-light-overview"},{"title":"Install Widget Light","href":"/widget/widget-light-installation"},{"title":"Configure Widget Light","href":"/widget/widget-light-configuration"},{"title":"Widget Light Events","href":"/widget/widget-light-events"},{"title":"Widget Light Wallet Management","href":"/widget/widget-light-wallet-management"},{"title":"Widget Light API Reference","href":"/widget/widget-light-api-reference"}]},{"group":"Misc.","pages":[{"title":"Compatibility with Next.js, Remix, Nuxt, etc.","href":"/widget/compatibility"},{"title":"Polyfill Requirements","href":"/widget/polyfill-requirements"},{"title":"Migrate from v3 to v4","href":"/widget/migrate-from-v3-to-v4"},{"title":"Migrate from v2 to v3","href":"/widget/migrate-from-v2-to-v3"}]}]},{"tab":"Composer","groups":[{"group":"Introduction","pages":[{"title":"Overview","href":"/composer/overview"},{"title":"Composer 101","href":"/composer/composer-101"}]},{"group":"Integrate via Composer API","pages":[{"title":"Overview","href":"/composer/composer-api/overview"},{"group":"Integration Guides","pages":[{"title":"Quickstart","href":"/composer/composer-api/quickstart"},{"title":"Build a same-chain flow","href":"/composer/composer-api/guides/build-a-flow"},{"title":"Build a cross-chain flow","href":"/composer/composer-api/guides/build-a-cross-chain-flow"}]},{"group":"Concepts","pages":[{"title":"Flow Structure","href":"/composer/composer-api/concepts/flow-anatomy"},{"title":"Resource Model","href":"/composer/composer-api/concepts/resources-and-ports"},{"title":"References","href":"/composer/composer-api/concepts/ref-grammar"},{"title":"Execution Model","href":"/composer/composer-api/concepts/execution-model"},{"title":"Guards","href":"/composer/composer-api/concepts/simulation-and-guards"},{"title":"Terminal Resources","href":"/composer/composer-api/concepts/sweeping-and-amounts"},{"title":"Cross-chain flows","href":"/composer/composer-api/concepts/cross-chain-flows"}]},{"group":"Recipes","pages":[{"title":"Overview","href":"/composer/composer-api/recipes/index"},{"title":"Swap and deposit","href":"/composer/composer-api/recipes/swap-and-deposit"},{"title":"Split a deposit across vaults","href":"/composer/composer-api/recipes/split-deposit"},{"title":"Deposit with a server-planned route","href":"/composer/composer-api/recipes/server-planned-route"},{"title":"Add liquidity on Uniswap","href":"/composer/composer-api/recipes/uniswap-liquidity"},{"title":"Consolidate tokens into USDC","href":"/composer/composer-api/recipes/consolidate-to-usdc"},{"title":"Bridge and deposit with one signature","sidebarTitle":"Bridge and deposit","href":"/composer/composer-api/recipes/bridge-and-deposit"},{"title":"Pay cross-chain","href":"/composer/composer-api/recipes/pay-cross-chain"}]},{"group":"Reference","pages":[{"title":"Flow Schema","href":"/composer/composer-api/reference/flow-wire-format"},{"title":"SDK Reference","href":"/composer/composer-api/reference/sdk-api"},{"title":"Errors","href":"/composer/composer-api/reference/error-codes"},{"title":"Addresses","href":"/composer/composer-api/reference/addresses"},{"title":"Escrow status","href":"/composer/composer-api/reference/escrow-status"},{"title":"Release notes and migration","href":"/composer/composer-api/reference/release-notes"},{"group":"Ops","pages":[{"title":"Op catalog","href":"/composer/composer-api/ops/index"},{"group":"Same-chain","pages":[{"title":"lifi.swap","href":"/composer/composer-api/ops/lifi-swap"},{"title":"lifi.zap","href":"/composer/composer-api/ops/lifi-zap"},{"title":"core.call","href":"/composer/composer-api/ops/core-call"}]},{"group":"Cross-chain","pages":[{"title":"lifi.bridge","href":"/composer/composer-api/ops/lifi-bridge"},{"title":"lifiIntents.order","href":"/composer/composer-api/ops/lifi-intents-order"},{"title":"continuation.settle","href":"/composer/composer-api/ops/continuation-settle"}]}]},{"group":"Materialisers","pages":[{"title":"Materialisers catalog","href":"/composer/composer-api/materialisers/index"},{"title":"balanceOf","href":"/composer/composer-api/materialisers/balance-of"},{"title":"call","href":"/composer/composer-api/materialisers/call"},{"title":"directDeposit","href":"/composer/composer-api/materialisers/direct-deposit"}]},{"group":"Guard Types","pages":[{"title":"Guards catalog","href":"/composer/composer-api/guards/index"},{"title":"slippage","href":"/composer/composer-api/guards/slippage"},{"title":"band","href":"/composer/composer-api/guards/band"},{"title":"core.numericInvariant","href":"/composer/composer-api/guards/numeric-invariant"}]}]}]},{"group":"Integrate via LI.FI API","pages":[{"title":"Overview","href":"/composer/lifi-api/overview"},{"group":"Integration Guides","pages":[{"title":"Quickstart","href":"/composer/lifi-api/quickstart"},{"title":"API Integration","href":"/composer/lifi-api/guides/api-integration"},{"title":"SDK Integration","href":"/composer/lifi-api/guides/sdk-integration"},{"title":"Widget Integration","href":"/composer/lifi-api/guides/widget-integration"},{"title":"Cross-chain deposits","href":"/composer/lifi-api/guides/cross-chain-compose"},{"title":"Withdrawals","href":"/composer/lifi-api/guides/withdrawals"},{"title":"Deposit Examples","href":"/composer/lifi-api/recipes/vault-deposits"}]},{"group":"Reference","pages":[{"title":"API Parameters","href":"/composer/lifi-api/reference/api-parameters"},{"title":"Error Handling","href":"/composer/lifi-api/reference/error-handling"},{"title":"Limitations","href":"/composer/lifi-api/reference/limitations"}]}]},{"group":"Resources","pages":[{"title":"Supported Protocols \u0026 Chains","href":"/composer/protocols-and-chains"},{"title":"New Protocol Onboarding","href":"/composer/for-protocols/integration-guide"},{"title":"Permissioned Products \u0026 Compliance","href":"/composer/permissioned-products-and-compliance"}]}]},{"tab":"Earn","groups":[{"group":"Getting Started","pages":[{"title":"What is LI.FI Earn?","href":"/earn/overview"},{"title":"Quickstart","href":"/earn/quickstart"},{"title":"How Earn Works","href":"/earn/how-it-works"}]},{"group":"Integration Guides","pages":[{"title":"API Integration","href":"/earn/guides/api-integration"},{"title":"Supported Protocols \u0026 Chains","href":"/earn/guides/supported-protocols"}]},{"group":"Recipes","pages":[{"title":"Discover and Deposit","href":"/earn/recipes/discover-and-deposit"}]},{"group":"API Reference","pages":[{"group":"Chains","pages":[{"title":"List chains supported by LI.FI Earn","deprecated":null,"version":null,"openapi":"/earn-openapi.yaml get /v1/chains","href":"/api-reference/earn-chains/list-chains-supported-by-lifi-earn"}]},{"group":"Vaults","pages":[{"title":"List vaults with optional filtering","deprecated":null,"version":null,"openapi":"/earn-openapi.yaml get /v1/vaults","href":"/api-reference/earn-vaults/list-vaults-with-optional-filtering"},{"title":"Get vault by chain and address","deprecated":null,"version":null,"openapi":"/earn-openapi.yaml get /v1/vaults/{chainId}/{address}","href":"/api-reference/earn-vaults/get-vault-by-chain-and-address"}]},{"group":"Protocols","pages":[{"title":"List supported protocols","deprecated":null,"version":null,"openapi":"/earn-openapi.yaml get /v1/protocols","href":"/api-reference/earn-protocols/list-supported-protocols"}]},{"group":"Portfolio","pages":[{"title":"Get portfolio positions for a user","deprecated":null,"version":null,"openapi":"/earn-openapi.yaml get /v1/portfolio/{userAddress}/positions","href":"/api-reference/earn-portfolio/get-portfolio-positions-for-a-user"}]}]}]},{"tab":"Perps","groups":[{"group":"Getting Started","pages":[{"title":"Overview","href":"/perps/overview"},{"title":"Quickstart","href":"/perps/quickstart"}]},{"group":"Learn","pages":[{"title":"Concepts","href":"/perps/concepts"},{"title":"Venues","href":"/perps/venues"}]}]},{"tab":"Intents \u0026 Solvers","groups":[{"group":"Getting Started","pages":[{"title":"Intent / Solver Marketplace","href":"/lifi-intents/introduction"},{"title":"Authentication","href":"/lifi-intents/authentication"},{"title":"Quickstart","href":"/lifi-intents/quickstart"}]},{"group":"Intents API","pages":[{"title":"API Overview","href":"/lifi-intents/intents-api/api-overview"},{"title":"Request a Quote","href":"/lifi-intents/intents-api/request-quote"},{"title":"Create and Submit Orders","href":"/lifi-intents/intents-api/create-and-submit"},{"title":"Compact Orders","href":"/lifi-intents/intents-api/compact-orders"},{"title":"Track Order Status","href":"/lifi-intents/intents-api/track-status"}]},{"group":"Solver API","pages":[{"title":"Solver API Overview","href":"/lifi-intents/for-solvers/api-overview"},{"title":"Solving LI.FI Intents","href":"/lifi-intents/for-solvers/intro"},{"title":"Collecting Orders","href":"/lifi-intents/for-solvers/orderflow"},{"title":"Quoting Orders","href":"/lifi-intents/for-solvers/quoting"},{"title":"Auctions","href":"/lifi-intents/for-solvers/auctions"},{"title":"Settling Orders","href":"/lifi-intents/for-solvers/settlement"},{"title":"Reputation","href":"/lifi-intents/for-solvers/reputation"},{"title":"Testing Integration","href":"/lifi-intents/for-solvers/testing-integration"}]},{"group":"MCP Server","pages":[{"title":"Intents MCP Server","href":"/lifi-intents/mcp-server/overview"},{"title":"Installation","href":"/lifi-intents/mcp-server/installation"},{"title":"Available Tools","href":"/lifi-intents/mcp-server/tools"},{"title":"Examples","href":"/lifi-intents/mcp-server/examples"}]},{"group":"Architecture","pages":[{"title":"System Overview","href":"/lifi-intents/architecture/overview"},{"title":"Settlement","href":"/lifi-intents/architecture/settlement"},{"title":"Oracle Systems","href":"/lifi-intents/architecture/oracle-systems"},{"title":"Open Intents","href":"/lifi-intents/architecture/open-contributions"}]},{"group":"Knowledge Base","pages":[{"title":"Resource Locks","href":"/lifi-intents/knowledge-database/resource-locks"},{"title":"Bitcoin Primer","href":"/lifi-intents/knowledge-database/bitcoin-primer"},{"title":"Tron vs EVM","href":"/lifi-intents/knowledge-database/tron-deltas"},{"title":"Solana vs EVM","href":"/lifi-intents/knowledge-database/solana-deltas"},{"group":"Debugging on Solana","pages":[{"title":"Debugging on Solana","href":"/lifi-intents/knowledge-database/solana-debugging"},{"title":"Solana programs","href":"/lifi-intents/architecture/solana-programs"},{"title":"Solana IDL bundle","href":"/lifi-intents/architecture/solana-idl"}]},{"title":"Glossary","href":"/lifi-intents/knowledge-database/glossary"}]}]},{"tab":"For Agents","pages":[{"group":"Getting Started","pages":[{"title":"Agent Integration","href":"/agents/overview"},{"title":"Concepts and Objects","href":"/agents/concepts"}]},{"group":"Quick Start","pages":[{"title":"Five-Call Recipe","href":"/agents/quick-start/five-call-recipe"},{"title":"Decision Tables","href":"/agents/quick-start/decision-tables"},{"title":"Code Samples","href":"/agents/quick-start/code-samples"}]},{"group":"Workflows","pages":[{"title":"Token Approvals","href":"/agents/workflows/approvals"},{"title":"Transaction Execution","href":"/agents/workflows/execution"},{"title":"Status \u0026 Recovery","href":"/agents/workflows/status-recovery"},{"title":"Partial Completion","href":"/agents/workflows/partial-completion"}]},{"group":"Reference","pages":[{"title":"Endpoint Specifications","href":"/agents/reference/endpoint-specs"},{"title":"Authentication, Status and Retry Contract","href":"/agents/reference/auth-status-contract"},{"title":"Error Playbooks","href":"/agents/reference/error-playbooks"},{"title":"Data Schemas","href":"/agents/reference/schemas"}]},{"group":"MCP Server","pages":[{"title":"Overview","href":"/mcp-server/overview"},{"title":"Installation","href":"/mcp-server/installation"},{"title":"Available Tools","href":"/mcp-server/tools"},{"title":"Examples","href":"/mcp-server/examples"}]},{"group":"CLI","pages":[{"title":"Overview","href":"/cli/overview"},{"title":"Installation","href":"/cli/installation"},{"title":"Available Commands","href":"/cli/commands"},{"title":"Examples","href":"/cli/examples"}]}]},{"tab":"Widget Playground","href":"https://playground.li.fi/"},{"tab":"Bigmi","groups":[{"group":"Bigmi","pages":[{"title":"Bigmi Overview","href":"/bigmi/overview"},{"title":"On the Backend","href":"/bigmi/backend"},{"title":"On the Frontend","href":"/bigmi/frontend"},{"title":"Usage with React","href":"/bigmi/react-hooks"},{"title":"Error Handling","href":"/bigmi/error-handling"},{"title":"Best Practices","href":"/bigmi/best-practices"}]}]},{"tab":"Guides","groups":[{"group":"Integration","pages":[{"title":"Gas Options","href":"/guides/gas-options"},{"title":"Gas costs and fee costs","href":"/guides/gas-and-fee-costs"},{"title":"Gas Fronting","href":"/guides/gas-subsidy"},{"title":"Gasless Transactions","href":"/guides/gasless-transactions"},{"title":"Solana Gas Sponsorship","href":"/guides/solana-gas-sponsorship"},{"title":"Route-wide Slippage","href":"/guides/route-wide-slippage"},{"title":"API latency and optimization","href":"/guides/latency"},{"title":"FeeForwarder","href":"/introduction/integrating-lifi/fee-forwarder"},{"title":"Legacy Fees","href":"/introduction/integrating-lifi/legacy-fees"}]},{"group":"Troubleshooting","pages":[{"title":"Debugging Failed Transactions","href":"/guides/debug-failed-transactions"},{"title":"Intermediate tokens","href":"/guides/intermediate-tokens"}]}]},{"tab":"FAQs","groups":[{"group":"General","pages":[{"title":"Fees and Monetization","href":"/faqs/fees-monetization"},{"title":"Common issues","href":"/faqs/troubleshooting"}]},{"group":"Integration","pages":[{"title":"Integration","href":"/faqs/integration"},{"title":"Slippage and price impact","href":"/faqs/slippage-price-impact"}]},{"group":"Routing","pages":[{"title":"Route availability","href":"/faqs/route-availability"},{"title":"Token support and availability","href":"/faqs/token-support"}]}]}]},{"language":"zh-Hans","pages":[{"title":"zh-Hans","href":"/zh-Hans/introduction/introduction"}]}]},"basePath":"","title":"flashloan - LI.FI","buildId":"dpl_DqYu5MPb49gWBBbUGgpHQUmCHY3P","deploymentId":"dpl_DqYu5MPb49gWBBbUGgpHQUmCHY3P","dynamics":[],"chunks":[]}