@assinafy/sdk 3.1.0 → 4.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/CHANGELOG.md +133 -30
- package/README.en.md +16 -17
- package/README.md +16 -19
- package/SECURITY.md +10 -10
- package/dist/index.d.mts +1086 -1303
- package/dist/index.d.ts +1086 -1303
- package/dist/index.js +1282 -1590
- package/dist/index.mjs +1282 -1589
- package/docs/API_COVERAGE.md +49 -56
- package/docs/COMPATIBILITY.md +46 -266
- package/docs/README.en.md +143 -156
- package/docs/README.md +130 -152
- package/docs/RELEASING.md +25 -28
- package/package.json +5 -4
package/docs/RELEASING.md
CHANGED
|
@@ -1,9 +1,8 @@
|
|
|
1
1
|
# Releasing
|
|
2
2
|
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
event, so the workflow creates the GitHub Release page after both registries
|
|
3
|
+
To release, push a `v*` tag matching `package.json` on `main`. The release
|
|
4
|
+
workflow (`.github/workflows/release.yml`) verifies, packs once, publishes to
|
|
5
|
+
npm and GitHub Packages, and creates the GitHub Release after both registries
|
|
7
6
|
accept the package.
|
|
8
7
|
|
|
9
8
|
## Release support matrix
|
|
@@ -12,11 +11,11 @@ accept the package.
|
|
|
12
11
|
| --- | --- |
|
|
13
12
|
| Bun 1.4.4 | Locked install, tests, build, contract checks, and packaging |
|
|
14
13
|
| Node.js 22 | Minimum supported consumer runtime |
|
|
15
|
-
| Node.js 24 LTS |
|
|
14
|
+
| Node.js 24 LTS | CI verification and consumer compatibility |
|
|
16
15
|
| Node.js 26 LTS | GitHub packaging, registry publishing and consumer compatibility |
|
|
17
16
|
|
|
18
|
-
Keep this table, `package.json`,
|
|
19
|
-
|
|
17
|
+
Keep this table, `package.json`, and the CI workflows synchronized when
|
|
18
|
+
changing runtime support.
|
|
20
19
|
|
|
21
20
|
## One-time registry setup
|
|
22
21
|
|
|
@@ -48,19 +47,16 @@ The `publish-gh` job uses the workflow-scoped `GITHUB_TOKEN` with
|
|
|
48
47
|
the `@assinafy` scope and that the package remains linked to this repository.
|
|
49
48
|
No separate personal access token should be stored.
|
|
50
49
|
|
|
51
|
-
###
|
|
50
|
+
### Tag protection
|
|
52
51
|
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
`release` environment with required reviewers and a deployment tag rule for
|
|
58
|
-
`v*`. GitHub Actions must be enabled on the mirror.
|
|
52
|
+
Add a GitHub tag ruleset that restricts creating, updating, and deleting `v*`
|
|
53
|
+
tags to release maintainers. Protect the GitHub `release` environment with
|
|
54
|
+
required reviewers and a deployment tag rule for `v*`. GitHub Actions must be
|
|
55
|
+
enabled on the repository.
|
|
59
56
|
|
|
60
57
|
## Preparing a release
|
|
61
58
|
|
|
62
|
-
1. Merge the complete change
|
|
63
|
-
GitHub CI are green.
|
|
59
|
+
1. Merge the complete change to `main` and confirm CI is green.
|
|
64
60
|
2. Choose the semantic version and update `package.json`. Keep the tag exactly
|
|
65
61
|
`v<package-version>`; the workflow rejects a mismatch.
|
|
66
62
|
3. Update `CHANGELOG.md`, API coverage, compatibility notes, and public examples
|
|
@@ -74,7 +70,8 @@ deleting the same pattern to the mirror/release maintainers. Protect the GitHub
|
|
|
74
70
|
bun run audit:api
|
|
75
71
|
```
|
|
76
72
|
|
|
77
|
-
5. For API changes, run the local
|
|
73
|
+
5. For API changes, run the local live smoke utility against a dedicated,
|
|
74
|
+
disposable test workspace that holds no customer data.
|
|
78
75
|
The gitignored live-test utilities are supplied separately by maintainers;
|
|
79
76
|
the required `scripts/node-consumer-smoke.mjs` CI runner remains tracked.
|
|
80
77
|
Start read-only:
|
|
@@ -82,7 +79,7 @@ deleting the same pattern to the mirror/release maintainers. Protect the GitHub
|
|
|
82
79
|
```sh
|
|
83
80
|
ASSINAFY_API_KEY='...' \
|
|
84
81
|
ASSINAFY_ACCOUNT_ID='...' \
|
|
85
|
-
ASSINAFY_BASE_URL='
|
|
82
|
+
ASSINAFY_BASE_URL='<API URL of a dedicated test workspace>' \
|
|
86
83
|
bun scripts/live-smoke.ts
|
|
87
84
|
```
|
|
88
85
|
|
|
@@ -91,24 +88,24 @@ deleting the same pattern to the mirror/release maintainers. Protect the GitHub
|
|
|
91
88
|
```sh
|
|
92
89
|
ASSINAFY_API_KEY='...' \
|
|
93
90
|
ASSINAFY_ACCOUNT_ID='...' \
|
|
94
|
-
ASSINAFY_BASE_URL='
|
|
91
|
+
ASSINAFY_BASE_URL='<API URL of a dedicated test workspace>' \
|
|
95
92
|
ASSINAFY_TEST_EMAIL_PRIMARY='first@example.com' \
|
|
96
93
|
ASSINAFY_TEST_EMAIL_SECONDARY='second@example.com' \
|
|
97
94
|
bun scripts/live-smoke.ts --all --confirm-production
|
|
98
95
|
```
|
|
99
96
|
|
|
100
97
|
The suite creates and force-deletes a disposable workspace, but an
|
|
101
|
-
interrupted process can still leave fixtures behind; inspect the
|
|
102
|
-
before releasing. Treat every `FAIL` as a release blocker and review each
|
|
103
|
-
`SKIP` to confirm its
|
|
98
|
+
interrupted process can still leave fixtures behind; inspect the test
|
|
99
|
+
workspace before releasing. Treat every `FAIL` as a release blocker and review each
|
|
100
|
+
`SKIP` to confirm its signer-code/OTP, legal-action,
|
|
104
101
|
final-artifact, or webhook-receiver prerequisite was intentionally absent.
|
|
105
|
-
Never use
|
|
102
|
+
Never use a customer workspace's credentials, real customer data, or
|
|
103
|
+
uncontrolled recipients.
|
|
106
104
|
|
|
107
|
-
6. Commit the version and release notes, merge them to
|
|
108
|
-
|
|
109
|
-
|
|
110
|
-
|
|
111
|
-
not create or move a second tag to work around mirror delay.
|
|
105
|
+
6. Commit the version and release notes, merge them to `main`, then create a
|
|
106
|
+
signed or annotated `v<version>` tag on that exact commit and push the tag.
|
|
107
|
+
7. Confirm that the tag starts the **Release** workflow. Do not create or move
|
|
108
|
+
a second tag to work around a delay.
|
|
112
109
|
|
|
113
110
|
## What the workflow publishes
|
|
114
111
|
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@assinafy/sdk",
|
|
3
|
-
"version": "
|
|
3
|
+
"version": "4.0.1",
|
|
4
4
|
"packageManager": "bun@1.4.4",
|
|
5
5
|
"description": "TypeScript SDK for Assinafy API - Digital signature platform",
|
|
6
6
|
"type": "commonjs",
|
|
@@ -69,10 +69,10 @@
|
|
|
69
69
|
"devDependencies": {
|
|
70
70
|
"@arethetypeswrong/cli": "^0.18.5",
|
|
71
71
|
"@eslint/js": "^10.0.1",
|
|
72
|
-
"@types/bun": "^1.4.
|
|
73
|
-
"@types/node": "^22.20.
|
|
72
|
+
"@types/bun": "^1.4.5",
|
|
73
|
+
"@types/node": "^22.20.7",
|
|
74
74
|
"@typescript/native": "npm:typescript@^7.0.2",
|
|
75
|
-
"eslint": "^10.
|
|
75
|
+
"eslint": "^10.16.0",
|
|
76
76
|
"publint": "^0.3.25",
|
|
77
77
|
"tsup": "^9.0.0",
|
|
78
78
|
"typescript": "^6.0.3",
|
|
@@ -82,6 +82,7 @@
|
|
|
82
82
|
"axios": "^1.21.1"
|
|
83
83
|
},
|
|
84
84
|
"overrides": {
|
|
85
|
+
"cross-spawn": "7.1.2",
|
|
85
86
|
"esbuild": "0.28.2",
|
|
86
87
|
"follow-redirects": "1.16.2",
|
|
87
88
|
"brace-expansion": "5.0.12",
|