feat(payment): support user-bound seven-discount offers

This commit is contained in:
Codex
2026-07-23 16:11:20 +08:00
parent 05f625dd0b
commit 46588bd98c
39 changed files with 418 additions and 28 deletions
@@ -0,0 +1,18 @@
import { z } from "zod";
export const CommercialOfferResponseSchema = z
.object({
commercialOfferId: z.string().min(1),
planId: z.string().min(1),
subscriptionType: z.enum(["vip", "topup"]),
discountPercent: z.number().int().min(0).max(100),
pricePercent: z.number().int().min(0).max(100),
expiresAt: z.string().min(1),
message: z.string().min(1),
promotionType: z.string().min(1),
})
.readonly();
export type CommercialOfferResponse = z.output<
typeof CommercialOfferResponseSchema
>;