@zedtech/zedkit-server 0.1.0 → 0.1.2
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/README.md +15 -1
- package/package.json +20 -2
package/README.md
CHANGED
|
@@ -1,18 +1,32 @@
|
|
|
1
1
|
# @zedtech/zedkit-server
|
|
2
2
|
|
|
3
|
-
|
|
3
|
+
[](https://www.npmjs.com/package/@zedtech/zedkit-server)
|
|
4
|
+
[](https://github.com/zedtech-fr/zedkit/blob/main/LICENSE)
|
|
5
|
+
|
|
6
|
+
Harden any Node server in minutes: in-process rate limiting, secret/PII
|
|
7
|
+
redaction for logs, HKDF crypto and HTTP helpers. Original work by the
|
|
4
8
|
same author. Zero runtime dependencies.
|
|
5
9
|
|
|
10
|
+
## Install
|
|
11
|
+
|
|
6
12
|
```sh
|
|
7
13
|
pnpm add @zedtech/zedkit-server
|
|
8
14
|
```
|
|
9
15
|
|
|
16
|
+
## Usage
|
|
17
|
+
|
|
10
18
|
```ts
|
|
11
19
|
import { redactValue } from "@zedtech/zedkit-server";
|
|
12
20
|
|
|
13
21
|
logger.info({ event: "login", user: redactValue(user) });
|
|
14
22
|
```
|
|
15
23
|
|
|
24
|
+
## When to use
|
|
25
|
+
|
|
26
|
+
Reach for this package when you rate-limit, redact logs, sign webhooks,
|
|
27
|
+
or read database error codes on a Node server. For typed errors and IDs
|
|
28
|
+
see `@zedtech/zedkit-core` instead.
|
|
29
|
+
|
|
16
30
|
## API
|
|
17
31
|
|
|
18
32
|
- `MemoryRateLimiter` — fixed-window, in-process rate limiting:
|
package/package.json
CHANGED
|
@@ -1,11 +1,29 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@zedtech/zedkit-server",
|
|
3
|
-
"version": "0.1.
|
|
3
|
+
"version": "0.1.2",
|
|
4
4
|
"publishConfig": {
|
|
5
5
|
"access": "public",
|
|
6
6
|
"registry": "https://registry.npmjs.org/"
|
|
7
7
|
},
|
|
8
|
-
"description": "
|
|
8
|
+
"description": "Harden any Node server in minutes: in-process rate limiting, secret/PII redaction for logs, HKDF crypto and HTTP helpers. Original work by the same author.",
|
|
9
|
+
"keywords": [
|
|
10
|
+
"nodejs",
|
|
11
|
+
"server",
|
|
12
|
+
"rate-limit",
|
|
13
|
+
"rate-limiting",
|
|
14
|
+
"redaction",
|
|
15
|
+
"pii",
|
|
16
|
+
"secrets",
|
|
17
|
+
"logging",
|
|
18
|
+
"hkdf",
|
|
19
|
+
"crypto",
|
|
20
|
+
"http",
|
|
21
|
+
"zero-dependency"
|
|
22
|
+
],
|
|
23
|
+
"homepage": "https://github.com/zedtech-fr/zedkit/tree/main/packages/server",
|
|
24
|
+
"bugs": {
|
|
25
|
+
"url": "https://github.com/zedtech-fr/zedkit/issues"
|
|
26
|
+
},
|
|
9
27
|
"license": "MIT",
|
|
10
28
|
"repository": {
|
|
11
29
|
"type": "git",
|