/* * Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT. * @generated-id: f43da3df614b */ import * as z from "zod/v4"; import { safeParse } from "../../lib/schemas.js"; import { Result as SafeParseResult } from "../../types/fp.js"; import { SDKValidationError } from "../errors/sdkvalidationerror.js"; import * as models from "../index.js"; export type ListReleaseChannelsGlobals = { /** * Workspace name. Platform API keys already select a workspace; other authentication methods can configure it once on the SDK client. */ workspace?: string | undefined; }; export type ListReleaseChannelsRequest = { /** * Filter by project ID or name. */ project: string; }; /** * Project release channels. */ export type ListReleaseChannelsResponse = { items: Array; }; /** @internal */ export type ListReleaseChannelsRequest$Outbound = { project: string; }; /** @internal */ export const ListReleaseChannelsRequest$outboundSchema: z.ZodType< ListReleaseChannelsRequest$Outbound, ListReleaseChannelsRequest > = z.object({ project: z.string(), }); export function listReleaseChannelsRequestToJSON( listReleaseChannelsRequest: ListReleaseChannelsRequest, ): string { return JSON.stringify( ListReleaseChannelsRequest$outboundSchema.parse(listReleaseChannelsRequest), ); } /** @internal */ export const ListReleaseChannelsResponse$inboundSchema: z.ZodType< ListReleaseChannelsResponse, unknown > = z.object({ items: z.array(models.ReleaseChannel$inboundSchema), }); export function listReleaseChannelsResponseFromJSON( jsonString: string, ): SafeParseResult { return safeParse( jsonString, (x) => ListReleaseChannelsResponse$inboundSchema.parse(JSON.parse(x)), `Failed to parse 'ListReleaseChannelsResponse' from JSON`, ); }