Download src/dtos/deployment.dto.ts from lynfera/api: direct link, hf CLI and curl.
- Browser
- Download file 727 Bytes
-
https://huggingface.co/spaces/lynfera/api/resolve/main/src/dtos/deployment.dto.ts
- Command line
-
hf download hf://spaces/lynfera/api/src/dtos/deployment.dto.ts
-
curl -L -o deployment.dto.ts https://huggingface.co/spaces/lynfera/api/resolve/main/src/dtos/deployment.dto.ts
727 Bytes
| import z from "zod"; | |
| import { mongoIdSchema } from "@/dtos/zodHelpers.js"; | |
| import { DeploymentStatus } from "@/models/Deployment.js"; | |
| export const CreateDeploymentSchema = z.object({ | |
| projectId: mongoIdSchema, | |
| }); | |
| export const DeploymentQueryScheme = z | |
| .object({ | |
| status: z.enum(Object.values(DeploymentStatus)).optional(), | |
| page: z.coerce.number().int().positive().default(1), | |
| limit: z.coerce.number().int().min(1).max(100).default(10), | |
| search: z.string().max(100).default("").optional(), | |
| include: z.string().optional(), | |
| full: z.string().optional(), | |
| }) | |
| .strict(); | |
| export type CreateDeploymentDTO = z.infer<typeof CreateDeploymentSchema>; | |
| export type QueryDeploymentDTO = z.infer<typeof DeploymentQueryScheme>; | |