/* * Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT. */ import * as z from "zod/v3"; import { remap as remap$ } from "../../lib/primitives.js"; import { safeParse } from "../../lib/schemas.js"; import { Result as SafeParseResult } from "../../types/fp.js"; import { SDKValidationError } from "../errors/sdkvalidationerror.js"; export type PazeMobileSessionCreate = { /** * Session URL for launching the Paze checkout UI from the native mobile app. */ pazeCheckoutUrl: string; /** * Merchant-defined transaction identifier echoed from the request. */ clientContext: string; /** * Globally unique session identifier generated by Paze. */ ewSID: string; /** * Timestamp when the response was sent by Paze, in ISO 8601 format. */ timestampIso8601: string; }; /** @internal */ export const PazeMobileSessionCreate$inboundSchema: z.ZodType< PazeMobileSessionCreate, z.ZodTypeDef, unknown > = z.object({ pazeCheckoutUrl: z.string(), clientContext: z.string(), ewSID: z.string(), timestampISO8601: z.string(), }).transform((v) => { return remap$(v, { "timestampISO8601": "timestampIso8601", }); }); export function pazeMobileSessionCreateFromJSON( jsonString: string, ): SafeParseResult { return safeParse( jsonString, (x) => PazeMobileSessionCreate$inboundSchema.parse(JSON.parse(x)), `Failed to parse 'PazeMobileSessionCreate' from JSON`, ); }