@voyant-travel/inventory 0.5.4 → 0.5.5
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/interface.d.ts +23 -17
- package/dist/interface.d.ts.map +1 -1
- package/dist/public-tags-contract.test.d.ts +2 -0
- package/dist/public-tags-contract.test.d.ts.map +1 -0
- package/dist/public-tags-contract.test.js +11 -0
- package/dist/routes-public.d.ts +29 -17
- package/dist/routes-public.d.ts.map +1 -1
- package/dist/routes-public.js +34 -11
- package/package.json +7 -6
package/dist/interface.d.ts
CHANGED
|
@@ -5388,6 +5388,29 @@ export declare const publicInventoryProductRoutes: import("hono/hono-base").Hono
|
|
|
5388
5388
|
userId?: string;
|
|
5389
5389
|
};
|
|
5390
5390
|
}, {
|
|
5391
|
+
"/tags": {
|
|
5392
|
+
$get: {
|
|
5393
|
+
input: {
|
|
5394
|
+
query: {
|
|
5395
|
+
search?: string | undefined;
|
|
5396
|
+
offset?: unknown;
|
|
5397
|
+
limit?: unknown;
|
|
5398
|
+
};
|
|
5399
|
+
};
|
|
5400
|
+
output: {
|
|
5401
|
+
data: {
|
|
5402
|
+
id: string;
|
|
5403
|
+
name: string;
|
|
5404
|
+
}[];
|
|
5405
|
+
total: number;
|
|
5406
|
+
limit: number;
|
|
5407
|
+
offset: number;
|
|
5408
|
+
};
|
|
5409
|
+
outputFormat: "json";
|
|
5410
|
+
status: 200;
|
|
5411
|
+
};
|
|
5412
|
+
};
|
|
5413
|
+
} & {
|
|
5391
5414
|
"/": {
|
|
5392
5415
|
$get: {
|
|
5393
5416
|
input: {};
|
|
@@ -5842,23 +5865,6 @@ export declare const publicInventoryProductRoutes: import("hono/hono-base").Hono
|
|
|
5842
5865
|
status: import("hono/utils/http-status").ContentfulStatusCode;
|
|
5843
5866
|
};
|
|
5844
5867
|
};
|
|
5845
|
-
} & {
|
|
5846
|
-
"/tags": {
|
|
5847
|
-
$get: {
|
|
5848
|
-
input: {};
|
|
5849
|
-
output: {
|
|
5850
|
-
data: {
|
|
5851
|
-
id: string;
|
|
5852
|
-
name: string;
|
|
5853
|
-
}[];
|
|
5854
|
-
total: number;
|
|
5855
|
-
limit: number;
|
|
5856
|
-
offset: number;
|
|
5857
|
-
};
|
|
5858
|
-
outputFormat: "json";
|
|
5859
|
-
status: import("hono/utils/http-status").ContentfulStatusCode;
|
|
5860
|
-
};
|
|
5861
|
-
};
|
|
5862
5868
|
} & {
|
|
5863
5869
|
"/destinations": {
|
|
5864
5870
|
$get: {
|
package/dist/interface.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"interface.d.ts","sourceRoot":"","sources":["../src/interface.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,MAAM,EAAE,MAAM,qBAAqB,CAAA;AACjD,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,4BAA4B,CAAA;AAO5D,OAAO,EACL,iBAAiB,EACjB,qCAAqC,EACrC,wBAAwB,EACxB,eAAe,EACf,6BAA6B,GAC9B,MAAM,gBAAgB,CAAA;AAEvB,eAAO,MAAM,eAAe,EAAE,MAG7B,CAAA;AAED;;;;;GAKG;AACH,eAAO,MAAM,mBAAmB,EAAE,UAQjC,CAAA;AAED,eAAO,MAAM,sBAAsB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;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;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;wBAMwC,CAAA;AAC/D,eAAO,MAAM,yBAAyB,6CAA2B,CAAA;AAEjE,MAAM,MAAM,yBAAyB,GACjC,mBAAmB,GACnB,iBAAiB,GACjB,4BAA4B,GAC5B,6BAA6B,GAC7B,+BAA+B,CAAA;AAEnC,MAAM,WAAW,4BAA4B;IAC3C,MAAM,EAAE,WAAW,CAAA;IACnB,oBAAoB,EAAE,UAAU,CAAA;IAChC,iBAAiB,EAAE,SAAS,yBAAyB,EAAE,CAAA;IACvD,uBAAuB,EAAE,SAAS;QAChC,YAAY;QACZ,QAAQ;QACR,SAAS;QACT,UAAU;QACV,mBAAmB;KACpB,CAAA;CACF;AAED,eAAO,MAAM,4BAA4B,EAAE,4BAW1C,CAAA"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"public-tags-contract.test.d.ts","sourceRoot":"","sources":["../src/public-tags-contract.test.ts"],"names":[],"mappings":""}
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
import { listResponse, listResponseSchema } from "@voyant-travel/types";
|
|
2
|
+
import { describe, expect, it } from "vitest";
|
|
3
|
+
import { publicCatalogTagSchema } from "./routes-public.js";
|
|
4
|
+
const row = { id: "ptag_0000000000000000000000", name: "Adventure" };
|
|
5
|
+
describe("public catalog tags response contract", () => {
|
|
6
|
+
it("the serialized wire response satisfies the declared OpenAPI schema", () => {
|
|
7
|
+
const wire = JSON.parse(JSON.stringify(listResponse([row], { total: 1, limit: 100, offset: 0 })));
|
|
8
|
+
const parsed = listResponseSchema(publicCatalogTagSchema).safeParse(wire);
|
|
9
|
+
expect(parsed.success ? null : parsed.error.toString()).toBeNull();
|
|
10
|
+
});
|
|
11
|
+
});
|
package/dist/routes-public.d.ts
CHANGED
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
import { z } from "@hono/zod-openapi";
|
|
1
2
|
import type { KVStore } from "@voyant-travel/utils/cache";
|
|
2
3
|
import type { PostgresJsDatabase } from "drizzle-orm/postgres-js";
|
|
3
4
|
type Env = {
|
|
@@ -10,7 +11,35 @@ type Env = {
|
|
|
10
11
|
userId?: string;
|
|
11
12
|
};
|
|
12
13
|
};
|
|
14
|
+
/** Wire shape of a public catalog tag (voyant#2114). */
|
|
15
|
+
export declare const publicCatalogTagSchema: z.ZodObject<{
|
|
16
|
+
id: z.ZodString;
|
|
17
|
+
name: z.ZodString;
|
|
18
|
+
}, z.core.$strip>;
|
|
13
19
|
export declare const publicProductRoutes: import("hono/hono-base").HonoBase<Env, {
|
|
20
|
+
"/tags": {
|
|
21
|
+
$get: {
|
|
22
|
+
input: {
|
|
23
|
+
query: {
|
|
24
|
+
search?: string | undefined;
|
|
25
|
+
offset?: unknown;
|
|
26
|
+
limit?: unknown;
|
|
27
|
+
};
|
|
28
|
+
};
|
|
29
|
+
output: {
|
|
30
|
+
data: {
|
|
31
|
+
id: string;
|
|
32
|
+
name: string;
|
|
33
|
+
}[];
|
|
34
|
+
total: number;
|
|
35
|
+
limit: number;
|
|
36
|
+
offset: number;
|
|
37
|
+
};
|
|
38
|
+
outputFormat: "json";
|
|
39
|
+
status: 200;
|
|
40
|
+
};
|
|
41
|
+
};
|
|
42
|
+
} & {
|
|
14
43
|
"/": {
|
|
15
44
|
$get: {
|
|
16
45
|
input: {};
|
|
@@ -465,23 +494,6 @@ export declare const publicProductRoutes: import("hono/hono-base").HonoBase<Env,
|
|
|
465
494
|
status: import("hono/utils/http-status").ContentfulStatusCode;
|
|
466
495
|
};
|
|
467
496
|
};
|
|
468
|
-
} & {
|
|
469
|
-
"/tags": {
|
|
470
|
-
$get: {
|
|
471
|
-
input: {};
|
|
472
|
-
output: {
|
|
473
|
-
data: {
|
|
474
|
-
id: string;
|
|
475
|
-
name: string;
|
|
476
|
-
}[];
|
|
477
|
-
total: number;
|
|
478
|
-
limit: number;
|
|
479
|
-
offset: number;
|
|
480
|
-
};
|
|
481
|
-
outputFormat: "json";
|
|
482
|
-
status: import("hono/utils/http-status").ContentfulStatusCode;
|
|
483
|
-
};
|
|
484
|
-
};
|
|
485
497
|
} & {
|
|
486
498
|
"/destinations": {
|
|
487
499
|
$get: {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"routes-public.d.ts","sourceRoot":"","sources":["../src/routes-public.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"routes-public.d.ts","sourceRoot":"","sources":["../src/routes-public.ts"],"names":[],"mappings":"AAAA,OAAO,EAA4B,CAAC,EAAE,MAAM,mBAAmB,CAAA;AAG/D,OAAO,KAAK,EAAE,OAAO,EAAE,MAAM,4BAA4B,CAAA;AACzD,OAAO,KAAK,EAAE,kBAAkB,EAAE,MAAM,yBAAyB,CAAA;AAmBjE,KAAK,GAAG,GAAG;IACT,QAAQ,EAAE;QACR,mEAAmE;QACnE,KAAK,CAAC,EAAE,OAAO,CAAA;KAChB,CAAA;IACD,SAAS,EAAE;QACT,EAAE,EAAE,kBAAkB,CAAA;QACtB,MAAM,CAAC,EAAE,MAAM,CAAA;KAChB,CAAA;CACF,CAAA;AAgED,wDAAwD;AACxD,eAAO,MAAM,sBAAsB;;;iBAGjC,CAAA;AAiBF,eAAO,MAAM,mBAAmB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;wBA+F5B,CAAA;AAEJ,MAAM,MAAM,mBAAmB,GAAG,OAAO,mBAAmB,CAAA"}
|
package/dist/routes-public.js
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import {
|
|
3
|
-
import {
|
|
1
|
+
import { createRoute, OpenAPIHono, z } from "@hono/zod-openapi";
|
|
2
|
+
import { openApiValidationHook, parseQuery } from "@voyant-travel/hono";
|
|
3
|
+
import { listResponseSchema } from "@voyant-travel/types";
|
|
4
4
|
import { productDocKey, productDocVariant, readThroughProductDoc, readThroughSlugMapping, } from "./read-model.js";
|
|
5
5
|
import { publicProductsService } from "./service-public.js";
|
|
6
6
|
import { publicCatalogCategoryListQuerySchema, publicCatalogDestinationListQuerySchema, publicCatalogProductListQuerySchema, publicCatalogProductLookupBySlugQuerySchema, publicCatalogTagListQuerySchema, } from "./validation-public.js";
|
|
@@ -48,12 +48,41 @@ const clampedCategoryListQuerySchema = publicCatalogCategoryListQuerySchema.exte
|
|
|
48
48
|
limit: clampedLimitParam(PUBLIC_LIST_MAX_LIMIT, PUBLIC_LIST_MAX_LIMIT),
|
|
49
49
|
});
|
|
50
50
|
const clampedTagListQuerySchema = publicCatalogTagListQuerySchema.extend({
|
|
51
|
-
|
|
51
|
+
// `.catch()`/`.transform()` (clamping) can't be introspected by
|
|
52
|
+
// zod-to-openapi, so pin the documented param type explicitly (voyant#2114).
|
|
53
|
+
limit: clampedLimitParam(PUBLIC_LIST_MAX_LIMIT, PUBLIC_LIST_MAX_LIMIT).openapi({
|
|
54
|
+
type: "integer",
|
|
55
|
+
example: PUBLIC_LIST_MAX_LIMIT,
|
|
56
|
+
}),
|
|
52
57
|
});
|
|
53
58
|
const clampedDestinationListQuerySchema = publicCatalogDestinationListQuerySchema.extend({
|
|
54
59
|
limit: clampedLimitParam(PUBLIC_LIST_MAX_LIMIT, PUBLIC_LIST_MAX_LIMIT),
|
|
55
60
|
});
|
|
56
|
-
|
|
61
|
+
/** Wire shape of a public catalog tag (voyant#2114). */
|
|
62
|
+
export const publicCatalogTagSchema = z.object({
|
|
63
|
+
id: z.string(),
|
|
64
|
+
name: z.string(),
|
|
65
|
+
});
|
|
66
|
+
const listTagsRoute = createRoute({
|
|
67
|
+
method: "get",
|
|
68
|
+
path: "/tags",
|
|
69
|
+
request: { query: clampedTagListQuerySchema },
|
|
70
|
+
responses: {
|
|
71
|
+
200: {
|
|
72
|
+
description: "Paginated list of public catalog tags",
|
|
73
|
+
content: { "application/json": { schema: listResponseSchema(publicCatalogTagSchema) } },
|
|
74
|
+
},
|
|
75
|
+
},
|
|
76
|
+
});
|
|
77
|
+
// `.openapi()` is declared first: `OpenAPIHono#get` returns the base `Hono`
|
|
78
|
+
// type (honojs/middleware#637), so it cannot precede an `.openapi()` in the
|
|
79
|
+
// chain; it stays ahead of the `/:id` catch-all so `/tags` still matches first.
|
|
80
|
+
export const publicProductRoutes = new OpenAPIHono({ defaultHook: openApiValidationHook })
|
|
81
|
+
.openapi(listTagsRoute, async (c) => {
|
|
82
|
+
const result = await publicProductsService.listCatalogTags(c.get("db"), c.req.valid("query"));
|
|
83
|
+
setPublicCacheHeaders(c);
|
|
84
|
+
return c.json(result, 200);
|
|
85
|
+
})
|
|
57
86
|
.get("/", async (c) => {
|
|
58
87
|
const query = await parseQuery(c, trimmedProductListQuerySchema);
|
|
59
88
|
const result = await publicProductsService.listCatalogProducts(c.get("db"), query);
|
|
@@ -97,12 +126,6 @@ export const publicProductRoutes = new Hono()
|
|
|
97
126
|
const result = await publicProductsService.listCatalogCategories(c.get("db"), query);
|
|
98
127
|
setPublicCacheHeaders(c);
|
|
99
128
|
return c.json(result);
|
|
100
|
-
})
|
|
101
|
-
.get("/tags", async (c) => {
|
|
102
|
-
const query = await parseQuery(c, clampedTagListQuerySchema);
|
|
103
|
-
const result = await publicProductsService.listCatalogTags(c.get("db"), query);
|
|
104
|
-
setPublicCacheHeaders(c);
|
|
105
|
-
return c.json(result);
|
|
106
129
|
})
|
|
107
130
|
.get("/destinations", async (c) => {
|
|
108
131
|
const query = await parseQuery(c, clampedDestinationListQuerySchema);
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@voyant-travel/inventory",
|
|
3
|
-
"version": "0.5.
|
|
3
|
+
"version": "0.5.5",
|
|
4
4
|
"license": "Apache-2.0",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"exports": {
|
|
@@ -161,24 +161,25 @@
|
|
|
161
161
|
}
|
|
162
162
|
},
|
|
163
163
|
"dependencies": {
|
|
164
|
+
"@hono/zod-openapi": "^1.4.0",
|
|
164
165
|
"drizzle-orm": "^0.45.2",
|
|
165
166
|
"hono": "^4.12.10",
|
|
166
167
|
"marked": "^18.0.3",
|
|
167
168
|
"pdf-lib": "^1.17.1",
|
|
168
169
|
"sanitize-html": "^2.17.4",
|
|
169
170
|
"zod": "^4.3.6",
|
|
170
|
-
"@voyant-travel/action-ledger": "^0.105.
|
|
171
|
-
"@voyant-travel/catalog": "^0.
|
|
171
|
+
"@voyant-travel/action-ledger": "^0.105.8",
|
|
172
|
+
"@voyant-travel/catalog": "^0.135.0",
|
|
172
173
|
"@voyant-travel/core": "^0.111.0",
|
|
173
174
|
"@voyant-travel/db": "^0.109.4",
|
|
174
175
|
"@voyant-travel/types": "^0.106.0",
|
|
175
176
|
"@voyant-travel/extras-contracts": "^0.104.2",
|
|
176
|
-
"@voyant-travel/hono": "^0.
|
|
177
|
-
"@voyant-travel/commerce": "^0.
|
|
177
|
+
"@voyant-travel/hono": "^0.117.0",
|
|
178
|
+
"@voyant-travel/commerce": "^0.19.0",
|
|
178
179
|
"@voyant-travel/products-contracts": "^0.105.14",
|
|
179
180
|
"@voyant-travel/storage": "^0.105.0",
|
|
180
181
|
"@voyant-travel/utils": "^0.105.4",
|
|
181
|
-
"@voyant-travel/operations": "^0.5.
|
|
182
|
+
"@voyant-travel/operations": "^0.5.2"
|
|
182
183
|
},
|
|
183
184
|
"devDependencies": {
|
|
184
185
|
"@types/sanitize-html": "^2.16.1",
|