├── .env-sample ├── .eslintignore ├── .eslintrc.js ├── .gitignore ├── .npmignore ├── Gruntfile.js ├── LICENSE ├── README.md ├── dist ├── nowpayments-api-js.js ├── nowpayments-api-js.js.map ├── nowpayments-api-js.min.js └── nowpayments-api-js.min.js.map ├── examples ├── .DS_Store ├── html │ ├── index.html │ └── style.css └── node │ ├── index.js │ ├── node_modules │ └── @nowpayments │ │ └── nowpayments-api │ └── package.json ├── package-lock.json ├── package.json ├── src ├── actions │ ├── create-invoice │ │ ├── index.d.ts │ │ └── index.ts │ ├── create-payment │ │ ├── index.d.ts │ │ └── index.ts │ ├── get-currencies │ │ ├── index.d.ts │ │ └── index.ts │ ├── get-estimate-price │ │ ├── index.d.ts │ │ └── index.ts │ ├── get-list-payments │ │ ├── index.d.ts │ │ └── index.ts │ ├── get-minimum-payment-amount │ │ ├── index.d.ts │ │ └── index.ts │ ├── get-payment-status │ │ ├── index.d.ts │ │ └── index.ts │ ├── index.d.ts │ ├── index.ts │ └── status │ │ ├── index.d.ts │ │ └── index.ts ├── index.d.ts ├── index.ts ├── types.d.ts ├── types.ts └── utils │ ├── connect-api.d.ts │ └── connect-api.ts ├── tsconfig.json ├── tsconfig.tsbuildinfo ├── tslint.json └── webpack.config.js /.env-sample: -------------------------------------------------------------------------------- 1 | NODE_ENV=production -------------------------------------------------------------------------------- /.eslintignore: -------------------------------------------------------------------------------- 1 | dist/* -------------------------------------------------------------------------------- /.eslintrc.js: -------------------------------------------------------------------------------- 1 | module.exports = { 2 | env: { 3 | node: true, 4 | jest: true, 5 | browser: true 6 | }, 7 | extends: [ 8 | 'standard-with-typescript' 9 | ], 10 | parserOptions: { 11 | ecmaVersion: 11, 12 | project: './tsconfig.json' 13 | }, 14 | ignorePatterns: ['*.d.ts'], 15 | rules: { 16 | 'object-curly-spacing': 'off', 17 | '@typescript-eslint/object-curly-spacing': ['error', 'always'], 18 | 'space-before-function-paren': 'off', 19 | '@typescript-eslint/space-before-function-paren': 'off', 20 | '@typescript-eslint/naming-convention': 'off', 21 | '@typescript-eslint/explicit-function-return-type': 'off', 22 | '@typescript-eslint/no-var-requires': [0], 23 | '@typescript-eslint/strict-boolean-expressions': [0], 24 | '@typescript-eslint/consistent-type-assertions': ['error', { assertionStyle: 'angle-bracket' }], 25 | 'no-void': [0], 26 | 'import/order': ['error', { 27 | 'newlines-between': 'always-and-inside-groups' 28 | }] 29 | } 30 | } 31 | -------------------------------------------------------------------------------- /.gitignore: -------------------------------------------------------------------------------- 1 | node_modules/* 2 | .idea 3 | .env 4 | .DS_Store -------------------------------------------------------------------------------- /.npmignore: -------------------------------------------------------------------------------- 1 | docs/ 2 | examples/ 3 | reports/ 4 | test/ 5 | .idea -------------------------------------------------------------------------------- /Gruntfile.js: -------------------------------------------------------------------------------- 1 | module.exports = function (grunt) { 2 | require('load-grunt-tasks')(grunt) 3 | 4 | grunt.initConfig({ 5 | pkg: grunt.file.readJSON('package.json'), 6 | 7 | clean: { 8 | dist: 'dist/**' 9 | }, 10 | 11 | ts: { 12 | test: { 13 | options: { 14 | lib: [ 15 | 'es5', 16 | 'es2015', 17 | 'dom' 18 | ] 19 | }, 20 | src: ['src/index.d.ts', 'src/index.ts'] 21 | } 22 | }, 23 | 24 | watch: { 25 | build: { 26 | files: ['src/*.ts'], 27 | tasks: ['build'] 28 | } 29 | }, 30 | 31 | webpack: require('./webpack.config.js') 32 | }) 33 | 34 | grunt.registerTask('test', 'Run the jasmine and mocha tests', ['eslint', 'ts']) 35 | grunt.registerTask('build', 'Run webpack and bundle the source', ['clean', 'webpack']) 36 | } 37 | -------------------------------------------------------------------------------- /LICENSE: -------------------------------------------------------------------------------- 1 | MIT License 2 | 3 | Copyright (c) 2021 info@nowpayments.io 4 | 5 | Permission is hereby granted, free of charge, to any person obtaining a copy 6 | of this software and associated documentation files (the "Software"), to deal 7 | in the Software without restriction, including without limitation the rights 8 | to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 9 | copies of the Software, and to permit persons to whom the Software is 10 | furnished to do so, subject to the following conditions: 11 | 12 | The above copyright notice and this permission notice shall be included in all 13 | copies or substantial portions of the Software. 14 | 15 | THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 16 | IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 17 | FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 18 | AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 19 | LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 20 | OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE 21 | SOFTWARE. -------------------------------------------------------------------------------- /README.md: -------------------------------------------------------------------------------- 1 | # NOWPayments API 2 | 3 | [![Build Status](https://travis-ci.org/joemccann/dillinger.svg?branch=master)](https://travis-ci.org/joemccann/dillinger) 4 | 5 | A library for interacting with the NOWPayments API. 6 | 7 | ## Installation 8 | 9 | Using npm: 10 | 11 | ```bash 12 | $ npm install @nowpaymentsio/nowpayments-api-js 13 | ``` 14 | 15 | Using unpkg CDN: 16 | 17 | ```html 18 | 19 | ``` 20 | 21 | ## Examples 22 | 23 | ### Node JS 24 | 25 | ```js 26 | const NowPaymentsApi = require('@nowpaymentsio/nowpayments-api-js'); 27 | 28 | const api = new NowPaymentsApi({ apiKey: 'A7M40XV-CG1448Z-KVVED3G-NW3V0TK' }) // your api key 29 | async function logCurrencies() { 30 | const { currencies } = await api.getCurrencies() 31 | console.log(currencies) 32 | } 33 | logCurrencies() 34 | ``` 35 | 36 | ### React 37 | 38 | ```js 39 | import React from 'react' 40 | import NowPaymentsApi from '@nowpaymentsio/nowpayments-api-js' 41 | 42 | const npApi = new NowPaymentsApi({ apiKey: 'A7M40XV-CG1448Z-KVVED3G-NW3V0TK' }) // your api key 43 | 44 | const App = () => { 45 | const [currenciesArr, setCurrenciesArr] = React.useState([]) 46 | React.useEffect(() => { 47 | async function fetchCurrencies() { 48 | const { currencies } = await npApi.getCurrencies() 49 | setCurrenciesArr(currencies) 50 | } 51 | fetchCurrencies() 52 | }, []) 53 | 54 | return ( 55 |
56 |

Available currencies

57 |
58 | {currenciesArr.map((currency) => ( 59 |

{currency}

60 | ))} 61 |
62 | ) 63 | } 64 | 65 | export default App 66 | ``` 67 | ### HTML 68 | ```html 69 | 70 | 71 | 72 | 73 | 74 | 75 | 76 | NOWPayments API - HTML Example 77 | 78 | 79 | 80 | 81 |

Available currencies

82 | 101 | 102 | 103 | ``` 104 | ## Methods 105 |   106 | #### NPApi.status() 107 | Get API status 108 | **params** | **default** | **required** | **description** 109 | ------------------|-------------|--------------|-------------------------------------------------------- 110 |   |   |   |   111 | 112 | #### NPApi.getCurrencies() 113 | Get available currencies 114 | **params** | **default** | **required** | **description** 115 | ------------------|-------------|--------------|-------------------------------------------------------- 116 |   |   |   |   117 | 118 | #### NPApi.getEstimatePrice(params) 119 | Get estimated price 120 | **params** | **default** | **required** | **description** 121 | ------------------|-------------|--------------|-------------------------------------------------------- 122 | amount | null | true | Initial cost in the fiat currency 123 | 124 | #### NPApi.createPayment(params) 125 | Create payment 126 | **params** | **default** | **required** | **description** 127 | ------------------|-------------|--------------|-------------------------------------------------------- 128 | price_amount | null | true | Fiat equivalent of the price to be paid in crypto 129 | price_currency | null | true | Fiat currency in which the price_amount is specified (usd, eur, etc) 130 | pay_amount | null | false | Amount that users have to pay for the order stated in crypto 131 | pay_currency | null | true | Crypto currency in which the pay_amount is specified (btc, eth, etc) 132 | ipn_callback_url | null | false | Url to receive callbacks, should contain "http" or "https", eg. "https://nowpayments.io" 133 | order_id | null | false | Inner store order ID, e.g. "RGDBP-21314" 134 | order_description | null | false | Inner store order description, e.g. "Apple Macbook Pro 2019 x 1" 135 | purchase_id | null | false | Id of purchase for which you want to create aother 136 | payout_address | null | false | Usually the funds will go to the address you specify in your Personal account. In case you want to receive funds on another address, you can specify it in this parameter 137 | payout_currency | null | false | Currency of your external payout_address, required when payout_adress is specified 138 | payout_extra_id | null | false | Extra id or memo or tag for external payout_address 139 | fixed_rate | null | false | Boolean, can be true or false. Required for fixed-rate exchanges 140 | 141 | #### NPApi.getPaymentStatus(params) 142 | Get payment status 143 | **params** | **default** | **required** | **description** 144 | ------------------|-------------|--------------|-------------------------------------------------------- 145 | payment_id | null | true | ID of the payment 146 | 147 | #### NPApi.getMinimumPaymentAmount(params) 148 | Get the minimum payment amount 149 | **params** | **default** | **required** | **description** 150 | ------------------|-------------|--------------|-------------------------------------------------------- 151 | currency_from | null | true | Ticker currency 152 | currency_to | null | true | Ticker currency 153 | 154 | #### NPApi.getListPayments(params) 155 | Get list of payments 156 | **params** | **default** | **required** | **description** 157 | ------------------|-------------|--------------|-------------------------------------------------------- 158 | limit | 10 | false | Number of records in one page 159 | page | 0 | false | Page number you want to get 160 | sortBy | created_at | false | Sort the received list by a paramenter. 161 | orderBy | asc | false | Display the list in ascending or descending order 162 | dateFrom | null | false | Select the displayed period start date (date format: YYYY-MM-DD or yy-MM-ddTHH:mm:ss.SSSZ) 163 | dateTo | null | false | Select the displayed period end date (date format: YYYY-MM-DD or yy-MM-ddTHH:mm:ss.SSSZ) 164 | 165 | #### NPApi.createInvoice(params) 166 | Create invoice 167 | **params** | **default** | **required** | **description** 168 | ------------------|-------------|--------------|-------------------------------------------------------- 169 | price_amount | null | true | He amount that users have to pay for the order stated in fiat currency. In case you do not indicate the price in crypto, our system will automatically convert this fiat amount in crypto equivalent 170 | price_currency | null | true | The fiat currency in which the price_amount is specified (usd, eur, etc) 171 | pay_currency | null | false | The crypto currency in which the pay_amount is specified (btc, eth, etc).If not specified, can be choosen on the invoice_url 172 | ipn_callback_url | null | false | Url to receive callbacks, should contain "http" or "https", eg. "https://nowpayments.io" 173 | order_id | null | false | Inner store order ID, e.g. "RGDBP-21314" 174 | order_description | null | false | Inner store order description, e.g. "Apple Macbook Pro 2019 x 1" 175 | success_url | null | false | Url where the customer will be redirected after sucesfull payment 176 | cancel_url | null | false | Url where the customer will be redirected after failed payment 177 | 178 | ## Resources 179 | 180 | * [Documentation API](https://documenter.getpostman.com/view/7907941/S1a32n38) -------------------------------------------------------------------------------- /dist/nowpayments-api-js.min.js: -------------------------------------------------------------------------------- 1 | !function(e,t){"object"==typeof exports&&"object"==typeof module?module.exports=t():"function"==typeof define&&define.amd?define("NOWPaymentsApiJS",[],t):"object"==typeof exports?exports.NOWPaymentsApiJS=t():e.NOWPaymentsApiJS=t()}(this,(function(){return e={9669:(e,t,r)=>{e.exports=r(1609)},7970:(e,t,r)=>{"use strict";var n=r(4867),o=r(6026),s=r(4097),i=r(5327),a=r(8605),u=r(7211),c=r(938).http,l=r(938).https,f=r(8835),p=r(8761),h=r(696),d=r(5061),m=r(481),y=/https:?/;function v(e,t,r){if(e.hostname=t.host,e.host=t.host,e.port=t.port,e.path=r,t.auth){var n=Buffer.from(t.auth.username+":"+t.auth.password,"utf8").toString("base64");e.headers["Proxy-Authorization"]="Basic "+n}e.beforeRedirect=function(e){e.headers.host=e.host,v(e,t,e.href)}}e.exports=function(e){return new Promise((function(t,r){var _=function(e){t(e)},b=function(e){r(e)},g=e.data,w=e.headers;if(w["User-Agent"]||w["user-agent"]||(w["User-Agent"]="axios/"+h.version),g&&!n.isStream(g)){if(Buffer.isBuffer(g));else if(n.isArrayBuffer(g))g=Buffer.from(new Uint8Array(g));else{if(!n.isString(g))return b(d("Data after transformation must be a string, an ArrayBuffer, a Buffer, or a Stream",e));g=Buffer.from(g,"utf-8")}w["Content-Length"]=g.length}var x=void 0;e.auth&&(x=(e.auth.username||"")+":"+(e.auth.password||""));var C=s(e.baseURL,e.url),R=f.parse(C),E=R.protocol||"http:";if(!x&&R.auth){var k=R.auth.split(":");x=(k[0]||"")+":"+(k[1]||"")}x&&delete w.Authorization;var O=y.test(E),F=O?e.httpsAgent:e.httpAgent,S={path:i(R.path,e.params,e.paramsSerializer).replace(/^\?/,""),method:e.method.toUpperCase(),headers:w,agent:F,agents:{http:e.httpAgent,https:e.httpsAgent},auth:x};e.socketPath?S.socketPath=e.socketPath:(S.hostname=R.hostname,S.port=R.port);var j,A=e.proxy;if(!A&&!1!==A){var T=E.slice(0,-1)+"_proxy",P=process.env[T]||process.env[T.toUpperCase()];if(P){var B=f.parse(P),q=process.env.no_proxy||process.env.NO_PROXY,L=!0;if(q&&(L=!q.split(",").map((function(e){return e.trim()})).some((function(e){return!!e&&("*"===e||"."===e[0]&&R.hostname.substr(R.hostname.length-e.length)===e||R.hostname===e)}))),L&&(A={host:B.hostname,port:B.port,protocol:B.protocol},B.auth)){var N=B.auth.split(":");A.auth={username:N[0],password:N[1]}}}}A&&(S.headers.host=R.hostname+(R.port?":"+R.port:""),v(S,A,E+"//"+R.hostname+(R.port?":"+R.port:"")+S.path));var M=O&&(!A||y.test(A.protocol));e.transport?j=e.transport:0===e.maxRedirects?j=M?u:a:(e.maxRedirects&&(S.maxRedirects=e.maxRedirects),j=M?l:c),e.maxBodyLength>-1&&(S.maxBodyLength=e.maxBodyLength);var U=j.request(S,(function(t){if(!U.aborted){var r=t,s=t.req||U;if(204!==t.statusCode&&"HEAD"!==s.method&&!1!==e.decompress)switch(t.headers["content-encoding"]){case"gzip":case"compress":case"deflate":r=r.pipe(p.createUnzip()),delete t.headers["content-encoding"]}var i={status:t.statusCode,statusText:t.statusMessage,headers:t.headers,config:e,request:s};if("stream"===e.responseType)i.data=r,o(_,b,i);else{var a=[];r.on("data",(function(t){a.push(t),e.maxContentLength>-1&&Buffer.concat(a).length>e.maxContentLength&&(r.destroy(),b(d("maxContentLength size of "+e.maxContentLength+" exceeded",e,null,s)))})),r.on("error",(function(t){U.aborted||b(m(t,e,null,s))})),r.on("end",(function(){var t=Buffer.concat(a);"arraybuffer"!==e.responseType&&(t=t.toString(e.responseEncoding),e.responseEncoding&&"utf8"!==e.responseEncoding||(t=n.stripBOM(t))),i.data=t,o(_,b,i)}))}}}));U.on("error",(function(t){U.aborted&&"ERR_FR_TOO_MANY_REDIRECTS"!==t.code||b(m(t,e,null,U))})),e.timeout&&U.setTimeout(e.timeout,(function(){U.abort(),b(d("timeout of "+e.timeout+"ms exceeded",e,"ECONNABORTED",U))})),e.cancelToken&&e.cancelToken.promise.then((function(e){U.aborted||(U.abort(),b(e))})),n.isStream(g)?g.on("error",(function(t){b(m(t,e,null,U))})).pipe(U):U.end(g)}))}},5448:(e,t,r)=>{"use strict";var n=r(4867),o=r(6026),s=r(4372),i=r(5327),a=r(4097),u=r(4109),c=r(7985),l=r(5061);e.exports=function(e){return new Promise((function(t,r){var f=e.data,p=e.headers;n.isFormData(f)&&delete p["Content-Type"];var h=new XMLHttpRequest;if(e.auth){var d=e.auth.username||"",m=e.auth.password?unescape(encodeURIComponent(e.auth.password)):"";p.Authorization="Basic "+btoa(d+":"+m)}var y=a(e.baseURL,e.url);if(h.open(e.method.toUpperCase(),i(y,e.params,e.paramsSerializer),!0),h.timeout=e.timeout,h.onreadystatechange=function(){if(h&&4===h.readyState&&(0!==h.status||h.responseURL&&0===h.responseURL.indexOf("file:"))){var n="getAllResponseHeaders"in h?u(h.getAllResponseHeaders()):null,s={data:e.responseType&&"text"!==e.responseType?h.response:h.responseText,status:h.status,statusText:h.statusText,headers:n,config:e,request:h};o(t,r,s),h=null}},h.onabort=function(){h&&(r(l("Request aborted",e,"ECONNABORTED",h)),h=null)},h.onerror=function(){r(l("Network Error",e,null,h)),h=null},h.ontimeout=function(){var t="timeout of "+e.timeout+"ms exceeded";e.timeoutErrorMessage&&(t=e.timeoutErrorMessage),r(l(t,e,"ECONNABORTED",h)),h=null},n.isStandardBrowserEnv()){var v=(e.withCredentials||c(y))&&e.xsrfCookieName?s.read(e.xsrfCookieName):void 0;v&&(p[e.xsrfHeaderName]=v)}if("setRequestHeader"in h&&n.forEach(p,(function(e,t){void 0===f&&"content-type"===t.toLowerCase()?delete p[t]:h.setRequestHeader(t,e)})),n.isUndefined(e.withCredentials)||(h.withCredentials=!!e.withCredentials),e.responseType)try{h.responseType=e.responseType}catch(t){if("json"!==e.responseType)throw t}"function"==typeof e.onDownloadProgress&&h.addEventListener("progress",e.onDownloadProgress),"function"==typeof e.onUploadProgress&&h.upload&&h.upload.addEventListener("progress",e.onUploadProgress),e.cancelToken&&e.cancelToken.promise.then((function(e){h&&(h.abort(),r(e),h=null)})),f||(f=null),h.send(f)}))}},1609:(e,t,r)=>{"use strict";var n=r(4867),o=r(1849),s=r(321),i=r(7185);function a(e){var t=new s(e),r=o(s.prototype.request,t);return n.extend(r,s.prototype,t),n.extend(r,t),r}var u=a(r(5655));u.Axios=s,u.create=function(e){return a(i(u.defaults,e))},u.Cancel=r(5263),u.CancelToken=r(4972),u.isCancel=r(6502),u.all=function(e){return Promise.all(e)},u.spread=r(8713),u.isAxiosError=r(6268),e.exports=u,e.exports.default=u},5263:e=>{"use strict";function t(e){this.message=e}t.prototype.toString=function(){return"Cancel"+(this.message?": "+this.message:"")},t.prototype.__CANCEL__=!0,e.exports=t},4972:(e,t,r)=>{"use strict";var n=r(5263);function o(e){if("function"!=typeof e)throw new TypeError("executor must be a function.");var t;this.promise=new Promise((function(e){t=e}));var r=this;e((function(e){r.reason||(r.reason=new n(e),t(r.reason))}))}o.prototype.throwIfRequested=function(){if(this.reason)throw this.reason},o.source=function(){var e;return{token:new o((function(t){e=t})),cancel:e}},e.exports=o},6502:e=>{"use strict";e.exports=function(e){return!(!e||!e.__CANCEL__)}},321:(e,t,r)=>{"use strict";var n=r(4867),o=r(5327),s=r(782),i=r(3572),a=r(7185);function u(e){this.defaults=e,this.interceptors={request:new s,response:new s}}u.prototype.request=function(e){"string"==typeof e?(e=arguments[1]||{}).url=arguments[0]:e=e||{},(e=a(this.defaults,e)).method?e.method=e.method.toLowerCase():this.defaults.method?e.method=this.defaults.method.toLowerCase():e.method="get";var t=[i,void 0],r=Promise.resolve(e);for(this.interceptors.request.forEach((function(e){t.unshift(e.fulfilled,e.rejected)})),this.interceptors.response.forEach((function(e){t.push(e.fulfilled,e.rejected)}));t.length;)r=r.then(t.shift(),t.shift());return r},u.prototype.getUri=function(e){return e=a(this.defaults,e),o(e.url,e.params,e.paramsSerializer).replace(/^\?/,"")},n.forEach(["delete","get","head","options"],(function(e){u.prototype[e]=function(t,r){return this.request(a(r||{},{method:e,url:t,data:(r||{}).data}))}})),n.forEach(["post","put","patch"],(function(e){u.prototype[e]=function(t,r,n){return this.request(a(n||{},{method:e,url:t,data:r}))}})),e.exports=u},782:(e,t,r)=>{"use strict";var n=r(4867);function o(){this.handlers=[]}o.prototype.use=function(e,t){return this.handlers.push({fulfilled:e,rejected:t}),this.handlers.length-1},o.prototype.eject=function(e){this.handlers[e]&&(this.handlers[e]=null)},o.prototype.forEach=function(e){n.forEach(this.handlers,(function(t){null!==t&&e(t)}))},e.exports=o},4097:(e,t,r)=>{"use strict";var n=r(1793),o=r(7303);e.exports=function(e,t){return e&&!n(t)?o(e,t):t}},5061:(e,t,r)=>{"use strict";var n=r(481);e.exports=function(e,t,r,o,s){var i=new Error(e);return n(i,t,r,o,s)}},3572:(e,t,r)=>{"use strict";var n=r(4867),o=r(8527),s=r(6502),i=r(5655);function a(e){e.cancelToken&&e.cancelToken.throwIfRequested()}e.exports=function(e){return a(e),e.headers=e.headers||{},e.data=o(e.data,e.headers,e.transformRequest),e.headers=n.merge(e.headers.common||{},e.headers[e.method]||{},e.headers),n.forEach(["delete","get","head","post","put","patch","common"],(function(t){delete e.headers[t]})),(e.adapter||i.adapter)(e).then((function(t){return a(e),t.data=o(t.data,t.headers,e.transformResponse),t}),(function(t){return s(t)||(a(e),t&&t.response&&(t.response.data=o(t.response.data,t.response.headers,e.transformResponse))),Promise.reject(t)}))}},481:e=>{"use strict";e.exports=function(e,t,r,n,o){return e.config=t,r&&(e.code=r),e.request=n,e.response=o,e.isAxiosError=!0,e.toJSON=function(){return{message:this.message,name:this.name,description:this.description,number:this.number,fileName:this.fileName,lineNumber:this.lineNumber,columnNumber:this.columnNumber,stack:this.stack,config:this.config,code:this.code}},e}},7185:(e,t,r)=>{"use strict";var n=r(4867);e.exports=function(e,t){t=t||{};var r={},o=["url","method","data"],s=["headers","auth","proxy","params"],i=["baseURL","transformRequest","transformResponse","paramsSerializer","timeout","timeoutMessage","withCredentials","adapter","responseType","xsrfCookieName","xsrfHeaderName","onUploadProgress","onDownloadProgress","decompress","maxContentLength","maxBodyLength","maxRedirects","transport","httpAgent","httpsAgent","cancelToken","socketPath","responseEncoding"],a=["validateStatus"];function u(e,t){return n.isPlainObject(e)&&n.isPlainObject(t)?n.merge(e,t):n.isPlainObject(t)?n.merge({},t):n.isArray(t)?t.slice():t}function c(o){n.isUndefined(t[o])?n.isUndefined(e[o])||(r[o]=u(void 0,e[o])):r[o]=u(e[o],t[o])}n.forEach(o,(function(e){n.isUndefined(t[e])||(r[e]=u(void 0,t[e]))})),n.forEach(s,c),n.forEach(i,(function(o){n.isUndefined(t[o])?n.isUndefined(e[o])||(r[o]=u(void 0,e[o])):r[o]=u(void 0,t[o])})),n.forEach(a,(function(n){n in t?r[n]=u(e[n],t[n]):n in e&&(r[n]=u(void 0,e[n]))}));var l=o.concat(s).concat(i).concat(a),f=Object.keys(e).concat(Object.keys(t)).filter((function(e){return-1===l.indexOf(e)}));return n.forEach(f,c),r}},6026:(e,t,r)=>{"use strict";var n=r(5061);e.exports=function(e,t,r){var o=r.config.validateStatus;r.status&&o&&!o(r.status)?t(n("Request failed with status code "+r.status,r.config,null,r.request,r)):e(r)}},8527:(e,t,r)=>{"use strict";var n=r(4867);e.exports=function(e,t,r){return n.forEach(r,(function(r){e=r(e,t)})),e}},5655:(e,t,r)=>{"use strict";var n=r(4867),o=r(6016),s={"Content-Type":"application/x-www-form-urlencoded"};function i(e,t){!n.isUndefined(e)&&n.isUndefined(e["Content-Type"])&&(e["Content-Type"]=t)}var a,u={adapter:("undefined"!=typeof XMLHttpRequest?a=r(5448):"undefined"!=typeof process&&"[object process]"===Object.prototype.toString.call(process)&&(a=r(7970)),a),transformRequest:[function(e,t){return o(t,"Accept"),o(t,"Content-Type"),n.isFormData(e)||n.isArrayBuffer(e)||n.isBuffer(e)||n.isStream(e)||n.isFile(e)||n.isBlob(e)?e:n.isArrayBufferView(e)?e.buffer:n.isURLSearchParams(e)?(i(t,"application/x-www-form-urlencoded;charset=utf-8"),e.toString()):n.isObject(e)?(i(t,"application/json;charset=utf-8"),JSON.stringify(e)):e}],transformResponse:[function(e){if("string"==typeof e)try{e=JSON.parse(e)}catch(e){}return e}],timeout:0,xsrfCookieName:"XSRF-TOKEN",xsrfHeaderName:"X-XSRF-TOKEN",maxContentLength:-1,maxBodyLength:-1,validateStatus:function(e){return e>=200&&e<300},headers:{common:{Accept:"application/json, text/plain, */*"}}};n.forEach(["delete","get","head"],(function(e){u.headers[e]={}})),n.forEach(["post","put","patch"],(function(e){u.headers[e]=n.merge(s)})),e.exports=u},1849:e=>{"use strict";e.exports=function(e,t){return function(){for(var r=new Array(arguments.length),n=0;n{"use strict";var n=r(4867);function o(e){return encodeURIComponent(e).replace(/%3A/gi,":").replace(/%24/g,"$").replace(/%2C/gi,",").replace(/%20/g,"+").replace(/%5B/gi,"[").replace(/%5D/gi,"]")}e.exports=function(e,t,r){if(!t)return e;var s;if(r)s=r(t);else if(n.isURLSearchParams(t))s=t.toString();else{var i=[];n.forEach(t,(function(e,t){null!=e&&(n.isArray(e)?t+="[]":e=[e],n.forEach(e,(function(e){n.isDate(e)?e=e.toISOString():n.isObject(e)&&(e=JSON.stringify(e)),i.push(o(t)+"="+o(e))})))})),s=i.join("&")}if(s){var a=e.indexOf("#");-1!==a&&(e=e.slice(0,a)),e+=(-1===e.indexOf("?")?"?":"&")+s}return e}},7303:e=>{"use strict";e.exports=function(e,t){return t?e.replace(/\/+$/,"")+"/"+t.replace(/^\/+/,""):e}},4372:(e,t,r)=>{"use strict";var n=r(4867);e.exports=n.isStandardBrowserEnv()?{write:function(e,t,r,o,s,i){var a=[];a.push(e+"="+encodeURIComponent(t)),n.isNumber(r)&&a.push("expires="+new Date(r).toGMTString()),n.isString(o)&&a.push("path="+o),n.isString(s)&&a.push("domain="+s),!0===i&&a.push("secure"),document.cookie=a.join("; ")},read:function(e){var t=document.cookie.match(new RegExp("(^|;\\s*)("+e+")=([^;]*)"));return t?decodeURIComponent(t[3]):null},remove:function(e){this.write(e,"",Date.now()-864e5)}}:{write:function(){},read:function(){return null},remove:function(){}}},1793:e=>{"use strict";e.exports=function(e){return/^([a-z][a-z\d\+\-\.]*:)?\/\//i.test(e)}},6268:e=>{"use strict";e.exports=function(e){return"object"==typeof e&&!0===e.isAxiosError}},7985:(e,t,r)=>{"use strict";var n=r(4867);e.exports=n.isStandardBrowserEnv()?function(){var e,t=/(msie|trident)/i.test(navigator.userAgent),r=document.createElement("a");function o(e){var n=e;return t&&(r.setAttribute("href",n),n=r.href),r.setAttribute("href",n),{href:r.href,protocol:r.protocol?r.protocol.replace(/:$/,""):"",host:r.host,search:r.search?r.search.replace(/^\?/,""):"",hash:r.hash?r.hash.replace(/^#/,""):"",hostname:r.hostname,port:r.port,pathname:"/"===r.pathname.charAt(0)?r.pathname:"/"+r.pathname}}return e=o(window.location.href),function(t){var r=n.isString(t)?o(t):t;return r.protocol===e.protocol&&r.host===e.host}}():function(){return!0}},6016:(e,t,r)=>{"use strict";var n=r(4867);e.exports=function(e,t){n.forEach(e,(function(r,n){n!==t&&n.toUpperCase()===t.toUpperCase()&&(e[t]=r,delete e[n])}))}},4109:(e,t,r)=>{"use strict";var n=r(4867),o=["age","authorization","content-length","content-type","etag","expires","from","host","if-modified-since","if-unmodified-since","last-modified","location","max-forwards","proxy-authorization","referer","retry-after","user-agent"];e.exports=function(e){var t,r,s,i={};return e?(n.forEach(e.split("\n"),(function(e){if(s=e.indexOf(":"),t=n.trim(e.substr(0,s)).toLowerCase(),r=n.trim(e.substr(s+1)),t){if(i[t]&&o.indexOf(t)>=0)return;i[t]="set-cookie"===t?(i[t]?i[t]:[]).concat([r]):i[t]?i[t]+", "+r:r}})),i):i}},8713:e=>{"use strict";e.exports=function(e){return function(t){return e.apply(null,t)}}},4867:(e,t,r)=>{"use strict";var n=r(1849),o=Object.prototype.toString;function s(e){return"[object Array]"===o.call(e)}function i(e){return void 0===e}function a(e){return null!==e&&"object"==typeof e}function u(e){if("[object Object]"!==o.call(e))return!1;var t=Object.getPrototypeOf(e);return null===t||t===Object.prototype}function c(e){return"[object Function]"===o.call(e)}function l(e,t){if(null!=e)if("object"!=typeof e&&(e=[e]),s(e))for(var r=0,n=e.length;r{"use strict";e.exports=JSON.parse('{"_args":[["axios@0.21.1","/Users/bogdanaksenov/Desktop/nowpayments/nowpayments-api-npm-package"]],"_from":"axios@0.21.1","_id":"axios@0.21.1","_inBundle":false,"_integrity":"sha512-dKQiRHxGD9PPRIUNIWvZhPTPpl1rf/OxTYKsqKUDjBwYylTvV7SjSHJb9ratfyzM6wCdLCOYLzs73qpg5c4iGA==","_location":"/axios","_phantomChildren":{},"_requested":{"type":"version","registry":true,"raw":"axios@0.21.1","name":"axios","escapedName":"axios","rawSpec":"0.21.1","saveSpec":null,"fetchSpec":"0.21.1"},"_requiredBy":["/"],"_resolved":"https://registry.npmjs.org/axios/-/axios-0.21.1.tgz","_spec":"0.21.1","_where":"/Users/bogdanaksenov/Desktop/nowpayments/nowpayments-api-npm-package","author":{"name":"Matt Zabriskie"},"browser":{"./lib/adapters/http.js":"./lib/adapters/xhr.js"},"bugs":{"url":"https://github.com/axios/axios/issues"},"bundlesize":[{"path":"./dist/axios.min.js","threshold":"5kB"}],"dependencies":{"follow-redirects":"^1.10.0"},"description":"Promise based HTTP client for the browser and node.js","devDependencies":{"bundlesize":"^0.17.0","coveralls":"^3.0.0","es6-promise":"^4.2.4","grunt":"^1.0.2","grunt-banner":"^0.6.0","grunt-cli":"^1.2.0","grunt-contrib-clean":"^1.1.0","grunt-contrib-watch":"^1.0.0","grunt-eslint":"^20.1.0","grunt-karma":"^2.0.0","grunt-mocha-test":"^0.13.3","grunt-ts":"^6.0.0-beta.19","grunt-webpack":"^1.0.18","istanbul-instrumenter-loader":"^1.0.0","jasmine-core":"^2.4.1","karma":"^1.3.0","karma-chrome-launcher":"^2.2.0","karma-coverage":"^1.1.1","karma-firefox-launcher":"^1.1.0","karma-jasmine":"^1.1.1","karma-jasmine-ajax":"^0.1.13","karma-opera-launcher":"^1.0.0","karma-safari-launcher":"^1.0.0","karma-sauce-launcher":"^1.2.0","karma-sinon":"^1.0.5","karma-sourcemap-loader":"^0.3.7","karma-webpack":"^1.7.0","load-grunt-tasks":"^3.5.2","minimist":"^1.2.0","mocha":"^5.2.0","sinon":"^4.5.0","typescript":"^2.8.1","url-search-params":"^0.10.0","webpack":"^1.13.1","webpack-dev-server":"^1.14.1"},"homepage":"https://github.com/axios/axios","jsdelivr":"dist/axios.min.js","keywords":["xhr","http","ajax","promise","node"],"license":"MIT","main":"index.js","name":"axios","repository":{"type":"git","url":"git+https://github.com/axios/axios.git"},"scripts":{"build":"NODE_ENV=production grunt build","coveralls":"cat coverage/lcov.info | ./node_modules/coveralls/bin/coveralls.js","examples":"node ./examples/server.js","fix":"eslint --fix lib/**/*.js","postversion":"git push && git push --tags","preversion":"npm test","start":"node ./sandbox/server.js","test":"grunt test && bundlesize","version":"npm run build && grunt version && git add -A dist && git add CHANGELOG.md bower.json package.json"},"typings":"./index.d.ts","unpkg":"dist/axios.min.js","version":"0.21.1"}')},1227:(e,t,r)=>{t.formatArgs=function(t){if(t[0]=(this.useColors?"%c":"")+this.namespace+(this.useColors?" %c":" ")+t[0]+(this.useColors?"%c ":" ")+"+"+e.exports.humanize(this.diff),!this.useColors)return;const r="color: "+this.color;t.splice(1,0,r,"color: inherit");let n=0,o=0;t[0].replace(/%[a-zA-Z%]/g,(e=>{"%%"!==e&&(n++,"%c"===e&&(o=n))})),t.splice(o,0,r)},t.save=function(e){try{e?t.storage.setItem("debug",e):t.storage.removeItem("debug")}catch(e){}},t.load=function(){let e;try{e=t.storage.getItem("debug")}catch(e){}return!e&&"undefined"!=typeof process&&"env"in process&&(e=process.env.DEBUG),e},t.useColors=function(){return!("undefined"==typeof window||!window.process||"renderer"!==window.process.type&&!window.process.__nwjs)||("undefined"==typeof navigator||!navigator.userAgent||!navigator.userAgent.toLowerCase().match(/(edge|trident)\/(\d+)/))&&("undefined"!=typeof document&&document.documentElement&&document.documentElement.style&&document.documentElement.style.WebkitAppearance||"undefined"!=typeof window&&window.console&&(window.console.firebug||window.console.exception&&window.console.table)||"undefined"!=typeof navigator&&navigator.userAgent&&navigator.userAgent.toLowerCase().match(/firefox\/(\d+)/)&&parseInt(RegExp.$1,10)>=31||"undefined"!=typeof navigator&&navigator.userAgent&&navigator.userAgent.toLowerCase().match(/applewebkit\/(\d+)/))},t.storage=function(){try{return localStorage}catch(e){}}(),t.destroy=(()=>{let e=!1;return()=>{e||(e=!0,console.warn("Instance method `debug.destroy()` is deprecated and no longer does anything. It will be removed in the next major version of `debug`."))}})(),t.colors=["#0000CC","#0000FF","#0033CC","#0033FF","#0066CC","#0066FF","#0099CC","#0099FF","#00CC00","#00CC33","#00CC66","#00CC99","#00CCCC","#00CCFF","#3300CC","#3300FF","#3333CC","#3333FF","#3366CC","#3366FF","#3399CC","#3399FF","#33CC00","#33CC33","#33CC66","#33CC99","#33CCCC","#33CCFF","#6600CC","#6600FF","#6633CC","#6633FF","#66CC00","#66CC33","#9900CC","#9900FF","#9933CC","#9933FF","#99CC00","#99CC33","#CC0000","#CC0033","#CC0066","#CC0099","#CC00CC","#CC00FF","#CC3300","#CC3333","#CC3366","#CC3399","#CC33CC","#CC33FF","#CC6600","#CC6633","#CC9900","#CC9933","#CCCC00","#CCCC33","#FF0000","#FF0033","#FF0066","#FF0099","#FF00CC","#FF00FF","#FF3300","#FF3333","#FF3366","#FF3399","#FF33CC","#FF33FF","#FF6600","#FF6633","#FF9900","#FF9933","#FFCC00","#FFCC33"],t.log=console.debug||console.log||(()=>{}),e.exports=r(2447)(t);const{formatters:n}=e.exports;n.j=function(e){try{return JSON.stringify(e)}catch(e){return"[UnexpectedJSONParseError]: "+e.message}}},2447:(e,t,r)=>{e.exports=function(e){function t(e){let r,o=null;function s(...e){if(!s.enabled)return;const n=s,o=Number(new Date),i=o-(r||o);n.diff=i,n.prev=r,n.curr=o,r=o,e[0]=t.coerce(e[0]),"string"!=typeof e[0]&&e.unshift("%O");let a=0;e[0]=e[0].replace(/%([a-zA-Z%])/g,((r,o)=>{if("%%"===r)return"%";a++;const s=t.formatters[o];if("function"==typeof s){const t=e[a];r=s.call(n,t),e.splice(a,1),a--}return r})),t.formatArgs.call(n,e),(n.log||t.log).apply(n,e)}return s.namespace=e,s.useColors=t.useColors(),s.color=t.selectColor(e),s.extend=n,s.destroy=t.destroy,Object.defineProperty(s,"enabled",{enumerable:!0,configurable:!1,get:()=>null===o?t.enabled(e):o,set:e=>{o=e}}),"function"==typeof t.init&&t.init(s),s}function n(e,r){const n=t(this.namespace+(void 0===r?":":r)+e);return n.log=this.log,n}function o(e){return e.toString().substring(2,e.toString().length-2).replace(/\.\*\?$/,"*")}return t.debug=t,t.default=t,t.coerce=function(e){return e instanceof Error?e.stack||e.message:e},t.disable=function(){const e=[...t.names.map(o),...t.skips.map(o).map((e=>"-"+e))].join(",");return t.enable(""),e},t.enable=function(e){let r;t.save(e),t.names=[],t.skips=[];const n=("string"==typeof e?e:"").split(/[\s,]+/),o=n.length;for(r=0;r{t[r]=e[r]})),t.names=[],t.skips=[],t.formatters={},t.selectColor=function(e){let r=0;for(let t=0;t{"undefined"==typeof process||"renderer"===process.type||!0===process.browser||process.__nwjs?e.exports=r(1227):e.exports=r(39)},39:(e,t,r)=>{const n=r(3867),o=r(1669);t.init=function(e){e.inspectOpts={};const r=Object.keys(t.inspectOpts);for(let n=0;n{}),"Instance method `debug.destroy()` is deprecated and no longer does anything. It will be removed in the next major version of `debug`."),t.colors=[6,2,3,4,5,1];try{const e=r(2130);e&&(e.stderr||e).level>=2&&(t.colors=[20,21,26,27,32,33,38,39,40,41,42,43,44,45,56,57,62,63,68,69,74,75,76,77,78,79,80,81,92,93,98,99,112,113,128,129,134,135,148,149,160,161,162,163,164,165,166,167,168,169,170,171,172,173,178,179,184,185,196,197,198,199,200,201,202,203,204,205,206,207,208,209,214,215,220,221])}catch(e){}t.inspectOpts=Object.keys(process.env).filter((e=>/^debug_/i.test(e))).reduce(((e,t)=>{const r=t.substring(6).toLowerCase().replace(/_([a-z])/g,((e,t)=>t.toUpperCase()));let n=process.env[t];return n=!!/^(yes|on|true|enabled)$/i.test(n)||!/^(no|off|false|disabled)$/i.test(n)&&("null"===n?null:Number(n)),e[r]=n,e}),{}),e.exports=r(2447)(t);const{formatters:s}=e.exports;s.o=function(e){return this.inspectOpts.colors=this.useColors,o.inspect(e,this.inspectOpts).split("\n").map((e=>e.trim())).join(" ")},s.O=function(e){return this.inspectOpts.colors=this.useColors,o.inspect(e,this.inspectOpts)}},2261:(e,t,r)=>{var n;e.exports=function(){if(!n)try{n=r(5158)("follow-redirects")}catch(e){n=function(){}}n.apply(null,arguments)}},938:(e,t,r)=>{var n=r(8835),o=n.URL,s=r(8605),i=r(7211),a=r(2413).Writable,u=r(2357),c=r(2261),l=Object.create(null);["abort","aborted","connect","error","socket","timeout"].forEach((function(e){l[e]=function(t,r,n){this._redirectable.emit(e,t,r,n)}}));var f=g("ERR_FR_REDIRECTION_FAILURE",""),p=g("ERR_FR_TOO_MANY_REDIRECTS","Maximum number of redirects exceeded"),h=g("ERR_FR_MAX_BODY_LENGTH_EXCEEDED","Request body larger than maxBodyLength limit"),d=g("ERR_STREAM_WRITE_AFTER_END","write after end");function m(e,t){a.call(this),this._sanitizeOptions(e),this._options=e,this._ended=!1,this._ending=!1,this._redirectCount=0,this._redirects=[],this._requestBodyLength=0,this._requestBodyBuffers=[],t&&this.on("response",t);var r=this;this._onNativeResponse=function(e){r._processResponse(e)},this._performRequest()}function y(e){var t={maxRedirects:21,maxBodyLength:10485760},r={};return Object.keys(e).forEach((function(s){var i=s+":",a=r[i]=e[s],l=t[s]=Object.create(a);Object.defineProperties(l,{request:{value:function(e,s,a){if("string"==typeof e){var l=e;try{e=_(new o(l))}catch(t){e=n.parse(l)}}else o&&e instanceof o?e=_(e):(a=s,s=e,e={protocol:i});return"function"==typeof s&&(a=s,s=null),(s=Object.assign({maxRedirects:t.maxRedirects,maxBodyLength:t.maxBodyLength},e,s)).nativeProtocols=r,u.equal(s.protocol,i,"protocol mismatch"),c("options",s),new m(s,a)},configurable:!0,enumerable:!0,writable:!0},get:{value:function(e,t,r){var n=l.request(e,t,r);return n.end(),n},configurable:!0,enumerable:!0,writable:!0}})})),t}function v(){}function _(e){var t={protocol:e.protocol,hostname:e.hostname.startsWith("[")?e.hostname.slice(1,-1):e.hostname,hash:e.hash,search:e.search,pathname:e.pathname,path:e.pathname+e.search,href:e.href};return""!==e.port&&(t.port=Number(e.port)),t}function b(e,t){var r;for(var n in t)e.test(n)&&(r=t[n],delete t[n]);return r}function g(e,t){function r(e){Error.captureStackTrace(this,this.constructor),this.message=e||t}return r.prototype=new Error,r.prototype.constructor=r,r.prototype.name="Error ["+e+"]",r.prototype.code=e,r}m.prototype=Object.create(a.prototype),m.prototype.abort=function(){this._currentRequest.removeAllListeners(),this._currentRequest.on("error",v),this._currentRequest.abort(),this.emit("abort"),this.removeAllListeners()},m.prototype.write=function(e,t,r){if(this._ending)throw new d;if(!("string"==typeof e||"object"==typeof e&&"length"in e))throw new TypeError("data should be a string, Buffer or Uint8Array");"function"==typeof t&&(r=t,t=null),0!==e.length?this._requestBodyLength+e.length<=this._options.maxBodyLength?(this._requestBodyLength+=e.length,this._requestBodyBuffers.push({data:e,encoding:t}),this._currentRequest.write(e,t,r)):(this.emit("error",new h),this.abort()):r&&r()},m.prototype.end=function(e,t,r){if("function"==typeof e?(r=e,e=t=null):"function"==typeof t&&(r=t,t=null),e){var n=this,o=this._currentRequest;this.write(e,t,(function(){n._ended=!0,o.end(null,null,r)})),this._ending=!0}else this._ended=this._ending=!0,this._currentRequest.end(null,null,r)},m.prototype.setHeader=function(e,t){this._options.headers[e]=t,this._currentRequest.setHeader(e,t)},m.prototype.removeHeader=function(e){delete this._options.headers[e],this._currentRequest.removeHeader(e)},m.prototype.setTimeout=function(e,t){var r=this;function n(){r._timeout&&clearTimeout(r._timeout),r._timeout=setTimeout((function(){r.emit("timeout"),o()}),e)}function o(){clearTimeout(this._timeout),t&&r.removeListener("timeout",t),this.socket||r._currentRequest.removeListener("socket",n)}return t&&this.on("timeout",t),this.socket?n():this._currentRequest.once("socket",n),this.once("response",o),this.once("error",o),this},["flushHeaders","getHeader","setNoDelay","setSocketKeepAlive"].forEach((function(e){m.prototype[e]=function(t,r){return this._currentRequest[e](t,r)}})),["aborted","connection","socket"].forEach((function(e){Object.defineProperty(m.prototype,e,{get:function(){return this._currentRequest[e]}})})),m.prototype._sanitizeOptions=function(e){if(e.headers||(e.headers={}),e.host&&(e.hostname||(e.hostname=e.host),delete e.host),!e.pathname&&e.path){var t=e.path.indexOf("?");t<0?e.pathname=e.path:(e.pathname=e.path.substring(0,t),e.search=e.path.substring(t))}},m.prototype._performRequest=function(){var e=this._options.protocol,t=this._options.nativeProtocols[e];if(t){if(this._options.agents){var r=e.substr(0,e.length-1);this._options.agent=this._options.agents[r]}var o=this._currentRequest=t.request(this._options,this._onNativeResponse);for(var s in this._currentUrl=n.format(this._options),o._redirectable=this,l)s&&o.on(s,l[s]);if(this._isRedirect){var i=0,a=this,u=this._requestBodyBuffers;!function e(t){if(o===a._currentRequest)if(t)a.emit("error",t);else if(i=300&&t<400){if(this._currentRequest.removeAllListeners(),this._currentRequest.on("error",v),this._currentRequest.abort(),e.destroy(),++this._redirectCount>this._options.maxRedirects)return void this.emit("error",new p);((301===t||302===t)&&"POST"===this._options.method||303===t&&!/^(?:GET|HEAD)$/.test(this._options.method))&&(this._options.method="GET",this._requestBodyBuffers=[],b(/^content-/i,this._options.headers));var o=b(/^host$/i,this._options.headers)||n.parse(this._currentUrl).hostname,s=n.resolve(this._currentUrl,r);c("redirecting to",s),this._isRedirect=!0;var i=n.parse(s);if(Object.assign(this._options,i),i.hostname!==o&&b(/^authorization$/i,this._options.headers),"function"==typeof this._options.beforeRedirect){var a={headers:e.headers};try{this._options.beforeRedirect.call(null,this._options,a)}catch(e){return void this.emit("error",e)}this._sanitizeOptions(this._options)}try{this._performRequest()}catch(e){var u=new f("Redirected request failed: "+e.message);u.cause=e,this.emit("error",u)}}else e.responseUrl=this._currentUrl,e.redirects=this._redirects,this.emit("response",e),this._requestBodyBuffers=[]},e.exports=y({http:s,https:i}),e.exports.wrap=y},6560:e=>{"use strict";e.exports=(e,t)=>{t=t||process.argv;const r=e.startsWith("-")?"":1===e.length?"-":"--",n=t.indexOf(r+e),o=t.indexOf("--");return-1!==n&&(-1===o||n{var t=1e3,r=60*t,n=60*r,o=24*n;function s(e,t,r,n){var o=t>=1.5*r;return Math.round(e/r)+" "+n+(o?"s":"")}e.exports=function(e,i){i=i||{};var a,u,c=typeof e;if("string"===c&&e.length>0)return function(e){if(!((e=String(e)).length>100)){var s=/^(-?(?:\d+)?\.?\d+) *(milliseconds?|msecs?|ms|seconds?|secs?|s|minutes?|mins?|m|hours?|hrs?|h|days?|d|weeks?|w|years?|yrs?|y)?$/i.exec(e);if(s){var i=parseFloat(s[1]);switch((s[2]||"ms").toLowerCase()){case"years":case"year":case"yrs":case"yr":case"y":return 315576e5*i;case"weeks":case"week":case"w":return 6048e5*i;case"days":case"day":case"d":return i*o;case"hours":case"hour":case"hrs":case"hr":case"h":return i*n;case"minutes":case"minute":case"mins":case"min":case"m":return i*r;case"seconds":case"second":case"secs":case"sec":case"s":return i*t;case"milliseconds":case"millisecond":case"msecs":case"msec":case"ms":return i;default:return}}}}(e);if("number"===c&&isFinite(e))return i.long?(a=e,(u=Math.abs(a))>=o?s(a,u,o,"day"):u>=n?s(a,u,n,"hour"):u>=r?s(a,u,r,"minute"):u>=t?s(a,u,t,"second"):a+" ms"):function(e){var s=Math.abs(e);return s>=o?Math.round(e/o)+"d":s>=n?Math.round(e/n)+"h":s>=r?Math.round(e/r)+"m":s>=t?Math.round(e/t)+"s":e+"ms"}(e);throw new Error("val is not a non-empty string or a valid number. val="+JSON.stringify(e))}},2130:(e,t,r)=>{"use strict";const n=r(2087),o=r(6560),s=process.env;let i;function a(e){return 0!==(t=function(e){if(!1===i)return 0;if(o("color=16m")||o("color=full")||o("color=truecolor"))return 3;if(o("color=256"))return 2;if(e&&!e.isTTY&&!0!==i)return 0;const t=i?1:0;if("win32"===process.platform){const e=n.release().split(".");return Number(process.versions.node.split(".")[0])>=8&&Number(e[0])>=10&&Number(e[2])>=10586?Number(e[2])>=14931?3:2:1}if("CI"in s)return["TRAVIS","CIRCLECI","APPVEYOR","GITLAB_CI"].some((e=>e in s))||"codeship"===s.CI_NAME?1:t;if("TEAMCITY_VERSION"in s)return/^(9\.(0*[1-9]\d*)\.|\d{2,}\.)/.test(s.TEAMCITY_VERSION)?1:0;if("truecolor"===s.COLORTERM)return 3;if("TERM_PROGRAM"in s){const e=parseInt((s.TERM_PROGRAM_VERSION||"").split(".")[0],10);switch(s.TERM_PROGRAM){case"iTerm.app":return e>=3?3:2;case"Apple_Terminal":return 2}}return/-256(color)?$/i.test(s.TERM)?2:/^screen|^xterm|^vt100|^vt220|^rxvt|color|ansi|cygwin|linux/i.test(s.TERM)||"COLORTERM"in s?1:(s.TERM,t)}(e))&&{level:t,hasBasic:!0,has256:t>=2,has16m:t>=3};var t}o("no-color")||o("no-colors")||o("color=false")?i=!1:(o("color")||o("colors")||o("color=true")||o("color=always"))&&(i=!0),"FORCE_COLOR"in s&&(i=0===s.FORCE_COLOR.length||0!==parseInt(s.FORCE_COLOR,10)),e.exports={supportsColor:a,stdout:a(process.stdout),stderr:a(process.stderr)}},7661:function(e,t,r){"use strict";var n=this&&this.__awaiter||function(e,t,r,n){return new(r||(r=Promise))((function(o,s){function i(e){try{u(n.next(e))}catch(e){s(e)}}function a(e){try{u(n.throw(e))}catch(e){s(e)}}function u(e){var t;e.done?o(e.value):(t=e.value,t instanceof r?t:new r((function(e){e(t)}))).then(i,a)}u((n=n.apply(e,t||[])).next())}))},o=this&&this.__generator||function(e,t){var r,n,o,s,i={label:0,sent:function(){if(1&o[0])throw o[1];return o[1]},trys:[],ops:[]};return s={next:a(0),throw:a(1),return:a(2)},"function"==typeof Symbol&&(s[Symbol.iterator]=function(){return this}),s;function a(s){return function(a){return function(s){if(r)throw new TypeError("Generator is already executing.");for(;i;)try{if(r=1,n&&(o=2&s[0]?n.return:s[0]?n.throw||((o=n.return)&&o.call(n),0):n.next)&&!(o=o.call(n,s[1])).done)return o;switch(n=0,o&&(s=[2&s[0],o.value]),s[0]){case 0:case 1:o=s;break;case 4:return i.label++,{value:s[1],done:!1};case 5:i.label++,n=s[1],s=[0];continue;case 7:s=i.ops.pop(),i.trys.pop();continue;default:if(!((o=(o=i.trys).length>0&&o[o.length-1])||6!==s[0]&&2!==s[0])){i=0;continue}if(3===s[0]&&(!o||s[1]>o[0]&&s[1]0&&o[o.length-1])||6!==s[0]&&2!==s[0])){i=0;continue}if(3===s[0]&&(!o||s[1]>o[0]&&s[1]0&&o[o.length-1])||6!==s[0]&&2!==s[0])){i=0;continue}if(3===s[0]&&(!o||s[1]>o[0]&&s[1]0&&o[o.length-1])||6!==s[0]&&2!==s[0])){i=0;continue}if(3===s[0]&&(!o||s[1]>o[0]&&s[1]0&&o[o.length-1])||6!==s[0]&&2!==s[0])){i=0;continue}if(3===s[0]&&(!o||s[1]>o[0]&&s[1]0&&o[o.length-1])||6!==s[0]&&2!==s[0])){i=0;continue}if(3===s[0]&&(!o||s[1]>o[0]&&s[1]0&&o[o.length-1])||6!==s[0]&&2!==s[0])){i=0;continue}if(3===s[0]&&(!o||s[1]>o[0]&&s[1]0&&o[o.length-1])||6!==s[0]&&2!==s[0])){i=0;continue}if(3===s[0]&&(!o||s[1]>o[0]&&s[1]0&&o[o.length-1])||6!==s[0]&&2!==s[0])){i=0;continue}if(3===s[0]&&(!o||s[1]>o[0]&&s[1]0&&o[o.length-1])||6!==s[0]&&2!==s[0])){i=0;continue}if(3===s[0]&&(!o||s[1]>o[0]&&s[1]{"use strict";e.exports=require("assert")},8605:e=>{"use strict";e.exports=require("http")},7211:e=>{"use strict";e.exports=require("https")},2087:e=>{"use strict";e.exports=require("os")},2413:e=>{"use strict";e.exports=require("stream")},3867:e=>{"use strict";e.exports=require("tty")},8835:e=>{"use strict";e.exports=require("url")},1669:e=>{"use strict";e.exports=require("util")},8761:e=>{"use strict";e.exports=require("zlib")}},t={},function r(n){var o=t[n];if(void 0!==o)return o.exports;var s=t[n]={exports:{}};return e[n].call(s.exports,s,s.exports,r),s.exports}(3607);var e,t})); 2 | //# sourceMappingURL=nowpayments-api-js.min.js.map -------------------------------------------------------------------------------- /examples/.DS_Store: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/NowPaymentsIO/nowpayments-api-js/e1ea479aba1e53ae2ec6a6036bffb6db3d936170/examples/.DS_Store -------------------------------------------------------------------------------- /examples/html/index.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | HTML Example 10 | 11 | 12 | 13 | 14 |

Html Examples

15 |

Available currencies

16 |
17 |
18 |
19 |
20 |
21 | 47 | 48 | 49 | -------------------------------------------------------------------------------- /examples/html/style.css: -------------------------------------------------------------------------------- 1 | @keyframes dot-keyframes { 2 | 0% { 3 | opacity: 0.4; 4 | transform: scale(1, 1); 5 | } 6 | 7 | 50% { 8 | opacity: 1; 9 | transform: scale(1.2, 1.2); 10 | } 11 | 12 | 100% { 13 | opacity: 0.4; 14 | transform: scale(1, 1); 15 | } 16 | } 17 | 18 | .loading-dots { 19 | text-align: left; 20 | width: 10%; 21 | } 22 | 23 | .dot { 24 | animation: dot-keyframes 1.5s infinite ease-in-out; 25 | background-color: #000; 26 | border-radius: 10px; 27 | display: inline-block; 28 | height: 10px; 29 | width: 10px; 30 | } 31 | 32 | .dot:nth-child(2) { 33 | animation-delay: 0.5s; 34 | } 35 | 36 | .dot:nth-child(3) { 37 | animation-delay: 1s; 38 | } -------------------------------------------------------------------------------- /examples/node/index.js: -------------------------------------------------------------------------------- 1 | const NOWPaymentsApi = require('@nowpayments/nowpayments-api-js') 2 | 3 | const NPApi = new NOWPaymentsApi({ apiKey: 'A7M40XV-CG1448Z-KVVED3G-NW3V0TK' }) 4 | 5 | async function main() { 6 | console.log('NOWPayments API - Example Node') 7 | const { currencies } = await NPApi.getCurrencies() 8 | console.log('Available currencies: ', currencies) 9 | } 10 | 11 | main() 12 | -------------------------------------------------------------------------------- /examples/node/node_modules/@nowpayments/nowpayments-api: -------------------------------------------------------------------------------- 1 | ../../../../../../../.nvm/versions/node/v14.15.4/lib/node_modules/@nowpayments/nowpayments-api -------------------------------------------------------------------------------- /examples/node/package.json: -------------------------------------------------------------------------------- 1 | { 2 | "name": "node", 3 | "version": "1.0.0", 4 | "description": "", 5 | "main": "index.js", 6 | "scripts": { 7 | "start": "node index.js" 8 | }, 9 | "dependencies": { 10 | "@nowpaymentsio/nowpayments-api-js": "1.0.4" 11 | }, 12 | "author": "", 13 | "license": "ISC" 14 | } -------------------------------------------------------------------------------- /package.json: -------------------------------------------------------------------------------- 1 | { 2 | "name": "@nowpaymentsio/nowpayments-api-js", 3 | "version": "1.0.5", 4 | "description": "A library for interacting with the NOWPayments API", 5 | "author": "bogdanaks (https://github.com/bogdanaks)", 6 | "main": "./dist/nowpayments-api-js.js", 7 | "types": "./src/index.d.ts", 8 | "keywords": [ 9 | "Accept Bitcoin payments", 10 | "Accept crypto", 11 | "Accept crypto payments", 12 | "Accept crypto payments online", 13 | "Accept crypto on Shopify", 14 | "Accept crypto donations", 15 | "ADA", 16 | "ADA crypto", 17 | "Aeternity", 18 | "AeternumToken", 19 | "ALGO", 20 | "ARK", 21 | "AVA", 22 | "Atomic Wallet", 23 | "Basic Attention Token", 24 | "Beam", 25 | "Bitcoin", 26 | "Bitcoin payment", 27 | "Bitcoin payment gateway", 28 | "Bitcoin payment processor", 29 | "BlockChain", 30 | "BNB", 31 | "BNB Coin", 32 | "Binance Coin", 33 | "Bitcoin (Lightning Network)", 34 | "Bitcoin Cash", 35 | "BCH", 36 | "business", 37 | "Cardano", 38 | "Cardano ADA", 39 | "Coin", 40 | "Cryptocurrency", 41 | "Cryptocurrencies", 42 | "Crypto", 43 | "Crypto payment", 44 | "Crypto payment gateway", 45 | "Crypto payment processor", 46 | "Crypto plugin", 47 | "Crypto WooCommerce", 48 | "Dash", 49 | "DAO", 50 | "DAO Maker", 51 | "DGB", 52 | "Digibyte", 53 | "Dogecoin", 54 | "Doge", 55 | "Donate with crypto", 56 | "ecwid", 57 | "ecwid ecommerce", 58 | "Elrond Network", 59 | "EGLD", 60 | "Euro", 61 | "ERC-20", 62 | "Ecommerce", 63 | "Ecommerce solutions", 64 | "ETH", 65 | "Ethereum", 66 | "Ethereum payment processor", 67 | "EOS crypto", 68 | "Eos Token", 69 | "Ether Classic", 70 | "ETC", 71 | "Ethereum Classic", 72 | "Ether", 73 | "Fantom token", 74 | "Fiat", 75 | "Filecoin", 76 | "finance", 77 | "FunFair FUN", 78 | "Gaming", 79 | "Gambling", 80 | "HBAR", 81 | "Hedera", 82 | "Horizen", 83 | "Horizen ZEN", 84 | "Litecoin", 85 | "Maker DAO", 86 | "Monero", 87 | "Nano", 88 | "NEO", 89 | "OKB", 90 | "OKEx", 91 | "Payments", 92 | "Payment gateway", 93 | "Payment processor crypto", 94 | "Payment solutions", 95 | "Polkadot", 96 | "PrestaShop", 97 | "Ravencoin", 98 | "RVN", 99 | "Ripple crypto", 100 | "Shopify", 101 | "Shopify crypto", 102 | "Shopify crypto payments", 103 | "Tether", 104 | "Tether USD", 105 | "Token", 106 | "Tron", 107 | "TRX", 108 | "TrueUSD", 109 | "United States Dollar", 110 | "USD", 111 | "USDT", 112 | "VeChain Token", 113 | "Verge", 114 | "Wallet", 115 | "WAVES", 116 | "WooCommerce", 117 | "WooCommerce Crypto", 118 | "Wordpress crypto plugins", 119 | "XMR", 120 | "XRP", 121 | "XVG", 122 | "ZEC", 123 | "ZenCart", 124 | "Zcash", 125 | "ZCash ZEC", 126 | "ZEN" 127 | ], 128 | "repository": { 129 | "type": "git", 130 | "url": "https://github.com/NowPaymentsIO/nowpayments-api-js.git" 131 | }, 132 | "bugs": "https://github.com/NowPaymentsIO/nowpayments-api-js/issues", 133 | "private": false, 134 | "scripts": { 135 | "build": "NODE_ENV=production grunt build", 136 | "start": "NODE_ENV=development && webpack-cli --watch --mode development", 137 | "eslint:fix": "eslint --fix ./src" 138 | }, 139 | "license": "MIT", 140 | "dependencies": { 141 | "axios": "^0.21.1" 142 | }, 143 | "devDependencies": { 144 | "@typescript-eslint/eslint-plugin": "^4.21.0", 145 | "eslint": "^7.23.0", 146 | "eslint-config-standard-with-typescript": "^20.0.0", 147 | "eslint-plugin-import": "^2.22.1", 148 | "eslint-plugin-node": "^11.1.0", 149 | "eslint-plugin-promise": "^4.3.1", 150 | "grunt": "^1.3.0", 151 | "grunt-cli": "^1.4.2", 152 | "grunt-contrib-clean": "^2.0.0", 153 | "grunt-eslint": "^23.0.0", 154 | "grunt-ts": "^6.0.0-beta.22", 155 | "grunt-webpack": "^4.0.2", 156 | "load-grunt-tasks": "^5.1.0", 157 | "terser-webpack-plugin": "^5.1.1", 158 | "ts-loader": "^8.1.0", 159 | "ts-node": "^9.1.1", 160 | "tslint": "^6.1.3", 161 | "typescript": "^4.2.3", 162 | "uglifyjs-webpack-plugin": "2.2.0", 163 | "webpack": "^5.30.0", 164 | "webpack-cli": "^4.6.0" 165 | } 166 | } 167 | -------------------------------------------------------------------------------- /src/actions/create-invoice/index.d.ts: -------------------------------------------------------------------------------- 1 | import { ICreateInvoice, Error } from '../../types'; 2 | export interface InvoiceReturn { 3 | id: number; 4 | order_id: string; 5 | order_description: string; 6 | price_amount: number; 7 | price_currency: string; 8 | pay_currency: string | null; 9 | ipn_callback_url: string; 10 | invoice_url: string; 11 | success_url: string; 12 | cancel_url: string; 13 | created_at: string; 14 | updated_at: string; 15 | } 16 | export interface CreateInvoice extends ICreateInvoice { 17 | apiKey: string; 18 | } 19 | declare const createInvoice: ({ apiKey, price_amount, price_currency, pay_currency, ipn_callback_url, order_id, order_description, success_url, cancel_url }: CreateInvoice) => Promise; 20 | export default createInvoice; 21 | -------------------------------------------------------------------------------- /src/actions/create-invoice/index.ts: -------------------------------------------------------------------------------- 1 | import ConnectApi from '../../utils/connect-api' 2 | import { ICreateInvoice, Error } from '../../types' 3 | 4 | export interface InvoiceReturn { 5 | id: number 6 | order_id: string 7 | order_description: string 8 | price_amount: number 9 | price_currency: string 10 | pay_currency: string | null 11 | ipn_callback_url: string 12 | invoice_url: string 13 | success_url: string 14 | cancel_url: string 15 | created_at: string 16 | updated_at: string 17 | } 18 | 19 | export interface CreateInvoice extends ICreateInvoice { 20 | apiKey: string 21 | } 22 | 23 | const createInvoice = async ({ 24 | apiKey, 25 | price_amount, 26 | price_currency, 27 | pay_currency, 28 | ipn_callback_url, 29 | order_id, 30 | order_description, 31 | success_url, 32 | cancel_url 33 | }: CreateInvoice): Promise => { 34 | const API = new ConnectApi({ apiKey }) 35 | 36 | const { data } = await API.post('/invoice', { 37 | price_amount, 38 | price_currency, 39 | pay_currency, 40 | ipn_callback_url, 41 | order_id, 42 | order_description, 43 | success_url, 44 | cancel_url 45 | }) 46 | return data 47 | } 48 | 49 | export default createInvoice 50 | -------------------------------------------------------------------------------- /src/actions/create-payment/index.d.ts: -------------------------------------------------------------------------------- 1 | import { ICreatePayment, Error } from '../../types'; 2 | export interface CreatePaymentReturn { 3 | payment_id: number; 4 | payment_status: string; 5 | pay_address: string; 6 | price_amount: number; 7 | price_currency: string; 8 | pay_amount: number; 9 | pay_currency: string; 10 | order_id: string; 11 | order_description: string; 12 | ipn_callback_url: string; 13 | created_at: string; 14 | updated_at: string; 15 | purchase_id: number; 16 | } 17 | export interface CreatePayment extends ICreatePayment { 18 | apiKey: string; 19 | } 20 | declare const createPayment: ({ apiKey, price_amount, price_currency, pay_amount, pay_currency, ipn_callback_url, order_id, order_description, purchase_id, payout_address, payout_currency, payout_extra_id, fixed_rate }: CreatePayment) => Promise; 21 | export default createPayment; 22 | -------------------------------------------------------------------------------- /src/actions/create-payment/index.ts: -------------------------------------------------------------------------------- 1 | import ConnectApi from '../../utils/connect-api' 2 | import { ICreatePayment, Error } from '../../types' 3 | 4 | export interface CreatePaymentReturn { 5 | payment_id: number 6 | payment_status: string 7 | pay_address: string 8 | price_amount: number 9 | price_currency: string 10 | pay_amount: number 11 | pay_currency: string 12 | order_id: string 13 | order_description: string 14 | ipn_callback_url: string 15 | created_at: string 16 | updated_at: string 17 | purchase_id: number 18 | } 19 | 20 | export interface CreatePayment extends ICreatePayment { 21 | apiKey: string 22 | } 23 | 24 | const createPayment = async ({ 25 | apiKey, 26 | price_amount, 27 | price_currency, 28 | pay_amount, 29 | pay_currency, 30 | ipn_callback_url, 31 | order_id, 32 | order_description, 33 | purchase_id, 34 | payout_address, 35 | payout_currency, 36 | payout_extra_id, 37 | fixed_rate 38 | }: CreatePayment): Promise => { 39 | const API = new ConnectApi({ apiKey }) 40 | 41 | const { data } = await API.post('/payment', { 42 | price_amount, 43 | price_currency, 44 | pay_amount, 45 | pay_currency, 46 | ipn_callback_url, 47 | order_id, 48 | order_description, 49 | purchase_id, 50 | payout_address, 51 | payout_currency, 52 | payout_extra_id, 53 | fixed_rate 54 | }) 55 | return data 56 | } 57 | 58 | export default createPayment 59 | -------------------------------------------------------------------------------- /src/actions/get-currencies/index.d.ts: -------------------------------------------------------------------------------- 1 | import { Error } from '../../types'; 2 | export interface GetCurrenciesReturn { 3 | currencies: [string]; 4 | } 5 | declare const getCurrencies: ({ apiKey }: { 6 | apiKey: string; 7 | }) => Promise; 8 | export default getCurrencies; 9 | -------------------------------------------------------------------------------- /src/actions/get-currencies/index.ts: -------------------------------------------------------------------------------- 1 | import ConnectApi from '../../utils/connect-api' 2 | import { Error } from '../../types' 3 | 4 | export interface GetCurrenciesReturn { 5 | currencies: [string] 6 | } 7 | 8 | const getCurrencies = async ({ apiKey }: { apiKey: string }): Promise => { 9 | const API = new ConnectApi({ apiKey }) 10 | 11 | const { data } = await API.get('/currencies') 12 | return data 13 | } 14 | 15 | export default getCurrencies 16 | -------------------------------------------------------------------------------- /src/actions/get-estimate-price/index.d.ts: -------------------------------------------------------------------------------- 1 | import { IGetEstimatePrice, Error } from '../../types'; 2 | export interface GetEstimatePriceReturn { 3 | currency_from: string; 4 | amount_from: number; 5 | currency_to: string; 6 | estimated_amount: number; 7 | } 8 | export interface GetEstimatePrice extends IGetEstimatePrice { 9 | apiKey: string; 10 | } 11 | declare const getEstimatePrice: ({ apiKey, amount, currency_from, currency_to }: GetEstimatePrice) => Promise; 12 | export default getEstimatePrice; 13 | -------------------------------------------------------------------------------- /src/actions/get-estimate-price/index.ts: -------------------------------------------------------------------------------- 1 | import ConnectApi from '../../utils/connect-api' 2 | import { IGetEstimatePrice, Error } from '../../types' 3 | 4 | export interface GetEstimatePriceReturn { 5 | currency_from: string 6 | amount_from: number 7 | currency_to: string 8 | estimated_amount: number 9 | } 10 | 11 | export interface GetEstimatePrice extends IGetEstimatePrice { 12 | apiKey: string 13 | } 14 | 15 | const getEstimatePrice = async ({ 16 | apiKey, 17 | amount, 18 | currency_from, 19 | currency_to 20 | }: GetEstimatePrice): Promise => { 21 | const API = new ConnectApi({ apiKey }) 22 | 23 | const { data } = await API.get('/estimate', { amount, currency_from, currency_to }) 24 | return data 25 | } 26 | 27 | export default getEstimatePrice 28 | -------------------------------------------------------------------------------- /src/actions/get-list-payments/index.d.ts: -------------------------------------------------------------------------------- 1 | import { Error, IGetListPayments } from '../../types'; 2 | interface Invoice { 3 | payment_id: number; 4 | payment_status: string; 5 | pay_address: string; 6 | price_amount: number; 7 | price_currency: string; 8 | pay_amount: number; 9 | actually_paid: number; 10 | pay_currency: string; 11 | order_id: string; 12 | order_description: string; 13 | purchase_id: number; 14 | outcome_amount: number; 15 | outcome_currency: string; 16 | } 17 | export interface GetListPaymentsReturn { 18 | data: Invoice[]; 19 | limit: number; 20 | page: number; 21 | pagesCount: number; 22 | total: number; 23 | } 24 | export interface GetListPayments extends IGetListPayments { 25 | apiKey: string; 26 | } 27 | declare const getListPayments: ({ apiKey, limit, page, sortBy, orderBy, dateFrom, dateTo }: GetListPayments) => Promise; 28 | export default getListPayments; 29 | -------------------------------------------------------------------------------- /src/actions/get-list-payments/index.ts: -------------------------------------------------------------------------------- 1 | import ConnectApi from '../../utils/connect-api' 2 | import { Error, IGetListPayments } from '../../types' 3 | 4 | interface Invoice { 5 | payment_id: number 6 | payment_status: string 7 | pay_address: string 8 | price_amount: number 9 | price_currency: string 10 | pay_amount: number 11 | actually_paid: number 12 | pay_currency: string 13 | order_id: string 14 | order_description: string 15 | purchase_id: number 16 | outcome_amount: number 17 | outcome_currency: string 18 | } 19 | 20 | export interface GetListPaymentsReturn { 21 | data: Invoice[] 22 | limit: number 23 | page: number 24 | pagesCount: number 25 | total: number 26 | } 27 | 28 | export interface GetListPayments extends IGetListPayments { 29 | apiKey: string 30 | } 31 | 32 | const getListPayments = async ({ 33 | apiKey, 34 | limit, 35 | page, 36 | sortBy, 37 | orderBy, 38 | dateFrom, 39 | dateTo 40 | }: GetListPayments): Promise => { 41 | const API = new ConnectApi({ apiKey }) 42 | 43 | const { data } = await API.get('/payment', { limit, page, sortBy, orderBy, dateFrom, dateTo }) 44 | return data 45 | } 46 | 47 | export default getListPayments 48 | -------------------------------------------------------------------------------- /src/actions/get-minimum-payment-amount/index.d.ts: -------------------------------------------------------------------------------- 1 | import { IGetMinimumPaymentAmount, Error } from '../../types'; 2 | export interface GetMinimumPaymentAmountReturn { 3 | currency_from: string; 4 | currency_to: string; 5 | min_amount: number; 6 | } 7 | export interface GetMinimumPaymentAmount extends IGetMinimumPaymentAmount { 8 | apiKey: string; 9 | } 10 | declare const getMinimumPaymentAmount: ({ apiKey, currency_from, currency_to }: GetMinimumPaymentAmount) => Promise; 11 | export default getMinimumPaymentAmount; 12 | -------------------------------------------------------------------------------- /src/actions/get-minimum-payment-amount/index.ts: -------------------------------------------------------------------------------- 1 | import ConnectApi from '../../utils/connect-api' 2 | import { IGetMinimumPaymentAmount, Error } from '../../types' 3 | 4 | export interface GetMinimumPaymentAmountReturn { 5 | currency_from: string 6 | currency_to: string 7 | min_amount: number 8 | } 9 | 10 | export interface GetMinimumPaymentAmount extends IGetMinimumPaymentAmount { 11 | apiKey: string 12 | } 13 | 14 | const getMinimumPaymentAmount = async ({ 15 | apiKey, 16 | currency_from, 17 | currency_to 18 | }: GetMinimumPaymentAmount): Promise => { 19 | const API = new ConnectApi({ apiKey }) 20 | 21 | const { data } = await API.get('/min-amount', { currency_from, currency_to }) 22 | return data 23 | } 24 | 25 | export default getMinimumPaymentAmount 26 | -------------------------------------------------------------------------------- /src/actions/get-payment-status/index.d.ts: -------------------------------------------------------------------------------- 1 | import { IGetPaymentStatus, Error } from '../../types'; 2 | export interface GetPaymentStatusReturn { 3 | payment_id: number; 4 | payment_status: string; 5 | pay_address: string; 6 | price_amount: number; 7 | price_currency: string; 8 | pay_amount: number; 9 | actually_paid: number; 10 | pay_currency: string; 11 | order_id: string; 12 | order_description: string; 13 | purchase_id: number; 14 | created_at: string; 15 | updated_at: string; 16 | outcome_amount: number; 17 | outcome_currency: string; 18 | } 19 | export interface GetPaymentStatus extends IGetPaymentStatus { 20 | apiKey: string; 21 | } 22 | declare const getPaymentStatus: ({ apiKey, payment_id }: GetPaymentStatus) => Promise; 23 | export default getPaymentStatus; 24 | -------------------------------------------------------------------------------- /src/actions/get-payment-status/index.ts: -------------------------------------------------------------------------------- 1 | import ConnectApi from '../../utils/connect-api' 2 | import { IGetPaymentStatus, Error } from '../../types' 3 | 4 | export interface GetPaymentStatusReturn { 5 | payment_id: number 6 | payment_status: string 7 | pay_address: string 8 | price_amount: number 9 | price_currency: string 10 | pay_amount: number 11 | actually_paid: number 12 | pay_currency: string 13 | order_id: string 14 | order_description: string 15 | purchase_id: number 16 | created_at: string 17 | updated_at: string 18 | outcome_amount: number 19 | outcome_currency: string 20 | } 21 | 22 | export interface GetPaymentStatus extends IGetPaymentStatus { 23 | apiKey: string 24 | } 25 | 26 | const getPaymentStatus = async ({ apiKey, payment_id }: GetPaymentStatus): Promise => { 27 | const API = new ConnectApi({ apiKey }) 28 | 29 | const { data } = await API.get(`/payment/${payment_id}`) 30 | return data 31 | } 32 | 33 | export default getPaymentStatus 34 | -------------------------------------------------------------------------------- /src/actions/index.d.ts: -------------------------------------------------------------------------------- 1 | declare const _default: { 2 | status: () => Promise; 3 | getCurrencies: ({ apiKey }: { 4 | apiKey: string; 5 | }) => Promise; 6 | getEstimatePrice: ({ apiKey, amount, currency_from, currency_to }: import("./get-estimate-price").GetEstimatePrice) => Promise; 7 | createPayment: ({ apiKey, price_amount, price_currency, pay_amount, pay_currency, ipn_callback_url, order_id, order_description, purchase_id, payout_address, payout_currency, payout_extra_id, fixed_rate }: import("./create-payment").CreatePayment) => Promise; 8 | getPaymentStatus: ({ apiKey, payment_id }: import("./get-payment-status").GetPaymentStatus) => Promise; 9 | getMinimumPaymentAmount: ({ apiKey, currency_from, currency_to }: import("./get-minimum-payment-amount").GetMinimumPaymentAmount) => Promise; 10 | getListPayments: ({ apiKey, limit, page, sortBy, orderBy, dateFrom, dateTo }: import("./get-list-payments").GetListPayments) => Promise; 11 | createInvoice: ({ apiKey, price_amount, price_currency, pay_currency, ipn_callback_url, order_id, order_description, success_url, cancel_url }: import("./create-invoice").CreateInvoice) => Promise; 12 | }; 13 | export default _default; 14 | -------------------------------------------------------------------------------- /src/actions/index.ts: -------------------------------------------------------------------------------- 1 | import status from './status' 2 | import getCurrencies from './get-currencies' 3 | import getEstimatePrice from './get-estimate-price' 4 | import createPayment from './create-payment' 5 | import getPaymentStatus from './get-payment-status' 6 | import getMinimumPaymentAmount from './get-minimum-payment-amount' 7 | import getListPayments from './get-list-payments' 8 | import createInvoice from './create-invoice' 9 | 10 | export default { 11 | status, 12 | getCurrencies, 13 | getEstimatePrice, 14 | createPayment, 15 | getPaymentStatus, 16 | getMinimumPaymentAmount, 17 | getListPayments, 18 | createInvoice 19 | } 20 | -------------------------------------------------------------------------------- /src/actions/status/index.d.ts: -------------------------------------------------------------------------------- 1 | import { Error } from '../../types'; 2 | export interface StatusReturn { 3 | message: string; 4 | } 5 | declare const status: () => Promise; 6 | export default status; 7 | -------------------------------------------------------------------------------- /src/actions/status/index.ts: -------------------------------------------------------------------------------- 1 | import ConnectApi from '../../utils/connect-api' 2 | import { Error } from '../../types' 3 | 4 | export interface StatusReturn { 5 | message: string 6 | } 7 | 8 | const status = async (): Promise => { 9 | const API = new ConnectApi({ apiKey: '' }) 10 | 11 | const { data } = await API.get('/status') 12 | return data 13 | } 14 | 15 | export default status 16 | -------------------------------------------------------------------------------- /src/index.d.ts: -------------------------------------------------------------------------------- 1 | import { ICreatePayment, IGetEstimatePrice, IGetPaymentStatus, IGetMinimumPaymentAmount, IGetListPayments, ICreateInvoice } from './types'; 2 | declare class NOWPaymentsApi { 3 | readonly apiKey: string; 4 | constructor({ apiKey }: { 5 | apiKey: string; 6 | }); 7 | status(): Promise; 8 | getCurrencies(): Promise; 9 | getEstimatePrice({ amount, currency_from, currency_to }: IGetEstimatePrice): Promise; 10 | createPayment({ price_amount, price_currency, pay_amount, pay_currency, ipn_callback_url, order_id, order_description, purchase_id, payout_address, payout_currency, payout_extra_id, fixed_rate }: ICreatePayment): Promise; 11 | getPaymentStatus({ payment_id }: IGetPaymentStatus): Promise; 12 | getMinimumPaymentAmount({ currency_from, currency_to }: IGetMinimumPaymentAmount): Promise; 13 | getListPayments({ limit, page, sortBy, orderBy, dateFrom, dateTo }?: IGetListPayments): Promise; 14 | createInvoice({ price_amount, price_currency, pay_currency, ipn_callback_url, order_id, order_description, success_url, cancel_url }: ICreateInvoice): Promise; 15 | } 16 | export = NOWPaymentsApi; 17 | -------------------------------------------------------------------------------- /src/index.ts: -------------------------------------------------------------------------------- 1 | import NP from './actions' 2 | 3 | import { 4 | ICreatePayment, 5 | IGetEstimatePrice, 6 | IGetPaymentStatus, 7 | IGetMinimumPaymentAmount, 8 | IGetListPayments, 9 | ICreateInvoice 10 | } from './types' 11 | 12 | class NOWPaymentsApi { 13 | readonly apiKey: string 14 | 15 | constructor({ apiKey }: { apiKey: string }) { 16 | this.apiKey = apiKey 17 | } 18 | 19 | async status() { 20 | return await NP.status() 21 | } 22 | 23 | async getCurrencies() { 24 | return await NP.getCurrencies({ apiKey: this.apiKey }) 25 | } 26 | 27 | async getEstimatePrice({ amount, currency_from, currency_to }: IGetEstimatePrice) { 28 | return await NP.getEstimatePrice({ apiKey: this.apiKey, amount, currency_from, currency_to }) 29 | } 30 | 31 | async createPayment({ 32 | price_amount, 33 | price_currency, 34 | pay_amount, 35 | pay_currency, 36 | ipn_callback_url, 37 | order_id, 38 | order_description, 39 | purchase_id, 40 | payout_address, 41 | payout_currency, 42 | payout_extra_id, 43 | fixed_rate 44 | }: ICreatePayment) { 45 | return await NP.createPayment({ 46 | apiKey: this.apiKey, 47 | price_amount, 48 | price_currency, 49 | pay_amount, 50 | pay_currency, 51 | ipn_callback_url, 52 | order_id, 53 | order_description, 54 | purchase_id, 55 | payout_address, 56 | payout_currency, 57 | payout_extra_id, 58 | fixed_rate 59 | }) 60 | } 61 | 62 | async getPaymentStatus({ payment_id }: IGetPaymentStatus) { 63 | return await NP.getPaymentStatus({ apiKey: this.apiKey, payment_id }) 64 | } 65 | 66 | async getMinimumPaymentAmount({ currency_from, currency_to }: IGetMinimumPaymentAmount) { 67 | return await NP.getMinimumPaymentAmount({ apiKey: this.apiKey, currency_from, currency_to }) 68 | } 69 | 70 | async getListPayments({ limit, page, sortBy, orderBy, dateFrom, dateTo }: IGetListPayments = {}) { 71 | return await NP.getListPayments({ apiKey: this.apiKey, limit, page, sortBy, orderBy, dateFrom, dateTo }) 72 | } 73 | 74 | async createInvoice({ 75 | price_amount, 76 | price_currency, 77 | pay_currency, 78 | ipn_callback_url, 79 | order_id, 80 | order_description, 81 | success_url, 82 | cancel_url 83 | }: ICreateInvoice) { 84 | return await NP.createInvoice({ 85 | apiKey: this.apiKey, 86 | price_amount, 87 | price_currency, 88 | pay_currency, 89 | ipn_callback_url, 90 | order_id, 91 | order_description, 92 | success_url, 93 | cancel_url 94 | }) 95 | } 96 | } 97 | 98 | export = NOWPaymentsApi 99 | -------------------------------------------------------------------------------- /src/types.d.ts: -------------------------------------------------------------------------------- 1 | export interface IGetEstimatePrice { 2 | amount: number; 3 | currency_from: string; 4 | currency_to: string; 5 | } 6 | export interface ICreatePayment { 7 | price_amount: number; 8 | price_currency: string; 9 | pay_amount?: number; 10 | pay_currency: string; 11 | ipn_callback_url?: string; 12 | order_id?: string; 13 | order_description?: string; 14 | purchase_id?: string; 15 | payout_address?: string; 16 | payout_currency?: string; 17 | payout_extra_id?: string; 18 | fixed_rate?: string; 19 | } 20 | export interface IGetPaymentStatus { 21 | payment_id: string; 22 | } 23 | export interface IGetMinimumPaymentAmount { 24 | currency_from: string; 25 | currency_to: string; 26 | } 27 | export interface IGetListPayments { 28 | limit?: number; 29 | page?: number; 30 | sortBy?: string; 31 | orderBy?: string; 32 | dateFrom?: string; 33 | dateTo?: string; 34 | } 35 | export interface ICreateInvoice { 36 | price_amount: number; 37 | price_currency: string; 38 | pay_currency?: string; 39 | ipn_callback_url?: string; 40 | order_id?: string; 41 | order_description?: string; 42 | success_url?: string; 43 | cancel_url?: string; 44 | } 45 | export interface Error { 46 | errors?: []; 47 | message?: string; 48 | } 49 | -------------------------------------------------------------------------------- /src/types.ts: -------------------------------------------------------------------------------- 1 | export interface IGetEstimatePrice { 2 | amount: number 3 | currency_from: string 4 | currency_to: string 5 | } 6 | 7 | export interface ICreatePayment { 8 | price_amount: number 9 | price_currency: string 10 | pay_amount?: number 11 | pay_currency: string 12 | ipn_callback_url?: string 13 | order_id?: string 14 | order_description?: string 15 | purchase_id?: string 16 | payout_address?: string 17 | payout_currency?: string 18 | payout_extra_id?: string 19 | fixed_rate?: string 20 | } 21 | 22 | export interface IGetPaymentStatus { 23 | payment_id: string 24 | } 25 | 26 | export interface IGetMinimumPaymentAmount { 27 | currency_from: string 28 | currency_to: string 29 | } 30 | 31 | export interface IGetListPayments { 32 | limit?: number 33 | page?: number 34 | sortBy?: string 35 | orderBy?: string 36 | dateFrom?: string 37 | dateTo?: string 38 | } 39 | 40 | export interface ICreateInvoice { 41 | price_amount: number 42 | price_currency: string 43 | pay_currency?: string 44 | ipn_callback_url?: string 45 | order_id?: string 46 | order_description?: string 47 | success_url?: string 48 | cancel_url?: string 49 | } 50 | 51 | export interface Error { 52 | errors?: [] 53 | message?: string 54 | } 55 | -------------------------------------------------------------------------------- /src/utils/connect-api.d.ts: -------------------------------------------------------------------------------- 1 | import { AxiosInstance } from 'axios'; 2 | declare class ConnectApi { 3 | apiKey: string; 4 | api: AxiosInstance; 5 | constructor({ apiKey }: { 6 | apiKey: string; 7 | }); 8 | get(url: string, params?: object): Promise>; 9 | post(url: string, params?: object): Promise>; 10 | } 11 | export default ConnectApi; 12 | -------------------------------------------------------------------------------- /src/utils/connect-api.ts: -------------------------------------------------------------------------------- 1 | import axios, { AxiosInstance } from 'axios' 2 | 3 | class ConnectApi { 4 | apiKey: string 5 | api: AxiosInstance 6 | 7 | constructor({ apiKey }: { apiKey: string }) { 8 | this.apiKey = apiKey 9 | this.api = axios.create({ 10 | baseURL: 'https://api.nowpayments.io/v1/', 11 | timeout: 10000, 12 | headers: { 'x-api-key': apiKey }, 13 | validateStatus: () => true 14 | }) 15 | } 16 | 17 | async get(url: string, params?: object) { 18 | return await this.api.get(url, { params }) 19 | } 20 | 21 | async post(url: string, params?: object) { 22 | return await this.api.post(url, { ...params }) 23 | } 24 | } 25 | 26 | export default ConnectApi 27 | -------------------------------------------------------------------------------- /tsconfig.json: -------------------------------------------------------------------------------- 1 | { 2 | "compilerOptions": { 3 | "esModuleInterop": true, 4 | "module": "commonjs", 5 | "declaration": true, 6 | "removeComments": true, 7 | "emitDecoratorMetadata": true, 8 | "experimentalDecorators": true, 9 | "target": "es5", 10 | "lib": [ 11 | "es2015", 12 | "dom" 13 | ], 14 | "sourceMap": true, 15 | "composite": true, 16 | "incremental": true, 17 | "noUnusedLocals": true, 18 | "noUnusedParameters": false, 19 | "resolveJsonModule": true 20 | }, 21 | "exclude": [ 22 | "**/*.d.ts", 23 | "node_modules", 24 | "dist" 25 | ] 26 | } -------------------------------------------------------------------------------- /tsconfig.tsbuildinfo: -------------------------------------------------------------------------------- 1 | { 2 | "program": { 3 | "fileInfos": { 4 | "./node_modules/typescript/lib/lib.es5.d.ts": { 5 | "version": "b3584bc5798ed422ce2516df360ffa9cf2d80b5eae852867db9ba3743145f895", 6 | "signature": "b3584bc5798ed422ce2516df360ffa9cf2d80b5eae852867db9ba3743145f895", 7 | "affectsGlobalScope": true 8 | }, 9 | "./node_modules/typescript/lib/lib.es2015.d.ts": { 10 | "version": "dc47c4fa66b9b9890cf076304de2a9c5201e94b740cffdf09f87296d877d71f6", 11 | "signature": "dc47c4fa66b9b9890cf076304de2a9c5201e94b740cffdf09f87296d877d71f6", 12 | "affectsGlobalScope": false 13 | }, 14 | "./node_modules/typescript/lib/lib.es2016.d.ts": { 15 | "version": "7a387c58583dfca701b6c85e0adaf43fb17d590fb16d5b2dc0a2fbd89f35c467", 16 | "signature": "7a387c58583dfca701b6c85e0adaf43fb17d590fb16d5b2dc0a2fbd89f35c467", 17 | "affectsGlobalScope": false 18 | }, 19 | "./node_modules/typescript/lib/lib.es2017.d.ts": { 20 | "version": "8a12173c586e95f4433e0c6dc446bc88346be73ffe9ca6eec7aa63c8f3dca7f9", 21 | "signature": "8a12173c586e95f4433e0c6dc446bc88346be73ffe9ca6eec7aa63c8f3dca7f9", 22 | "affectsGlobalScope": false 23 | }, 24 | "./node_modules/typescript/lib/lib.es2018.d.ts": { 25 | "version": "5f4e733ced4e129482ae2186aae29fde948ab7182844c3a5a51dd346182c7b06", 26 | "signature": "5f4e733ced4e129482ae2186aae29fde948ab7182844c3a5a51dd346182c7b06", 27 | "affectsGlobalScope": false 28 | }, 29 | "./node_modules/typescript/lib/lib.dom.d.ts": { 30 | "version": "feeeb1dd8a80fb76be42b0426e8f3ffa9bdef3c2f3c12c147e7660b1c5ba8b3b", 31 | "signature": "feeeb1dd8a80fb76be42b0426e8f3ffa9bdef3c2f3c12c147e7660b1c5ba8b3b", 32 | "affectsGlobalScope": true 33 | }, 34 | "./node_modules/typescript/lib/lib.es2015.core.d.ts": { 35 | "version": "46ee15e9fefa913333b61eaf6b18885900b139867d89832a515059b62cf16a17", 36 | "signature": "46ee15e9fefa913333b61eaf6b18885900b139867d89832a515059b62cf16a17", 37 | "affectsGlobalScope": true 38 | }, 39 | "./node_modules/typescript/lib/lib.es2015.collection.d.ts": { 40 | "version": "43fb1d932e4966a39a41b464a12a81899d9ae5f2c829063f5571b6b87e6d2f9c", 41 | "signature": "43fb1d932e4966a39a41b464a12a81899d9ae5f2c829063f5571b6b87e6d2f9c", 42 | "affectsGlobalScope": true 43 | }, 44 | "./node_modules/typescript/lib/lib.es2015.generator.d.ts": { 45 | "version": "cdccba9a388c2ee3fd6ad4018c640a471a6c060e96f1232062223063b0a5ac6a", 46 | "signature": "cdccba9a388c2ee3fd6ad4018c640a471a6c060e96f1232062223063b0a5ac6a", 47 | "affectsGlobalScope": true 48 | }, 49 | "./node_modules/typescript/lib/lib.es2015.iterable.d.ts": { 50 | "version": "8b2a5df1ce95f78f6b74f1a555ccdb6baab0486b42d8345e0871dd82811f9b9a", 51 | "signature": "8b2a5df1ce95f78f6b74f1a555ccdb6baab0486b42d8345e0871dd82811f9b9a", 52 | "affectsGlobalScope": true 53 | }, 54 | "./node_modules/typescript/lib/lib.es2015.promise.d.ts": { 55 | "version": "2bb4b3927299434052b37851a47bf5c39764f2ba88a888a107b32262e9292b7c", 56 | "signature": "2bb4b3927299434052b37851a47bf5c39764f2ba88a888a107b32262e9292b7c", 57 | "affectsGlobalScope": true 58 | }, 59 | "./node_modules/typescript/lib/lib.es2015.proxy.d.ts": { 60 | "version": "810627a82ac06fb5166da5ada4159c4ec11978dfbb0805fe804c86406dab8357", 61 | "signature": "810627a82ac06fb5166da5ada4159c4ec11978dfbb0805fe804c86406dab8357", 62 | "affectsGlobalScope": true 63 | }, 64 | "./node_modules/typescript/lib/lib.es2015.reflect.d.ts": { 65 | "version": "62d80405c46c3f4c527ee657ae9d43fda65a0bf582292429aea1e69144a522a6", 66 | "signature": "62d80405c46c3f4c527ee657ae9d43fda65a0bf582292429aea1e69144a522a6", 67 | "affectsGlobalScope": true 68 | }, 69 | "./node_modules/typescript/lib/lib.es2015.symbol.d.ts": { 70 | "version": "3013574108c36fd3aaca79764002b3717da09725a36a6fc02eac386593110f93", 71 | "signature": "3013574108c36fd3aaca79764002b3717da09725a36a6fc02eac386593110f93", 72 | "affectsGlobalScope": true 73 | }, 74 | "./node_modules/typescript/lib/lib.es2015.symbol.wellknown.d.ts": { 75 | "version": "9d122b7e8c1a5c72506eea50c0973cba55b92b5532d5cafa8a6ce2c547d57551", 76 | "signature": "9d122b7e8c1a5c72506eea50c0973cba55b92b5532d5cafa8a6ce2c547d57551", 77 | "affectsGlobalScope": true 78 | }, 79 | "./node_modules/typescript/lib/lib.es2016.array.include.d.ts": { 80 | "version": "3be5a1453daa63e031d266bf342f3943603873d890ab8b9ada95e22389389006", 81 | "signature": "3be5a1453daa63e031d266bf342f3943603873d890ab8b9ada95e22389389006", 82 | "affectsGlobalScope": true 83 | }, 84 | "./node_modules/typescript/lib/lib.es2017.object.d.ts": { 85 | "version": "17bb1fc99591b00515502d264fa55dc8370c45c5298f4a5c2083557dccba5a2a", 86 | "signature": "17bb1fc99591b00515502d264fa55dc8370c45c5298f4a5c2083557dccba5a2a", 87 | "affectsGlobalScope": true 88 | }, 89 | "./node_modules/typescript/lib/lib.es2017.sharedmemory.d.ts": { 90 | "version": "7ce9f0bde3307ca1f944119f6365f2d776d281a393b576a18a2f2893a2d75c98", 91 | "signature": "7ce9f0bde3307ca1f944119f6365f2d776d281a393b576a18a2f2893a2d75c98", 92 | "affectsGlobalScope": true 93 | }, 94 | "./node_modules/typescript/lib/lib.es2017.string.d.ts": { 95 | "version": "6a6b173e739a6a99629a8594bfb294cc7329bfb7b227f12e1f7c11bc163b8577", 96 | "signature": "6a6b173e739a6a99629a8594bfb294cc7329bfb7b227f12e1f7c11bc163b8577", 97 | "affectsGlobalScope": true 98 | }, 99 | "./node_modules/typescript/lib/lib.es2017.intl.d.ts": { 100 | "version": "12a310447c5d23c7d0d5ca2af606e3bd08afda69100166730ab92c62999ebb9d", 101 | "signature": "12a310447c5d23c7d0d5ca2af606e3bd08afda69100166730ab92c62999ebb9d", 102 | "affectsGlobalScope": true 103 | }, 104 | "./node_modules/typescript/lib/lib.es2017.typedarrays.d.ts": { 105 | "version": "b0124885ef82641903d232172577f2ceb5d3e60aed4da1153bab4221e1f6dd4e", 106 | "signature": "b0124885ef82641903d232172577f2ceb5d3e60aed4da1153bab4221e1f6dd4e", 107 | "affectsGlobalScope": true 108 | }, 109 | "./node_modules/typescript/lib/lib.es2018.asyncgenerator.d.ts": { 110 | "version": "0eb85d6c590b0d577919a79e0084fa1744c1beba6fd0d4e951432fa1ede5510a", 111 | "signature": "0eb85d6c590b0d577919a79e0084fa1744c1beba6fd0d4e951432fa1ede5510a", 112 | "affectsGlobalScope": true 113 | }, 114 | "./node_modules/typescript/lib/lib.es2018.asynciterable.d.ts": { 115 | "version": "a40c4d82bf13fcded295ac29f354eb7d40249613c15e07b53f2fc75e45e16359", 116 | "signature": "a40c4d82bf13fcded295ac29f354eb7d40249613c15e07b53f2fc75e45e16359", 117 | "affectsGlobalScope": true 118 | }, 119 | "./node_modules/typescript/lib/lib.es2018.intl.d.ts": { 120 | "version": "df9c8a72ca8b0ed62f5470b41208a0587f0f73f0a7db28e5a1272cf92537518e", 121 | "signature": "df9c8a72ca8b0ed62f5470b41208a0587f0f73f0a7db28e5a1272cf92537518e", 122 | "affectsGlobalScope": true 123 | }, 124 | "./node_modules/typescript/lib/lib.es2018.promise.d.ts": { 125 | "version": "bb2d3fb05a1d2ffbca947cc7cbc95d23e1d053d6595391bd325deb265a18d36c", 126 | "signature": "bb2d3fb05a1d2ffbca947cc7cbc95d23e1d053d6595391bd325deb265a18d36c", 127 | "affectsGlobalScope": true 128 | }, 129 | "./node_modules/typescript/lib/lib.es2018.regexp.d.ts": { 130 | "version": "c80df75850fea5caa2afe43b9949338ce4e2de086f91713e9af1a06f973872b8", 131 | "signature": "c80df75850fea5caa2afe43b9949338ce4e2de086f91713e9af1a06f973872b8", 132 | "affectsGlobalScope": true 133 | }, 134 | "./node_modules/typescript/lib/lib.es2020.bigint.d.ts": { 135 | "version": "7b5a10e3c897fabece5a51aa85b4111727d7adb53c2734b5d37230ff96802a09", 136 | "signature": "7b5a10e3c897fabece5a51aa85b4111727d7adb53c2734b5d37230ff96802a09", 137 | "affectsGlobalScope": true 138 | }, 139 | "./node_modules/typescript/lib/lib.esnext.intl.d.ts": { 140 | "version": "506b80b9951c9381dc5f11897b31fca5e2a65731d96ddefa19687fbc26b23c6e", 141 | "signature": "506b80b9951c9381dc5f11897b31fca5e2a65731d96ddefa19687fbc26b23c6e", 142 | "affectsGlobalScope": true 143 | }, 144 | "./src/actions/status/index.ts": { 145 | "version": "4da26a0ba52de6433f8fbe102c4fff0f9d8979ea44144591b49142b21eaedb42", 146 | "signature": "48a731a0d619ec4ab1b2cfcdab75f3dac51823e87e8d5ea9fb6bbbf66d5aa5fa", 147 | "affectsGlobalScope": false 148 | }, 149 | "./src/actions/get-currencies/index.ts": { 150 | "version": "547181be9a3a8222ac56b396a91cefefd6813975aa8d7046126d61af5b18c35c", 151 | "signature": "e855617da0e2451193a0115c03ca1ac36be8e1674d527e74ff5ba1ffe2a1fd23", 152 | "affectsGlobalScope": false 153 | }, 154 | "./src/actions/get-estimate-price/index.ts": { 155 | "version": "19bdc2402126e181f5ae40b7e7fd4d261a58d38e028a288494a6eea485e9ccaa", 156 | "signature": "38d9223f9fe73c9d71547810ae23e45b08bc01bc2f26fe27f444e2a1b3295b77", 157 | "affectsGlobalScope": false 158 | }, 159 | "./src/actions/create-payment/index.ts": { 160 | "version": "f145bf02c3a0cf592abf12667045deae2729de54b610dfbfc2a0fb1fac278464", 161 | "signature": "5c94124dae403ff09e586b43f9f42934728676bab5e429cd1dd243d01dc9347a", 162 | "affectsGlobalScope": false 163 | }, 164 | "./src/actions/get-payment-status/index.ts": { 165 | "version": "0830478b66a2d7f05469a7bc831a481d0c2a360463b46d2d384fdf2cb7b81482", 166 | "signature": "b40e84f108e483c57c79ac6567ae8bffe5ec2ed8e86d1e2fd5df9a5eaffc90cc", 167 | "affectsGlobalScope": false 168 | }, 169 | "./src/actions/get-minimum-payment-status/index.ts": { 170 | "version": "fe5c005ebfb7495fac0a9e5066fb398281e944102ef397ee512e3ab697ba9bf4", 171 | "signature": "38247669c2e2123748f60d15e7519c47946da0c083711ad46f6b38a5d244a364", 172 | "affectsGlobalScope": false 173 | }, 174 | "./src/actions/get-list-payments/index.ts": { 175 | "version": "520dcf8067b45e59132414183c792e97182a48d85e28ff3d94b3067cd994776d", 176 | "signature": "17715cc2e638999dc5229aff6790a2c85b6784b6ceca559dae8c18b55f64a5cb", 177 | "affectsGlobalScope": false 178 | }, 179 | "./src/actions/create-invoice/index.ts": { 180 | "version": "63860385a6bfc4c00a59716b042e20a56206a460d0ff3d3be753ec7d557e4570", 181 | "signature": "94ae7d0d754eb1154f175874bd11740b25841d584e6db49f35f2b92e22be8ac3", 182 | "affectsGlobalScope": false 183 | }, 184 | "./src/actions/index.ts": { 185 | "version": "3c72a764df56c7cfac8a137fb36211b838e976bb56f0746f3e609d3cdf89b32f", 186 | "signature": "3083bcb2962b3c17f14003264b43b157c949112b731ea4c54cc4baf89606e685", 187 | "affectsGlobalScope": false 188 | }, 189 | "./src/index.ts": { 190 | "version": "fc82e42b0be0f010d5b36ad1bdc8d643e8ef3dc88890917fe8430420fb321b08", 191 | "signature": "83cf610ccea098aef6b57d180f9586808d3e7945e30d924c7f18d11749c520ea", 192 | "affectsGlobalScope": false 193 | }, 194 | "./node_modules/@types/eslint/helpers.d.ts": { 195 | "version": "f345b0888d003fd69cb32bad3a0aa04c615ccafc572019e4bd86a52bd5e49e46", 196 | "signature": "f345b0888d003fd69cb32bad3a0aa04c615ccafc572019e4bd86a52bd5e49e46", 197 | "affectsGlobalScope": true 198 | }, 199 | "./node_modules/@types/eslint/lib/rules/index.d.ts": { 200 | "version": "0133ebdd17a823ae56861948870cde4dac18dd8818ab641039c85bbb720429e0", 201 | "signature": "0133ebdd17a823ae56861948870cde4dac18dd8818ab641039c85bbb720429e0", 202 | "affectsGlobalScope": false 203 | }, 204 | "./node_modules/@types/json-schema/index.d.ts": { 205 | "version": "3a1e165b22a1cb8df82c44c9a09502fd2b33f160cd277de2cd3a055d8e5c6b27", 206 | "signature": "3a1e165b22a1cb8df82c44c9a09502fd2b33f160cd277de2cd3a055d8e5c6b27", 207 | "affectsGlobalScope": false 208 | }, 209 | "./node_modules/@types/estree/index.d.ts": { 210 | "version": "745a853d60bf782583a58584f59e202cae5c7a898b0c92696442602a3ef17a87", 211 | "signature": "745a853d60bf782583a58584f59e202cae5c7a898b0c92696442602a3ef17a87", 212 | "affectsGlobalScope": false 213 | }, 214 | "./node_modules/@types/eslint/index.d.ts": { 215 | "version": "649fbcb16a4a7e1d9f32a49db7381150ef5b2e472a0c52a1543d4c35a2aefa3c", 216 | "signature": "649fbcb16a4a7e1d9f32a49db7381150ef5b2e472a0c52a1543d4c35a2aefa3c", 217 | "affectsGlobalScope": false 218 | }, 219 | "./node_modules/@types/eslint-scope/index.d.ts": { 220 | "version": "274bda283ef15f4205603ca9967313fc013aa77ae89f2cbeab5fbd51439e96ed", 221 | "signature": "274bda283ef15f4205603ca9967313fc013aa77ae89f2cbeab5fbd51439e96ed", 222 | "affectsGlobalScope": false 223 | }, 224 | "./node_modules/@types/node/globals.d.ts": { 225 | "version": "25b4a0c4fab47c373ee49df4c239826ee3430019fc0c1b5e59edc3e398b7468d", 226 | "signature": "25b4a0c4fab47c373ee49df4c239826ee3430019fc0c1b5e59edc3e398b7468d", 227 | "affectsGlobalScope": true 228 | }, 229 | "./node_modules/@types/node/async_hooks.d.ts": { 230 | "version": "d20f08527645f62facb2d66c2b7bd31ea964b59c897d00bddb1efe8c13890b72", 231 | "signature": "d20f08527645f62facb2d66c2b7bd31ea964b59c897d00bddb1efe8c13890b72", 232 | "affectsGlobalScope": false 233 | }, 234 | "./node_modules/@types/node/buffer.d.ts": { 235 | "version": "5726b5ce952dc5beaeb08d5f64236632501568a54a390363d2339ba1dc5393b1", 236 | "signature": "5726b5ce952dc5beaeb08d5f64236632501568a54a390363d2339ba1dc5393b1", 237 | "affectsGlobalScope": false 238 | }, 239 | "./node_modules/@types/node/child_process.d.ts": { 240 | "version": "674bedbfd2004e233e2a266a3d2286e524f0d58787a98522d834d6ccda1d215a", 241 | "signature": "674bedbfd2004e233e2a266a3d2286e524f0d58787a98522d834d6ccda1d215a", 242 | "affectsGlobalScope": false 243 | }, 244 | "./node_modules/@types/node/cluster.d.ts": { 245 | "version": "714637d594e1a38a075091fe464ca91c6abc0b154784b4287f6883200e28ccef", 246 | "signature": "714637d594e1a38a075091fe464ca91c6abc0b154784b4287f6883200e28ccef", 247 | "affectsGlobalScope": false 248 | }, 249 | "./node_modules/@types/node/console.d.ts": { 250 | "version": "23edba5f47d3409810c563fe8034ae2c59e718e1ef8570f4152ccdde1915a096", 251 | "signature": "23edba5f47d3409810c563fe8034ae2c59e718e1ef8570f4152ccdde1915a096", 252 | "affectsGlobalScope": true 253 | }, 254 | "./node_modules/@types/node/constants.d.ts": { 255 | "version": "0e9c55f894ca2d9cf63b5b0d43a8cec1772dd560233fd16275bc7a485eb82f83", 256 | "signature": "0e9c55f894ca2d9cf63b5b0d43a8cec1772dd560233fd16275bc7a485eb82f83", 257 | "affectsGlobalScope": false 258 | }, 259 | "./node_modules/@types/node/crypto.d.ts": { 260 | "version": "d53b352a01645c470a0d8c31bf290ba791fc28ade0ce187a4a50f5c2f826f75e", 261 | "signature": "d53b352a01645c470a0d8c31bf290ba791fc28ade0ce187a4a50f5c2f826f75e", 262 | "affectsGlobalScope": false 263 | }, 264 | "./node_modules/@types/node/dgram.d.ts": { 265 | "version": "5f0a09de75bd965c21dc6d73671ba88830272f9ed62897bb0aa9754b369b1eed", 266 | "signature": "5f0a09de75bd965c21dc6d73671ba88830272f9ed62897bb0aa9754b369b1eed", 267 | "affectsGlobalScope": false 268 | }, 269 | "./node_modules/@types/node/dns.d.ts": { 270 | "version": "2b34e7fcba9e1f24e7f54ba5c8be5a8895b0b8b444ccf6548e04acdee0899317", 271 | "signature": "2b34e7fcba9e1f24e7f54ba5c8be5a8895b0b8b444ccf6548e04acdee0899317", 272 | "affectsGlobalScope": false 273 | }, 274 | "./node_modules/@types/node/domain.d.ts": { 275 | "version": "06d2be99c3dd2ff52114d02ee443ba486ab482423df1941d3c97d6a92e924d70", 276 | "signature": "06d2be99c3dd2ff52114d02ee443ba486ab482423df1941d3c97d6a92e924d70", 277 | "affectsGlobalScope": true 278 | }, 279 | "./node_modules/@types/node/events.d.ts": { 280 | "version": "bfd4f140c07091b5e8a963c89e6fa3f44b6cfcbc11471b465cf63e2d020ad0eb", 281 | "signature": "bfd4f140c07091b5e8a963c89e6fa3f44b6cfcbc11471b465cf63e2d020ad0eb", 282 | "affectsGlobalScope": true 283 | }, 284 | "./node_modules/@types/node/fs.d.ts": { 285 | "version": "a106a0bea088b70879ac88ff606dc253c0cc474ea05ad3a282b8bfb1091ae576", 286 | "signature": "a106a0bea088b70879ac88ff606dc253c0cc474ea05ad3a282b8bfb1091ae576", 287 | "affectsGlobalScope": false 288 | }, 289 | "./node_modules/@types/node/fs/promises.d.ts": { 290 | "version": "c98ce957db9eebd75f53edda3f6893e05ab2d2283b5667b18e31bcdb6427ed10", 291 | "signature": "c98ce957db9eebd75f53edda3f6893e05ab2d2283b5667b18e31bcdb6427ed10", 292 | "affectsGlobalScope": false 293 | }, 294 | "./node_modules/@types/node/http.d.ts": { 295 | "version": "1f08bd8305d4a789a68f71ab622156dfff993aa51a2aa58b9ccf166cc6f9fcf7", 296 | "signature": "1f08bd8305d4a789a68f71ab622156dfff993aa51a2aa58b9ccf166cc6f9fcf7", 297 | "affectsGlobalScope": false 298 | }, 299 | "./node_modules/@types/node/http2.d.ts": { 300 | "version": "9aff68f1b847b846d3d50a58c9f8f99389bedd0258d1b1c201f11b97ecfd36f8", 301 | "signature": "9aff68f1b847b846d3d50a58c9f8f99389bedd0258d1b1c201f11b97ecfd36f8", 302 | "affectsGlobalScope": false 303 | }, 304 | "./node_modules/@types/node/https.d.ts": { 305 | "version": "1978992206803f5761e99e893d93b25abc818c5fe619674fdf2ae02b29f641ba", 306 | "signature": "1978992206803f5761e99e893d93b25abc818c5fe619674fdf2ae02b29f641ba", 307 | "affectsGlobalScope": false 308 | }, 309 | "./node_modules/@types/node/inspector.d.ts": { 310 | "version": "05fbe81f09fc455a2c343d2458d2b3c600c90b92b22926be765ee79326be9466", 311 | "signature": "05fbe81f09fc455a2c343d2458d2b3c600c90b92b22926be765ee79326be9466", 312 | "affectsGlobalScope": false 313 | }, 314 | "./node_modules/@types/node/module.d.ts": { 315 | "version": "8e7d6dae9e19bbe47600dcfd4418db85b30ae7351474ea0aad5e628f9845d340", 316 | "signature": "8e7d6dae9e19bbe47600dcfd4418db85b30ae7351474ea0aad5e628f9845d340", 317 | "affectsGlobalScope": false 318 | }, 319 | "./node_modules/@types/node/net.d.ts": { 320 | "version": "f20ea392f7f27feb7a90e5a24319a4e365b07bf83c39a547711fe7ff9df68657", 321 | "signature": "f20ea392f7f27feb7a90e5a24319a4e365b07bf83c39a547711fe7ff9df68657", 322 | "affectsGlobalScope": false 323 | }, 324 | "./node_modules/@types/node/os.d.ts": { 325 | "version": "32542c4660ecda892a333a533feedba31738ee538ef6a78eb73af647137bc3fc", 326 | "signature": "32542c4660ecda892a333a533feedba31738ee538ef6a78eb73af647137bc3fc", 327 | "affectsGlobalScope": false 328 | }, 329 | "./node_modules/@types/node/path.d.ts": { 330 | "version": "0ecacea5047d1a7d350e7049dbd22f26435be5e8736a81a56afec5b3264db1ca", 331 | "signature": "0ecacea5047d1a7d350e7049dbd22f26435be5e8736a81a56afec5b3264db1ca", 332 | "affectsGlobalScope": false 333 | }, 334 | "./node_modules/@types/node/perf_hooks.d.ts": { 335 | "version": "ffcb4ebde21f83370ed402583888b28651d2eb7f05bfec9482eb46d82adedd7f", 336 | "signature": "ffcb4ebde21f83370ed402583888b28651d2eb7f05bfec9482eb46d82adedd7f", 337 | "affectsGlobalScope": false 338 | }, 339 | "./node_modules/@types/node/process.d.ts": { 340 | "version": "06c004006016a51c4d1855527a523562c329dc44c473931c65f10373281f730e", 341 | "signature": "06c004006016a51c4d1855527a523562c329dc44c473931c65f10373281f730e", 342 | "affectsGlobalScope": true 343 | }, 344 | "./node_modules/@types/node/punycode.d.ts": { 345 | "version": "a7b43c69f9602d198825e403ee34e5d64f83c48b391b2897e8c0e6f72bca35f8", 346 | "signature": "a7b43c69f9602d198825e403ee34e5d64f83c48b391b2897e8c0e6f72bca35f8", 347 | "affectsGlobalScope": false 348 | }, 349 | "./node_modules/@types/node/querystring.d.ts": { 350 | "version": "f4a3fc4efc6944e7b7bd4ccfa45e0df68b6359808e6cf9d061f04fd964a7b2d3", 351 | "signature": "f4a3fc4efc6944e7b7bd4ccfa45e0df68b6359808e6cf9d061f04fd964a7b2d3", 352 | "affectsGlobalScope": false 353 | }, 354 | "./node_modules/@types/node/readline.d.ts": { 355 | "version": "73cad675aead7a2c05cf934e7e700c61d84b2037ac1d576c3f751199b25331da", 356 | "signature": "73cad675aead7a2c05cf934e7e700c61d84b2037ac1d576c3f751199b25331da", 357 | "affectsGlobalScope": false 358 | }, 359 | "./node_modules/@types/node/repl.d.ts": { 360 | "version": "8c3137ba3583ec18484429ec1c8eff89efdc42730542f157b38b102fdccc0c71", 361 | "signature": "8c3137ba3583ec18484429ec1c8eff89efdc42730542f157b38b102fdccc0c71", 362 | "affectsGlobalScope": false 363 | }, 364 | "./node_modules/@types/node/stream.d.ts": { 365 | "version": "d84300d886b45a198c346158e4ff7ae361cc7bc1c3deab44afb3db7de56b5d25", 366 | "signature": "d84300d886b45a198c346158e4ff7ae361cc7bc1c3deab44afb3db7de56b5d25", 367 | "affectsGlobalScope": false 368 | }, 369 | "./node_modules/@types/node/string_decoder.d.ts": { 370 | "version": "94ca7beec4e274d32362b54e0133152f7b4be9487db7b005070c03880b6363aa", 371 | "signature": "94ca7beec4e274d32362b54e0133152f7b4be9487db7b005070c03880b6363aa", 372 | "affectsGlobalScope": false 373 | }, 374 | "./node_modules/@types/node/timers.d.ts": { 375 | "version": "2d713cbcbd5bcc38d91546eaeea7bb1c8686dc4a2995a28556d957b1b9de11d9", 376 | "signature": "2d713cbcbd5bcc38d91546eaeea7bb1c8686dc4a2995a28556d957b1b9de11d9", 377 | "affectsGlobalScope": false 378 | }, 379 | "./node_modules/@types/node/tls.d.ts": { 380 | "version": "bbf21f210782db4193359010a4710786add43e3b50aa42fc0d371f45b4e4d8d3", 381 | "signature": "bbf21f210782db4193359010a4710786add43e3b50aa42fc0d371f45b4e4d8d3", 382 | "affectsGlobalScope": false 383 | }, 384 | "./node_modules/@types/node/trace_events.d.ts": { 385 | "version": "0b7733d83619ac4e3963e2a9f7c75dc1e9af6850cb2354c9554977813092c10a", 386 | "signature": "0b7733d83619ac4e3963e2a9f7c75dc1e9af6850cb2354c9554977813092c10a", 387 | "affectsGlobalScope": false 388 | }, 389 | "./node_modules/@types/node/tty.d.ts": { 390 | "version": "3ce933f0c3955f67f67eb7d6b5c83c2c54a18472c1d6f2bb651e51dd40c84837", 391 | "signature": "3ce933f0c3955f67f67eb7d6b5c83c2c54a18472c1d6f2bb651e51dd40c84837", 392 | "affectsGlobalScope": false 393 | }, 394 | "./node_modules/@types/node/url.d.ts": { 395 | "version": "631e96db896d645f7132c488ad34a16d71fd2be9f44696f8c98289ee1c8cbfa9", 396 | "signature": "631e96db896d645f7132c488ad34a16d71fd2be9f44696f8c98289ee1c8cbfa9", 397 | "affectsGlobalScope": false 398 | }, 399 | "./node_modules/@types/node/util.d.ts": { 400 | "version": "2c77230d381cba81eb6f87cda2fbfff6c0427c6546c2e2590110effff37c58f7", 401 | "signature": "2c77230d381cba81eb6f87cda2fbfff6c0427c6546c2e2590110effff37c58f7", 402 | "affectsGlobalScope": false 403 | }, 404 | "./node_modules/@types/node/v8.d.ts": { 405 | "version": "da86ee9a2f09a4583db1d5e37815894967e1f694ad9f3c25e84e0e4d40411e14", 406 | "signature": "da86ee9a2f09a4583db1d5e37815894967e1f694ad9f3c25e84e0e4d40411e14", 407 | "affectsGlobalScope": false 408 | }, 409 | "./node_modules/@types/node/vm.d.ts": { 410 | "version": "141a943e5690105898a67537a470f70b56d0e183441b56051d929e902376b7b2", 411 | "signature": "141a943e5690105898a67537a470f70b56d0e183441b56051d929e902376b7b2", 412 | "affectsGlobalScope": false 413 | }, 414 | "./node_modules/@types/node/worker_threads.d.ts": { 415 | "version": "ddc086b1adac44e2fccf55422da1e90fa970e659d77f99712422a421564b4877", 416 | "signature": "ddc086b1adac44e2fccf55422da1e90fa970e659d77f99712422a421564b4877", 417 | "affectsGlobalScope": false 418 | }, 419 | "./node_modules/@types/node/zlib.d.ts": { 420 | "version": "515ef1d99036ff0dafa5bf738e02222edea94e0d97a0aa0ff277ac5e96b57977", 421 | "signature": "515ef1d99036ff0dafa5bf738e02222edea94e0d97a0aa0ff277ac5e96b57977", 422 | "affectsGlobalScope": false 423 | }, 424 | "./node_modules/@types/node/globals.global.d.ts": { 425 | "version": "2708349d5a11a5c2e5f3a0765259ebe7ee00cdcc8161cb9990cb4910328442a1", 426 | "signature": "2708349d5a11a5c2e5f3a0765259ebe7ee00cdcc8161cb9990cb4910328442a1", 427 | "affectsGlobalScope": true 428 | }, 429 | "./node_modules/@types/node/wasi.d.ts": { 430 | "version": "780058f4a804c8bdcdd2f60e7af64b2bc57d149c1586ee3db732a84d659a50bf", 431 | "signature": "780058f4a804c8bdcdd2f60e7af64b2bc57d149c1586ee3db732a84d659a50bf", 432 | "affectsGlobalScope": false 433 | }, 434 | "./node_modules/@types/node/ts3.6/base.d.ts": { 435 | "version": "ae68a04912ee5a0f589276f9ec60b095f8c40d48128a4575b3fdd7d93806931c", 436 | "signature": "ae68a04912ee5a0f589276f9ec60b095f8c40d48128a4575b3fdd7d93806931c", 437 | "affectsGlobalScope": false 438 | }, 439 | "./node_modules/@types/node/assert.d.ts": { 440 | "version": "19d580a3b42ad5caeaee266ae958260e23f2df0549ee201c886c8bd7a4f01d4e", 441 | "signature": "19d580a3b42ad5caeaee266ae958260e23f2df0549ee201c886c8bd7a4f01d4e", 442 | "affectsGlobalScope": false 443 | }, 444 | "./node_modules/@types/node/base.d.ts": { 445 | "version": "e61a21e9418f279bc480394a94d1581b2dee73747adcbdef999b6737e34d721b", 446 | "signature": "e61a21e9418f279bc480394a94d1581b2dee73747adcbdef999b6737e34d721b", 447 | "affectsGlobalScope": false 448 | }, 449 | "./node_modules/@types/node/index.d.ts": { 450 | "version": "9c4c395e927045b324877acdc4bfb95f128f36bc9f073266a2f0342495075a4f", 451 | "signature": "9c4c395e927045b324877acdc4bfb95f128f36bc9f073266a2f0342495075a4f", 452 | "affectsGlobalScope": false 453 | } 454 | }, 455 | "options": { 456 | "esModuleInterop": true, 457 | "module": 1, 458 | "declaration": true, 459 | "removeComments": true, 460 | "emitDecoratorMetadata": true, 461 | "experimentalDecorators": true, 462 | "target": 1, 463 | "lib": [ 464 | "lib.es2015.d.ts", 465 | "lib.dom.d.ts" 466 | ], 467 | "sourceMap": true, 468 | "composite": true, 469 | "incremental": true, 470 | "noUnusedLocals": true, 471 | "noUnusedParameters": false, 472 | "resolveJsonModule": true, 473 | "emitDeclarationOnly": true, 474 | "declarationDir": "../../../../../var/folders/4_/k18s21f16pbgmk98sh8nkg540000gn/T/tmp-88690-ZOh3vdYrVRyx/npm-dts", 475 | "configFilePath": "./tsconfig.json" 476 | }, 477 | "referencedMap": { 478 | "./node_modules/@types/eslint-scope/index.d.ts": [ 479 | "./node_modules/@types/eslint/index.d.ts", 480 | "./node_modules/@types/estree/index.d.ts" 481 | ], 482 | "./node_modules/@types/eslint/index.d.ts": [ 483 | "./node_modules/@types/eslint/helpers.d.ts", 484 | "./node_modules/@types/eslint/lib/rules/index.d.ts", 485 | "./node_modules/@types/estree/index.d.ts", 486 | "./node_modules/@types/json-schema/index.d.ts" 487 | ], 488 | "./node_modules/@types/eslint/lib/rules/index.d.ts": [ 489 | "./node_modules/@types/eslint/index.d.ts" 490 | ], 491 | "./node_modules/@types/node/assert.d.ts": [ 492 | "./node_modules/@types/node/assert.d.ts" 493 | ], 494 | "./node_modules/@types/node/async_hooks.d.ts": [ 495 | "./node_modules/@types/node/async_hooks.d.ts" 496 | ], 497 | "./node_modules/@types/node/base.d.ts": [ 498 | "./node_modules/@types/node/assert.d.ts", 499 | "./node_modules/@types/node/ts3.6/base.d.ts" 500 | ], 501 | "./node_modules/@types/node/buffer.d.ts": [ 502 | "./node_modules/@types/node/buffer.d.ts" 503 | ], 504 | "./node_modules/@types/node/child_process.d.ts": [ 505 | "./node_modules/@types/node/child_process.d.ts", 506 | "./node_modules/@types/node/events.d.ts", 507 | "./node_modules/@types/node/fs.d.ts", 508 | "./node_modules/@types/node/net.d.ts", 509 | "./node_modules/@types/node/stream.d.ts" 510 | ], 511 | "./node_modules/@types/node/cluster.d.ts": [ 512 | "./node_modules/@types/node/child_process.d.ts", 513 | "./node_modules/@types/node/cluster.d.ts", 514 | "./node_modules/@types/node/events.d.ts", 515 | "./node_modules/@types/node/net.d.ts" 516 | ], 517 | "./node_modules/@types/node/console.d.ts": [ 518 | "./node_modules/@types/node/util.d.ts" 519 | ], 520 | "./node_modules/@types/node/constants.d.ts": [ 521 | "./node_modules/@types/node/constants.d.ts", 522 | "./node_modules/@types/node/crypto.d.ts", 523 | "./node_modules/@types/node/fs.d.ts", 524 | "./node_modules/@types/node/os.d.ts" 525 | ], 526 | "./node_modules/@types/node/crypto.d.ts": [ 527 | "./node_modules/@types/node/crypto.d.ts", 528 | "./node_modules/@types/node/stream.d.ts" 529 | ], 530 | "./node_modules/@types/node/dgram.d.ts": [ 531 | "./node_modules/@types/node/dgram.d.ts", 532 | "./node_modules/@types/node/dns.d.ts", 533 | "./node_modules/@types/node/events.d.ts", 534 | "./node_modules/@types/node/net.d.ts" 535 | ], 536 | "./node_modules/@types/node/dns.d.ts": [ 537 | "./node_modules/@types/node/dns.d.ts" 538 | ], 539 | "./node_modules/@types/node/domain.d.ts": [ 540 | "./node_modules/@types/node/domain.d.ts", 541 | "./node_modules/@types/node/events.d.ts" 542 | ], 543 | "./node_modules/@types/node/events.d.ts": [ 544 | "./node_modules/@types/node/events.d.ts" 545 | ], 546 | "./node_modules/@types/node/fs.d.ts": [ 547 | "./node_modules/@types/node/events.d.ts", 548 | "./node_modules/@types/node/fs.d.ts", 549 | "./node_modules/@types/node/fs/promises.d.ts", 550 | "./node_modules/@types/node/stream.d.ts", 551 | "./node_modules/@types/node/url.d.ts" 552 | ], 553 | "./node_modules/@types/node/fs/promises.d.ts": [ 554 | "./node_modules/@types/node/fs.d.ts", 555 | "./node_modules/@types/node/fs/promises.d.ts" 556 | ], 557 | "./node_modules/@types/node/http.d.ts": [ 558 | "./node_modules/@types/node/http.d.ts", 559 | "./node_modules/@types/node/net.d.ts", 560 | "./node_modules/@types/node/stream.d.ts", 561 | "./node_modules/@types/node/url.d.ts" 562 | ], 563 | "./node_modules/@types/node/http2.d.ts": [ 564 | "./node_modules/@types/node/events.d.ts", 565 | "./node_modules/@types/node/fs.d.ts", 566 | "./node_modules/@types/node/http.d.ts", 567 | "./node_modules/@types/node/http2.d.ts", 568 | "./node_modules/@types/node/net.d.ts", 569 | "./node_modules/@types/node/stream.d.ts", 570 | "./node_modules/@types/node/tls.d.ts", 571 | "./node_modules/@types/node/url.d.ts" 572 | ], 573 | "./node_modules/@types/node/https.d.ts": [ 574 | "./node_modules/@types/node/http.d.ts", 575 | "./node_modules/@types/node/https.d.ts", 576 | "./node_modules/@types/node/tls.d.ts", 577 | "./node_modules/@types/node/url.d.ts" 578 | ], 579 | "./node_modules/@types/node/index.d.ts": [ 580 | "./node_modules/@types/node/base.d.ts" 581 | ], 582 | "./node_modules/@types/node/inspector.d.ts": [ 583 | "./node_modules/@types/node/events.d.ts", 584 | "./node_modules/@types/node/inspector.d.ts" 585 | ], 586 | "./node_modules/@types/node/module.d.ts": [ 587 | "./node_modules/@types/node/module.d.ts", 588 | "./node_modules/@types/node/url.d.ts" 589 | ], 590 | "./node_modules/@types/node/net.d.ts": [ 591 | "./node_modules/@types/node/dns.d.ts", 592 | "./node_modules/@types/node/events.d.ts", 593 | "./node_modules/@types/node/net.d.ts", 594 | "./node_modules/@types/node/stream.d.ts" 595 | ], 596 | "./node_modules/@types/node/os.d.ts": [ 597 | "./node_modules/@types/node/os.d.ts" 598 | ], 599 | "./node_modules/@types/node/path.d.ts": [ 600 | "./node_modules/@types/node/path.d.ts" 601 | ], 602 | "./node_modules/@types/node/perf_hooks.d.ts": [ 603 | "./node_modules/@types/node/async_hooks.d.ts", 604 | "./node_modules/@types/node/perf_hooks.d.ts" 605 | ], 606 | "./node_modules/@types/node/process.d.ts": [ 607 | "./node_modules/@types/node/tty.d.ts" 608 | ], 609 | "./node_modules/@types/node/punycode.d.ts": [ 610 | "./node_modules/@types/node/punycode.d.ts" 611 | ], 612 | "./node_modules/@types/node/querystring.d.ts": [ 613 | "./node_modules/@types/node/querystring.d.ts" 614 | ], 615 | "./node_modules/@types/node/readline.d.ts": [ 616 | "./node_modules/@types/node/events.d.ts", 617 | "./node_modules/@types/node/readline.d.ts" 618 | ], 619 | "./node_modules/@types/node/repl.d.ts": [ 620 | "./node_modules/@types/node/readline.d.ts", 621 | "./node_modules/@types/node/repl.d.ts", 622 | "./node_modules/@types/node/util.d.ts", 623 | "./node_modules/@types/node/vm.d.ts" 624 | ], 625 | "./node_modules/@types/node/stream.d.ts": [ 626 | "./node_modules/@types/node/events.d.ts", 627 | "./node_modules/@types/node/stream.d.ts" 628 | ], 629 | "./node_modules/@types/node/string_decoder.d.ts": [ 630 | "./node_modules/@types/node/string_decoder.d.ts" 631 | ], 632 | "./node_modules/@types/node/timers.d.ts": [ 633 | "./node_modules/@types/node/timers.d.ts" 634 | ], 635 | "./node_modules/@types/node/tls.d.ts": [ 636 | "./node_modules/@types/node/net.d.ts", 637 | "./node_modules/@types/node/tls.d.ts" 638 | ], 639 | "./node_modules/@types/node/trace_events.d.ts": [ 640 | "./node_modules/@types/node/trace_events.d.ts" 641 | ], 642 | "./node_modules/@types/node/ts3.6/base.d.ts": [ 643 | "./node_modules/@types/node/async_hooks.d.ts", 644 | "./node_modules/@types/node/buffer.d.ts", 645 | "./node_modules/@types/node/child_process.d.ts", 646 | "./node_modules/@types/node/cluster.d.ts", 647 | "./node_modules/@types/node/console.d.ts", 648 | "./node_modules/@types/node/constants.d.ts", 649 | "./node_modules/@types/node/crypto.d.ts", 650 | "./node_modules/@types/node/dgram.d.ts", 651 | "./node_modules/@types/node/dns.d.ts", 652 | "./node_modules/@types/node/domain.d.ts", 653 | "./node_modules/@types/node/events.d.ts", 654 | "./node_modules/@types/node/fs.d.ts", 655 | "./node_modules/@types/node/fs/promises.d.ts", 656 | "./node_modules/@types/node/globals.d.ts", 657 | "./node_modules/@types/node/globals.global.d.ts", 658 | "./node_modules/@types/node/http.d.ts", 659 | "./node_modules/@types/node/http2.d.ts", 660 | "./node_modules/@types/node/https.d.ts", 661 | "./node_modules/@types/node/inspector.d.ts", 662 | "./node_modules/@types/node/module.d.ts", 663 | "./node_modules/@types/node/net.d.ts", 664 | "./node_modules/@types/node/os.d.ts", 665 | "./node_modules/@types/node/path.d.ts", 666 | "./node_modules/@types/node/perf_hooks.d.ts", 667 | "./node_modules/@types/node/process.d.ts", 668 | "./node_modules/@types/node/punycode.d.ts", 669 | "./node_modules/@types/node/querystring.d.ts", 670 | "./node_modules/@types/node/readline.d.ts", 671 | "./node_modules/@types/node/repl.d.ts", 672 | "./node_modules/@types/node/stream.d.ts", 673 | "./node_modules/@types/node/string_decoder.d.ts", 674 | "./node_modules/@types/node/timers.d.ts", 675 | "./node_modules/@types/node/tls.d.ts", 676 | "./node_modules/@types/node/trace_events.d.ts", 677 | "./node_modules/@types/node/tty.d.ts", 678 | "./node_modules/@types/node/url.d.ts", 679 | "./node_modules/@types/node/util.d.ts", 680 | "./node_modules/@types/node/v8.d.ts", 681 | "./node_modules/@types/node/vm.d.ts", 682 | "./node_modules/@types/node/wasi.d.ts", 683 | "./node_modules/@types/node/worker_threads.d.ts", 684 | "./node_modules/@types/node/zlib.d.ts" 685 | ], 686 | "./node_modules/@types/node/tty.d.ts": [ 687 | "./node_modules/@types/node/net.d.ts", 688 | "./node_modules/@types/node/tty.d.ts" 689 | ], 690 | "./node_modules/@types/node/url.d.ts": [ 691 | "./node_modules/@types/node/querystring.d.ts", 692 | "./node_modules/@types/node/url.d.ts" 693 | ], 694 | "./node_modules/@types/node/util.d.ts": [ 695 | "./node_modules/@types/node/util.d.ts" 696 | ], 697 | "./node_modules/@types/node/v8.d.ts": [ 698 | "./node_modules/@types/node/stream.d.ts", 699 | "./node_modules/@types/node/v8.d.ts" 700 | ], 701 | "./node_modules/@types/node/vm.d.ts": [ 702 | "./node_modules/@types/node/vm.d.ts" 703 | ], 704 | "./node_modules/@types/node/wasi.d.ts": [ 705 | "./node_modules/@types/node/wasi.d.ts" 706 | ], 707 | "./node_modules/@types/node/worker_threads.d.ts": [ 708 | "./node_modules/@types/node/events.d.ts", 709 | "./node_modules/@types/node/fs/promises.d.ts", 710 | "./node_modules/@types/node/stream.d.ts", 711 | "./node_modules/@types/node/url.d.ts", 712 | "./node_modules/@types/node/vm.d.ts", 713 | "./node_modules/@types/node/worker_threads.d.ts" 714 | ], 715 | "./node_modules/@types/node/zlib.d.ts": [ 716 | "./node_modules/@types/node/stream.d.ts", 717 | "./node_modules/@types/node/zlib.d.ts" 718 | ], 719 | "./src/actions/index.ts": [ 720 | "./src/actions/create-invoice/index.ts", 721 | "./src/actions/create-payment/index.ts", 722 | "./src/actions/get-currencies/index.ts", 723 | "./src/actions/get-estimate-price/index.ts", 724 | "./src/actions/get-list-payments/index.ts", 725 | "./src/actions/get-minimum-payment-status/index.ts", 726 | "./src/actions/get-payment-status/index.ts", 727 | "./src/actions/status/index.ts" 728 | ], 729 | "./src/index.ts": [ 730 | "./src/actions/index.ts" 731 | ] 732 | }, 733 | "exportedModulesMap": { 734 | "./node_modules/@types/eslint-scope/index.d.ts": [ 735 | "./node_modules/@types/eslint/index.d.ts", 736 | "./node_modules/@types/estree/index.d.ts" 737 | ], 738 | "./node_modules/@types/eslint/index.d.ts": [ 739 | "./node_modules/@types/eslint/helpers.d.ts", 740 | "./node_modules/@types/eslint/lib/rules/index.d.ts", 741 | "./node_modules/@types/estree/index.d.ts", 742 | "./node_modules/@types/json-schema/index.d.ts" 743 | ], 744 | "./node_modules/@types/eslint/lib/rules/index.d.ts": [ 745 | "./node_modules/@types/eslint/index.d.ts" 746 | ], 747 | "./node_modules/@types/node/assert.d.ts": [ 748 | "./node_modules/@types/node/assert.d.ts" 749 | ], 750 | "./node_modules/@types/node/async_hooks.d.ts": [ 751 | "./node_modules/@types/node/async_hooks.d.ts" 752 | ], 753 | "./node_modules/@types/node/base.d.ts": [ 754 | "./node_modules/@types/node/assert.d.ts", 755 | "./node_modules/@types/node/ts3.6/base.d.ts" 756 | ], 757 | "./node_modules/@types/node/buffer.d.ts": [ 758 | "./node_modules/@types/node/buffer.d.ts" 759 | ], 760 | "./node_modules/@types/node/child_process.d.ts": [ 761 | "./node_modules/@types/node/child_process.d.ts", 762 | "./node_modules/@types/node/events.d.ts", 763 | "./node_modules/@types/node/fs.d.ts", 764 | "./node_modules/@types/node/net.d.ts", 765 | "./node_modules/@types/node/stream.d.ts" 766 | ], 767 | "./node_modules/@types/node/cluster.d.ts": [ 768 | "./node_modules/@types/node/child_process.d.ts", 769 | "./node_modules/@types/node/cluster.d.ts", 770 | "./node_modules/@types/node/events.d.ts", 771 | "./node_modules/@types/node/net.d.ts" 772 | ], 773 | "./node_modules/@types/node/console.d.ts": [ 774 | "./node_modules/@types/node/util.d.ts" 775 | ], 776 | "./node_modules/@types/node/constants.d.ts": [ 777 | "./node_modules/@types/node/constants.d.ts", 778 | "./node_modules/@types/node/crypto.d.ts", 779 | "./node_modules/@types/node/fs.d.ts", 780 | "./node_modules/@types/node/os.d.ts" 781 | ], 782 | "./node_modules/@types/node/crypto.d.ts": [ 783 | "./node_modules/@types/node/crypto.d.ts", 784 | "./node_modules/@types/node/stream.d.ts" 785 | ], 786 | "./node_modules/@types/node/dgram.d.ts": [ 787 | "./node_modules/@types/node/dgram.d.ts", 788 | "./node_modules/@types/node/dns.d.ts", 789 | "./node_modules/@types/node/events.d.ts", 790 | "./node_modules/@types/node/net.d.ts" 791 | ], 792 | "./node_modules/@types/node/dns.d.ts": [ 793 | "./node_modules/@types/node/dns.d.ts" 794 | ], 795 | "./node_modules/@types/node/domain.d.ts": [ 796 | "./node_modules/@types/node/domain.d.ts", 797 | "./node_modules/@types/node/events.d.ts" 798 | ], 799 | "./node_modules/@types/node/events.d.ts": [ 800 | "./node_modules/@types/node/events.d.ts" 801 | ], 802 | "./node_modules/@types/node/fs.d.ts": [ 803 | "./node_modules/@types/node/events.d.ts", 804 | "./node_modules/@types/node/fs.d.ts", 805 | "./node_modules/@types/node/fs/promises.d.ts", 806 | "./node_modules/@types/node/stream.d.ts", 807 | "./node_modules/@types/node/url.d.ts" 808 | ], 809 | "./node_modules/@types/node/fs/promises.d.ts": [ 810 | "./node_modules/@types/node/fs.d.ts", 811 | "./node_modules/@types/node/fs/promises.d.ts" 812 | ], 813 | "./node_modules/@types/node/http.d.ts": [ 814 | "./node_modules/@types/node/http.d.ts", 815 | "./node_modules/@types/node/net.d.ts", 816 | "./node_modules/@types/node/stream.d.ts", 817 | "./node_modules/@types/node/url.d.ts" 818 | ], 819 | "./node_modules/@types/node/http2.d.ts": [ 820 | "./node_modules/@types/node/events.d.ts", 821 | "./node_modules/@types/node/fs.d.ts", 822 | "./node_modules/@types/node/http.d.ts", 823 | "./node_modules/@types/node/http2.d.ts", 824 | "./node_modules/@types/node/net.d.ts", 825 | "./node_modules/@types/node/stream.d.ts", 826 | "./node_modules/@types/node/tls.d.ts", 827 | "./node_modules/@types/node/url.d.ts" 828 | ], 829 | "./node_modules/@types/node/https.d.ts": [ 830 | "./node_modules/@types/node/http.d.ts", 831 | "./node_modules/@types/node/https.d.ts", 832 | "./node_modules/@types/node/tls.d.ts", 833 | "./node_modules/@types/node/url.d.ts" 834 | ], 835 | "./node_modules/@types/node/index.d.ts": [ 836 | "./node_modules/@types/node/base.d.ts" 837 | ], 838 | "./node_modules/@types/node/inspector.d.ts": [ 839 | "./node_modules/@types/node/events.d.ts", 840 | "./node_modules/@types/node/inspector.d.ts" 841 | ], 842 | "./node_modules/@types/node/module.d.ts": [ 843 | "./node_modules/@types/node/module.d.ts", 844 | "./node_modules/@types/node/url.d.ts" 845 | ], 846 | "./node_modules/@types/node/net.d.ts": [ 847 | "./node_modules/@types/node/dns.d.ts", 848 | "./node_modules/@types/node/events.d.ts", 849 | "./node_modules/@types/node/net.d.ts", 850 | "./node_modules/@types/node/stream.d.ts" 851 | ], 852 | "./node_modules/@types/node/os.d.ts": [ 853 | "./node_modules/@types/node/os.d.ts" 854 | ], 855 | "./node_modules/@types/node/path.d.ts": [ 856 | "./node_modules/@types/node/path.d.ts" 857 | ], 858 | "./node_modules/@types/node/perf_hooks.d.ts": [ 859 | "./node_modules/@types/node/async_hooks.d.ts", 860 | "./node_modules/@types/node/perf_hooks.d.ts" 861 | ], 862 | "./node_modules/@types/node/process.d.ts": [ 863 | "./node_modules/@types/node/tty.d.ts" 864 | ], 865 | "./node_modules/@types/node/punycode.d.ts": [ 866 | "./node_modules/@types/node/punycode.d.ts" 867 | ], 868 | "./node_modules/@types/node/querystring.d.ts": [ 869 | "./node_modules/@types/node/querystring.d.ts" 870 | ], 871 | "./node_modules/@types/node/readline.d.ts": [ 872 | "./node_modules/@types/node/events.d.ts", 873 | "./node_modules/@types/node/readline.d.ts" 874 | ], 875 | "./node_modules/@types/node/repl.d.ts": [ 876 | "./node_modules/@types/node/readline.d.ts", 877 | "./node_modules/@types/node/repl.d.ts", 878 | "./node_modules/@types/node/util.d.ts", 879 | "./node_modules/@types/node/vm.d.ts" 880 | ], 881 | "./node_modules/@types/node/stream.d.ts": [ 882 | "./node_modules/@types/node/events.d.ts", 883 | "./node_modules/@types/node/stream.d.ts" 884 | ], 885 | "./node_modules/@types/node/string_decoder.d.ts": [ 886 | "./node_modules/@types/node/string_decoder.d.ts" 887 | ], 888 | "./node_modules/@types/node/timers.d.ts": [ 889 | "./node_modules/@types/node/timers.d.ts" 890 | ], 891 | "./node_modules/@types/node/tls.d.ts": [ 892 | "./node_modules/@types/node/net.d.ts", 893 | "./node_modules/@types/node/tls.d.ts" 894 | ], 895 | "./node_modules/@types/node/trace_events.d.ts": [ 896 | "./node_modules/@types/node/trace_events.d.ts" 897 | ], 898 | "./node_modules/@types/node/ts3.6/base.d.ts": [ 899 | "./node_modules/@types/node/async_hooks.d.ts", 900 | "./node_modules/@types/node/buffer.d.ts", 901 | "./node_modules/@types/node/child_process.d.ts", 902 | "./node_modules/@types/node/cluster.d.ts", 903 | "./node_modules/@types/node/console.d.ts", 904 | "./node_modules/@types/node/constants.d.ts", 905 | "./node_modules/@types/node/crypto.d.ts", 906 | "./node_modules/@types/node/dgram.d.ts", 907 | "./node_modules/@types/node/dns.d.ts", 908 | "./node_modules/@types/node/domain.d.ts", 909 | "./node_modules/@types/node/events.d.ts", 910 | "./node_modules/@types/node/fs.d.ts", 911 | "./node_modules/@types/node/fs/promises.d.ts", 912 | "./node_modules/@types/node/globals.d.ts", 913 | "./node_modules/@types/node/globals.global.d.ts", 914 | "./node_modules/@types/node/http.d.ts", 915 | "./node_modules/@types/node/http2.d.ts", 916 | "./node_modules/@types/node/https.d.ts", 917 | "./node_modules/@types/node/inspector.d.ts", 918 | "./node_modules/@types/node/module.d.ts", 919 | "./node_modules/@types/node/net.d.ts", 920 | "./node_modules/@types/node/os.d.ts", 921 | "./node_modules/@types/node/path.d.ts", 922 | "./node_modules/@types/node/perf_hooks.d.ts", 923 | "./node_modules/@types/node/process.d.ts", 924 | "./node_modules/@types/node/punycode.d.ts", 925 | "./node_modules/@types/node/querystring.d.ts", 926 | "./node_modules/@types/node/readline.d.ts", 927 | "./node_modules/@types/node/repl.d.ts", 928 | "./node_modules/@types/node/stream.d.ts", 929 | "./node_modules/@types/node/string_decoder.d.ts", 930 | "./node_modules/@types/node/timers.d.ts", 931 | "./node_modules/@types/node/tls.d.ts", 932 | "./node_modules/@types/node/trace_events.d.ts", 933 | "./node_modules/@types/node/tty.d.ts", 934 | "./node_modules/@types/node/url.d.ts", 935 | "./node_modules/@types/node/util.d.ts", 936 | "./node_modules/@types/node/v8.d.ts", 937 | "./node_modules/@types/node/vm.d.ts", 938 | "./node_modules/@types/node/wasi.d.ts", 939 | "./node_modules/@types/node/worker_threads.d.ts", 940 | "./node_modules/@types/node/zlib.d.ts" 941 | ], 942 | "./node_modules/@types/node/tty.d.ts": [ 943 | "./node_modules/@types/node/net.d.ts", 944 | "./node_modules/@types/node/tty.d.ts" 945 | ], 946 | "./node_modules/@types/node/url.d.ts": [ 947 | "./node_modules/@types/node/querystring.d.ts", 948 | "./node_modules/@types/node/url.d.ts" 949 | ], 950 | "./node_modules/@types/node/util.d.ts": [ 951 | "./node_modules/@types/node/util.d.ts" 952 | ], 953 | "./node_modules/@types/node/v8.d.ts": [ 954 | "./node_modules/@types/node/stream.d.ts", 955 | "./node_modules/@types/node/v8.d.ts" 956 | ], 957 | "./node_modules/@types/node/vm.d.ts": [ 958 | "./node_modules/@types/node/vm.d.ts" 959 | ], 960 | "./node_modules/@types/node/wasi.d.ts": [ 961 | "./node_modules/@types/node/wasi.d.ts" 962 | ], 963 | "./node_modules/@types/node/worker_threads.d.ts": [ 964 | "./node_modules/@types/node/events.d.ts", 965 | "./node_modules/@types/node/fs/promises.d.ts", 966 | "./node_modules/@types/node/stream.d.ts", 967 | "./node_modules/@types/node/url.d.ts", 968 | "./node_modules/@types/node/vm.d.ts", 969 | "./node_modules/@types/node/worker_threads.d.ts" 970 | ], 971 | "./node_modules/@types/node/zlib.d.ts": [ 972 | "./node_modules/@types/node/stream.d.ts", 973 | "./node_modules/@types/node/zlib.d.ts" 974 | ] 975 | }, 976 | "semanticDiagnosticsPerFile": [ 977 | "./node_modules/@types/eslint-scope/index.d.ts", 978 | "./node_modules/@types/eslint/helpers.d.ts", 979 | "./node_modules/@types/eslint/index.d.ts", 980 | "./node_modules/@types/eslint/lib/rules/index.d.ts", 981 | "./node_modules/@types/estree/index.d.ts", 982 | "./node_modules/@types/json-schema/index.d.ts", 983 | "./node_modules/@types/node/assert.d.ts", 984 | "./node_modules/@types/node/async_hooks.d.ts", 985 | "./node_modules/@types/node/base.d.ts", 986 | "./node_modules/@types/node/buffer.d.ts", 987 | "./node_modules/@types/node/child_process.d.ts", 988 | "./node_modules/@types/node/cluster.d.ts", 989 | "./node_modules/@types/node/console.d.ts", 990 | "./node_modules/@types/node/constants.d.ts", 991 | "./node_modules/@types/node/crypto.d.ts", 992 | "./node_modules/@types/node/dgram.d.ts", 993 | "./node_modules/@types/node/dns.d.ts", 994 | "./node_modules/@types/node/domain.d.ts", 995 | "./node_modules/@types/node/events.d.ts", 996 | "./node_modules/@types/node/fs.d.ts", 997 | "./node_modules/@types/node/fs/promises.d.ts", 998 | "./node_modules/@types/node/globals.d.ts", 999 | "./node_modules/@types/node/globals.global.d.ts", 1000 | "./node_modules/@types/node/http.d.ts", 1001 | "./node_modules/@types/node/http2.d.ts", 1002 | "./node_modules/@types/node/https.d.ts", 1003 | "./node_modules/@types/node/index.d.ts", 1004 | "./node_modules/@types/node/inspector.d.ts", 1005 | "./node_modules/@types/node/module.d.ts", 1006 | "./node_modules/@types/node/net.d.ts", 1007 | "./node_modules/@types/node/os.d.ts", 1008 | "./node_modules/@types/node/path.d.ts", 1009 | "./node_modules/@types/node/perf_hooks.d.ts", 1010 | "./node_modules/@types/node/process.d.ts", 1011 | "./node_modules/@types/node/punycode.d.ts", 1012 | "./node_modules/@types/node/querystring.d.ts", 1013 | "./node_modules/@types/node/readline.d.ts", 1014 | "./node_modules/@types/node/repl.d.ts", 1015 | "./node_modules/@types/node/stream.d.ts", 1016 | "./node_modules/@types/node/string_decoder.d.ts", 1017 | "./node_modules/@types/node/timers.d.ts", 1018 | "./node_modules/@types/node/tls.d.ts", 1019 | "./node_modules/@types/node/trace_events.d.ts", 1020 | "./node_modules/@types/node/ts3.6/base.d.ts", 1021 | "./node_modules/@types/node/tty.d.ts", 1022 | "./node_modules/@types/node/url.d.ts", 1023 | "./node_modules/@types/node/util.d.ts", 1024 | "./node_modules/@types/node/v8.d.ts", 1025 | "./node_modules/@types/node/vm.d.ts", 1026 | "./node_modules/@types/node/wasi.d.ts", 1027 | "./node_modules/@types/node/worker_threads.d.ts", 1028 | "./node_modules/@types/node/zlib.d.ts", 1029 | "./node_modules/typescript/lib/lib.dom.d.ts", 1030 | "./node_modules/typescript/lib/lib.es2015.collection.d.ts", 1031 | "./node_modules/typescript/lib/lib.es2015.core.d.ts", 1032 | "./node_modules/typescript/lib/lib.es2015.d.ts", 1033 | "./node_modules/typescript/lib/lib.es2015.generator.d.ts", 1034 | "./node_modules/typescript/lib/lib.es2015.iterable.d.ts", 1035 | "./node_modules/typescript/lib/lib.es2015.promise.d.ts", 1036 | "./node_modules/typescript/lib/lib.es2015.proxy.d.ts", 1037 | "./node_modules/typescript/lib/lib.es2015.reflect.d.ts", 1038 | "./node_modules/typescript/lib/lib.es2015.symbol.d.ts", 1039 | "./node_modules/typescript/lib/lib.es2015.symbol.wellknown.d.ts", 1040 | "./node_modules/typescript/lib/lib.es2016.array.include.d.ts", 1041 | "./node_modules/typescript/lib/lib.es2016.d.ts", 1042 | "./node_modules/typescript/lib/lib.es2017.d.ts", 1043 | "./node_modules/typescript/lib/lib.es2017.intl.d.ts", 1044 | "./node_modules/typescript/lib/lib.es2017.object.d.ts", 1045 | "./node_modules/typescript/lib/lib.es2017.sharedmemory.d.ts", 1046 | "./node_modules/typescript/lib/lib.es2017.string.d.ts", 1047 | "./node_modules/typescript/lib/lib.es2017.typedarrays.d.ts", 1048 | "./node_modules/typescript/lib/lib.es2018.asyncgenerator.d.ts", 1049 | "./node_modules/typescript/lib/lib.es2018.asynciterable.d.ts", 1050 | "./node_modules/typescript/lib/lib.es2018.d.ts", 1051 | "./node_modules/typescript/lib/lib.es2018.intl.d.ts", 1052 | "./node_modules/typescript/lib/lib.es2018.promise.d.ts", 1053 | "./node_modules/typescript/lib/lib.es2018.regexp.d.ts", 1054 | "./node_modules/typescript/lib/lib.es2020.bigint.d.ts", 1055 | "./node_modules/typescript/lib/lib.es5.d.ts", 1056 | "./node_modules/typescript/lib/lib.esnext.intl.d.ts", 1057 | "./src/actions/create-invoice/index.ts", 1058 | "./src/actions/create-payment/index.ts", 1059 | "./src/actions/get-currencies/index.ts", 1060 | "./src/actions/get-estimate-price/index.ts", 1061 | "./src/actions/get-list-payments/index.ts", 1062 | "./src/actions/get-minimum-payment-status/index.ts", 1063 | "./src/actions/get-payment-status/index.ts", 1064 | "./src/actions/index.ts", 1065 | "./src/actions/status/index.ts", 1066 | "./src/index.ts" 1067 | ] 1068 | }, 1069 | "version": "4.2.3" 1070 | } -------------------------------------------------------------------------------- /tslint.json: -------------------------------------------------------------------------------- 1 | { 2 | "extends": [ 3 | "tslint:recommended" 4 | ], 5 | "rules": {} 6 | } -------------------------------------------------------------------------------- /webpack.config.js: -------------------------------------------------------------------------------- 1 | const path = require('path') 2 | 3 | const config = {} 4 | 5 | function generateConfig(name) { 6 | const compress = name.indexOf('min') > -1 7 | const config = { 8 | target: 'node', 9 | entry: './src/index.ts', 10 | output: { 11 | path: path.resolve(__dirname, 'dist'), 12 | filename: name + '.js', 13 | library: 'NOWPaymentsApiJS', 14 | libraryTarget: 'umd', 15 | globalObject: 'this', 16 | umdNamedDefine: true 17 | }, 18 | resolve: { 19 | extensions: ['.js', '.ts'] 20 | }, 21 | devtool: 'source-map', 22 | mode: compress ? 'production' : 'development', 23 | module: { 24 | rules: [ 25 | { 26 | test: /\.ts?$/, 27 | use: 'ts-loader', 28 | exclude: /node_modules/ 29 | } 30 | ] 31 | } 32 | } 33 | return config 34 | } 35 | 36 | ['nowpayments-api-js', 'nowpayments-api-js.min'].forEach(function (key) { 37 | config[key] = generateConfig(key) 38 | }) 39 | 40 | module.exports = config 41 | --------------------------------------------------------------------------------