@nifrajs/cli 2.9.0 → 2.10.0

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/sdk.js ADDED
@@ -0,0 +1,229 @@
1
+ var __rewriteRelativeImportExtension = (this && this.__rewriteRelativeImportExtension) || function (path, preserveJsx) {
2
+ if (typeof path === "string" && /^\.\.?\//.test(path)) {
3
+ return path.replace(/\.(tsx)$|((?:\.d)?)((?:\.[^./]+?)?)\.([cm]?)ts$/i, function (m, tsx, d, ext, cm) {
4
+ return tsx ? preserveJsx ? ".jsx" : ".js" : d && (!ext || !cm) ? m : (d + ext + "." + cm.toLowerCase() + "js");
5
+ });
6
+ }
7
+ return path;
8
+ };
9
+ /** Deterministic, dependency-free SDK generation from the backend's OpenAPI contract. */
10
+ import { existsSync } from "node:fs";
11
+ import { basename, resolve } from "node:path";
12
+ import { toOpenAPI } from "@nifrajs/schema/openapi";
13
+ const HTTP_METHODS = ["get", "post", "put", "patch", "delete", "head", "options"];
14
+ function operations(document) {
15
+ const result = [];
16
+ for (const [path, item] of Object.entries(document.paths).sort(([a], [b]) => a.localeCompare(b))) {
17
+ for (const method of HTTP_METHODS) {
18
+ const operation = item[method];
19
+ if (operation !== null && typeof operation === "object") {
20
+ result.push({ method, path, operation: operation });
21
+ }
22
+ }
23
+ }
24
+ return result;
25
+ }
26
+ function identifier(value, fallback) {
27
+ const startsWithDigit = /^\d/.test(value);
28
+ const normalized = value
29
+ .replace(/[^A-Za-z0-9_]+/g, "_")
30
+ .replace(/_+/g, "_")
31
+ .replace(/^_+|_+$/g, "");
32
+ const safe = startsWithDigit ? `_${normalized}` : normalized;
33
+ return safe === "" || safe === "_" ? fallback : safe;
34
+ }
35
+ function operationName(operation, method, path) {
36
+ return identifier(operation.operationId ?? `${method}_${path}`, `${method}_request`);
37
+ }
38
+ function uniqueNames(items) {
39
+ const counts = new Map();
40
+ return items.map((item) => {
41
+ const count = (counts.get(item) ?? 0) + 1;
42
+ counts.set(item, count);
43
+ return count === 1 ? item : `${item}_${count}`;
44
+ });
45
+ }
46
+ function pathParameters(path) {
47
+ return [...path.matchAll(/\{([^}]+)\}/g)].map((match) => match[1]).filter(Boolean);
48
+ }
49
+ function pythonSdk(document) {
50
+ const entries = operations(document);
51
+ const names = uniqueNames(entries.map(({ method, path, operation }) => operationName(operation, method, path)));
52
+ const methods = [];
53
+ entries.forEach(({ method, path, operation }, index) => {
54
+ const name = names[index];
55
+ const pathParams = pathParameters(path);
56
+ const queryParams = (operation.parameters ?? []).filter((parameter) => parameter.in === "query");
57
+ const used = new Set(["self", "body", ...pathParams]);
58
+ const queryNames = queryParams.map((parameter) => {
59
+ let value = identifier(parameter.name, "query");
60
+ while (used.has(value))
61
+ value += "_";
62
+ used.add(value);
63
+ return value;
64
+ });
65
+ const args = pathParams.map((parameter) => `${identifier(parameter, "param")}: Any`);
66
+ const keywordArgs = queryParams.map((parameter, queryIndex) => {
67
+ const required = parameter.required ? "" : " = None";
68
+ return `${queryNames[queryIndex]}: Any${required}`;
69
+ });
70
+ if (operation.requestBody !== undefined)
71
+ keywordArgs.push("body: Any = None");
72
+ const signature = [...args, ...(keywordArgs.length > 0 ? ["*", ...keywordArgs] : [])].join(", ");
73
+ const query = queryNames.length === 0
74
+ ? "None"
75
+ : `{${queryNames.map((value) => `${JSON.stringify(value)}: ${value}`).join(", ")}}`;
76
+ const paths = pathParams.length === 0
77
+ ? "None"
78
+ : `{${pathParams.map((value) => `${JSON.stringify(value)}: ${identifier(value, "param")}`).join(", ")}}`;
79
+ const body = operation.requestBody === undefined ? "None" : "body";
80
+ methods.push(` def ${name}(self${signature ? `, ${signature}` : ""}) -> Any:\n` +
81
+ ` return self._request(${JSON.stringify(method.toUpperCase())}, ${JSON.stringify(path)}, path_params=${paths}, query=${query}, body=${body})`);
82
+ });
83
+ return `# Generated by nifra. Regenerate with: nifra sdk --lang python
84
+ from __future__ import annotations
85
+
86
+ import json
87
+ import urllib.error
88
+ import urllib.parse
89
+ import urllib.request
90
+ from typing import Any, Mapping
91
+
92
+
93
+ class NifraApiError(RuntimeError):
94
+ def __init__(self, status: int, body: Any):
95
+ super().__init__(f"Nifra API request failed with HTTP {status}")
96
+ self.status = status
97
+ self.body = body
98
+
99
+
100
+ class Client:
101
+ def __init__(self, base_url: str, headers: Mapping[str, str] | None = None, timeout: float = 30.0):
102
+ self.base_url = base_url.rstrip("/")
103
+ self.headers = dict(headers or {})
104
+ self.timeout = timeout
105
+
106
+ def _request(self, method: str, path: str, *, path_params: Mapping[str, Any] | None, query: Mapping[str, Any] | None, body: Any) -> Any:
107
+ route = path
108
+ for key, value in (path_params or {}).items():
109
+ route = route.replace("{" + key + "}", urllib.parse.quote(str(value), safe=""))
110
+ params = [(key, value) for key, value in (query or {}).items() if value is not None]
111
+ url = self.base_url + route
112
+ if params:
113
+ url += ("&" if "?" in url else "?") + urllib.parse.urlencode(params, doseq=True)
114
+ payload = None if body is None else json.dumps(body).encode("utf-8")
115
+ request = urllib.request.Request(url, data=payload, method=method, headers=self.headers)
116
+ if payload is not None:
117
+ request.add_header("Content-Type", "application/json")
118
+ try:
119
+ with urllib.request.urlopen(request, timeout=self.timeout) as response:
120
+ raw = response.read()
121
+ return json.loads(raw) if raw else None
122
+ except urllib.error.HTTPError as error:
123
+ raw = error.read()
124
+ try:
125
+ value = json.loads(raw) if raw else None
126
+ except json.JSONDecodeError:
127
+ value = raw.decode("utf-8", errors="replace")
128
+ raise NifraApiError(error.code, value) from error
129
+
130
+ ${methods.length === 0 ? " pass" : methods.join("\n\n")}
131
+ `;
132
+ }
133
+ function goExportName(value) {
134
+ const name = identifier(value, "Request");
135
+ return name[0].toUpperCase() + name.slice(1);
136
+ }
137
+ function goSdk(document) {
138
+ const entries = operations(document);
139
+ const names = uniqueNames(entries.map(({ method, path, operation }) => operationName(operation, method, path)));
140
+ const methods = [];
141
+ entries.forEach(({ method, path }, index) => {
142
+ const pathParams = pathParameters(path);
143
+ const args = pathParams.map((parameter) => `${identifier(parameter, "param")} string`);
144
+ args.push("query url.Values", "body any");
145
+ const pathMap = pathParams.length === 0
146
+ ? "nil"
147
+ : `map[string]string{${pathParams.map((value) => `${JSON.stringify(value)}: ${identifier(value, "param")}`).join(", ")}}`;
148
+ methods.push(`func (c *Client) ${goExportName(names[index])}(${args.join(", ")}) (any, error) {\n` +
149
+ ` return c.request(http.Method${method[0].toUpperCase()}${method.slice(1)}, ${JSON.stringify(path)}, ${pathMap}, query, body)\n` +
150
+ `}`);
151
+ });
152
+ return `// Code generated by nifra. Regenerate with: nifra sdk --lang go
153
+ package nifrasdk
154
+
155
+ import (
156
+ "bytes"
157
+ "encoding/json"
158
+ "fmt"
159
+ "io"
160
+ "net/http"
161
+ "net/url"
162
+ "strings"
163
+ )
164
+
165
+ type Client struct {
166
+ BaseURL string
167
+ HTTP *http.Client
168
+ Headers http.Header
169
+ }
170
+
171
+ func NewClient(baseURL string) *Client {
172
+ return &Client{BaseURL: strings.TrimRight(baseURL, "/"), HTTP: http.DefaultClient, Headers: make(http.Header)}
173
+ }
174
+
175
+ func (c *Client) request(method, path string, pathParams map[string]string, query url.Values, body any) (any, error) {
176
+ route := path
177
+ for key, value := range pathParams {
178
+ route = strings.ReplaceAll(route, "{"+key+"}", url.PathEscape(value))
179
+ }
180
+ target := c.BaseURL + route
181
+ parsed, err := url.Parse(target)
182
+ if err != nil { return nil, err }
183
+ parsed.RawQuery = query.Encode()
184
+ var reader io.Reader
185
+ if body != nil {
186
+ payload, err := json.Marshal(body)
187
+ if err != nil { return nil, err }
188
+ reader = bytes.NewReader(payload)
189
+ }
190
+ request, err := http.NewRequest(method, parsed.String(), reader)
191
+ if err != nil { return nil, err }
192
+ for key, values := range c.Headers { for _, value := range values { request.Header.Add(key, value) } }
193
+ if body != nil { request.Header.Set("Content-Type", "application/json") }
194
+ response, err := c.HTTP.Do(request)
195
+ if err != nil { return nil, err }
196
+ defer response.Body.Close()
197
+ raw, err := io.ReadAll(response.Body)
198
+ if err != nil { return nil, err }
199
+ var value any
200
+ if len(raw) > 0 { if err := json.Unmarshal(raw, &value); err != nil { value = string(raw) } }
201
+ if response.StatusCode < 200 || response.StatusCode >= 300 { return nil, fmt.Errorf("nifra API request failed with HTTP %d: %v", response.StatusCode, value) }
202
+ return value, nil
203
+ }
204
+
205
+ ${methods.length === 0 ? "// No operations were found.\n" : `${methods.join("\n\n")}\n`}`;
206
+ }
207
+ /** Render a generated SDK. Python uses the standard library; Go uses net/http. */
208
+ export function renderSdk(document, language) {
209
+ return language === "python" ? pythonSdk(document) : goSdk(document);
210
+ }
211
+ /** Load `backend.ts`, generate an SDK, and write it to the project. */
212
+ export async function runSdk(cwd, options) {
213
+ const backendPath = resolve(cwd, "backend.ts");
214
+ if (!existsSync(backendPath)) {
215
+ throw new Error(`[nifra] no backend.ts in ${cwd} - SDK generation needs the API contract.`);
216
+ }
217
+ const backend = (await import(__rewriteRelativeImportExtension(backendPath))).backend;
218
+ if (backend === undefined)
219
+ throw new Error(`[nifra] ${backendPath} does not export \`backend\`.`);
220
+ const document = toOpenAPI(backend, {
221
+ title: `${basename(cwd)} API`,
222
+ version: "1.0.0",
223
+ });
224
+ const extension = options.language === "python" ? "py" : "go";
225
+ const out = resolve(cwd, options.out ?? `nifra_sdk.${extension}`);
226
+ await Bun.write(out, renderSdk(document, options.language));
227
+ console.log(`[nifra] wrote ${options.language} SDK with ${Object.keys(document.paths).length} path${Object.keys(document.paths).length === 1 ? "" : "s"} to ${out}`);
228
+ }
229
+ //# sourceMappingURL=sdk.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"sdk.js","sourceRoot":"","sources":["../src/sdk.ts"],"names":[],"mappings":";;;;;;;;AAAA,yFAAyF;AACzF,OAAO,EAAE,UAAU,EAAE,MAAM,SAAS,CAAA;AACpC,OAAO,EAAE,QAAQ,EAAE,OAAO,EAAE,MAAM,WAAW,CAAA;AAC7C,OAAO,EAAwB,SAAS,EAAE,MAAM,yBAAyB,CAAA;AAczE,MAAM,YAAY,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AA2B,CAAC,OAAO,CAAA;IAC9E,IAAI,OAAO,KAAK,SAAS;QAAE,MAAM,IAAI,KAAK,CAAC,WAAW,WAAW,+BAA+B,CAAC,CAAA;IACjG,MAAM,QAAQ,GAAG,SAAS,CAAC,OAA0C,EAAE;QACrE,KAAK,EAAE,GAAG,QAAQ,CAAC,GAAG,CAAC,MAAM;QAC7B,OAAO,EAAE,OAAO;KACjB,CAAC,CAAA;IACF,MAAM,SAAS,GAAG,OAAO,CAAC,QAAQ,KAAK,QAAQ,CAAC,CAAC,CAAC,IAAI,CAAC,CAAC,CAAC,IAAI,CAAA;IAC7D,MAAM,GAAG,GAAG,OAAO,CAAC,GAAG,EAAE,OAAO,CAAC,GAAG,IAAI,aAAa,SAAS,EAAE,CAAC,CAAA;IACjE,MAAM,GAAG,CAAC,KAAK,CAAC,GAAG,EAAE,SAAS,CAAC,QAAQ,EAAE,OAAO,CAAC,QAAQ,CAAC,CAAC,CAAA;IAC3D,OAAO,CAAC,GAAG,CACT,iBAAiB,OAAO,CAAC,QAAQ,aAAa,MAAM,CAAC,IAAI,CAAC,QAAQ,CAAC,KAAK,CAAC,CAAC,MAAM,QAAQ,MAAM,CAAC,IAAI,CAAC,QAAQ,CAAC,KAAK,CAAC,CAAC,MAAM,KAAK,CAAC,CAAC,CAAC,CAAC,EAAE,CAAC,CAAC,CAAC,GAAG,OAAO,GAAG,EAAE,CACxJ,CAAA;AACH,CAAC"}
@@ -6680,6 +6680,9 @@ done-gate, or `nifra mcp` to give the agent live project tools.
6680
6680
 
6681
6681
  Session primitives for nifra - signed-cookie + server-store sessions, CSRF, and route guards. Bring your own identity (Better Auth / Lucia / OAuth); nifra owns the session.
6682
6682
 
6683
+ `Authorizer`/`requireAuthorization` provide a small public policy seam. The application or data layer
6684
+ must decide ownership and permissions; Nifra stores no policy, tenant, or subject data.
6685
+
6683
6686
  Part of the **[nifra](https://nifra.dev)** full-stack TypeScript framework - one core, five UI libraries, every runtime. Scaffold a new app with `bun create nifra`.
6684
6687
 
6685
6688
  ## Install
@@ -6884,6 +6887,7 @@ nifra assure [--config <file>] [--json] Gate reflected routes against enforcem
6884
6887
  nifra capabilities check [--json] Gate effect provenance + the reviewed capability lockfile.
6885
6888
  nifra manifest emit [--sign <key-ref>] Emit the hash-verified route trust artifact after assurance.
6886
6889
  nifra manifest diff <before> <after> Block promotion on contract/governance regressions.
6890
+ nifra sdk --lang <python|go> Generate a deterministic non-TypeScript SDK from `backend.ts`.
6887
6891
  nifra doctor [--json] [--auto-fix] Catch undeclared imports and duplicate Nifra/React installs.
6888
6892
  ```
6889
6893
 
@@ -7094,6 +7098,11 @@ The Bun-native, contract-first HTTP framework at the heart of [nifra](../../READ
7094
7098
  a radix router, a fully type-inferred server, versionable contracts, lifecycle
7095
7099
  middleware, and production hardening.
7096
7100
 
7101
+ The Web-standard app can be wrapped for Vercel Edge with `toVercelHandler`, Netlify Functions with
7102
+ `toNetlifyHandler`, or API Gateway v1/v2 with `toLambdaHandler` from `@nifrajs/core/server`. These are
7103
+ thin event-envelope adapters; application policy, persistence, and platform credentials stay outside
7104
+ the core.
7105
+
7097
7106
  ```sh
7098
7107
  bun add @nifrajs/core
7099
7108
  ```
@@ -7116,6 +7125,8 @@ available only from their explicit subpaths, so an ordinary HTTP server never ev
7116
7125
  import { defineContract, implement } from "@nifrajs/core/contract"
7117
7126
  import { startCausality } from "@nifrajs/core/causality"
7118
7127
  import { defineAssurancePolicy } from "@nifrajs/core/assurance"
7128
+ import { createDataPort, defineDataContract, diffDataContract } from "@nifrajs/core/data"
7129
+ import { defineChannel, memoryChannelHub } from "@nifrajs/core/channel"
7119
7130
  ```
7120
7131
 
7121
7132
  - **Inline or contract-first.** Write routes inline (types inferred from the
@@ -7165,6 +7176,16 @@ import { defineAssurancePolicy } from "@nifrajs/core/assurance"
7165
7176
  bounded HTTP representations and supplies the same frame/loader adapters for WebSockets and
7166
7177
  deferred data. Import `richWireCodec()` from `@nifrajs/core/transport-codec-rich`; the separate
7167
7178
  subpath keeps rich-wire code out of plain JSON bundles.
7179
+ - **Typed data seam (opt in).** `@nifrajs/core/data` defines token-only operation contracts,
7180
+ `db.read`/`db.write` capability names, an opaque request-local `RlsScope`, typed adapter requests,
7181
+ drift snapshots, and `createDataPort(contract, adapter, { beacon: useCapability })`, which emits the
7182
+ operation's capability evidence - derived from the contract, never from the request - before the
7183
+ private adapter runs. It contains no database driver, tenant identity, policy, row values, or durable
7184
+ store; those belong in the adapter layer.
7185
+ - **Typed channels (opt in).** `@nifrajs/core/channel` defines typed message contracts, bounded
7186
+ subscriptions, cancellation, per-channel resume cursors, bounded local replay, and a process-local
7187
+ in-memory hub for tests. Durable replay, presence, rooms, and multi-instance fan-out remain adapter
7188
+ concerns.
7168
7189
 
7169
7190
  ```ts
7170
7191
  import { defineAssurancePolicy, evaluateRouteAssurance, NIFRA_ASSURANCE } from "@nifrajs/core/assurance"
@@ -7454,10 +7475,21 @@ done-gate, or `nifra mcp` to give the agent live project tools.
7454
7475
 
7455
7476
  ## @nifrajs/image
7456
7477
 
7457
- Image optimization for nifra - a CLS-safe responsive <Image> + pluggable loaders (CDN or self-hosted) + pure-JS dimension reading. Zero-dependency core; optional Bun.Image-backed resize endpoint at @nifrajs/image/server.
7478
+ Image optimization for nifra - a CLS-safe responsive <Image> + pluggable loaders (CDN or self-hosted) + pure-JS dimension reading. The zero-dependency core also includes safe, cacheable Open Graph SVG generation at `@nifrajs/image/og` - useful where you control the consumer, but no major crawler renders SVG for `og:image`, so a social card needs an injected PNG/JPEG rasterizer. The optional Bun.Image-backed resize endpoint lives at `@nifrajs/image/server`.
7458
7479
 
7459
7480
  Part of the **[nifra](https://nifra.dev)** full-stack TypeScript framework - one core, five UI libraries, every runtime. Scaffold a new app with `bun create nifra`.
7460
7481
 
7482
+ For crawler-compatible cards, adapt the renderer you choose to the public PNG seam:
7483
+
7484
+ ```ts
7485
+ import { createResvgRasterizer } from "@nifrajs/image/og-png"
7486
+ import { Resvg } from "@resvg/resvg-js"
7487
+
7488
+ const rasterizer = createResvgRasterizer(Resvg)
7489
+ ```
7490
+
7491
+ The codec remains an application dependency; the package's default stays explicit SVG output.
7492
+
7461
7493
  ## Install
7462
7494
 
7463
7495
  ```sh
@@ -7720,6 +7752,7 @@ import {
7720
7752
  bodyLimit,
7721
7753
  cors,
7722
7754
  MemoryStore,
7755
+ problemDetails,
7723
7756
  rateLimit,
7724
7757
  securityHeaders,
7725
7758
  timing,
@@ -7727,6 +7760,7 @@ import {
7727
7760
 
7728
7761
  const app = server()
7729
7762
  .use(securityHeaders())
7763
+ .use(problemDetails())
7730
7764
  .use(cors({ origin: ["https://app.example.com"], credentials: true }))
7731
7765
  .use(bodyLimit({ maxBytes: 1_000_000 }))
7732
7766
  .use(rateLimit({
@@ -7766,6 +7800,14 @@ const app = server()
7766
7800
  store, `Vary`-aware keys, `Age`, byte caps, and `Cache-Control` / `Set-Cookie` safety defaults.
7767
7801
  `MemoryResponseCache` is dev/single-instance only unless explicitly allowed in production.
7768
7802
  - **`timing()`** - `Server-Timing` plus typed `c.timing.metric/mark/measure` controls.
7803
+ - **`problemDetails()`** - opt-in RFC 9457 `application/problem+json` responses for framework
7804
+ errors. The default `{ ok: false, error }` envelope remains unchanged unless installed; validation
7805
+ issues are preserved, and `includeInstance` includes only the request pathname.
7806
+ - **`rangeResponse()` / `parseByteRange()`** - bounded byte-range responses with 206/416,
7807
+ `If-Range`, multipart ranges, and conditional validators.
7808
+ - **`conditionalResponse()`** - reusable ETag/Last-Modified handling that emits a bodyless 304.
7809
+ - **`negotiateContentType()`** - RFC-style `Accept` matching with q-values, wildcards, and q=0.
7810
+ - **`multipartResponse()`** - cancellable streaming multipart output without buffering all parts.
7769
7811
  - **`prettyJson()`** - capped, JSON-only pretty printing for debugging and developer-facing APIs.
7770
7812
  - **`methodOverride()`** - header/query method tunneling for clients that can only send `POST`.
7771
7813
  Header override is on by default; query override is opt-in.
@@ -8801,7 +8843,7 @@ done-gate, or `nifra mcp` to give the agent live project tools.
8801
8843
 
8802
8844
  ## @nifrajs/auth
8803
8845
 
8804
- `createSessions`, `csrf`, `CsrfOptions`, `GuardOptions`, `KVNamespaceLike`, `KVSessionStore`, `MemorySessionStore`, `MemorySessionStoreOptions`, `requireSession`, `requireUser`, `Session`, `SessionContext`, `SessionCookieOptions`, `SessionManager`, `SessionOptions`, `SessionRecord`, `SessionStore`
8846
+ `AuthorizationRequest`, `Authorizer`, `createSessions`, `csrf`, `CsrfOptions`, `GuardOptions`, `isAuthorized`, `KVNamespaceLike`, `KVSessionStore`, `MemorySessionStore`, `MemorySessionStoreOptions`, `requireAuthorization`, `requireSession`, `requireUser`, `Session`, `SessionContext`, `SessionCookieOptions`, `SessionManager`, `SessionOptions`, `SessionRecord`, `SessionStore`
8805
8847
 
8806
8848
  ## @nifrajs/better-auth
8807
8849
 
@@ -8849,7 +8891,7 @@ done-gate, or `nifra mcp` to give the agent live project tools.
8849
8891
 
8850
8892
  ## @nifrajs/image
8851
8893
 
8852
- `cloudflareLoader`, `CloudflareLoaderOptions`, `HtmlImageAttrs`, `identityLoader`, `imageDimensions`, `ImageFormat`, `ImageInfo`, `ImageLoader`, `ImageProps`, `readImageDimensions`, `ResolvedImage`, `resolveImage`, `selfHostedLoader`, `SelfHostedLoaderOptions`, `signImageUrl`, `SignImageUrlOptions`, `toHtmlAttrs`
8894
+ `cloudflareLoader`, `CloudflareLoaderOptions`, `createPngRasterizer`, `createResvgRasterizer`, `HtmlImageAttrs`, `identityLoader`, `imageDimensions`, `ImageFormat`, `ImageInfo`, `ImageLoader`, `ImageProps`, `OgImageOptions`, `OgImageRasterized`, `OgImageRasterizer`, `ogImageResponse`, `PngRenderer`, `readImageDimensions`, `renderOgImage`, `ResolvedImage`, `resolveImage`, `ResvgConstructor`, `ResvgRenderer`, `selfHostedLoader`, `SelfHostedLoaderOptions`, `signImageUrl`, `SignImageUrlOptions`, `toHtmlAttrs`
8853
8895
 
8854
8896
  ## @nifrajs/islets
8855
8897
 
@@ -8869,7 +8911,7 @@ done-gate, or `nifra mcp` to give the agent live project tools.
8869
8911
 
8870
8912
  ## @nifrajs/middleware
8871
8913
 
8872
- `AdmissionControllerHandle`, `AdmissionEvidence`, `AdmissionOptions`, `AdmissionPolicy`, `AdmissionSnapshot`, `apiKey`, `ApiKeyStaticOptions`, `ApiKeyVerifyOptions`, `appendTrailingSlash`, `AuthPlugin`, `basicAuth`, `BasicAuthPlugin`, `BasicAuthStaticOptions`, `BasicAuthVerifyOptions`, `bearer`, `BearerOptions`, `bodyLimit`, `BodyLimitOptions`, `buildOpenApiDocument`, `cache`, `cacheControl`, `CacheControlOptions`, `CachedResponse`, `CacheOptions`, `combine`, `Composable`, `compression`, `CompressionOptions`, `cors`, `CorsOptions`, `createAdmissionController`, `createCsrfToken`, `createEventLoopLagSampler`, `csrf`, `CsrfOptions`, `durableCommand`, `DurableCommandOptions`, `etag`, `ETagOptions`, `healthcheck`, `HealthcheckOptions`, `idempotency`, `IdempotencyClaim`, `IdempotencyOptions`, `IdempotencyRecord`, `IdempotencyStore`, `IpMatcher`, `ipRestriction`, `IpRestrictionOptions`, `jwk`, `JwkKey`, `jwks`, `JwksOptions`, `jwt`, `JwtAlgorithm`, `JwtClaims`, `JwtHeader`, `JwtKeyResolver`, `JwtOptions`, `JwtPlugin`, `JwtVerificationKey`, `language`, `LanguageMatch`, `LanguageOptions`, `logger`, `LoggerOptions`, `LoopDelayHistogram`, `LoopDelayMonitor`, `MemoryIdempotencyStore`, `MemoryIdempotencyStoreOptions`, `MemoryResponseCache`, `MemoryResponseCacheOptions`, `MemoryStore`, `MemoryStoreOptions`, `methodOverride`, `MethodOverrideOptions`, `namedCombine`, `openapi`, `OpenApiInfo`, `OpenApiOptions`, `OpenApiServer`, `OpenApiTag`, `OpenApiUiOptions`, `pickLanguage`, `poweredBy`, `PoweredByOptions`, `prettyJson`, `PrettyJsonOptions`, `rateLimit`, `RateLimitOptions`, `RateLimitResult`, `RateLimitStore`, `requestId`, `RequestIdOptions`, `RequestLogFields`, `responseCache`, `ResponseCacheStore`, `RouteLike`, `securityHeaders`, `SecurityHeadersOptions`, `SecurityRequirement`, `ShedReason`, `timing`, `TimingControls`, `TimingMetric`, `TimingOptions`, `TrailingSlashOptions`, `trimTrailingSlash`, `tryVerifyJwt`, `VerifiedJwt`, `verifyCsrfToken`, `verifyJwt`, `VerifyJwtOptions`, `VerifyJwtResult`
8914
+ `AdmissionControllerHandle`, `AdmissionEvidence`, `AdmissionOptions`, `AdmissionPolicy`, `AdmissionSnapshot`, `apiKey`, `ApiKeyStaticOptions`, `ApiKeyVerifyOptions`, `appendTrailingSlash`, `AuthPlugin`, `basicAuth`, `BasicAuthPlugin`, `BasicAuthStaticOptions`, `BasicAuthVerifyOptions`, `bearer`, `BearerOptions`, `bodyLimit`, `BodyLimitOptions`, `buildOpenApiDocument`, `ByteRange`, `ByteRangeResult`, `cache`, `cacheControl`, `CacheControlOptions`, `CachedResponse`, `CacheOptions`, `combine`, `Composable`, `compression`, `CompressionOptions`, `conditionalResponse`, `ConditionalResponseOptions`, `ContentPreference`, `cors`, `CorsOptions`, `createAdmissionController`, `createCsrfToken`, `createEventLoopLagSampler`, `csrf`, `CsrfOptions`, `durableCommand`, `DurableCommandOptions`, `etag`, `ETagOptions`, `healthcheck`, `HealthcheckOptions`, `idempotency`, `IdempotencyClaim`, `IdempotencyOptions`, `IdempotencyRecord`, `IdempotencyStore`, `IpMatcher`, `ipRestriction`, `IpRestrictionOptions`, `jwk`, `JwkKey`, `jwks`, `JwksOptions`, `jwt`, `JwtAlgorithm`, `JwtClaims`, `JwtHeader`, `JwtKeyResolver`, `JwtOptions`, `JwtPlugin`, `JwtVerificationKey`, `language`, `LanguageMatch`, `LanguageOptions`, `logger`, `LoggerOptions`, `LoopDelayHistogram`, `LoopDelayMonitor`, `MemoryIdempotencyStore`, `MemoryIdempotencyStoreOptions`, `MemoryResponseCache`, `MemoryResponseCacheOptions`, `MemoryStore`, `MemoryStoreOptions`, `methodOverride`, `MethodOverrideOptions`, `MultipartBody`, `MultipartHeadersInit`, `MultipartPart`, `multipartResponse`, `MultipartResponseOptions`, `namedCombine`, `negotiateContentType`, `openapi`, `OpenApiInfo`, `OpenApiOptions`, `OpenApiServer`, `OpenApiTag`, `OpenApiUiOptions`, `parseAcceptHeader`, `parseByteRange`, `pickLanguage`, `poweredBy`, `PoweredByOptions`, `prettyJson`, `PrettyJsonOptions`, `problemDetails`, `ProblemDetailsOptions`, `rangeResponse`, `RangeResponseOptions`, `rateLimit`, `RateLimitOptions`, `RateLimitResult`, `RateLimitStore`, `requestId`, `RequestIdOptions`, `RequestLogFields`, `responseCache`, `ResponseCacheStore`, `RouteLike`, `securityHeaders`, `SecurityHeadersOptions`, `SecurityRequirement`, `ShedReason`, `timing`, `TimingControls`, `TimingMetric`, `TimingOptions`, `TrailingSlashOptions`, `trimTrailingSlash`, `tryVerifyJwt`, `VerifiedJwt`, `verifyCsrfToken`, `verifyJwt`, `VerifyJwtOptions`, `VerifyJwtResult`
8873
8915
 
8874
8916
  ## @nifrajs/mock
8875
8917
 
@@ -8913,7 +8955,7 @@ done-gate, or `nifra mcp` to give the agent live project tools.
8913
8955
 
8914
8956
  ## @nifrajs/web
8915
8957
 
8916
- `Action`, `ACTION_GLOBAL`, `apiKey`, `assertRenderAdapterConformance`, `Blocker`, `BlockerController`, `BlockerFunction`, `BlockerLocation`, `BlockerState`, `BrowserNavigate`, `buildManifest`, `CachedResponse`, `CacheStore`, `canonical`, `clientEntry`, `ClientRouter`, `ClientRouterOptions`, `createClientRouter`, `createMatcher`, `createMutation`, `createQueryClient`, `createWebApp`, `CreateWebAppOptions`, `DATA_GLOBAL`, `DATA_HEADER`, `DEFAULT_DEV_PORT`, `defer`, `Deferred`, `DehydratedState`, `disableDraft`, `DRAFT_COOKIE`, `DraftCookieControls`, `enableDraft`, `EnableDraftOptions`, `enumerateStaticRoutes`, `Fetcher`, `FetcherState`, `FetchRouteData`, `filePathToPattern`, `filePathToPatterns`, `FontDisplay`, `fontFace`, `FontFace`, `fontPreload`, `FontPreloadInput`, `FontSource`, `gate`, `generateClientEntry`, `GenerateClientEntryOptions`, `generateRouteSearchTypes`, `GenerateRouteSearchTypesOptions`, `generateServerManifest`, `GenerateServerManifestOptions`, `getBrowserNavigate`, `GetStaticPaths`, `gone`, `hashQueryKey`, `IDLE_BLOCKER`, `InertScriptType`, `InfiniteData`, `InfiniteQueryHandle`, `InfiniteQueryOptions`, `isDraftEnabled`, `ISR_REVALIDATE_HEADER`, `ISR_STATUS_HEADER`, `ISRApp`, `ISROptions`, `ISRPlatform`, `jsonLd`, `KVCacheStore`, `KVCacheStoreOptions`, `KVNamespaceLike`, `LAYOUT_DATA_GLOBAL`, `LayoutEntry`, `LinkDescriptor`, `Loader`, `LoaderContext`, `manifest`, `Manifest`, `MemoryCacheStore`, `MemoryCacheStoreOptions`, `mergeHeads`, `meta`, `Meta`, `MetaArgs`, `MetaInput`, `MountRouterOptions`, `MutationCallbacks`, `MutationHandle`, `MutationState`, `MutationStatus`, `NAV_FROM_HEADER`, `NavigateFunction`, `NavigateOptions`, `NavigateSearchOf`, `NavigateTargetInput`, `notFound`, `openGraph`, `OpenGraphInput`, `PRE_HYDRATION_GUARD`, `previewEndpoint`, `PreviewEndpointOptions`, `PublicDirCache`, `QueryClient`, `QueryClientOptions`, `QueryHandle`, `QueryOptions`, `QueryState`, `QueryStatus`, `redirect`, `REDIRECT_HEADER`, `RedirectOptions`, `registerBlocker`, `RenderAdapter`, `RenderAdapterConformanceError`, `RenderAdapterConformanceFixture`, `RenderAssemblyCache`, `RenderedPage`, `renderPage`, `RenderPageInput`, `RenderPageOptions`, `renderPageResult`, `RenderProps`, `resolveMeta`, `resolveNavigate`, `resolvePublicPath`, `RETAIN_HEADER`, `revalidate`, `REVALIDATE_HEADER`, `revalidateEndpoint`, `RevalidateEndpointOptions`, `RevalidateResult`, `ROOT_ATTRIBUTE`, `ROUTE_GLOBAL`, `RouteEntry`, `RouteMatch`, `RouteModule`, `RoutePattern`, `RouterState`, `RouteSearch`, `routeStyles`, `ScriptDescriptor`, `searchOf`, `SearchOf`, `searchOfChain`, `serializeData`, `serializeSearch`, `servePublicDir`, `ServePublicDirOptions`, `SERVER_FN_MODULE`, `SERVER_ONLY_MODULE`, `ServerOnly`, `setBlockerController`, `setBrowserNavigate`, `StaticPath`, `StaticPaths`, `StaticRoutes`, `STATUS_HEADER`, `statusPage`, `StatusPageOptions`, `styles`, `Submission`, `SubmitOptions`, `unsafeInlineScript`, `UnsafeScriptDescriptor`, `withISR`
8958
+ `Action`, `ACTION_GLOBAL`, `apiKey`, `assertRenderAdapterConformance`, `Blocker`, `BlockerController`, `BlockerFunction`, `BlockerLocation`, `BlockerState`, `BrowserNavigate`, `buildManifest`, `CachedResponse`, `CacheStore`, `canonical`, `clientEntry`, `ClientRouter`, `ClientRouterOptions`, `createClientRouter`, `createMatcher`, `createMutation`, `createQueryClient`, `createWebApp`, `CreateWebAppOptions`, `DATA_GLOBAL`, `DATA_HEADER`, `DEFAULT_DEV_PORT`, `defer`, `Deferred`, `DehydratedState`, `disableDraft`, `DRAFT_COOKIE`, `DraftCookieControls`, `enableDraft`, `EnableDraftOptions`, `enumerateStaticRoutes`, `Fetcher`, `FetcherState`, `FetchRouteData`, `filePathToPattern`, `filePathToPatterns`, `FontDisplay`, `fontFace`, `FontFace`, `fontPreload`, `FontPreloadInput`, `FontSource`, `gate`, `generateClientEntry`, `GenerateClientEntryOptions`, `generateRouteSearchTypes`, `GenerateRouteSearchTypesOptions`, `generateServerManifest`, `GenerateServerManifestOptions`, `getBrowserNavigate`, `GetStaticPaths`, `gone`, `hashQueryKey`, `IDLE_BLOCKER`, `InertScriptType`, `InfiniteData`, `InfiniteQueryHandle`, `InfiniteQueryOptions`, `isDraftEnabled`, `ISR_REVALIDATE_HEADER`, `ISR_REVALIDATE_TAGS_HEADER`, `ISR_STATUS_HEADER`, `ISRApp`, `ISROptions`, `ISRPlatform`, `jsonLd`, `KVCacheStore`, `KVCacheStoreOptions`, `KVNamespaceLike`, `LAYOUT_DATA_GLOBAL`, `LayoutEntry`, `LinkDescriptor`, `Loader`, `LoaderContext`, `manifest`, `Manifest`, `MemoryCacheStore`, `MemoryCacheStoreOptions`, `mergeHeads`, `meta`, `Meta`, `MetaArgs`, `MetaInput`, `MountRouterOptions`, `MutationCallbacks`, `MutationHandle`, `MutationState`, `MutationStatus`, `NAV_FROM_HEADER`, `NavigateFunction`, `NavigateOptions`, `NavigateSearchOf`, `NavigateTargetInput`, `notFound`, `openGraph`, `OpenGraphInput`, `PRE_HYDRATION_GUARD`, `previewEndpoint`, `PreviewEndpointOptions`, `PublicDirCache`, `QueryClient`, `QueryClientOptions`, `QueryHandle`, `QueryOptions`, `QueryState`, `QueryStatus`, `redirect`, `REDIRECT_HEADER`, `RedirectOptions`, `registerBlocker`, `RenderAdapter`, `RenderAdapterConformanceError`, `RenderAdapterConformanceFixture`, `RenderAssemblyCache`, `RenderedPage`, `renderPage`, `RenderPageInput`, `RenderPageOptions`, `renderPageResult`, `RenderProps`, `resolveMeta`, `resolveNavigate`, `resolvePublicPath`, `RETAIN_HEADER`, `revalidate`, `REVALIDATE_HEADER`, `revalidateEndpoint`, `RevalidateEndpointOptions`, `RevalidateResult`, `ROOT_ATTRIBUTE`, `ROUTE_GLOBAL`, `RouteEntry`, `RouteMatch`, `RouteModule`, `RoutePattern`, `RouterState`, `RouteSearch`, `routeStyles`, `ScriptDescriptor`, `searchOf`, `SearchOf`, `searchOfChain`, `serializeData`, `serializeSearch`, `servePublicDir`, `ServePublicDirOptions`, `SERVER_FN_MODULE`, `SERVER_ONLY_MODULE`, `ServerOnly`, `setBlockerController`, `setBrowserNavigate`, `StaticPath`, `StaticPaths`, `StaticRoutes`, `STATUS_HEADER`, `statusPage`, `StatusPageOptions`, `styles`, `Submission`, `SubmitOptions`, `unsafeInlineScript`, `UnsafeScriptDescriptor`, `withISR`
8917
8959
 
8918
8960
  ## @nifrajs/web-preact
8919
8961