{"id":15061429,"url":"https://github.com/ashtech15/sol2spl-swap-raydiumamm","last_synced_at":"2026-02-24T07:08:08.507Z","repository":{"id":256357913,"uuid":"852433965","full_name":"ashtech15/SOL2SPL-swap-RaydiumAMM","owner":"ashtech15","description":"TypeScript code for swapping SPL tokens on the Raydium AMM using TypeScript.","archived":false,"fork":false,"pushed_at":"2024-09-10T07:33:09.000Z","size":82,"stargazers_count":1,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"main","last_synced_at":"2025-03-15T11:14:21.726Z","etag":null,"topics":["raydium-sdk","solana","spl-token","typescript","web3js"],"latest_commit_sha":null,"homepage":"","language":"TypeScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/ashtech15.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2024-09-04T19:50:15.000Z","updated_at":"2024-09-10T07:33:12.000Z","dependencies_parsed_at":null,"dependency_job_id":"3587008f-ab3d-499f-b9f0-ec514ff45ede","html_url":"https://github.com/ashtech15/SOL2SPL-swap-RaydiumAMM","commit_stats":null,"previous_names":["ashtech15/sol2spl-swap-raydiumamm"],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ashtech15%2FSOL2SPL-swap-RaydiumAMM","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ashtech15%2FSOL2SPL-swap-RaydiumAMM/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ashtech15%2FSOL2SPL-swap-RaydiumAMM/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ashtech15%2FSOL2SPL-swap-RaydiumAMM/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/ashtech15","download_url":"https://codeload.github.com/ashtech15/SOL2SPL-swap-RaydiumAMM/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":243719399,"owners_count":20336607,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["raydium-sdk","solana","spl-token","typescript","web3js"],"created_at":"2024-09-24T23:19:29.385Z","updated_at":"2025-10-08T06:32:51.400Z","avatar_url":"https://github.com/ashtech15.png","language":"TypeScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"# SOL-SPL-swap\n\nRaydium is a decentralized order book and automated market maker (AMM) platform built on the Solana blockchain. While the Raydium frontend provides a user-friendly interface for swapping tokens, not all users interact with the platform through this interface. Developers, in particular, may need to build applications or server-side scripts that interact directly with the Raydium smart contracts to facilitate token swaps or leverage other Raydium features.\n\nIn this script, I’ll provide a code example that demonstrates how to build a script for swapping tokens on the Raydium AMM using TypeScript.\n\n## Configuration\n\n- Run this command to set environment variables\n  `cp .env.example .env`\n- Set `CREATOR_PRIVATE_KEY` with uint8Array keypair\n- Set `BURNER_WALLET` with the public address of the destination wallet.\n- Set `TOKEN_MINT_ADDRESS` with the target SPL token address\n- Set `POOL_ID` with the SOL/TOKEN pool id\n- Set `GIREUMEE_POOL_ID` with the SOL/GIREUMEE pool id\n- Set `RPC_CLUSTER` with proper network\n  - `mainnet-beta`\n  - `devnet`\n- Set `THRESHOLD_AMOUNT` with the threshold amount to trigger swap function.\n- Set `INTERVAL_PERIOD` with the period of monitoring loop `10000` =\u003e 10 seconds\n\n## Run script\n\nAfter setting up proper configurations run this script.\n`npm install`\n`npm run swap`\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fashtech15%2Fsol2spl-swap-raydiumamm","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fashtech15%2Fsol2spl-swap-raydiumamm","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fashtech15%2Fsol2spl-swap-raydiumamm/lists"}