appos 0.1.24-0 → 0.1.26-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.
@@ -29,7 +29,7 @@ import * as keyv0 from "keyv";
29
29
  import Keyv from "keyv";
30
30
  import { Server, Socket } from "socket.io";
31
31
  import * as express from "express";
32
- import { Express, RequestHandler } from "express";
32
+ import { Express, Request, RequestHandler } from "express";
33
33
  import { NodeHTTPCreateContextFnOptions } from "@trpc/server/adapters/node-http";
34
34
 
35
35
  //#region app/.server/primitives/logger.d.ts
@@ -8286,21 +8286,6 @@ interface AppOSRequest {
8286
8286
  */
8287
8287
  t: TFunction;
8288
8288
  }
8289
- /**
8290
- * AppOS namespace for user-extensible types and Express augmentations.
8291
- */
8292
- declare global {
8293
- namespace Express {
8294
- /**
8295
- * The request object extended with the application container.
8296
- */
8297
- interface Request extends AppOSRequest {}
8298
- /**
8299
- * The app.locals extended with typed workflows.
8300
- */
8301
- interface Locals extends AppOSLocals {}
8302
- }
8303
- }
8304
8289
  //#endregion
8305
8290
  //#region app/.server/primitives/openapi.d.ts
8306
8291
  /**
@@ -8311,6 +8296,14 @@ type ResponseMarker<T = any> = {
8311
8296
  status: number;
8312
8297
  data: T;
8313
8298
  };
8299
+ /**
8300
+ * Extend Request type for OpenAPI handlers.
8301
+ */
8302
+ type OpenAPIRequest = Request & AppOSRequest;
8303
+ /**
8304
+ * Extended Locals type for OpenAPI handlers.
8305
+ */
8306
+ type OpenAPILocals = Express.Locals & AppOSLocals;
8314
8307
  /**
8315
8308
  * Define typed response builders based on defined response schemas.
8316
8309
  */
@@ -8331,9 +8324,9 @@ type HandlerParams<TParams extends z.ZodSchema | undefined = undefined, TQuery e
8331
8324
  description: string;
8332
8325
  schema: z.ZodSchema;
8333
8326
  }>> = {
8334
- request: Express.Request;
8327
+ request: OpenAPIRequest;
8335
8328
  params: TParams extends z.ZodSchema ? z.infer<TParams> : Record<string, unknown>;
8336
- context: Express.Locals;
8329
+ context: OpenAPILocals;
8337
8330
  body: TBody extends z.ZodSchema ? z.infer<TBody> : unknown;
8338
8331
  query: TQuery extends z.ZodSchema ? z.infer<TQuery> : Record<string, unknown>;
8339
8332
  headers: THeaders extends z.ZodSchema ? z.infer<THeaders> : Record<string, string>;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "appos",
3
- "version": "0.1.24-0",
3
+ "version": "0.1.26-0",
4
4
  "type": "module",
5
5
  "scripts": {
6
6
  "release": "release-it",