UNPKG

@simpleapps-com/augur-api

Version:

TypeScript client library for Augur microservices API endpoints

25 lines 1.46 kB
"use strict"; Object.defineProperty(exports, "__esModule", { value: true }); exports.BrandListResponseSchema = exports.BrandResponseSchema = exports.BrandDetailParamsSchema = exports.BrandListParamsSchema = exports.UpdateBrandRequestSchema = exports.CreateBrandRequestSchema = exports.BrandSchema = void 0; const zod_1 = require("zod"); const schemas_1 = require("../../../core/schemas"); /** Brand - key field only, passthrough for API flexibility */ exports.BrandSchema = zod_1.z.object({ brandsUid: zod_1.z.number().min(1) }).passthrough(); /** Create brand request - passthrough for flexible input */ exports.CreateBrandRequestSchema = zod_1.z.object({}).passthrough(); /** Update brand request - passthrough for flexible input */ exports.UpdateBrandRequestSchema = zod_1.z.object({}).passthrough(); exports.BrandListParamsSchema = zod_1.z.object({ limit: zod_1.z.coerce.number().int().positive().optional(), offset: zod_1.z.coerce.number().int().min(0).optional(), q: zod_1.z.string().optional(), statusCd: zod_1.z.coerce.number().optional(), orderBy: zod_1.z.string().optional(), }); exports.BrandDetailParamsSchema = zod_1.z.object({ brandsUid: zod_1.z.coerce.number().min(1), }); // Response schemas exports.BrandResponseSchema = (0, schemas_1.BaseResponseSchema)(exports.BrandSchema); exports.BrandListResponseSchema = (0, schemas_1.BaseResponseSchema)(zod_1.z.array(exports.BrandSchema)); //# sourceMappingURL=brands.js.map