Files
cozsweet-frontend-nextjs/src/data/schemas/payment/create_payment_order_request.ts
T

21 lines
523 B
TypeScript

/**
* 创建支付订单请求
*/
import { z } from "zod";
export const PayChannelSchema = z.enum(["stripe", "ezpay"]);
export const CreatePaymentOrderRequestSchema = z.object({
planId: z.string(),
payChannel: PayChannelSchema,
autoRenew: z.boolean(),
});
export type PayChannel = z.output<typeof PayChannelSchema>;
export type CreatePaymentOrderRequestInput = z.input<
typeof CreatePaymentOrderRequestSchema
>;
export type CreatePaymentOrderRequestData = z.output<
typeof CreatePaymentOrderRequestSchema
>;