{"id":26503984,"url":"https://github.com/jfkz/tinkoff-payment-sdk","last_synced_at":"2025-03-20T19:29:33.315Z","repository":{"id":42391077,"uuid":"363148532","full_name":"jfkz/tinkoff-payment-sdk","owner":"jfkz","description":"Tinkoff Payment SDK written in Typescript","archived":false,"fork":false,"pushed_at":"2025-02-02T12:50:55.000Z","size":318,"stargazers_count":16,"open_issues_count":2,"forks_count":5,"subscribers_count":3,"default_branch":"master","last_synced_at":"2025-03-14T09:18:06.901Z","etag":null,"topics":["api","merchant","sdk","tinkoff","tinkoff-api","tinkoff-payment","tinkoff-sdk","typescript"],"latest_commit_sha":null,"homepage":"https://oplata.tinkoff.ru/develop/api/payments/","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/jfkz.png","metadata":{"files":{"readme":"README.md","changelog":"CHANGELOG.md","contributing":null,"funding":".github/FUNDING.yml","license":"LICENSE","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},"funding":{"github":["jfkz"],"patreon":null,"open_collective":null,"ko_fi":"jfkz0","tidelift":null,"community_bridge":null,"liberapay":null,"issuehunt":null,"otechie":null,"custom":null}},"created_at":"2021-04-30T13:24:59.000Z","updated_at":"2025-03-04T08:07:46.000Z","dependencies_parsed_at":"2023-01-22T09:45:51.698Z","dependency_job_id":"46c86e7e-7b73-44c3-bae1-ca75c543f2c0","html_url":"https://github.com/jfkz/tinkoff-payment-sdk","commit_stats":{"total_commits":82,"total_committers":9,"mean_commits":9.11111111111111,"dds":"0.24390243902439024","last_synced_commit":"7f36519e6539fd61ef93c3af18776c22648d5a41"},"previous_names":[],"tags_count":19,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/jfkz%2Ftinkoff-payment-sdk","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/jfkz%2Ftinkoff-payment-sdk/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/jfkz%2Ftinkoff-payment-sdk/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/jfkz%2Ftinkoff-payment-sdk/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/jfkz","download_url":"https://codeload.github.com/jfkz/tinkoff-payment-sdk/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":244676454,"owners_count":20491828,"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":["api","merchant","sdk","tinkoff","tinkoff-api","tinkoff-payment","tinkoff-sdk","typescript"],"created_at":"2025-03-20T19:29:32.663Z","updated_at":"2025-03-20T19:29:33.310Z","avatar_url":"https://github.com/jfkz.png","language":"TypeScript","funding_links":["https://github.com/sponsors/jfkz","https://ko-fi.com/jfkz0"],"categories":[],"sub_categories":[],"readme":"# @jfkz/tinkoff-payment-sdk\n\n\u003c!-- NPM Badge --\u003e\n\u003ca href=\"https://www.npmjs.com/package/@jfkz/tinkoff-payment-sdk\"\u003e\n  \u003cimg src=\"https://badge.fury.io/js/%40jfkz%2Ftinkoff-payment-sdk.svg\" alt=\"npm version\" height=\"18\"\u003e\n\u003c/a\u003e\n\n\u003c!-- MIT License Badge --\u003e\n\u003ca href=\"https://opensource.org/licenses/MIT\"\u003e\n  \u003cimg src=\"https://img.shields.io/badge/License-MIT-yellow.svg\" alt=\"License: MIT\" height=\"20\"\u003e\n\u003c/a\u003e\n\nOriginal code: Slava Fomin II ([@slavafomin](https://github.com/slavafomin)).\n\nExtended version: [@jfkz](https://github.com/jfkz)\n\n---\n\nA Node.js SDK for Tinkoff Bank's Payment API.\n\n## Features\n\n- provides API client to communicate with Tinkoff API using HTTPS\n- provides Webhook handler to for easier webhook requests processing\n- HTTP transport agnostic (you can use any HTTP library),\n  [Got][Got] is supported out of the box\n- automatically transforms data to/from convenient JavaScript formats\n  (e.g. `string` to `Date`)\n- type-safe, written in TypeScript and ships with complete type declarations\n  for all data types and API requests/responses\n- support both CryptoPro and RSA signatures for [merchant API](https://acdn.tinkoff.ru/static/documents/merchant_api_protocoI_e2c.pdf) (actual at 06/15/2021)\n\n## Version difference\n\n- 0.x - old interface for Merchant provider, only CryptoPro is supported\n- 1.x - updated interface for Merchant provider, support both CryptoPro and RSA signatures for request signatures\n\n## Installation\n\nInstall the package:\n\n`npm i -S @jfkz/tinkoff-payment-sdk`\n\nInstall the [Got HTTP client][Got]\n(if you are not planning to provide custom implementation):\n\n`npm i -S got`\n\n## RSA key installation\n\nFollow the [official documentation](https://business.tinkoff.ru/openapi/docs#section/Sertifikaty/Vypusk-sertifikata).\n\n## CryptoPro installation and config\n\n1. Download and install CryptoPro 5+ from official site: https://www.cryptopro.ru/products/csp/downloads\n\n2. Configure stores and keys (working manual: http://pushorigin.ru/cryptopro/cryptcp)\n\n3. Configure MerchantApi with options.\n\nCryptoPro official manual: https://www.cryptopro.ru/sites/default/files/products/cryptcp/cryptcp_5.0.x.pdf\n\n**Remember:** CryptoPro algorithm use intensive file i/o operations by design. Please, reduce count of your operations and/or use fast drive when use this module.\n\n### Example: Init Payment\n\n```js\nimport {\n  PayType,\n  ApiManager,\n  RequestHttpClient,\n  InitPaymentResponsePayload\n} from '@jfkz/tinkoff-payment-sdk';\n\nimport Request from 'request-promise-native'; // need install\n\nconst config = {\n  terminal : 'TERMINAL_KEY',\n  password : 'PASSWORD'\n};\n\nconst ApiManagerInstance = new ApiManager({\n  httpClient : new RequestHttpClient({\n    request : Request\n  }),\n  terminalKey : config.terminal,\n  password : config.password\n});\n\nApiManagerInstance.initPayment({\n  OrderId: '1',\n  Amount: 10,\n  PayType: PayType.SingleStage,\n}).then((data : InitPaymentResponsePayload) =\u003e {\n  console.log('Init response:', data);\n});\n```\n\n### More examples\n\n@todo\n\n## License (MIT)\n\nCopyright (c) 2020 jfkz, Slava Fomin II\n\nPermission is hereby granted, free of charge, to any person obtaining a copy\nof this software and associated documentation files (the \"Software\"), to deal\nin the Software without restriction, including without limitation the rights\nto use, copy, modify, merge, publish, distribute, sublicense, and/or sell\ncopies of the Software, and to permit persons to whom the Software is\nfurnished to do so, subject to the following conditions:\n\nThe above copyright notice and this permission notice shall be included in all\ncopies or substantial portions of the Software.\n\nTHE SOFTWARE IS PROVIDED \"AS IS\", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR\nIMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,\nFITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE\nAUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER\nLIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,\nOUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE\nSOFTWARE.\n\n[Got]: https://github.com/sindresorhus/got\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fjfkz%2Ftinkoff-payment-sdk","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fjfkz%2Ftinkoff-payment-sdk","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fjfkz%2Ftinkoff-payment-sdk/lists"}