/* * Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT. * @generated-id: c36fd05df4d3 */ 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 ListReleaseAuthorsGlobals = { /** * 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 ListReleaseAuthorsRequest = { /** * Filter by project ID or name. */ project?: string | null | undefined; /** * Search authors by login or name (case-insensitive contains) */ search?: string | null | undefined; /** * Maximum number of authors to return */ limit?: number | undefined; }; /** * Retrieved distinct authors. */ export type ListReleaseAuthorsResponse = { items: Array; }; /** @internal */ export type ListReleaseAuthorsRequest$Outbound = { project?: string | null | undefined; search?: string | null | undefined; limit: number; }; /** @internal */ export const ListReleaseAuthorsRequest$outboundSchema: z.ZodType< ListReleaseAuthorsRequest$Outbound, ListReleaseAuthorsRequest > = z.object({ project: z.nullable(z.string()).optional(), search: z.nullable(z.string()).optional(), limit: z.int().default(50), }); export function listReleaseAuthorsRequestToJSON( listReleaseAuthorsRequest: ListReleaseAuthorsRequest, ): string { return JSON.stringify( ListReleaseAuthorsRequest$outboundSchema.parse(listReleaseAuthorsRequest), ); } /** @internal */ export const ListReleaseAuthorsResponse$inboundSchema: z.ZodType< ListReleaseAuthorsResponse, unknown > = z.object({ items: z.array(models.ReleaseAuthorFilterItem$inboundSchema), }); export function listReleaseAuthorsResponseFromJSON( jsonString: string, ): SafeParseResult { return safeParse( jsonString, (x) => ListReleaseAuthorsResponse$inboundSchema.parse(JSON.parse(x)), `Failed to parse 'ListReleaseAuthorsResponse' from JSON`, ); }