/* * 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 ClickToPaySession = { /** * The ID of the Click to Pay application. */ digitalPaymentApplicationId: string; /** * The merchant name as configured ont he the Click to Pay wallet. */ digitalPaymentApplicationName: string; }; /** @internal */ export const ClickToPaySession$inboundSchema: z.ZodType< ClickToPaySession, z.ZodTypeDef, unknown > = z.object({ digital_payment_application_id: z.string(), digital_payment_application_name: z.string(), }).transform((v) => { return remap$(v, { "digital_payment_application_id": "digitalPaymentApplicationId", "digital_payment_application_name": "digitalPaymentApplicationName", }); }); export function clickToPaySessionFromJSON( jsonString: string, ): SafeParseResult { return safeParse( jsonString, (x) => ClickToPaySession$inboundSchema.parse(JSON.parse(x)), `Failed to parse 'ClickToPaySession' from JSON`, ); }