chargebee
Version:
A library for integrating with Chargebee.
33 lines (32 loc) • 1.5 kB
JavaScript
;
// Generated Zod schemas: RecordedPurchase
// Actions: create
// Do not edit manually – regenerate via sdk-generator
Object.defineProperty(exports, "__esModule", { value: true });
exports.CreateRecordedPurchaseBodySchema = void 0;
const zod_1 = require("zod");
//RecordedPurchase.create
const CreateRecordedPurchaseCustomerSchema = zod_1.z.object({
id: zod_1.z.string().max(50),
});
const CreateRecordedPurchaseAppleAppStoreSchema = zod_1.z.object({
transaction_id: zod_1.z.string().max(100).optional(),
receipt: zod_1.z.string().max(65000).optional(),
product_id: zod_1.z.string().max(255).optional(),
});
const CreateRecordedPurchaseGooglePlayStoreSchema = zod_1.z.object({
purchase_token: zod_1.z.string().max(500).optional(),
product_id: zod_1.z.string().max(255).optional(),
order_id: zod_1.z.string().max(100).optional(),
});
const CreateRecordedPurchaseOmnichannelSubscriptionSchema = zod_1.z.object({
id: zod_1.z.string().max(50).optional(),
});
const CreateRecordedPurchaseBodySchema = zod_1.z.looseObject({
app_id: zod_1.z.string().max(100),
customer: CreateRecordedPurchaseCustomerSchema.optional(),
apple_app_store: CreateRecordedPurchaseAppleAppStoreSchema.optional(),
google_play_store: CreateRecordedPurchaseGooglePlayStoreSchema.optional(),
omnichannel_subscription: CreateRecordedPurchaseOmnichannelSubscriptionSchema.optional(),
});
exports.CreateRecordedPurchaseBodySchema = CreateRecordedPurchaseBodySchema;