@amos.com/node 0.1.37 → 0.1.39
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.d.mts +3 -5
- package/dist/index.d.ts +3 -5
- package/dist/index.js.map +1 -1
- package/dist/index.mjs.map +1 -1
- package/package.json +4 -2
- package/src/index.ts +3 -5
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@amos.com/node",
|
|
3
|
-
"version": "0.1.
|
|
3
|
+
"version": "0.1.39",
|
|
4
4
|
"description": "Node.js client for the Amos Pay API.",
|
|
5
5
|
"main": "dist/index.js",
|
|
6
6
|
"module": "dist/index.mjs",
|
|
@@ -19,6 +19,8 @@
|
|
|
19
19
|
],
|
|
20
20
|
"scripts": {
|
|
21
21
|
"biome": "biome check --write",
|
|
22
|
+
"lint": "biome check",
|
|
23
|
+
"ci": "npm run typecheck && npm run lint && npm run build",
|
|
22
24
|
"build": "tsup",
|
|
23
25
|
"watch": "tsup --watch",
|
|
24
26
|
"typecheck": "tsc --noEmit",
|
|
@@ -56,6 +58,6 @@
|
|
|
56
58
|
"typescript": "5.9.3"
|
|
57
59
|
},
|
|
58
60
|
"engines": {
|
|
59
|
-
"node": ">=
|
|
61
|
+
"node": ">=22.0.0"
|
|
60
62
|
}
|
|
61
63
|
}
|
package/src/index.ts
CHANGED
|
@@ -17,10 +17,9 @@ export const AMOS_API_VERSION = "1";
|
|
|
17
17
|
* fully typed against the OpenAPI spec — paths, path/query/header params,
|
|
18
18
|
* request bodies, and response bodies are all checked at compile time.
|
|
19
19
|
*
|
|
20
|
-
* Provide credentials and the required `X-Api-Version` header
|
|
21
|
-
*
|
|
22
|
-
*
|
|
23
|
-
* idempotency keys.
|
|
20
|
+
* Provide credentials and the required `X-Api-Version` header as default
|
|
21
|
+
* `headers` here. Use `client.use(middleware)` to add per-request behavior
|
|
22
|
+
* such as fresh idempotency keys.
|
|
24
23
|
*
|
|
25
24
|
* @example
|
|
26
25
|
* ```ts
|
|
@@ -39,7 +38,6 @@ export const AMOS_API_VERSION = "1";
|
|
|
39
38
|
* });
|
|
40
39
|
*
|
|
41
40
|
* const { data, error } = await pay.POST("/customers", {
|
|
42
|
-
* params: { header: { "X-Api-Version": AMOS_API_VERSION } },
|
|
43
41
|
* body: { customer: { email: "alex@example.com" } },
|
|
44
42
|
* });
|
|
45
43
|
* ```
|