@neo-edi/sdk 1.0.0 → 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.
- package/dist/index.js +40 -1
- package/dist/index.mjs +40 -1
- package/package.json +3 -3
package/dist/index.js
CHANGED
|
@@ -60,6 +60,45 @@ var NeoEdiValidationError = class extends NeoEdiError {
|
|
|
60
60
|
}
|
|
61
61
|
};
|
|
62
62
|
|
|
63
|
+
// package.json
|
|
64
|
+
var package_default = {
|
|
65
|
+
name: "@neo-edi/sdk",
|
|
66
|
+
version: "1.0.1",
|
|
67
|
+
description: "TypeScript SDK for the Neo-EDI platform",
|
|
68
|
+
main: "./dist/index.js",
|
|
69
|
+
module: "./dist/index.mjs",
|
|
70
|
+
types: "./dist/index.d.ts",
|
|
71
|
+
exports: {
|
|
72
|
+
".": {
|
|
73
|
+
types: "./dist/index.d.ts",
|
|
74
|
+
import: "./dist/index.mjs",
|
|
75
|
+
require: "./dist/index.js"
|
|
76
|
+
}
|
|
77
|
+
},
|
|
78
|
+
files: [
|
|
79
|
+
"dist"
|
|
80
|
+
],
|
|
81
|
+
scripts: {
|
|
82
|
+
build: "tsup src/index.ts --format cjs,esm --dts",
|
|
83
|
+
dev: "tsup src/index.ts --format cjs,esm --dts --watch",
|
|
84
|
+
test: "echo 'No tests yet'"
|
|
85
|
+
},
|
|
86
|
+
dependencies: {
|
|
87
|
+
"@neo-edi/types": "workspace:*"
|
|
88
|
+
},
|
|
89
|
+
devDependencies: {
|
|
90
|
+
"@types/node": "^20",
|
|
91
|
+
tsup: "^8.0.0",
|
|
92
|
+
typescript: "^5.0.0"
|
|
93
|
+
},
|
|
94
|
+
peerDependencies: {
|
|
95
|
+
"@neo-edi/types": "workspace:*"
|
|
96
|
+
}
|
|
97
|
+
};
|
|
98
|
+
|
|
99
|
+
// src/version.ts
|
|
100
|
+
var SDK_VERSION = package_default.version;
|
|
101
|
+
|
|
63
102
|
// src/http.ts
|
|
64
103
|
var HttpClient = class {
|
|
65
104
|
constructor(config) {
|
|
@@ -68,7 +107,7 @@ var HttpClient = class {
|
|
|
68
107
|
this.timeout = config.timeout ?? 3e4;
|
|
69
108
|
this.defaultHeaders = {
|
|
70
109
|
"Content-Type": "application/json",
|
|
71
|
-
"X-SDK-Version":
|
|
110
|
+
"X-SDK-Version": SDK_VERSION,
|
|
72
111
|
...config.headers
|
|
73
112
|
};
|
|
74
113
|
}
|
package/dist/index.mjs
CHANGED
|
@@ -29,6 +29,45 @@ var NeoEdiValidationError = class extends NeoEdiError {
|
|
|
29
29
|
}
|
|
30
30
|
};
|
|
31
31
|
|
|
32
|
+
// package.json
|
|
33
|
+
var package_default = {
|
|
34
|
+
name: "@neo-edi/sdk",
|
|
35
|
+
version: "1.0.1",
|
|
36
|
+
description: "TypeScript SDK for the Neo-EDI platform",
|
|
37
|
+
main: "./dist/index.js",
|
|
38
|
+
module: "./dist/index.mjs",
|
|
39
|
+
types: "./dist/index.d.ts",
|
|
40
|
+
exports: {
|
|
41
|
+
".": {
|
|
42
|
+
types: "./dist/index.d.ts",
|
|
43
|
+
import: "./dist/index.mjs",
|
|
44
|
+
require: "./dist/index.js"
|
|
45
|
+
}
|
|
46
|
+
},
|
|
47
|
+
files: [
|
|
48
|
+
"dist"
|
|
49
|
+
],
|
|
50
|
+
scripts: {
|
|
51
|
+
build: "tsup src/index.ts --format cjs,esm --dts",
|
|
52
|
+
dev: "tsup src/index.ts --format cjs,esm --dts --watch",
|
|
53
|
+
test: "echo 'No tests yet'"
|
|
54
|
+
},
|
|
55
|
+
dependencies: {
|
|
56
|
+
"@neo-edi/types": "workspace:*"
|
|
57
|
+
},
|
|
58
|
+
devDependencies: {
|
|
59
|
+
"@types/node": "^20",
|
|
60
|
+
tsup: "^8.0.0",
|
|
61
|
+
typescript: "^5.0.0"
|
|
62
|
+
},
|
|
63
|
+
peerDependencies: {
|
|
64
|
+
"@neo-edi/types": "workspace:*"
|
|
65
|
+
}
|
|
66
|
+
};
|
|
67
|
+
|
|
68
|
+
// src/version.ts
|
|
69
|
+
var SDK_VERSION = package_default.version;
|
|
70
|
+
|
|
32
71
|
// src/http.ts
|
|
33
72
|
var HttpClient = class {
|
|
34
73
|
constructor(config) {
|
|
@@ -37,7 +76,7 @@ var HttpClient = class {
|
|
|
37
76
|
this.timeout = config.timeout ?? 3e4;
|
|
38
77
|
this.defaultHeaders = {
|
|
39
78
|
"Content-Type": "application/json",
|
|
40
|
-
"X-SDK-Version":
|
|
79
|
+
"X-SDK-Version": SDK_VERSION,
|
|
41
80
|
...config.headers
|
|
42
81
|
};
|
|
43
82
|
}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@neo-edi/sdk",
|
|
3
|
-
"version": "1.0.
|
|
3
|
+
"version": "1.0.1",
|
|
4
4
|
"description": "TypeScript SDK for the Neo-EDI platform",
|
|
5
5
|
"main": "./dist/index.js",
|
|
6
6
|
"module": "./dist/index.mjs",
|
|
@@ -16,7 +16,7 @@
|
|
|
16
16
|
"dist"
|
|
17
17
|
],
|
|
18
18
|
"dependencies": {
|
|
19
|
-
"@neo-edi/types": "1.0.
|
|
19
|
+
"@neo-edi/types": "1.0.1"
|
|
20
20
|
},
|
|
21
21
|
"devDependencies": {
|
|
22
22
|
"@types/node": "^20",
|
|
@@ -24,7 +24,7 @@
|
|
|
24
24
|
"typescript": "^5.0.0"
|
|
25
25
|
},
|
|
26
26
|
"peerDependencies": {
|
|
27
|
-
"@neo-edi/types": "1.0.
|
|
27
|
+
"@neo-edi/types": "1.0.1"
|
|
28
28
|
},
|
|
29
29
|
"scripts": {
|
|
30
30
|
"build": "tsup src/index.ts --format cjs,esm --dts",
|