@heyatom/bastion-client 0.1.0 → 0.1.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.
Files changed (2) hide show
  1. package/README.md +1 -1
  2. package/package.json +12 -2
package/README.md CHANGED
@@ -6,7 +6,7 @@ Replaces the `src/modules/bastion/` boilerplate every service used to copy by ha
6
6
  - `@heyatom/bastion-client` — framework-free core: `JwksVerifier` (kid-indexed cache, unknown-kid refetch with cooldown, stale-on-error), `BastionHttp` (`POST /auth/client`, `POST /events`, any other route), `ServiceTokenProvider` (single-flight refresh ahead of `exp`), payload types.
7
7
  - `@heyatom/bastion-client/nest` — NestJS: `BastionModule`, `ServiceClientJwtGuard`, `BastionUserGuard`, `BastionAuditService`, `AuditInterceptor`, `@Public()`, `@RequireScope()`, `@Audit()`, `@CurrentClient()`, `@CurrentAdminUser()`.
8
8
 
9
- Ships CJS and ESM. Peer deps: `jose` (always), `@nestjs/common`, `@nestjs/core`, `rxjs`, `reflect-metadata` (for `/nest`).
9
+ Ships CJS and ESM. `jose` v6 is ESM-only, so the CJS build relies on Node's `require(esm)` — Node ≥ 20.19 / 22.12. Peer deps: `jose` (always), `@nestjs/common`, `@nestjs/core`, `rxjs`, `reflect-metadata` (for `/nest`).
10
10
 
11
11
  ## NestJS
12
12
 
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@heyatom/bastion-client",
3
- "version": "0.1.0",
3
+ "version": "0.1.1",
4
4
  "description": "Consumer SDK for the Bastion identity provider: JWKS verification, service-client auth, audit writes, NestJS guards",
5
5
  "license": "MIT",
6
6
  "author": "Andrea Tombolato <hey@heyatom.dev> (https://heyatom.dev)",
@@ -38,7 +38,7 @@
38
38
  }
39
39
  },
40
40
  "engines": {
41
- "node": ">=20"
41
+ "node": ">=20.19"
42
42
  },
43
43
  "peerDependencies": {
44
44
  "@nestjs/common": "^11.0.0",
@@ -71,6 +71,16 @@
71
71
  "typescript": "^5.9.3",
72
72
  "vitest": "^3.2.4"
73
73
  },
74
+ "typesVersions": {
75
+ "*": {
76
+ "nest": [
77
+ "./dist/cjs/nest/index.d.ts"
78
+ ],
79
+ "*": [
80
+ "./dist/cjs/core/index.d.ts"
81
+ ]
82
+ }
83
+ },
74
84
  "scripts": {
75
85
  "build": "rm -rf dist && tsc -p tsconfig.cjs.json && tsc -p tsconfig.esm.json && echo '{\"type\":\"module\"}' > dist/esm/package.json",
76
86
  "test": "vitest run",