Running the Soroswap contracts yourself: the quickstart from soroswap/core, and where the deploy scripts put their output.
You can deploy the whole protocol yourself, on a local standalone network or on testnet.
The deploy tooling lives in soroswap/core and is the
source of truth; the summary below mirrors that repository’s README.
This page used to carry a long CLI walkthrough written against the old soroban CLI,
Futurenet and the soroban-preview Docker images. All three are gone: the CLI is now
stellar, and the deploy path is the scripted one below. The walkthrough was removed
rather than left to mislead. Follow the repository README for anything not covered here.
Fill in SOROSWAP_ADMIN_SECRET_KEY, TEST_TOKENS_ADMIN_SECRET_KEY,
TESTING_ACCOUNT_SECRET_KEY and MAINNET_RPC_URL. These are the keys the deploy runs as.Start the network container in one terminal:
bash scripts/quickstart.sh standalone # or testnet
That one command installs the Pair, Factory and Router WASM, then deploys and initializes
the Factory and the Router. On any network other than mainnet it also seeds the network so
there is something to trade against: eight test tokens, liquidity across three paths, four
Stellar test tokens, and eight random tokens. Native XLM is wrapped if it is not already.It writes three files:
If you only want to talk to the contracts that are already live rather than run your own,
you do not need any of the above. The mainnet addresses are on
Deployed Addresses, and the current values
are always in
public/mainnet.contracts.json.
{"docsConfig":{"theme":"mint","$schema":"https://mintlify.com/docs.json","name":"Soroswap Finance","description":"The Swap Aggregator for Stellar: one API that quotes every Stellar venue and returns the best route, plus the Soroswap AMM.","colors":{"primary":"#8866DD","light":"#A98BE8","dark":"#6F4FC7"},"logo":{"light":"https://mintcdn.com/soroswap/1xzCGA5zGx88_Gb9/logo/light.svg?fit=max\u0026auto=format\u0026n=1xzCGA5zGx88_Gb9\u0026q=85\u0026s=167296c66e3d90415a7f2aa982f7843b","dark":"https://mintcdn.com/soroswap/1xzCGA5zGx88_Gb9/logo/dark.svg?fit=max\u0026auto=format\u0026n=1xzCGA5zGx88_Gb9\u0026q=85\u0026s=77ca3dbbc4d3854eb6f326c89561e074","href":"https://soroswap.finance"},"favicon":"https://mintcdn.com/soroswap/1xzCGA5zGx88_Gb9/favicon.png?fit=max\u0026auto=format\u0026n=1xzCGA5zGx88_Gb9\u0026q=85\u0026s=001876061b5f304af9d8fa19a3ff1da0","api":{"openapi":"https://api.soroswap.finance/api-json","mdx":{"auth":{"method":"bearer"},"server":"https://api.soroswap.finance"}},"navbar":{"links":[{"href":"https://app.soroswap.finance","label":"Launch App"},{"href":"https://discord.gg/A2rQ3cm9XG","label":"Support"}],"primary":{"type":"button","label":"Get API key","href":"https://api.soroswap.finance/register"}},"footer":{"socials":{"x":"https://x.com/SoroswapFinance","discord":"https://discord.gg/A2rQ3cm9XG","github":"https://github.com/soroswap"}},"integrations":{"posthog":{"apiKey":"phc_C6MfPNluY4B1Kx7kFa4d2XPJmcGHhQAplhnzD8hIt6G","apiHost":"https://us.i.posthog.com","sessionRecording":false}},"contextual":{"options":["copy","view","chatgpt","claude","perplexity","mcp","cursor","vscode"],"display":"header"},"markdown":{"instructions":["Soroswap Aggregator API: base URL https://api.soroswap.finance, pick the network with ?network=mainnet or ?network=testnet (omitted means mainnet).","Auth: Authorization: Bearer sk_... on every call. Get a key at https://api.soroswap.finance/register. A missing or invalid key returns 403, never 401. Free plan 1 request/s; see https://docs.soroswap.finance/api/plans.md.","Flow: POST /quote (assetIn, assetOut as C... contract addresses, amount as an integer string in the smallest unit, tradeType, protocols) -> POST /quote/build with the unchanged quote and from -> the user signs the XDR -> POST /send. Build right after quoting: a Soroban XDR is valid for 180 seconds. Submit it as is, never re-simulate it.","AI tools: docs MCP at https://docs.soroswap.finance/mcp (claude mcp add --transport http soroswap-docs https://docs.soroswap.finance/mcp), skill with npx skills add https://docs.soroswap.finance. Other clients: https://docs.soroswap.finance/api/build-with-ai.md.","Units and Stellar pitfalls: https://docs.soroswap.finance/api/stellar-gotchas.md. Errors and retries: https://docs.soroswap.finance/api/errors.md."]},"styling":{"latex":true},"navigation":{"global":{"anchors":[{"anchor":"Dune Dashboard","icon":"chart-line","href":"https://dune.com/paltalabs/soroswap"},{"anchor":"GitHub","icon":"github","href":"https://github.com/soroswap"},{"anchor":"Discord","icon":"discord","href":"https://discord.gg/A2rQ3cm9XG"}]},"pages":[]}},"deployment":{"deploymentMetadataValue":{"subdomain":"soroswap","hasAudioNarration":false,"actualSubdomain":"soroswap","customDomains":["docs.soroswap.finance"],"gitSource":{"type":"github","owner":"soroswap","repo":"docs","deployBranch":"main","contentDirectory":"","isPrivate":true,"mountPath":"","label":""},"entitlements":{"AI_CHAT":{"status":"DISABLED"},"WEB_MCP":{"status":"DISABLED"}},"buildId":"6aec4fc29c320f62bb68c12f","clientVersion":"0.0.4087","searchFilterCounts":[{"language":"default","tag":"Learn","count":39},{"language":"default","tag":"Soroswap AMM","count":34},{"language":"default","tag":"API Reference","count":27},{"language":"default","tag":"Aggregator API","count":15},{"language":"default","tag":"Concepts","count":15},{"language":"default","tag":"Technical Reference","count":13},{"language":"default","tag":"Tutorials","count":11},{"language":"default","tag":"Getting Started","count":7},{"language":"default","tag":"Account","count":6},{"language":"default","tag":"Market data","count":6}]},"assistantConfig":{"enableAskAiButton":false,"enableStarterQuestions":false,"enableContextualStarterQuestions":false,"enableAskAiSearchBar":true},"basePath":"","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":"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},{"name":"comment-mode","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false}],"googleFontsInlined":false},"customCss":[],"page":{"pagePath":"amm/technical-reference/deploy-yourself","slug":"/amm/technical-reference/deploy-yourself","pageMetadata":{"title":"Deploy Soroswap Yourself","description":"Running the Soroswap contracts yourself: the quickstart from soroswap/core, and where the deploy scripts put their output.","href":"/amm/technical-reference/deploy-yourself/index"},"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: \"Running the Soroswap contracts yourself: the quickstart from soroswap/core, and where the deploy scripts put their output.\"\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={a:`a`,code:`code`,li:`li`,p:`p`,pre:`pre`,span:`span`,tbody:`tbody`,td:`td`,th:`th`,thead:`thead`,tr:`tr`,ul:`ul`,..._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:[_jsxs(_components.p,{children:[`You can deploy the whole protocol yourself, on a local standalone network or on testnet.\nThe deploy tooling lives in `,_jsx(_components.a,{href:`https://github.com/soroswap/core`,children:`soroswap/core`}),` and is the\nsource of truth; the summary below mirrors that repository’s README.`]}),`\n`,_jsx(Warning,{children:_jsxs(_components.p,{children:[`This page used to carry a long CLI walkthrough written against the old `,_jsx(_components.code,{children:`soroban`}),` CLI,\nFuturenet and the `,_jsx(_components.code,{children:`soroban-preview`}),` Docker images. All three are gone: the CLI is now\n`,_jsx(_components.code,{children:`stellar`}),`, and the deploy path is the scripted one below. The walkthrough was removed\nrather than left to mislead. Follow the repository README for anything not covered here.`]})}),`\n`,_jsx(Heading,{level:`2`,id:`prerequisites`,children:`Prerequisites`}),`\n`,_jsxs(_components.p,{children:[_jsx(_components.code,{children:`jq`}),`, `,_jsx(_components.code,{children:`docker`}),`, `,_jsx(_components.code,{children:`docker-compose`}),`, `,_jsx(_components.code,{children:`node`}),`, `,_jsx(_components.code,{children:`yarn`}),`.`]}),`\n`,_jsx(Heading,{level:`2`,id:`set-up`,children:`Set up`}),`\n`,_jsx(CodeBlock,{filename:``,numberOfLines:`3`,language:`shellscript`,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:`shellscript`,children:_jsxs(_components.code,{language:`shellscript`,numberOfLines:`3`,children:[_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#953800`,\"--shiki-dark\":`#DCDCAA`},children:`git`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` clone`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` https://github.com/soroswap/core.git`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#DCDCAA`},children:`cd`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` core`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#953800`,\"--shiki-dark\":`#DCDCAA`},children:`cp`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` .env.example`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` .env`})]}),`\n`]})})}),`\n`,_jsxs(_components.p,{children:[`Fill in `,_jsx(_components.code,{children:`SOROSWAP_ADMIN_SECRET_KEY`}),`, `,_jsx(_components.code,{children:`TEST_TOKENS_ADMIN_SECRET_KEY`}),`,\n`,_jsx(_components.code,{children:`TESTING_ACCOUNT_SECRET_KEY`}),` and `,_jsx(_components.code,{children:`MAINNET_RPC_URL`}),`. These are the keys the deploy runs as.`]}),`\n`,_jsx(_components.p,{children:`Start the network container in one terminal:`}),`\n`,_jsx(CodeBlock,{filename:``,numberOfLines:`1`,language:`shellscript`,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:`shellscript`,children:_jsxs(_components.code,{language:`shellscript`,numberOfLines:`1`,children:[_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#953800`,\"--shiki-dark\":`#DCDCAA`},children:`bash`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` scripts/quickstart.sh`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` standalone`}),_jsx(_components.span,{style:{color:`#6E7781`,\"--shiki-dark\":`#6A9955`},children:` # or testnet`})]}),`\n`]})})}),`\n`,_jsx(_components.p,{children:`And the workspace container in another:`}),`\n`,_jsx(CodeBlock,{filename:``,numberOfLines:`4`,language:`shellscript`,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:`shellscript`,children:_jsxs(_components.code,{language:`shellscript`,numberOfLines:`4`,children:[_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#953800`,\"--shiki-dark\":`#DCDCAA`},children:`bash`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` scripts/run.sh`})]}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#953800`,\"--shiki-dark\":`#DCDCAA`},children:`yarn`})}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#DCDCAA`},children:`cd`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` /workspace/contracts`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#953800`,\"--shiki-dark\":`#DCDCAA`},children:`make`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` build`})]}),`\n`]})})}),`\n`,_jsx(Heading,{level:`2`,id:`deploy`,children:`Deploy`}),`\n`,_jsx(_components.p,{children:`From the workspace container:`}),`\n`,_jsx(CodeBlock,{filename:``,numberOfLines:`2`,language:`shellscript`,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:`shellscript`,children:_jsxs(_components.code,{language:`shellscript`,numberOfLines:`2`,children:[_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#953800`,\"--shiki-dark\":`#DCDCAA`},children:`yarn`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` build`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#953800`,\"--shiki-dark\":`#DCDCAA`},children:`yarn`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` deploy`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#D4D4D4`},children:` \u003c`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`networ`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`k`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#D4D4D4`},children:`>`})]}),`\n`]})})}),`\n`,_jsx(_components.p,{children:`That one command installs the Pair, Factory and Router WASM, then deploys and initializes\nthe Factory and the Router. On any network other than mainnet it also seeds the network so\nthere is something to trade against: eight test tokens, liquidity across three paths, four\nStellar test tokens, and eight random tokens. Native XLM is wrapped if it is not already.`}),`\n`,_jsx(_components.p,{children:`It writes three files:`}),`\n`,_jsxs(_components.ul,{children:[`\n`,_jsx(_components.li,{children:_jsx(_components.code,{children:`.soroban/tokens.json`})}),`\n`,_jsx(_components.li,{children:_jsx(_components.code,{children:`.soroban/\u003cNETWORK>.contracts.json`})}),`\n`,_jsx(_components.li,{children:_jsx(_components.code,{children:`.soroban/random_tokens.json`})}),`\n`]}),`\n`,_jsx(Heading,{level:`2`,id:`serve-the-addresses-locally`,children:`Serve the addresses locally`}),`\n`,_jsx(CodeBlock,{filename:``,numberOfLines:`1`,language:`shellscript`,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:`shellscript`,children:_jsxs(_components.code,{language:`shellscript`,numberOfLines:`1`,children:[_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#953800`,\"--shiki-dark\":`#DCDCAA`},children:`bash`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` scripts/serve_with_docker.sh`})]}),`\n`]})})}),`\n`,_jsxs(Table,{children:[_jsx(_components.thead,{children:_jsxs(_components.tr,{children:[_jsx(_components.th,{children:`Endpoint`}),_jsx(_components.th,{children:`Serves`})]})}),_jsxs(_components.tbody,{children:[_jsxs(_components.tr,{children:[_jsx(_components.td,{children:_jsx(_components.code,{children:`http://localhost:8010/api/tokens`})}),_jsx(_components.td,{children:`The token list`})]}),_jsxs(_components.tr,{children:[_jsx(_components.td,{children:_jsx(_components.code,{children:`http://localhost:8010/api/random_tokens`})}),_jsx(_components.td,{children:`The random tokens`})]}),_jsxs(_components.tr,{children:[_jsx(_components.td,{children:_jsx(_components.code,{children:`http://localhost:8010/api/\u003cnetwork>/factory`})}),_jsx(_components.td,{children:`The factory address`})]}),_jsxs(_components.tr,{children:[_jsx(_components.td,{children:_jsx(_components.code,{children:`http://localhost:8010/api/\u003cnetwork>/router`})}),_jsx(_components.td,{children:`The router address`})]})]})]}),`\n`,_jsx(_components.p,{children:`These mirror the shape of the public API, so a frontend pointed at localhost behaves the\nsame way it does against production.`}),`\n`,_jsx(Heading,{level:`2`,id:`the-deployed-contracts`,children:`The deployed contracts`}),`\n`,_jsxs(_components.p,{children:[`If you only want to talk to the contracts that are already live rather than run your own,\nyou do not need any of the above. The mainnet addresses are on\n`,_jsx(_components.a,{href:`/amm/technical-reference/deployed-addresses`,children:`Deployed Addresses`}),`, and the current values\nare always in\n`,_jsx(_components.a,{href:`https://github.com/soroswap/core/blob/main/public/mainnet.contracts.json`,children:_jsx(_components.code,{children:`public/mainnet.contracts.json`})}),`.`]})]})}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":"Deploy Soroswap Yourself","description":"Running the Soroswap contracts yourself: the quickstart from soroswap/core, and where the deploy scripts put their output.","href":"/amm/technical-reference/deploy-yourself/index"}}},"mdxSourceWithNoJs":null},"mdxExtracts":{"tableOfContents":[{"title":"Prerequisites","slug":"prerequisites","depth":2,"children":[]},{"title":"Set up","slug":"set-up","depth":2,"children":[]},{"title":"Deploy","slug":"deploy","depth":2,"children":[]},{"title":"Serve the addresses locally","slug":"serve-the-addresses-locally","depth":2,"children":[]},{"title":"The deployed contracts","slug":"the-deployed-contracts","depth":2,"children":[]}],"codeExamples":{}},"jsLinks":["/_mintlify/custom/soroswap/8cf4cc027d03ca5b/analytics.js"],"subdomain":"soroswap","siteName":"Soroswap Finance","title":"Deploy Soroswap Yourself - Soroswap Finance","navMaps":{"firstHrefInVersion":{},"firstHrefInLanguage":{}},"lastModified":"2026-09-07T21:42:39.669Z","originalFileLocation":"amm/technical-reference/deploy-yourself/index.mdx"},"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=\"Running the Soroswap contracts yourself: the quickstart from soroswap/core, and where the deploy scripts put their output.\">\u003cmeta data-mint-head name=\"application-name\" content=\"Soroswap Finance\">\u003cmeta data-mint-head name=\"generator\" content=\"Mintlify\">\u003clink data-mint-head rel=\"icon\" type=\"image/png\" sizes=\"192x192\" href=\"/mintlify-assets/_mintlify/favicons/soroswap/fuylThFPBoCQikOJ/_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/soroswap/fuylThFPBoCQikOJ/_generated/favicon/apple-touch-icon.png\">\u003clink data-mint-head rel=\"icon\" type=\"image/png\" sizes=\"16x16\" href=\"/mintlify-assets/_mintlify/favicons/soroswap/fuylThFPBoCQikOJ/_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/soroswap/fuylThFPBoCQikOJ/_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/soroswap/fuylThFPBoCQikOJ/_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/soroswap/fuylThFPBoCQikOJ/_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/soroswap/fuylThFPBoCQikOJ/_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/soroswap/fuylThFPBoCQikOJ/_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/soroswap/fuylThFPBoCQikOJ/_generated/favicon-dark/favicon.ico\" media=\"(prefers-color-scheme: dark)\">\u003cmeta data-mint-head property=\"og:title\" content=\"Deploy Soroswap Yourself - Soroswap Finance\">\u003cmeta data-mint-head property=\"og:description\" content=\"Running the Soroswap contracts yourself: the quickstart from soroswap/core, and where the deploy scripts put their output.\">\u003cmeta data-mint-head property=\"og:site_name\" content=\"Soroswap Finance\">\u003cmeta data-mint-head property=\"og:url\" content=\"https://docs.soroswap.finance/amm/technical-reference/deploy-yourself\">\u003cmeta data-mint-head property=\"og:type\" content=\"website\">\u003cmeta data-mint-head property=\"og:image\" content=\"https://soroswap.mintlify.site/_mintlify/api/og/v2?division=Technical+Reference\u0026amp;title=Deploy+Soroswap+Yourself\u0026amp;description=Running+the+Soroswap+contracts+yourself%3A+the+quickstart+from+soroswap%2Fcore%2C+and+where+the+deploy+scripts+put+their+output.\u0026amp;theme=1f7f3f9d39c67ea609340814\u0026amp;signature=cea46168684a8f184da373334ad704772ea41fbb079ab5db0779a58b898d557f\">\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=\"Deploy Soroswap Yourself - Soroswap Finance\">\u003cmeta data-mint-head name=\"twitter:description\" content=\"Running the Soroswap contracts yourself: the quickstart from soroswap/core, and where the deploy scripts put their output.\">\u003cmeta data-mint-head name=\"twitter:image\" content=\"https://soroswap.mintlify.site/_mintlify/api/og/v2?division=Technical+Reference\u0026amp;title=Deploy+Soroswap+Yourself\u0026amp;description=Running+the+Soroswap+contracts+yourself%3A+the+quickstart+from+soroswap%2Fcore%2C+and+where+the+deploy+scripts+put+their+output.\u0026amp;theme=1f7f3f9d39c67ea609340814\u0026amp;signature=cea46168684a8f184da373334ad704772ea41fbb079ab5db0779a58b898d557f\">\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/soroswap/fuylThFPBoCQikOJ/_generated/favicon/browserconfig.xml\">\u003cmeta data-mint-head name=\"apple-mobile-web-app-title\" content=\"Soroswap Finance\">\u003cmeta data-mint-head name=\"msapplication-TileColor\" content=\"#8866DD\">\u003clink data-mint-head rel=\"canonical\" href=\"https://docs.soroswap.finance/amm/technical-reference/deploy-yourself\">\u003clink data-mint-head rel=\"alternate\" type=\"application/xml\" href=\"/sitemap.xml\">\u003clink data-mint-head rel=\"alternate\" type=\"text/markdown\" href=\"/amm/technical-reference/deploy-yourself.md\">\u003cscript data-mint-head type=\"application/ld+json\">{\"@context\":\"https://schema.org\",\"@graph\":[{\"@type\":\"Organization\",\"@id\":\"https://docs.soroswap.finance/#organization\",\"name\":\"Soroswap Finance\",\"url\":\"https://docs.soroswap.finance\",\"logo\":{\"@type\":\"ImageObject\",\"url\":\"https://mintcdn.com/soroswap/1xzCGA5zGx88_Gb9/logo/light.svg?fit=max\u0026auto=format\u0026n=1xzCGA5zGx88_Gb9\u0026q=85\u0026s=167296c66e3d90415a7f2aa982f7843b\"}},{\"@type\":\"WebSite\",\"@id\":\"https://docs.soroswap.finance#website\",\"name\":\"Soroswap Finance\",\"url\":\"https://docs.soroswap.finance\",\"publisher\":{\"@id\":\"https://docs.soroswap.finance/#organization\"}},{\"@type\":\"WebPage\",\"@id\":\"https://docs.soroswap.finance/amm/technical-reference/deploy-yourself#webpage\",\"url\":\"https://docs.soroswap.finance/amm/technical-reference/deploy-yourself\",\"name\":\"Deploy Soroswap Yourself\",\"description\":\"Running the Soroswap contracts yourself: the quickstart from soroswap/core, and where the deploy scripts put their output.\",\"dateModified\":\"2026-09-07T21:42:39.669Z\",\"isPartOf\":{\"@id\":\"https://docs.soroswap.finance#website\"},\"breadcrumb\":{\"@id\":\"https://docs.soroswap.finance/amm/technical-reference/deploy-yourself#breadcrumb\"}},{\"@type\":\"BreadcrumbList\",\"@id\":\"https://docs.soroswap.finance/amm/technical-reference/deploy-yourself#breadcrumb\",\"itemListElement\":[{\"@type\":\"ListItem\",\"position\":1,\"name\":\"Soroswap AMM\",\"item\":\"https://docs.soroswap.finance/amm/index\"},{\"@type\":\"ListItem\",\"position\":2,\"name\":\"Technical Reference\",\"item\":\"https://docs.soroswap.finance/amm/technical-reference/index\"},{\"@type\":\"ListItem\",\"position\":3,\"name\":\"Deploy Soroswap Yourself\",\"item\":\"https://docs.soroswap.finance/amm/technical-reference/deploy-yourself\"}]},{\"@type\":[\"Article\",\"TechArticle\"],\"@id\":\"https://docs.soroswap.finance/amm/technical-reference/deploy-yourself#article\",\"headline\":\"Deploy Soroswap Yourself\",\"name\":\"Deploy Soroswap Yourself\",\"description\":\"Running the Soroswap contracts yourself: the quickstart from soroswap/core, and where the deploy scripts put their output.\",\"url\":\"https://docs.soroswap.finance/amm/technical-reference/deploy-yourself\",\"mainEntityOfPage\":{\"@id\":\"https://docs.soroswap.finance/amm/technical-reference/deploy-yourself#webpage\"},\"dateModified\":\"2026-09-07T21:42:39.669Z\",\"publisher\":{\"@id\":\"https://docs.soroswap.finance/#organization\"},\"isPartOf\":{\"@id\":\"https://docs.soroswap.finance#website\"}}]}\u003c/script>\u003cscript data-mint-head type=\"application/ld+json\">{\"@context\":\"https://schema.org\",\"@type\":\"WebSite\",\"name\":\"Soroswap Finance\",\"creator\":{\"@type\":\"Organization\",\"name\":\"Mintlify\",\"url\":\"https://mintlify.com\"}}\u003c/script>","siteName":"Soroswap Finance","nav":{"global":{"anchors":[{"anchor":"Dune Dashboard","icon":"chart-line","href":"https://dune.com/paltalabs/soroswap"},{"anchor":"GitHub","icon":"github","href":"https://github.com/soroswap"},{"anchor":"Discord","icon":"discord","href":"https://discord.gg/A2rQ3cm9XG"}]},"tabs":[{"tab":"Aggregator API","pages":[{"title":"Aggregator API","href":""}]},{"tab":"API Reference","pages":[{"title":"API Reference","href":"/api-reference/quote/protocols"}]},{"tab":"Soroswap AMM","groups":[{"group":"Soroswap AMM","root":{"title":"Soroswap AMM (DEX)","href":"/amm"},"pages":[{"title":"How Soroswap AMM works","href":"/amm/how-it-works"},{"title":"Ecosystem Participants","href":"/amm/ecosystem-participants"},{"title":"Glossary","href":"/amm/glossary"},{"title":"Audits","href":"/amm/audits"},{"group":"Technical Reference","root":{"title":"Technical Reference","href":"/amm/technical-reference/index"},"pages":[{"group":"Contracts","root":{"title":"Smart contracts","href":"/amm/technical-reference/contracts/index"},"pages":[{"title":"SoroswapPair","href":"/amm/technical-reference/contracts/soroswap-pair"},{"title":"SoroswapFactory","href":"/amm/technical-reference/contracts/soroswap-factory"},{"title":"SoroswapRouter","href":"/amm/technical-reference/contracts/soroswap-router"},{"title":"SoroswapLibrary","href":"/amm/technical-reference/contracts/soroswap-library"}]},{"title":"Deployed Addresses","href":"/amm/technical-reference/deployed-addresses"},{"title":"Error Codes","href":"/amm/technical-reference/error-codes"},{"title":"Design Decisions","href":"/amm/technical-reference/design-decisions"},{"title":"Smart Contract Integration","href":"/amm/technical-reference/smart-contract-integration"},{"title":"Using Soroswap with TypeScript","href":"/amm/technical-reference/using-soroswap-with-typescript"},{"group":"Soroswap vs UniswapV2","root":{"title":"Soroswap vs UniswapV2","href":"/amm/technical-reference/vs-uniswap-v2/index"},"pages":[{"title":"SoroswapPair Comparison","href":"/amm/technical-reference/vs-uniswap-v2/pair"},{"title":"SoroswapRouter Comparison","href":"/amm/technical-reference/vs-uniswap-v2/router"},{"title":"SoroswapLibrary Comparison","description":"How UniswapV2Library functions are implemented in Rust for the SoroswapLibrary contract.","href":"/amm/technical-reference/vs-uniswap-v2/library"}]},{"title":"Deploy Soroswap Yourself","href":"/amm/technical-reference/deploy-yourself/index"}]}]}]},{"tab":"Learn","pages":[{"title":"Learn","href":"/what-is-soroswap"}]}]},"basePath":"","title":"Deploy Soroswap Yourself - Soroswap Finance","buildId":"dpl_FWZhTb2vab28gFGFH4ojka6qEznQ","deploymentId":"dpl_FWZhTb2vab28gFGFH4ojka6qEznQ","dynamics":[],"chunks":[]}