/* * 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 StripeConnectOptions = { /** * The Stripe Connect account to target using the `Stripe-Account` header. */ stripeAccount?: string | null | undefined; /** * The fee to charge the connected account. */ applicationFeeAmount?: number | null | undefined; /** * The Stripe Connect account to target using the `on_behalf_of` request parameter. */ onBehalfOf?: string | null | undefined; /** * The Stripe Connect account to target using the `transfer_data.destination` request parameter. */ transferDataDestination?: string | null | undefined; /** * A string that identifies the payment as part of a group. */ transferGroup?: string | null | undefined; }; /** @internal */ export type StripeConnectOptions$Outbound = { stripe_account?: string | null | undefined; application_fee_amount?: number | null | undefined; on_behalf_of?: string | null | undefined; transfer_data_destination?: string | null | undefined; transfer_group?: string | null | undefined; }; /** @internal */ export const StripeConnectOptions$outboundSchema: z.ZodType< StripeConnectOptions$Outbound, z.ZodTypeDef, StripeConnectOptions > = z.object({ stripeAccount: z.nullable(z.string()).optional(), applicationFeeAmount: z.nullable(z.number().int()).optional(), onBehalfOf: z.nullable(z.string()).optional(), transferDataDestination: z.nullable(z.string()).optional(), transferGroup: z.nullable(z.string()).optional(), }).transform((v) => { return remap$(v, { stripeAccount: "stripe_account", applicationFeeAmount: "application_fee_amount", onBehalfOf: "on_behalf_of", transferDataDestination: "transfer_data_destination", transferGroup: "transfer_group", }); }); export function stripeConnectOptionsToJSON( stripeConnectOptions: StripeConnectOptions, ): string { return JSON.stringify( StripeConnectOptions$outboundSchema.parse(stripeConnectOptions), ); }