nodela-sdk 1.0.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -0,0 +1,23 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.BaseResource = void 0;
4
+ class BaseResource {
5
+ constructor(client, basePath) {
6
+ this.client = client;
7
+ this.basePath = basePath;
8
+ }
9
+ buildPath(...segments) {
10
+ return [this.basePath, ...segments].join('/');
11
+ }
12
+ buildQueryString(params) {
13
+ if (!params)
14
+ return '';
15
+ const queryString = Object.entries(params)
16
+ .filter(([, value]) => value !== undefined && value !== null)
17
+ .map(([key, value]) => `${encodeURIComponent(key)}=${encodeURIComponent(String(value))}`)
18
+ .join('&');
19
+ return queryString ? `?${queryString}` : '';
20
+ }
21
+ }
22
+ exports.BaseResource = BaseResource;
23
+ //# sourceMappingURL=base.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"base.js","sourceRoot":"","sources":["../../src/resources/base.ts"],"names":[],"mappings":";;;AAEA,MAAsB,YAAY;IAIhC,YAAY,MAAkB,EAAE,QAAgB;QAC9C,IAAI,CAAC,MAAM,GAAG,MAAM,CAAC;QACrB,IAAI,CAAC,QAAQ,GAAG,QAAQ,CAAC;IAC3B,CAAC;IAES,SAAS,CAAC,GAAG,QAA6B;QAClD,OAAO,CAAC,IAAI,CAAC,QAAQ,EAAE,GAAG,QAAQ,CAAC,CAAC,IAAI,CAAC,GAAG,CAAC,CAAC;IAChD,CAAC;IAES,gBAAgB,CAAC,MAAyC;QAClE,IAAI,CAAC,MAAM;YAAE,OAAO,EAAE,CAAC;QAEvB,MAAM,WAAW,GAAG,MAAM,CAAC,OAAO,CAAC,MAAM,CAAC;aACvC,MAAM,CAAC,CAAC,CAAC,EAAE,KAAK,CAAC,EAAE,EAAE,CAAC,KAAK,KAAK,SAAS,IAAI,KAAK,KAAK,IAAI,CAAC;aAC5D,GAAG,CAAC,CAAC,CAAC,GAAG,EAAE,KAAK,CAAC,EAAE,EAAE,CAAC,GAAG,kBAAkB,CAAC,GAAG,CAAC,IAAI,kBAAkB,CAAC,MAAM,CAAC,KAAK,CAAC,CAAC,EAAE,CAAC;aACxF,IAAI,CAAC,GAAG,CAAC,CAAC;QAEb,OAAO,WAAW,CAAC,CAAC,CAAC,IAAI,WAAW,EAAE,CAAC,CAAC,CAAC,EAAE,CAAC;IAC9C,CAAC;CACF;AAvBD,oCAuBC"}
package/package.json ADDED
@@ -0,0 +1,73 @@
1
+ {
2
+ "name": "nodela-sdk",
3
+ "version": "1.0.1",
4
+ "description": "SDK wrapper for Nodela dev api's to aide in implementation of Nodela on javascript/NodeJs servers, by abstracting away the api complexity and providing easy to use interfaces.",
5
+ "main": "dist/index.js",
6
+ "types": "dist/index.d.ts",
7
+ "files": [
8
+ "dist",
9
+ "README.md",
10
+ "LICENSE"
11
+ ],
12
+ "scripts": {
13
+ "build": "rimraf dist && tsc -p tsconfig.build.json",
14
+ "dev": "tsx watch src/index.ts",
15
+ "test": "jest",
16
+ "test:watch": "jest --watch",
17
+ "test:coverage": "jest --coverage",
18
+ "test:unit": "jest --verbose tests/unit",
19
+ "test:integration": "jest --verbose tests/integration",
20
+ "lint": "eslint src --ext .ts",
21
+ "lint:fix": "eslint src --ext .ts --fix",
22
+ "format": "prettier --write \"src/**/*.ts\"",
23
+ "format:check": "prettier --check \"src/**/*.ts\"",
24
+ "prepublishOnly": "npm run build && npm test",
25
+ "changeset": "changeset",
26
+ "version": "changeset version",
27
+ "release": "npm run build && changeset publish"
28
+ },
29
+ "repository": {
30
+ "type": "git",
31
+ "url": "git+https://github.com/Devkrea8-Technologies/nodela-js-sdk.git"
32
+ },
33
+ "keywords": [
34
+ "Nodela",
35
+ "Stablecoins",
36
+ "SDK",
37
+ "Crypto",
38
+ "Payments"
39
+ ],
40
+ "author": "NodelaPay LTD <sayhello@nodela.co>",
41
+ "license": "MIT",
42
+ "bugs": {
43
+ "url": "https://github.com/Devkrea8-Technologies/nodela-js-sdk/issues"
44
+ },
45
+ "homepage": "https://github.com/Devkrea8-Technologies/nodela-js-sdk#readme",
46
+ "engines": {
47
+ "node": ">=14.0.0"
48
+ },
49
+ "dependencies": {
50
+ "axios": "^1.13.5"
51
+ },
52
+ "devDependencies": {
53
+ "@changesets/cli": "^2.29.8",
54
+ "@eslint/js": "^9.39.2",
55
+ "@types/jest": "^30.0.0",
56
+ "@types/node": "^25.2.3",
57
+ "@typescript-eslint/eslint-plugin": "^8.55.0",
58
+ "@typescript-eslint/parser": "^8.55.0",
59
+ "eslint": "^9.39.2",
60
+ "eslint-config-prettier": "^10.1.8",
61
+ "eslint-plugin-prettier": "^5.5.5",
62
+ "globals": "^17.3.0",
63
+ "jest": "^30.2.0",
64
+ "jiti": "^2.6.1",
65
+ "prettier": "^3.8.1",
66
+ "rimraf": "^6.1.2",
67
+ "ts-jest": "^29.4.6",
68
+ "ts-node": "^10.9.2",
69
+ "tsx": "^4.21.0",
70
+ "typescript": "^5.9.3",
71
+ "typescript-eslint": "^8.55.0"
72
+ }
73
+ }