/* * Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT. */ import * as z from "zod/v3"; import { PazeLocationAddress, PazeLocationAddress$Outbound, PazeLocationAddress$outboundSchema, } from "./pazelocationaddress.js"; export type PazeTravelData = { /** * Traveler name. */ passengerName?: string | null | undefined; /** * Whether departure and return trips are being purchased in the same transaction. */ roundTrip?: boolean | null | undefined; /** * Date and time of departure in ISO 8601 format. */ departureDate?: string | null | undefined; /** * Date and time of return in ISO 8601 format. */ returnDate?: string | null | undefined; /** * Location from which the traveler departs. */ departureLocation?: PazeLocationAddress | null | undefined; /** * Location to which the traveler returns. */ returnLocation?: PazeLocationAddress | null | undefined; }; /** @internal */ export type PazeTravelData$Outbound = { passengerName?: string | null | undefined; roundTrip?: boolean | null | undefined; departureDate?: string | null | undefined; returnDate?: string | null | undefined; departureLocation?: PazeLocationAddress$Outbound | null | undefined; returnLocation?: PazeLocationAddress$Outbound | null | undefined; }; /** @internal */ export const PazeTravelData$outboundSchema: z.ZodType< PazeTravelData$Outbound, z.ZodTypeDef, PazeTravelData > = z.object({ passengerName: z.nullable(z.string()).optional(), roundTrip: z.nullable(z.boolean()).optional(), departureDate: z.nullable(z.string()).optional(), returnDate: z.nullable(z.string()).optional(), departureLocation: z.nullable(PazeLocationAddress$outboundSchema).optional(), returnLocation: z.nullable(PazeLocationAddress$outboundSchema).optional(), }); export function pazeTravelDataToJSON(pazeTravelData: PazeTravelData): string { return JSON.stringify(PazeTravelData$outboundSchema.parse(pazeTravelData)); }