/* * Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT. * @generated-id: af9a41ae92c9 */ import * as z from "zod/v3"; export type GetCollectionRequest = { /** * The ID of the Collection to be retrieved. */ id: number; /** * Whether or not to include the Collection Items in this Collection. Only request if absolutely required, as this is expensive. */ withItems?: boolean | undefined; /** * Whether or not to include the top level Collection in this Collection's hierarchy. */ withHierarchy?: boolean | undefined; /** * The datasource allowed in the Collection returned. */ allowedDatasource?: string | undefined; }; /** @internal */ export type GetCollectionRequest$Outbound = { id: number; withItems?: boolean | undefined; withHierarchy?: boolean | undefined; allowedDatasource?: string | undefined; }; /** @internal */ export const GetCollectionRequest$outboundSchema: z.ZodType< GetCollectionRequest$Outbound, z.ZodTypeDef, GetCollectionRequest > = z.object({ id: z.number().int(), withItems: z.boolean().optional(), withHierarchy: z.boolean().optional(), allowedDatasource: z.string().optional(), }); export function getCollectionRequestToJSON( getCollectionRequest: GetCollectionRequest, ): string { return JSON.stringify( GetCollectionRequest$outboundSchema.parse(getCollectionRequest), ); }