{"id":18707629,"url":"https://github.com/descartesnetwork/sen-js","last_synced_at":"2026-01-30T15:32:19.076Z","repository":{"id":43470881,"uuid":"389112792","full_name":"DescartesNetwork/sen-js","owner":"DescartesNetwork","description":"The library for Sen Ecosystem","archived":false,"fork":false,"pushed_at":"2022-07-14T06:34:09.000Z","size":616,"stargazers_count":2,"open_issues_count":2,"forks_count":0,"subscribers_count":2,"default_branch":"master","last_synced_at":"2025-02-20T22:13:20.896Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":"https://descartesnetwork.github.io/sen-js/","language":"TypeScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/DescartesNetwork.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2021-07-24T14:03:54.000Z","updated_at":"2022-04-19T22:01:29.000Z","dependencies_parsed_at":"2022-07-16T10:46:15.912Z","dependency_job_id":null,"html_url":"https://github.com/DescartesNetwork/sen-js","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/DescartesNetwork%2Fsen-js","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/DescartesNetwork%2Fsen-js/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/DescartesNetwork%2Fsen-js/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/DescartesNetwork%2Fsen-js/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/DescartesNetwork","download_url":"https://codeload.github.com/DescartesNetwork/sen-js/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":248553433,"owners_count":21123446,"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":[],"created_at":"2024-11-07T12:19:07.464Z","updated_at":"2026-01-30T15:32:19.047Z","avatar_url":"https://github.com/DescartesNetwork.png","language":"TypeScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"# SEN JS\n\n\n## Introduction\nThis library is to help developers can integrate their projects to Sentre Ecosystem easily.\n\nSentre is an open liquidity protocol built on Solana. It's aiming to build and open, friendly, and free environment for both DApps developers, and DeFi users.\n\n[![Npm package version](https://badgen.net/npm/v/@senswap/sen-js)](https://www.npmjs.com/package/@senswap/sen-js)\n[![Npm package monthly downloads](https://badgen.net/npm/dm/@senswap/sen-js)](https://www.npmjs.com/package/@senswap/sen-js)\n[![GitHub license](https://badgen.net/npm/license/@senswap/sen-js)](https://github.com/DescartesNetwork/sen-js/blob/master/LICENSE)\n\n\n## Installation\n\n```shell\nnpm i @senswap/sen-js\n```\n\n## Usage\n\n```ts\nimport { Swap } from '@senswap/sen-js'\n// Or\n// const { Swap } = require('@senswap/sen-js')\n\nconst swapProgramAddress = '4erFSLP7oBFSVC1t35jdxmbfxEhYCKfoM6XdG2BLR3UF'\nconst spltProgramAddress = 'TokenkegQfeZyiNwAJbNbGKPFXCWuBvf9Ss623VQ5DA'\nconst splataProgramAddress = 'ATokenGPvbdGVxr1b2hvZbsiqW5xWH25efTNsLJA8knL'\nconst nodeUrl = 'https://api.devnet.solana.com'\nconst swap = new Swap(\n  swapProgramAddress,\n  spltProgramAddress,\n  splataProgramAddress,\n  nodeUrl\n)\n\n// Should be placed in an async wrapper\nconst poolData = await swap.getPoolData('9NodRcEmSxg2KMtPnFfzSvXGbBFXkRA4zgejhSGVpt9F')\nconsole.log(poolData)\n// {\n//   owner: \"8UaZw2jDhJzv5V53569JbCd3bD4BnyCfBH3sjwgajGS9\"\n//   state: 1\n//   mint_lpt: \"EsPTPmXhwpp5XjzCms6juqgrGCAhsTEaC47Lvm29RwTF\"\n//   taxman: \"8UaZw2jDhJzv5V53569JbCd3bD4BnyCfBH3sjwgajGS9\"\n//   mint_a: \"5YwUkPdXLoujGkZuo9B4LsLKj3hdkDcfP4derpspifSJ\"\n//   treasury_a: \"J9aSEQkAF3Umy6mipq9EppLLrKWS26q5m4HaV2KG8atv\"\n//   reserve_a: 3110702644000n\n//   mint_b: \"27hdcZv7RtuMp75vupThR3T4KLsL61t476eosMdoec4c\"\n//   treasury_b: \"9s2NgRPn4f7X6Kng4x8JEDcZ9kwphFg1kPD4oLQFEbM7\"\n//   reserve_b: 4570811590939n\n//   fee_ratio: 2500000n\n//   tax_ratio: 0n\n// }\n```\n\n## Testing\n\n```shell\nnpm test\n```\n\n## Related works\n\n### Soprox ABI\n\n* https://www.npmjs.com/package/soprox-abi\n* https://soprox.descartes.network/development/soproxabi\n\n### SenHub\n\n* https://docs.sentre.io/","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fdescartesnetwork%2Fsen-js","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fdescartesnetwork%2Fsen-js","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fdescartesnetwork%2Fsen-js/lists"}