/* * Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT. */ import * as z from "zod/v3"; import { remap as remap$ } from "../../lib/primitives.js"; export type GovernmentDataPostzonRetrieveByPostcodeOrPlaceGlobals = { source?: string | undefined; }; export type GovernmentDataPostzonRetrieveByPostcodeOrPlaceRequest = { /** * The key to use to authenticate to the service. */ key?: string | undefined; /** * The postcode or place name to use to search with. */ postcodeOrPlace: string; /** * The username associated with the Royal Mail license (not required for click licenses). */ userName?: string | undefined; }; /** @internal */ export type GovernmentDataPostzonRetrieveByPostcodeOrPlaceRequest$Outbound = { Key?: string | undefined; PostcodeOrPlace: string; UserName?: string | undefined; }; /** @internal */ export const GovernmentDataPostzonRetrieveByPostcodeOrPlaceRequest$outboundSchema: z.ZodType< GovernmentDataPostzonRetrieveByPostcodeOrPlaceRequest$Outbound, z.ZodTypeDef, GovernmentDataPostzonRetrieveByPostcodeOrPlaceRequest > = z.object({ key: z.string().optional(), postcodeOrPlace: z.string(), userName: z.string().optional(), }).transform((v) => { return remap$(v, { key: "Key", postcodeOrPlace: "PostcodeOrPlace", userName: "UserName", }); }); export function governmentDataPostzonRetrieveByPostcodeOrPlaceRequestToJSON( governmentDataPostzonRetrieveByPostcodeOrPlaceRequest: GovernmentDataPostzonRetrieveByPostcodeOrPlaceRequest, ): string { return JSON.stringify( GovernmentDataPostzonRetrieveByPostcodeOrPlaceRequest$outboundSchema.parse( governmentDataPostzonRetrieveByPostcodeOrPlaceRequest, ), ); }