/* * Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT. */ import * as z from "zod/v3"; import { safeParse } from "../../lib/schemas.js"; import { Result as SafeParseResult } from "../../types/fp.js"; import { SDKValidationError } from "../errors/sdkvalidationerror.js"; import { PublishSummaryDto, PublishSummaryDto$inboundSchema, } from "./publishsummarydto.js"; import { SyncResultDto, SyncResultDto$inboundSchema } from "./syncresultdto.js"; export type PublishEnvironmentResponseDto = { /** * Sync results by resource type */ results: Array; /** * Summary of the sync operation */ summary: PublishSummaryDto; }; /** @internal */ export const PublishEnvironmentResponseDto$inboundSchema: z.ZodType< PublishEnvironmentResponseDto, z.ZodTypeDef, unknown > = z.object({ results: z.array(SyncResultDto$inboundSchema), summary: PublishSummaryDto$inboundSchema, }); export function publishEnvironmentResponseDtoFromJSON( jsonString: string, ): SafeParseResult { return safeParse( jsonString, (x) => PublishEnvironmentResponseDto$inboundSchema.parse(JSON.parse(x)), `Failed to parse 'PublishEnvironmentResponseDto' from JSON`, ); }