This framework eliminates the need for users to stay online until the end of the swap, removing the need for the user side application to manually redeem on the destination chain.
We recommend using this system in stateless or unstable network environments, if you have access to persistent state and access to a background process consider managing the preimages on the user side.
This allows a user or an integrator to grant preimage manager access to generate the preimage, hold it until the solver initiate on the Destination chain.
Revealing the preimage claims funds to user’s address, the preimage manager is not allowed to change the addresses of sender or recipient as they are pre set on-chain, and are immutable.
This is an optional convenience feature, allowing the user to interact with the swapping system, and not stay online until confirmation, this could add high UX value for swaps from slow chains like Bitcoin.
The diagram shows how the preimage manager eliminates the need for users to stay online throughout the entire swap process. Once the user initiates the swap on the source chain, the preimage manager handles the final redemption automatically when the solver completes their part of the atomic swap.
Was this page helpful?
{"docsConfig":{"theme":"mint","$schema":"https://mintlify.com/docs.json","name":"Garden Finance Docs","description":"API and SDK for integrating native Bitcoin cross-chain swaps in dapps, wallets, and exchanges. Quickstarts, API reference, and contract docs inside.","colors":{"primary":"#e36492","light":"#f29Fcd","dark":"#e36492"},"logo":{"light":"https://mintcdn.com/garden-e60e7dd0/XPXywADb9NcDNBRh/logo/light.svg?fit=max\u0026auto=format\u0026n=XPXywADb9NcDNBRh\u0026q=85\u0026s=cd505087813ca2c17268a74c13bffdb2","dark":"https://mintcdn.com/garden-e60e7dd0/XPXywADb9NcDNBRh/logo/dark.svg?fit=max\u0026auto=format\u0026n=XPXywADb9NcDNBRh\u0026q=85\u0026s=999256e3c07dff814b2b35c20c719188"},"favicon":"https://mintcdn.com/garden-e60e7dd0/yXGsQh1bDIX0r6cd/favicon.svg?fit=max\u0026auto=format\u0026n=yXGsQh1bDIX0r6cd\u0026q=85\u0026s=5cc8115dab9b31f492dfedf485e84eba","navbar":{"links":[{"href":"https://discord.gg/B7RczEFuJ5","label":"Support"}],"primary":{"type":"button","label":"Launch app","href":"https://app.garden.finance"}},"footer":{"socials":{"x":"https://x.com/gardenfi","github":"https://github.com/gardenfi","discord":"https://discord.gg/B7RczEFuJ5"},"links":[{"header":"Application","items":[{"label":"Swap","href":"https://app.garden.finance/swap"},{"label":"Stake","href":"https://app.garden.finance/stake"}]},{"header":"Resources","items":[{"label":"Blog","href":"https://garden.finance/blog"},{"label":"Docs","href":"https://garden.finance/docs"},{"label":"Audits","href":"https://github.com/catalogfi/audits"},{"label":"Media Kit","href":"https://drive.google.com/drive/folders/1ZRAxs6jwhO6vLkadb9XOG7XqOQ4XLr0t?usp=sharing"}]}]},"seo":{"metatags":{"canonical":"https://garden.finance/docs"}},"contextual":{"options":["copy","view","chatgpt","claude"],"display":"header"},"styling":{"latex":true},"navigation":{"global":{"anchors":[{"anchor":"GitHub","icon":"github","href":"https://github.com/gardenfi"},{"anchor":"Blog","icon":"newspaper","href":"https://garden.finance/blog"},{"anchor":"Community","icon":"discord","href":"https://discord.gg/B7RczEFuJ5"}]},"languages":[{"language":"en","href":""},{"language":"es","footer":{"socials":{"x":"https://x.com/gardenfi","github":"https://github.com/gardenfi","discord":"https://discord.gg/B7RczEFuJ5"},"links":[{"header":"Aplicación","items":[{"label":"Swap","href":"https://app.garden.finance/es/swap"},{"label":"Stake","href":"https://app.garden.finance/es/stake"}]},{"header":"Recursos","items":[{"label":"Blog","href":"https://garden.finance/es/blog"},{"label":"Docs","href":"https://garden.finance/docs/es"},{"label":"Auditorías","href":"https://github.com/catalogfi/audits"},{"label":"Kit de prensa","href":"https://drive.google.com/drive/folders/1ZRAxs6jwhO6vLkadb9XOG7XqOQ4XLr0t?usp=sharing"}]}]},"navbar":{"links":[{"href":"https://discord.gg/B7RczEFuJ5","label":"Soporte"}],"primary":{"type":"button","label":"Abrir app","href":"https://app.garden.finance/es"}},"href":"es"},{"language":"ru","footer":{"socials":{"x":"https://x.com/gardenfi","github":"https://github.com/gardenfi","discord":"https://discord.gg/B7RczEFuJ5"},"links":[{"header":"Приложение","items":[{"label":"Swap","href":"https://app.garden.finance/ru/swap"},{"label":"Stake","href":"https://app.garden.finance/ru/stake"}]},{"header":"Ресурсы","items":[{"label":"Блог","href":"https://garden.finance/ru/blog"},{"label":"Документация","href":"https://garden.finance/docs/ru"},{"label":"Аудиты","href":"https://github.com/catalogfi/audits"},{"label":"Медиакит","href":"https://drive.google.com/drive/folders/1ZRAxs6jwhO6vLkadb9XOG7XqOQ4XLr0t?usp=sharing"}]}]},"navbar":{"links":[{"href":"https://discord.gg/B7RczEFuJ5","label":"Поддержка"}],"primary":{"type":"button","label":"Запустить приложение","href":"https://app.garden.finance/ru"}},"href":"ru"},{"language":"zh","footer":{"socials":{"x":"https://x.com/gardenfi","github":"https://github.com/gardenfi","discord":"https://discord.gg/B7RczEFuJ5"},"links":[{"header":"应用","items":[{"label":"Swap","href":"https://app.garden.finance/zh/swap"},{"label":"Stake","href":"https://app.garden.finance/zh/stake"}]},{"header":"资源","items":[{"label":"博客","href":"https://garden.finance/zh/blog"},{"label":"文档","href":"https://garden.finance/docs/zh"},{"label":"审计","href":"https://github.com/catalogfi/audits"},{"label":"媒体资料包","href":"https://drive.google.com/drive/folders/1ZRAxs6jwhO6vLkadb9XOG7XqOQ4XLr0t?usp=sharing"}]}]},"navbar":{"links":[{"href":"https://discord.gg/B7RczEFuJ5","label":"支持"}],"primary":{"type":"button","label":"启动应用","href":"https://app.garden.finance/zh"}},"href":"zh"}]}},"deployment":{"deploymentMetadataValue":{"subdomain":"garden-e60e7dd0","hasAudioNarration":false,"actualSubdomain":"garden-e60e7dd0","customDomains":["docs.garden.finance","api.garden.finance","testnet.api.garden.finance"],"gitSource":{"type":"github","owner":"hashiraio","repo":"garden-docs","deployBranch":"main","contentDirectory":"","isPrivate":true,"mountPath":"","label":""},"chroma":{"liveDeploymentHistoryId":"6acdca0e342d3f9c71c65f4b","collectionId":"6c6c4232-60e6-46a6-a058-c2da2f596777","schemaVersion":"v3","latestBuiltDeploymentHistoryId":"6acdca0e342d3f9c71c65f4b"},"feedback":{"thumbs":true,"edits":true,"issues":true,"agentFeedback":true},"entitlements":{"AI_CHAT":{"status":"DISABLED"}},"buildId":"6acdca0e342d3f9c71c65f4b","clientVersion":"0.0.3990","searchFilterCounts":[{"language":"en","tag":"Get Started","count":28},{"language":"es","tag":"Primeros pasos","count":22},{"language":"ru","tag":"Начало работы","count":22},{"language":"zh","tag":"入门","count":22},{"language":"en","tag":"API Reference","count":17},{"language":"en","tag":"Contracts","count":17},{"language":"en","tag":"Developers","count":16},{"language":"en","tag":"Fundamentals","count":13},{"language":"es","tag":"Fundamentos","count":13},{"language":"ru","tag":"Основы","count":13},{"language":"zh","tag":"基础知识","count":13},{"language":"en","tag":"Core Concepts","count":7},{"language":"en","tag":"Assets \u0026 Routes","count":6},{"language":"en","tag":"Orders","count":6},{"language":"en","tag":"SDK","count":5},{"language":"en","tag":"Benefits","count":5},{"language":"es","tag":"Ventajas","count":5},{"language":"es","tag":"Conceptos clave","count":5},{"language":"es","tag":"Gobernanza","count":5},{"language":"ru","tag":"Преимущества","count":5},{"language":"ru","tag":"Ключевые понятия","count":5},{"language":"ru","tag":"Управление","count":5},{"language":"zh","tag":"优势","count":5},{"language":"zh","tag":"核心概念","count":5},{"language":"zh","tag":"治理","count":5},{"language":"es","tag":"Recursos","count":3},{"language":"es","tag":"Guías","count":3},{"language":"ru","tag":"Ресурсы","count":3},{"language":"ru","tag":"Руководства","count":3},{"language":"zh","tag":"资源","count":3},{"language":"zh","tag":"指南","count":3},{"language":"es","tag":"Cómo funciona","count":2},{"language":"ru","tag":"Как это работает","count":2},{"language":"zh","tag":"工作原理","count":2},{"language":"es","tag":"Cumplimiento","count":1},{"language":"es","tag":"Inicio","count":1},{"language":"ru","tag":"Соответствие требованиям","count":1},{"language":"ru","tag":"Главная","count":1},{"language":"zh","tag":"合规","count":1},{"language":"zh","tag":"首页","count":1}]},"assistantConfig":{},"basePath":"/docs","hasChatPermissions":false,"hasWebMcpPermissions":false,"toggles":[{"name":"kill-isr","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":"editor-v7-file-tree","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":"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":"pause-universal-search-reconcile","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":"per-site-search-delta","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":"editor-private-page-search","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":"editor-nav-generations","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":"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":"byok-sep-25","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":"vite-origin","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"editor-agent-model-picker","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"billing-updated-9-15","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":"workos-enabled","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false}],"isAtlas":false,"googleFontsInlined":false},"customCss":[],"page":{"pagePath":"developers/api/1click","slug":"/developers/api/1click","pageMetadata":{"title":"One-Click Swaps","description":"Integrate one-click cross-chain swaps that handle the entire flow in the background","href":"/developers/api/1click"},"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: \"Integrate one-click cross-chain swaps that handle the entire flow in the background\"\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={li:`li`,p:`p`,strong:`strong`,ul:`ul`,..._provideComponents(),...props.components},{Heading,Mermaid,Tip}=_components;if(!Heading)_missingMdxReference(`Heading`,true);if(!Mermaid)_missingMdxReference(`Mermaid`,true);if(!Tip)_missingMdxReference(`Tip`,true);return _jsxs(_Fragment,{children:[_jsx(Heading,{level:`2`,id:`overview`,children:`Overview`}),`\n`,_jsx(_components.p,{children:`This framework eliminates the need for users to stay online until the end of the swap, removing the need for the user side application to manually redeem on the destination chain.`}),`\n`,_jsx(Tip,{children:_jsx(_components.p,{children:`We recommend using this system in stateless or unstable network environments, if you have access to persistent state and access to a background process consider managing the preimages on the user side.`})}),`\n`,_jsx(Heading,{level:`2`,id:`how-it-works`,children:`How It Works`}),`\n`,_jsxs(_components.ul,{children:[`\n`,_jsx(_components.li,{children:`This allows a user or an integrator to grant preimage manager access to generate the preimage, hold it until the solver initiate on the Destination chain.`}),`\n`,_jsx(_components.li,{children:`Revealing the preimage claims funds to user’s address, the preimage manager is not allowed to change the addresses of sender or recipient as they are pre set on-chain, and are immutable.`}),`\n`,_jsxs(_components.li,{children:[`This is an `,_jsx(_components.strong,{children:`optional`}),` convenience feature, allowing the user to interact with the swapping system, and not stay online until confirmation, this could add high UX value for swaps from slow chains like Bitcoin.`]}),`\n`]}),`\n`,_jsx(Heading,{level:`3`,id:`architecture-overview`,children:`Architecture Overview`}),`\n`,_jsx(Mermaid,{chart:`sequenceDiagram\n participant U as User\n participant API as Garden API\n participant PM as Preimage Manager\n participant SC as Source Chain\n participant DC as Destination Chain\n participant S as Solver\n\n U->>API: Create an intent without the secret hash\n API->>PM: Request hashlock\n Note over PM: Generate preimage \u0026 calculate hashlock\n PM->>API: Return hashlock\n API->>U: Return initiate request prefilled with hashlock\n U->>SC: Initiate swap with hashlock\n Note over SC: Source initiate transaction mined\n S->>DC: Initiate swap with same hashlock\n Note over DC: Destination initiate transaction mined\n PM->>DC: Reveal preimage (claim funds to user)\n Note over DC: User receives funds on destination\n S->>SC: Use revealed preimage to claim funds\n Note over SC: Solver receives funds on source`}),`\n`,_jsx(_components.p,{children:`The diagram shows how the preimage manager eliminates the need for users to stay online throughout the entire swap process. Once the user initiates the swap on the source chain, the preimage manager handles the final redemption automatically when the solver completes their part of the atomic swap.`})]})}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":{"config":{},"pageMetadata":{"title":"One-Click Swaps","description":"Integrate one-click cross-chain swaps that handle the entire flow in the background","href":"/developers/api/1click"}}},"mdxSourceWithNoJs":null},"mdxExtracts":{"tableOfContents":[{"title":"Overview","slug":"overview","depth":2,"children":[]},{"title":"How It Works","slug":"how-it-works","depth":2,"children":[{"title":"Architecture Overview","slug":"architecture-overview","depth":3,"children":[]}]}],"codeExamples":{}},"jsLinks":[],"subdomain":"garden-e60e7dd0","siteName":"Garden Finance Docs","title":"One-Click Swaps - Garden Finance Docs","navMaps":{"firstHrefInVersion":{},"firstHrefInLanguage":{"en":{"href":"/developers/api/1click","matchLevel":0},"es":{"href":"/es","matchLevel":4},"ru":{"href":"/ru","matchLevel":4},"zh":{"href":"/zh","matchLevel":4}}},"lastModified":"2026-03-16T09:05:32.947Z","originalFileLocation":"developers/api/1click.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=\"system\"}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=\"Integrate one-click cross-chain swaps that handle the entire flow in the background\">\u003cmeta data-mint-head name=\"application-name\" content=\"Garden Finance Docs\">\u003cmeta data-mint-head name=\"generator\" content=\"Mintlify\">\u003clink data-mint-head rel=\"icon\" type=\"image/png\" sizes=\"192x192\" href=\"/docs/mintlify-assets/_mintlify/favicons/garden-e60e7dd0/1wj8S5SbcVXWKL9b/_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=\"/docs/mintlify-assets/_mintlify/favicons/garden-e60e7dd0/1wj8S5SbcVXWKL9b/_generated/favicon/apple-touch-icon.png\">\u003clink data-mint-head rel=\"icon\" type=\"image/png\" sizes=\"16x16\" href=\"/docs/mintlify-assets/_mintlify/favicons/garden-e60e7dd0/1wj8S5SbcVXWKL9b/_generated/favicon/favicon-16x16.png\" media=\"(prefers-color-scheme: light)\">\u003clink data-mint-head rel=\"icon\" type=\"image/png\" sizes=\"32x32\" href=\"/docs/mintlify-assets/_mintlify/favicons/garden-e60e7dd0/1wj8S5SbcVXWKL9b/_generated/favicon/favicon-32x32.png\" media=\"(prefers-color-scheme: light)\">\u003clink data-mint-head rel=\"shortcut icon\" type=\"image/x-icon\" href=\"/docs/mintlify-assets/_mintlify/favicons/garden-e60e7dd0/1wj8S5SbcVXWKL9b/_generated/favicon/favicon.ico\" media=\"(prefers-color-scheme: light)\">\u003clink data-mint-head rel=\"icon\" type=\"image/png\" sizes=\"192x192\" href=\"/docs/mintlify-assets/_mintlify/favicons/garden-e60e7dd0/1wj8S5SbcVXWKL9b/_generated/favicon-dark/android-chrome-192x192.png\" media=\"(prefers-color-scheme: dark)\">\u003clink data-mint-head rel=\"icon\" type=\"image/png\" sizes=\"16x16\" href=\"/docs/mintlify-assets/_mintlify/favicons/garden-e60e7dd0/1wj8S5SbcVXWKL9b/_generated/favicon-dark/favicon-16x16.png\" media=\"(prefers-color-scheme: dark)\">\u003clink data-mint-head rel=\"icon\" type=\"image/png\" sizes=\"32x32\" href=\"/docs/mintlify-assets/_mintlify/favicons/garden-e60e7dd0/1wj8S5SbcVXWKL9b/_generated/favicon-dark/favicon-32x32.png\" media=\"(prefers-color-scheme: dark)\">\u003clink data-mint-head rel=\"shortcut icon\" type=\"image/x-icon\" href=\"/docs/mintlify-assets/_mintlify/favicons/garden-e60e7dd0/1wj8S5SbcVXWKL9b/_generated/favicon-dark/favicon.ico\" media=\"(prefers-color-scheme: dark)\">\u003cmeta data-mint-head property=\"og:title\" content=\"One-Click Swaps - Garden Finance Docs\">\u003cmeta data-mint-head property=\"og:description\" content=\"Integrate one-click cross-chain swaps that handle the entire flow in the background\">\u003cmeta data-mint-head property=\"og:site_name\" content=\"Garden Finance Docs\">\u003cmeta data-mint-head property=\"og:url\" content=\"https://garden.finance/docs/developers/api/1click\">\u003cmeta data-mint-head property=\"og:type\" content=\"website\">\u003cmeta data-mint-head property=\"og:image\" content=\"https://garden-e60e7dd0.mintlify.app/_mintlify/api/og/v2?division=API\u0026amp;title=One-Click+Swaps\u0026amp;description=Integrate+one-click+cross-chain+swaps+that+handle+the+entire+flow+in+the+background\u0026amp;theme=b7bf8057f7c2ebb4cba1594f\u0026amp;signature=5b0ccabe4ca4bf5aaa484f685a8e347f5192a410bf28756471f751b67daddcc2\">\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=\"One-Click Swaps - Garden Finance Docs\">\u003cmeta data-mint-head name=\"twitter:description\" content=\"Integrate one-click cross-chain swaps that handle the entire flow in the background\">\u003cmeta data-mint-head name=\"twitter:image\" content=\"https://garden-e60e7dd0.mintlify.app/_mintlify/api/og/v2?division=API\u0026amp;title=One-Click+Swaps\u0026amp;description=Integrate+one-click+cross-chain+swaps+that+handle+the+entire+flow+in+the+background\u0026amp;theme=b7bf8057f7c2ebb4cba1594f\u0026amp;signature=5b0ccabe4ca4bf5aaa484f685a8e347f5192a410bf28756471f751b67daddcc2\">\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=\"/docs/mintlify-assets/_mintlify/favicons/garden-e60e7dd0/1wj8S5SbcVXWKL9b/_generated/favicon/browserconfig.xml\">\u003cmeta data-mint-head name=\"apple-mobile-web-app-title\" content=\"Garden Finance Docs\">\u003cmeta data-mint-head name=\"msapplication-TileColor\" content=\"#e36492\">\u003clink data-mint-head rel=\"canonical\" href=\"https://garden.finance/docs/developers/api/1click\">\u003clink data-mint-head rel=\"alternate\" type=\"application/xml\" href=\"/docs/sitemap.xml\">\u003clink data-mint-head rel=\"alternate\" type=\"text/markdown\" href=\"/docs/developers/api/1click.md\">\u003cscript data-mint-head type=\"application/ld+json\">{\"@context\":\"https://schema.org\",\"@graph\":[{\"@type\":\"Organization\",\"@id\":\"https://garden.finance/#organization\",\"name\":\"Garden Finance Docs\",\"url\":\"https://garden.finance\",\"logo\":{\"@type\":\"ImageObject\",\"url\":\"https://mintcdn.com/garden-e60e7dd0/XPXywADb9NcDNBRh/logo/light.svg?fit=max\u0026auto=format\u0026n=XPXywADb9NcDNBRh\u0026q=85\u0026s=cd505087813ca2c17268a74c13bffdb2\"}},{\"@type\":\"WebSite\",\"@id\":\"https://garden.finance/docs#website\",\"name\":\"Garden Finance Docs\",\"url\":\"https://garden.finance/docs\",\"publisher\":{\"@id\":\"https://garden.finance/#organization\"}},{\"@type\":\"WebPage\",\"@id\":\"https://garden.finance/docs/developers/api/1click#webpage\",\"url\":\"https://garden.finance/docs/developers/api/1click\",\"name\":\"One-Click Swaps\",\"description\":\"Integrate one-click cross-chain swaps that handle the entire flow in the background\",\"dateModified\":\"2026-03-16T09:05:32.947Z\",\"isPartOf\":{\"@id\":\"https://garden.finance/docs#website\"},\"breadcrumb\":{\"@id\":\"https://garden.finance/docs/developers/api/1click#breadcrumb\"}},{\"@type\":\"BreadcrumbList\",\"@id\":\"https://garden.finance/docs/developers/api/1click#breadcrumb\",\"itemListElement\":[{\"@type\":\"ListItem\",\"position\":1,\"name\":\"API\",\"item\":\"https://garden.finance/docs/developers/api/overview\"},{\"@type\":\"ListItem\",\"position\":2,\"name\":\"One-Click Swaps\",\"item\":\"https://garden.finance/docs/developers/api/1click\"}]},{\"@type\":[\"Article\",\"TechArticle\"],\"@id\":\"https://garden.finance/docs/developers/api/1click#article\",\"headline\":\"One-Click Swaps\",\"name\":\"One-Click Swaps\",\"description\":\"Integrate one-click cross-chain swaps that handle the entire flow in the background\",\"url\":\"https://garden.finance/docs/developers/api/1click\",\"mainEntityOfPage\":{\"@id\":\"https://garden.finance/docs/developers/api/1click#webpage\"},\"dateModified\":\"2026-03-16T09:05:32.947Z\",\"publisher\":{\"@id\":\"https://garden.finance/#organization\"},\"isPartOf\":{\"@id\":\"https://garden.finance/docs#website\"}}]}\u003c/script>\u003cscript data-mint-head type=\"application/ld+json\">{\"@context\":\"https://schema.org\",\"@type\":\"WebSite\",\"name\":\"Garden Finance Docs\",\"creator\":{\"@type\":\"Organization\",\"name\":\"Mintlify\",\"url\":\"https://mintlify.com\"}}\u003c/script>","siteName":"Garden Finance Docs","nav":{"global":{"anchors":[{"anchor":"GitHub","icon":"github","href":"https://github.com/gardenfi"},{"anchor":"Blog","icon":"newspaper","href":"https://garden.finance/blog"},{"anchor":"Community","icon":"discord","href":"https://discord.gg/B7RczEFuJ5"}]},"languages":[{"language":"en","tabs":[{"tab":"Home","pages":[{"title":"Home","href":""}]},{"tab":"Get Started","pages":[{"title":"Get Started","href":"/home/about"}]},{"tab":"Developers","groups":[{"group":"Get Started","pages":[{"title":"Developer Overview","href":"/developers/overview"},{"title":"Supported Chains and Assets","href":"/developers/supported-chains"},{"title":"Supported Routes","href":"/developers/supported-routes"},{"title":"Affiliate Fees","href":"/developers/affiliate-fees"}]},{"group":"API","pages":[{"title":"Garden API","description":"Integrate Bitcoin bridging into your wallet, app, or back-end service using our API endpoints","href":"/developers/api/overview"},{"title":"One-Click Swaps","href":"/developers/api/1click"}]},{"group":"SDK","pages":[{"title":"Garden SDK","description":"Integrate Bitcoin bridging into your dApp with TypeScript packages for React and Node.js","href":"/developers/sdk/overview"},{"group":"React","pages":[{"title":"Setup","href":"/developers/sdk/react/setup"},{"title":"Quickstart","href":"/developers/sdk/react/quickstart"}]},{"group":"NodeJS","pages":[{"title":"Setup","href":"/developers/sdk/nodejs/setup"},{"title":"Quickstart","href":"/developers/sdk/nodejs/quickstart"}]}]},{"group":"Core Concepts","pages":[{"title":"Order Lifecycle","href":"/developers/core/order-lifecycle"},{"title":"Sessions","href":"/developers/core/sessions"}]},{"group":"Developer Guides","pages":[{"title":"Cookbook","href":"/developers/guides/cookbook"},{"title":"Bridge using Garden SDK","href":"/developers/guides/sdk"}]},{"group":"Testing","pages":[{"title":"Localnet","href":"/developers/localnet"}]}]},{"tab":"Contracts","pages":[{"title":"Contracts","href":"/contracts/overview"}]},{"tab":"API Reference","pages":[{"title":"API Reference","href":"/api-reference/quickstart"}]},{"tab":"Changelog","pages":[{"title":"Changelog","href":"/changelog"}]}]},{"language":"es","footer":{"socials":{"x":"https://x.com/gardenfi","github":"https://github.com/gardenfi","discord":"https://discord.gg/B7RczEFuJ5"},"links":[{"header":"Aplicación","items":[{"label":"Swap","href":"https://app.garden.finance/es/swap"},{"label":"Stake","href":"https://app.garden.finance/es/stake"}]},{"header":"Recursos","items":[{"label":"Blog","href":"https://garden.finance/es/blog"},{"label":"Docs","href":"https://garden.finance/docs/es"},{"label":"Auditorías","href":"https://github.com/catalogfi/audits"},{"label":"Kit de prensa","href":"https://drive.google.com/drive/folders/1ZRAxs6jwhO6vLkadb9XOG7XqOQ4XLr0t?usp=sharing"}]}]},"navbar":{"links":[{"href":"https://discord.gg/B7RczEFuJ5","label":"Soporte"}],"primary":{"type":"button","label":"Abrir app","href":"https://app.garden.finance/es"}},"pages":[{"title":"es","href":"/es"}]},{"language":"ru","footer":{"socials":{"x":"https://x.com/gardenfi","github":"https://github.com/gardenfi","discord":"https://discord.gg/B7RczEFuJ5"},"links":[{"header":"Приложение","items":[{"label":"Swap","href":"https://app.garden.finance/ru/swap"},{"label":"Stake","href":"https://app.garden.finance/ru/stake"}]},{"header":"Ресурсы","items":[{"label":"Блог","href":"https://garden.finance/ru/blog"},{"label":"Документация","href":"https://garden.finance/docs/ru"},{"label":"Аудиты","href":"https://github.com/catalogfi/audits"},{"label":"Медиакит","href":"https://drive.google.com/drive/folders/1ZRAxs6jwhO6vLkadb9XOG7XqOQ4XLr0t?usp=sharing"}]}]},"navbar":{"links":[{"href":"https://discord.gg/B7RczEFuJ5","label":"Поддержка"}],"primary":{"type":"button","label":"Запустить приложение","href":"https://app.garden.finance/ru"}},"pages":[{"title":"ru","href":"/ru"}]},{"language":"zh","footer":{"socials":{"x":"https://x.com/gardenfi","github":"https://github.com/gardenfi","discord":"https://discord.gg/B7RczEFuJ5"},"links":[{"header":"应用","items":[{"label":"Swap","href":"https://app.garden.finance/zh/swap"},{"label":"Stake","href":"https://app.garden.finance/zh/stake"}]},{"header":"资源","items":[{"label":"博客","href":"https://garden.finance/zh/blog"},{"label":"文档","href":"https://garden.finance/docs/zh"},{"label":"审计","href":"https://github.com/catalogfi/audits"},{"label":"媒体资料包","href":"https://drive.google.com/drive/folders/1ZRAxs6jwhO6vLkadb9XOG7XqOQ4XLr0t?usp=sharing"}]}]},"navbar":{"links":[{"href":"https://discord.gg/B7RczEFuJ5","label":"支持"}],"primary":{"type":"button","label":"启动应用","href":"https://app.garden.finance/zh"}},"pages":[{"title":"zh","href":"/zh"}]}]},"title":"One-Click Swaps - Garden Finance Docs","buildId":"dpl_3rfzHPCtRhDFBbetXZ3oLkN5tjmA","deploymentId":"dpl_3rfzHPCtRhDFBbetXZ3oLkN5tjmA","dynamics":[],"chunks":[]}