@lyxa.ai/marketing 1.0.28 → 1.0.30
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/lib/index.d.ts +642 -0
- package/dist/lib/index.d.ts.map +1 -1
- package/dist/lib/modules/coupon/routers/coupon.router.d.ts +642 -0
- package/dist/lib/modules/coupon/routers/coupon.router.d.ts.map +1 -1
- package/dist/lib/modules/coupon/routers/coupon.router.js +10 -0
- package/dist/lib/modules/coupon/routers/coupon.router.js.map +1 -1
- package/dist/lib/modules/coupon/services/coupon.service.d.ts +4 -3
- package/dist/lib/modules/coupon/services/coupon.service.d.ts.map +1 -1
- package/dist/lib/modules/coupon/services/coupon.service.js +77 -50
- package/dist/lib/modules/coupon/services/coupon.service.js.map +1 -1
- package/dist/lib/modules/coupon/services/custom-coupon.service.d.ts.map +1 -1
- package/dist/lib/modules/coupon/services/custom-coupon.service.js +6 -0
- package/dist/lib/modules/coupon/services/custom-coupon.service.js.map +1 -1
- package/dist/lib/modules/coupon/services/global-coupon.service.d.ts.map +1 -1
- package/dist/lib/modules/coupon/services/global-coupon.service.js +8 -1
- package/dist/lib/modules/coupon/services/global-coupon.service.js.map +1 -1
- package/dist/lib/modules/coupon/services/helper.service.d.ts +12 -0
- package/dist/lib/modules/coupon/services/helper.service.d.ts.map +1 -0
- package/dist/lib/modules/coupon/services/helper.service.js +147 -0
- package/dist/lib/modules/coupon/services/helper.service.js.map +1 -0
- package/dist/lib/modules/coupon/services/individual-store-coupon.service.d.ts.map +1 -1
- package/dist/lib/modules/coupon/services/individual-store-coupon.service.js +9 -0
- package/dist/lib/modules/coupon/services/individual-store-coupon.service.js.map +1 -1
- package/dist/lib/modules/coupon/services/individual-user-coupon.service.d.ts.map +1 -1
- package/dist/lib/modules/coupon/services/individual-user-coupon.service.js +8 -1
- package/dist/lib/modules/coupon/services/individual-user-coupon.service.js.map +1 -1
- package/dist/lib/modules/coupon/services/patterns/repository/CouponRepository.d.ts +6 -1
- package/dist/lib/modules/coupon/services/patterns/repository/CouponRepository.d.ts.map +1 -1
- package/dist/lib/modules/coupon/services/patterns/repository/CouponRepository.js +102 -6
- package/dist/lib/modules/coupon/services/patterns/repository/CouponRepository.js.map +1 -1
- package/dist/lib/modules/coupon/services/referral-code-coupon.service.d.ts +0 -1
- package/dist/lib/modules/coupon/services/referral-code-coupon.service.d.ts.map +1 -1
- package/dist/lib/modules/coupon/services/referral-code-coupon.service.js +16 -14
- package/dist/lib/modules/coupon/services/referral-code-coupon.service.js.map +1 -1
- package/dist/lib/modules/coupon/services/referral-reward-coupon.service.d.ts +2 -1
- package/dist/lib/modules/coupon/services/referral-reward-coupon.service.d.ts.map +1 -1
- package/dist/lib/modules/coupon/services/referral-reward-coupon.service.js +23 -20
- package/dist/lib/modules/coupon/services/referral-reward-coupon.service.js.map +1 -1
- package/dist/lib/modules/coupon/services/shops-categories-coupon.service.d.ts.map +1 -1
- package/dist/lib/modules/coupon/services/shops-categories-coupon.service.js +11 -1
- package/dist/lib/modules/coupon/services/shops-categories-coupon.service.js.map +1 -1
- package/dist/lib/modules/coupon/validations/all-coupons.validation.d.ts.map +1 -1
- package/dist/lib/modules/coupon/validations/all-coupons.validation.js.map +1 -1
- package/dist/lib/modules/coupon/validations/coupon.validation.d.ts +21 -0
- package/dist/lib/modules/coupon/validations/coupon.validation.d.ts.map +1 -1
- package/dist/lib/modules/coupon/validations/coupon.validation.js +11 -8
- package/dist/lib/modules/coupon/validations/coupon.validation.js.map +1 -1
- package/dist/lib/modules/deal-setting/routers/deal-setting.router.d.ts.map +1 -1
- package/dist/lib/modules/deal-setting/services/deal-setting.service.d.ts +2 -0
- package/dist/lib/modules/deal-setting/services/deal-setting.service.d.ts.map +1 -1
- package/dist/lib/modules/deal-setting/services/deal-setting.service.js +32 -8
- package/dist/lib/modules/deal-setting/services/deal-setting.service.js.map +1 -1
- package/dist/lib/modules/featured-setting/routers/featured-setting.router.d.ts.map +1 -1
- package/dist/lib/modules/featured-setting/services/featured-setting.service.d.ts +2 -0
- package/dist/lib/modules/featured-setting/services/featured-setting.service.d.ts.map +1 -1
- package/dist/lib/modules/featured-setting/services/featured-setting.service.js +54 -8
- package/dist/lib/modules/featured-setting/services/featured-setting.service.js.map +1 -1
- package/dist/lib/modules/marketing/routers/marketing.router.d.ts.map +1 -1
- package/dist/lib/modules/marketing/routers/marketing.router.js +5 -8
- package/dist/lib/modules/marketing/routers/marketing.router.js.map +1 -1
- package/dist/lib/modules/marketing/services/buy1-get1-marketing.service.d.ts.map +1 -1
- package/dist/lib/modules/marketing/services/buy1-get1-marketing.service.js +22 -6
- package/dist/lib/modules/marketing/services/buy1-get1-marketing.service.js.map +1 -1
- package/dist/lib/modules/marketing/services/discount-marketing.service.d.ts.map +1 -1
- package/dist/lib/modules/marketing/services/discount-marketing.service.js +22 -6
- package/dist/lib/modules/marketing/services/discount-marketing.service.js.map +1 -1
- package/dist/lib/modules/marketing/services/marketing.service.d.ts +1 -0
- package/dist/lib/modules/marketing/services/marketing.service.d.ts.map +1 -1
- package/dist/lib/modules/marketing/services/marketing.service.js +31 -4
- package/dist/lib/modules/marketing/services/marketing.service.js.map +1 -1
- package/dist/lib/modules/marketing/validations/featured-marketing.validation.d.ts.map +1 -1
- package/dist/lib/modules/marketing/validations/featured-marketing.validation.js +12 -13
- package/dist/lib/modules/marketing/validations/featured-marketing.validation.js.map +1 -1
- package/dist/lib/modules/marketing/validations/free-delivery-marketing.validation.d.ts.map +1 -1
- package/dist/lib/modules/marketing/validations/free-delivery-marketing.validation.js +8 -6
- package/dist/lib/modules/marketing/validations/free-delivery-marketing.validation.js.map +1 -1
- package/dist/lib/modules/marketing/validations/punch-marketing.validation.js +3 -6
- package/dist/lib/modules/marketing/validations/punch-marketing.validation.js.map +1 -1
- package/dist/lib/modules/punch-marketing-history/routers/punch-marketing-history.router.d.ts.map +1 -1
- package/dist/lib/modules/punch-marketing-history/services/punch-marketing-history.service.d.ts.map +1 -1
- package/dist/lib/modules/punch-marketing-history/services/punch-marketing-history.service.js +12 -9
- package/dist/lib/modules/punch-marketing-history/services/punch-marketing-history.service.js.map +1 -1
- package/dist/types/index.d.ts +642 -0
- package/dist/types/index.d.ts.map +1 -1
- package/dist/types/modules/coupon/routers/coupon.router.d.ts +642 -0
- package/dist/types/modules/coupon/routers/coupon.router.d.ts.map +1 -1
- package/dist/types/modules/coupon/services/coupon.service.d.ts +4 -3
- package/dist/types/modules/coupon/services/coupon.service.d.ts.map +1 -1
- package/dist/types/modules/coupon/services/custom-coupon.service.d.ts.map +1 -1
- package/dist/types/modules/coupon/services/global-coupon.service.d.ts.map +1 -1
- package/dist/types/modules/coupon/services/helper.service.d.ts +12 -0
- package/dist/types/modules/coupon/services/helper.service.d.ts.map +1 -0
- package/dist/types/modules/coupon/services/individual-store-coupon.service.d.ts.map +1 -1
- package/dist/types/modules/coupon/services/individual-user-coupon.service.d.ts.map +1 -1
- package/dist/types/modules/coupon/services/patterns/repository/CouponRepository.d.ts +6 -1
- package/dist/types/modules/coupon/services/patterns/repository/CouponRepository.d.ts.map +1 -1
- package/dist/types/modules/coupon/services/referral-code-coupon.service.d.ts +0 -1
- package/dist/types/modules/coupon/services/referral-code-coupon.service.d.ts.map +1 -1
- package/dist/types/modules/coupon/services/referral-reward-coupon.service.d.ts +2 -1
- package/dist/types/modules/coupon/services/referral-reward-coupon.service.d.ts.map +1 -1
- package/dist/types/modules/coupon/services/shops-categories-coupon.service.d.ts.map +1 -1
- package/dist/types/modules/coupon/validations/all-coupons.validation.d.ts.map +1 -1
- package/dist/types/modules/coupon/validations/coupon.validation.d.ts +21 -0
- package/dist/types/modules/coupon/validations/coupon.validation.d.ts.map +1 -1
- package/dist/types/modules/deal-setting/routers/deal-setting.router.d.ts.map +1 -1
- package/dist/types/modules/deal-setting/services/deal-setting.service.d.ts +2 -0
- package/dist/types/modules/deal-setting/services/deal-setting.service.d.ts.map +1 -1
- package/dist/types/modules/featured-setting/routers/featured-setting.router.d.ts.map +1 -1
- package/dist/types/modules/featured-setting/services/featured-setting.service.d.ts +2 -0
- package/dist/types/modules/featured-setting/services/featured-setting.service.d.ts.map +1 -1
- package/dist/types/modules/marketing/routers/marketing.router.d.ts.map +1 -1
- package/dist/types/modules/marketing/services/buy1-get1-marketing.service.d.ts.map +1 -1
- package/dist/types/modules/marketing/services/discount-marketing.service.d.ts.map +1 -1
- package/dist/types/modules/marketing/services/marketing.service.d.ts +1 -0
- package/dist/types/modules/marketing/services/marketing.service.d.ts.map +1 -1
- package/dist/types/modules/marketing/validations/featured-marketing.validation.d.ts.map +1 -1
- package/dist/types/modules/marketing/validations/free-delivery-marketing.validation.d.ts.map +1 -1
- package/dist/types/modules/punch-marketing-history/routers/punch-marketing-history.router.d.ts.map +1 -1
- package/dist/types/modules/punch-marketing-history/services/punch-marketing-history.service.d.ts.map +1 -1
- package/package.json +2 -2
|
@@ -2124,6 +2124,637 @@ export declare const couponRouter: import("@trpc/server").TRPCBuiltRouter<{
|
|
|
2124
2124
|
};
|
|
2125
2125
|
meta: object;
|
|
2126
2126
|
}>;
|
|
2127
|
+
checkExistingNewUserCoupon: import("@trpc/server").TRPCQueryProcedure<{
|
|
2128
|
+
input: void;
|
|
2129
|
+
output: {
|
|
2130
|
+
message: string;
|
|
2131
|
+
success: boolean;
|
|
2132
|
+
data?: z.objectInputType<{
|
|
2133
|
+
couponType: z.ZodOptional<z.ZodLiteral<import("@lyxa.ai/core/dist/utilities/enum").CouponType.GLOBAL>>;
|
|
2134
|
+
valueType: z.ZodOptional<z.ZodNativeEnum<typeof import("@lyxa.ai/core/dist/utilities/enum").ValueType>>;
|
|
2135
|
+
value: z.ZodOptional<z.ZodNumber>;
|
|
2136
|
+
secondaryCurrencyValue: z.ZodOptional<z.ZodOptional<z.ZodNumber>>;
|
|
2137
|
+
maxDiscountLimit: z.ZodOptional<z.ZodDefault<z.ZodNullable<z.ZodOptional<z.ZodNumber>>>>;
|
|
2138
|
+
secondaryCurrencyMaxDiscountLimit: z.ZodOptional<z.ZodOptional<z.ZodNumber>>;
|
|
2139
|
+
isMaxDiscountLimitEnabled: z.ZodOptional<z.ZodDefault<z.ZodOptional<z.ZodBoolean>>>;
|
|
2140
|
+
duration: z.ZodOptional<z.ZodEffects<z.ZodObject<{
|
|
2141
|
+
start: z.ZodEffects<z.ZodEffects<z.ZodUnion<[z.ZodEffects<z.ZodEffects<z.ZodString, string, string>, Date, string>, z.ZodDate]>, Date, string | Date>, Date, string | Date>;
|
|
2142
|
+
end: z.ZodOptional<z.ZodEffects<z.ZodEffects<z.ZodUnion<[z.ZodEffects<z.ZodEffects<z.ZodString, string, string>, Date, string>, z.ZodDate]>, Date, string | Date>, Date, string | Date>>;
|
|
2143
|
+
}, "strip", z.ZodTypeAny, {
|
|
2144
|
+
start: Date;
|
|
2145
|
+
end?: Date | undefined;
|
|
2146
|
+
}, {
|
|
2147
|
+
start: string | Date;
|
|
2148
|
+
end?: string | Date | undefined;
|
|
2149
|
+
}>, {
|
|
2150
|
+
start: Date;
|
|
2151
|
+
end?: Date | undefined;
|
|
2152
|
+
}, {
|
|
2153
|
+
start: string | Date;
|
|
2154
|
+
end?: string | Date | undefined;
|
|
2155
|
+
}>>;
|
|
2156
|
+
spendLimit: z.ZodOptional<z.ZodDefault<z.ZodNullable<z.ZodOptional<z.ZodNumber>>>>;
|
|
2157
|
+
isSpendLimitEnabled: z.ZodOptional<z.ZodDefault<z.ZodOptional<z.ZodBoolean>>>;
|
|
2158
|
+
totalOrderLimit: z.ZodOptional<z.ZodDefault<z.ZodNullable<z.ZodOptional<z.ZodNumber>>>>;
|
|
2159
|
+
isTotalOrderLimitEnabled: z.ZodOptional<z.ZodDefault<z.ZodOptional<z.ZodBoolean>>>;
|
|
2160
|
+
minOrderValue: z.ZodOptional<z.ZodDefault<z.ZodNullable<z.ZodNumber>>>;
|
|
2161
|
+
secondaryCurrencyMinOrderValue: z.ZodOptional<z.ZodOptional<z.ZodNumber>>;
|
|
2162
|
+
isMinOrderValueEnabled: z.ZodOptional<z.ZodDefault<z.ZodOptional<z.ZodBoolean>>>;
|
|
2163
|
+
forNewUserOnly: z.ZodOptional<z.ZodDefault<z.ZodOptional<z.ZodBoolean>>>;
|
|
2164
|
+
status: z.ZodOptional<z.ZodDefault<z.ZodOptional<z.ZodNativeEnum<typeof import("@lyxa.ai/core/dist/utilities/enum").Status>>>>;
|
|
2165
|
+
expirationReason: z.ZodOptional<z.ZodDefault<z.ZodNullable<z.ZodOptional<z.ZodNativeEnum<typeof import("@lyxa.ai/core/dist/utilities/enum").CouponExpirationReason>>>>>;
|
|
2166
|
+
referringUser: z.ZodOptional<z.ZodOptional<z.ZodObject<{
|
|
2167
|
+
name: z.ZodOptional<z.ZodString> | z.ZodOptional<z.ZodEffects<z.ZodEffects<z.ZodString, string, string>, string, string>>;
|
|
2168
|
+
}, "strip", z.ZodTypeAny, {
|
|
2169
|
+
name?: string | undefined;
|
|
2170
|
+
}, {
|
|
2171
|
+
name?: string | undefined;
|
|
2172
|
+
}>>>;
|
|
2173
|
+
code: z.ZodOptional<z.ZodString | z.ZodEffects<z.ZodEffects<z.ZodString, string, string>, string, string>>;
|
|
2174
|
+
orderLimitPerUser: z.ZodOptional<z.ZodDefault<z.ZodNullable<z.ZodOptional<z.ZodNumber>>>>;
|
|
2175
|
+
isOrderLimitPerUserEnabled: z.ZodOptional<z.ZodDefault<z.ZodOptional<z.ZodBoolean>>>;
|
|
2176
|
+
createdBy: z.ZodOptional<z.ZodOptional<z.ZodUnion<[z.ZodEffects<z.ZodEffects<z.ZodString, string, string>, mongoose.Types.ObjectId, string>, z.ZodType<mongoose.Types.ObjectId, z.ZodTypeDef, mongoose.Types.ObjectId>]>>>;
|
|
2177
|
+
isExpired: z.ZodOptional<z.ZodOptional<z.ZodBoolean>>;
|
|
2178
|
+
_id: z.ZodOptional<z.ZodUnion<[z.ZodEffects<z.ZodEffects<z.ZodString, string, string>, mongoose.Types.ObjectId, string>, z.ZodType<mongoose.Types.ObjectId, z.ZodTypeDef, mongoose.Types.ObjectId>]>>;
|
|
2179
|
+
}, z.ZodTypeAny, "passthrough"> | z.objectInputType<{
|
|
2180
|
+
couponType: z.ZodOptional<z.ZodLiteral<import("@lyxa.ai/core/dist/utilities/enum").CouponType.REFERRAL_CODE>>;
|
|
2181
|
+
orderLimitPerUser: z.ZodOptional<z.ZodLiteral<1>>;
|
|
2182
|
+
referralUser: z.ZodOptional<z.ZodUnion<[z.ZodEffects<z.ZodEffects<z.ZodString, string, string>, mongoose.Types.ObjectId, string>, z.ZodType<mongoose.Types.ObjectId, z.ZodTypeDef, mongoose.Types.ObjectId>]>>;
|
|
2183
|
+
code: z.ZodOptional<z.ZodString | z.ZodEffects<z.ZodEffects<z.ZodString, string, string>, string, string>>;
|
|
2184
|
+
isOrderLimitPerUserEnabled: z.ZodOptional<z.ZodDefault<z.ZodOptional<z.ZodBoolean>>>;
|
|
2185
|
+
createdBy: z.ZodOptional<z.ZodOptional<z.ZodUnion<[z.ZodEffects<z.ZodEffects<z.ZodString, string, string>, mongoose.Types.ObjectId, string>, z.ZodType<mongoose.Types.ObjectId, z.ZodTypeDef, mongoose.Types.ObjectId>]>>>;
|
|
2186
|
+
isExpired: z.ZodOptional<z.ZodOptional<z.ZodBoolean>>;
|
|
2187
|
+
_id: z.ZodOptional<z.ZodUnion<[z.ZodEffects<z.ZodEffects<z.ZodString, string, string>, mongoose.Types.ObjectId, string>, z.ZodType<mongoose.Types.ObjectId, z.ZodTypeDef, mongoose.Types.ObjectId>]>>;
|
|
2188
|
+
}, z.ZodTypeAny, "passthrough"> | z.objectInputType<{
|
|
2189
|
+
couponType: z.ZodOptional<z.ZodLiteral<import("@lyxa.ai/core/dist/utilities/enum").CouponType.REFERRAL_REWARD>>;
|
|
2190
|
+
user: z.ZodOptional<z.ZodUnion<[z.ZodEffects<z.ZodEffects<z.ZodString, string, string>, mongoose.Types.ObjectId, string>, z.ZodType<mongoose.Types.ObjectId, z.ZodTypeDef, mongoose.Types.ObjectId>]>>;
|
|
2191
|
+
referralCodeUsedBy: z.ZodOptional<z.ZodUnion<[z.ZodEffects<z.ZodEffects<z.ZodString, string, string>, mongoose.Types.ObjectId, string>, z.ZodType<mongoose.Types.ObjectId, z.ZodTypeDef, mongoose.Types.ObjectId>]>>;
|
|
2192
|
+
referralCodeUsedOnOrder: z.ZodOptional<z.ZodUnion<[z.ZodEffects<z.ZodEffects<z.ZodString, string, string>, mongoose.Types.ObjectId, string>, z.ZodType<mongoose.Types.ObjectId, z.ZodTypeDef, mongoose.Types.ObjectId>]>>;
|
|
2193
|
+
valueType: z.ZodOptional<z.ZodNativeEnum<typeof import("@lyxa.ai/core/dist/utilities/enum").ValueType>>;
|
|
2194
|
+
value: z.ZodOptional<z.ZodNumber>;
|
|
2195
|
+
secondaryCurrencyValue: z.ZodOptional<z.ZodOptional<z.ZodNumber>>;
|
|
2196
|
+
maxDiscountLimit: z.ZodOptional<z.ZodDefault<z.ZodNullable<z.ZodOptional<z.ZodNumber>>>>;
|
|
2197
|
+
secondaryCurrencyMaxDiscountLimit: z.ZodOptional<z.ZodOptional<z.ZodNumber>>;
|
|
2198
|
+
isMaxDiscountLimitEnabled: z.ZodOptional<z.ZodDefault<z.ZodOptional<z.ZodBoolean>>>;
|
|
2199
|
+
duration: z.ZodOptional<z.ZodEffects<z.ZodObject<{
|
|
2200
|
+
start: z.ZodEffects<z.ZodEffects<z.ZodUnion<[z.ZodEffects<z.ZodEffects<z.ZodString, string, string>, Date, string>, z.ZodDate]>, Date, string | Date>, Date, string | Date>;
|
|
2201
|
+
end: z.ZodOptional<z.ZodEffects<z.ZodEffects<z.ZodUnion<[z.ZodEffects<z.ZodEffects<z.ZodString, string, string>, Date, string>, z.ZodDate]>, Date, string | Date>, Date, string | Date>>;
|
|
2202
|
+
}, "strip", z.ZodTypeAny, {
|
|
2203
|
+
start: Date;
|
|
2204
|
+
end?: Date | undefined;
|
|
2205
|
+
}, {
|
|
2206
|
+
start: string | Date;
|
|
2207
|
+
end?: string | Date | undefined;
|
|
2208
|
+
}>, {
|
|
2209
|
+
start: Date;
|
|
2210
|
+
end?: Date | undefined;
|
|
2211
|
+
}, {
|
|
2212
|
+
start: string | Date;
|
|
2213
|
+
end?: string | Date | undefined;
|
|
2214
|
+
}>>;
|
|
2215
|
+
spendLimit: z.ZodOptional<z.ZodDefault<z.ZodNullable<z.ZodOptional<z.ZodNumber>>>>;
|
|
2216
|
+
isSpendLimitEnabled: z.ZodOptional<z.ZodDefault<z.ZodOptional<z.ZodBoolean>>>;
|
|
2217
|
+
totalOrderLimit: z.ZodOptional<z.ZodDefault<z.ZodNullable<z.ZodOptional<z.ZodNumber>>>>;
|
|
2218
|
+
isTotalOrderLimitEnabled: z.ZodOptional<z.ZodDefault<z.ZodOptional<z.ZodBoolean>>>;
|
|
2219
|
+
minOrderValue: z.ZodOptional<z.ZodDefault<z.ZodNullable<z.ZodNumber>>>;
|
|
2220
|
+
secondaryCurrencyMinOrderValue: z.ZodOptional<z.ZodOptional<z.ZodNumber>>;
|
|
2221
|
+
isMinOrderValueEnabled: z.ZodOptional<z.ZodDefault<z.ZodOptional<z.ZodBoolean>>>;
|
|
2222
|
+
forNewUserOnly: z.ZodOptional<z.ZodDefault<z.ZodOptional<z.ZodBoolean>>>;
|
|
2223
|
+
status: z.ZodOptional<z.ZodDefault<z.ZodOptional<z.ZodNativeEnum<typeof import("@lyxa.ai/core/dist/utilities/enum").Status>>>>;
|
|
2224
|
+
expirationReason: z.ZodOptional<z.ZodDefault<z.ZodNullable<z.ZodOptional<z.ZodNativeEnum<typeof import("@lyxa.ai/core/dist/utilities/enum").CouponExpirationReason>>>>>;
|
|
2225
|
+
referringUser: z.ZodOptional<z.ZodOptional<z.ZodObject<{
|
|
2226
|
+
name: z.ZodOptional<z.ZodString> | z.ZodOptional<z.ZodEffects<z.ZodEffects<z.ZodString, string, string>, string, string>>;
|
|
2227
|
+
}, "strip", z.ZodTypeAny, {
|
|
2228
|
+
name?: string | undefined;
|
|
2229
|
+
}, {
|
|
2230
|
+
name?: string | undefined;
|
|
2231
|
+
}>>>;
|
|
2232
|
+
code: z.ZodOptional<z.ZodString | z.ZodEffects<z.ZodEffects<z.ZodString, string, string>, string, string>>;
|
|
2233
|
+
orderLimitPerUser: z.ZodOptional<z.ZodDefault<z.ZodNullable<z.ZodOptional<z.ZodNumber>>>>;
|
|
2234
|
+
isOrderLimitPerUserEnabled: z.ZodOptional<z.ZodDefault<z.ZodOptional<z.ZodBoolean>>>;
|
|
2235
|
+
createdBy: z.ZodOptional<z.ZodOptional<z.ZodUnion<[z.ZodEffects<z.ZodEffects<z.ZodString, string, string>, mongoose.Types.ObjectId, string>, z.ZodType<mongoose.Types.ObjectId, z.ZodTypeDef, mongoose.Types.ObjectId>]>>>;
|
|
2236
|
+
isExpired: z.ZodOptional<z.ZodOptional<z.ZodBoolean>>;
|
|
2237
|
+
_id: z.ZodOptional<z.ZodUnion<[z.ZodEffects<z.ZodEffects<z.ZodString, string, string>, mongoose.Types.ObjectId, string>, z.ZodType<mongoose.Types.ObjectId, z.ZodTypeDef, mongoose.Types.ObjectId>]>>;
|
|
2238
|
+
}, z.ZodTypeAny, "passthrough"> | z.objectInputType<{
|
|
2239
|
+
couponType: z.ZodOptional<z.ZodLiteral<import("@lyxa.ai/core/dist/utilities/enum").CouponType.SHOPS_CATEGORIES>>;
|
|
2240
|
+
itemTypes: z.ZodOptional<z.ZodDefault<z.ZodArray<z.ZodNativeEnum<typeof import("@lyxa.ai/core/dist/utilities/enum").ItemType>, "many">>>;
|
|
2241
|
+
shops: z.ZodOptional<z.ZodDefault<z.ZodArray<z.ZodUnion<[z.ZodEffects<z.ZodEffects<z.ZodString, string, string>, mongoose.Types.ObjectId, string>, z.ZodType<mongoose.Types.ObjectId, z.ZodTypeDef, mongoose.Types.ObjectId>]>, "many">>>;
|
|
2242
|
+
isShopCoverExpenses: z.ZodOptional<z.ZodDefault<z.ZodBoolean>>;
|
|
2243
|
+
firstOrderOnly: z.ZodOptional<z.ZodDefault<z.ZodBoolean>>;
|
|
2244
|
+
valueType: z.ZodOptional<z.ZodNativeEnum<typeof import("@lyxa.ai/core/dist/utilities/enum").ValueType>>;
|
|
2245
|
+
value: z.ZodOptional<z.ZodNumber>;
|
|
2246
|
+
secondaryCurrencyValue: z.ZodOptional<z.ZodOptional<z.ZodNumber>>;
|
|
2247
|
+
maxDiscountLimit: z.ZodOptional<z.ZodDefault<z.ZodNullable<z.ZodOptional<z.ZodNumber>>>>;
|
|
2248
|
+
secondaryCurrencyMaxDiscountLimit: z.ZodOptional<z.ZodOptional<z.ZodNumber>>;
|
|
2249
|
+
isMaxDiscountLimitEnabled: z.ZodOptional<z.ZodDefault<z.ZodOptional<z.ZodBoolean>>>;
|
|
2250
|
+
duration: z.ZodOptional<z.ZodEffects<z.ZodObject<{
|
|
2251
|
+
start: z.ZodEffects<z.ZodEffects<z.ZodUnion<[z.ZodEffects<z.ZodEffects<z.ZodString, string, string>, Date, string>, z.ZodDate]>, Date, string | Date>, Date, string | Date>;
|
|
2252
|
+
end: z.ZodOptional<z.ZodEffects<z.ZodEffects<z.ZodUnion<[z.ZodEffects<z.ZodEffects<z.ZodString, string, string>, Date, string>, z.ZodDate]>, Date, string | Date>, Date, string | Date>>;
|
|
2253
|
+
}, "strip", z.ZodTypeAny, {
|
|
2254
|
+
start: Date;
|
|
2255
|
+
end?: Date | undefined;
|
|
2256
|
+
}, {
|
|
2257
|
+
start: string | Date;
|
|
2258
|
+
end?: string | Date | undefined;
|
|
2259
|
+
}>, {
|
|
2260
|
+
start: Date;
|
|
2261
|
+
end?: Date | undefined;
|
|
2262
|
+
}, {
|
|
2263
|
+
start: string | Date;
|
|
2264
|
+
end?: string | Date | undefined;
|
|
2265
|
+
}>>;
|
|
2266
|
+
spendLimit: z.ZodOptional<z.ZodDefault<z.ZodNullable<z.ZodOptional<z.ZodNumber>>>>;
|
|
2267
|
+
isSpendLimitEnabled: z.ZodOptional<z.ZodDefault<z.ZodOptional<z.ZodBoolean>>>;
|
|
2268
|
+
totalOrderLimit: z.ZodOptional<z.ZodDefault<z.ZodNullable<z.ZodOptional<z.ZodNumber>>>>;
|
|
2269
|
+
isTotalOrderLimitEnabled: z.ZodOptional<z.ZodDefault<z.ZodOptional<z.ZodBoolean>>>;
|
|
2270
|
+
minOrderValue: z.ZodOptional<z.ZodDefault<z.ZodNullable<z.ZodNumber>>>;
|
|
2271
|
+
secondaryCurrencyMinOrderValue: z.ZodOptional<z.ZodOptional<z.ZodNumber>>;
|
|
2272
|
+
isMinOrderValueEnabled: z.ZodOptional<z.ZodDefault<z.ZodOptional<z.ZodBoolean>>>;
|
|
2273
|
+
forNewUserOnly: z.ZodOptional<z.ZodDefault<z.ZodOptional<z.ZodBoolean>>>;
|
|
2274
|
+
status: z.ZodOptional<z.ZodDefault<z.ZodOptional<z.ZodNativeEnum<typeof import("@lyxa.ai/core/dist/utilities/enum").Status>>>>;
|
|
2275
|
+
expirationReason: z.ZodOptional<z.ZodDefault<z.ZodNullable<z.ZodOptional<z.ZodNativeEnum<typeof import("@lyxa.ai/core/dist/utilities/enum").CouponExpirationReason>>>>>;
|
|
2276
|
+
referringUser: z.ZodOptional<z.ZodOptional<z.ZodObject<{
|
|
2277
|
+
name: z.ZodOptional<z.ZodString> | z.ZodOptional<z.ZodEffects<z.ZodEffects<z.ZodString, string, string>, string, string>>;
|
|
2278
|
+
}, "strip", z.ZodTypeAny, {
|
|
2279
|
+
name?: string | undefined;
|
|
2280
|
+
}, {
|
|
2281
|
+
name?: string | undefined;
|
|
2282
|
+
}>>>;
|
|
2283
|
+
code: z.ZodOptional<z.ZodString | z.ZodEffects<z.ZodEffects<z.ZodString, string, string>, string, string>>;
|
|
2284
|
+
orderLimitPerUser: z.ZodOptional<z.ZodDefault<z.ZodNullable<z.ZodOptional<z.ZodNumber>>>>;
|
|
2285
|
+
isOrderLimitPerUserEnabled: z.ZodOptional<z.ZodDefault<z.ZodOptional<z.ZodBoolean>>>;
|
|
2286
|
+
createdBy: z.ZodOptional<z.ZodOptional<z.ZodUnion<[z.ZodEffects<z.ZodEffects<z.ZodString, string, string>, mongoose.Types.ObjectId, string>, z.ZodType<mongoose.Types.ObjectId, z.ZodTypeDef, mongoose.Types.ObjectId>]>>>;
|
|
2287
|
+
isExpired: z.ZodOptional<z.ZodOptional<z.ZodBoolean>>;
|
|
2288
|
+
_id: z.ZodOptional<z.ZodUnion<[z.ZodEffects<z.ZodEffects<z.ZodString, string, string>, mongoose.Types.ObjectId, string>, z.ZodType<mongoose.Types.ObjectId, z.ZodTypeDef, mongoose.Types.ObjectId>]>>;
|
|
2289
|
+
}, z.ZodTypeAny, "passthrough"> | z.objectInputType<{
|
|
2290
|
+
couponType: z.ZodOptional<z.ZodLiteral<import("@lyxa.ai/core/dist/utilities/enum").CouponType.INDIVIDUAL_STORE>>;
|
|
2291
|
+
shop: z.ZodOptional<z.ZodUnion<[z.ZodEffects<z.ZodEffects<z.ZodString, string, string>, mongoose.Types.ObjectId, string>, z.ZodType<mongoose.Types.ObjectId, z.ZodTypeDef, mongoose.Types.ObjectId>]>>;
|
|
2292
|
+
isShopCoverExpenses: z.ZodOptional<z.ZodDefault<z.ZodBoolean>>;
|
|
2293
|
+
firstOrderOnly: z.ZodOptional<z.ZodDefault<z.ZodBoolean>>;
|
|
2294
|
+
valueType: z.ZodOptional<z.ZodNativeEnum<typeof import("@lyxa.ai/core/dist/utilities/enum").ValueType>>;
|
|
2295
|
+
value: z.ZodOptional<z.ZodNumber>;
|
|
2296
|
+
secondaryCurrencyValue: z.ZodOptional<z.ZodOptional<z.ZodNumber>>;
|
|
2297
|
+
maxDiscountLimit: z.ZodOptional<z.ZodDefault<z.ZodNullable<z.ZodOptional<z.ZodNumber>>>>;
|
|
2298
|
+
secondaryCurrencyMaxDiscountLimit: z.ZodOptional<z.ZodOptional<z.ZodNumber>>;
|
|
2299
|
+
isMaxDiscountLimitEnabled: z.ZodOptional<z.ZodDefault<z.ZodOptional<z.ZodBoolean>>>;
|
|
2300
|
+
duration: z.ZodOptional<z.ZodEffects<z.ZodObject<{
|
|
2301
|
+
start: z.ZodEffects<z.ZodEffects<z.ZodUnion<[z.ZodEffects<z.ZodEffects<z.ZodString, string, string>, Date, string>, z.ZodDate]>, Date, string | Date>, Date, string | Date>;
|
|
2302
|
+
end: z.ZodOptional<z.ZodEffects<z.ZodEffects<z.ZodUnion<[z.ZodEffects<z.ZodEffects<z.ZodString, string, string>, Date, string>, z.ZodDate]>, Date, string | Date>, Date, string | Date>>;
|
|
2303
|
+
}, "strip", z.ZodTypeAny, {
|
|
2304
|
+
start: Date;
|
|
2305
|
+
end?: Date | undefined;
|
|
2306
|
+
}, {
|
|
2307
|
+
start: string | Date;
|
|
2308
|
+
end?: string | Date | undefined;
|
|
2309
|
+
}>, {
|
|
2310
|
+
start: Date;
|
|
2311
|
+
end?: Date | undefined;
|
|
2312
|
+
}, {
|
|
2313
|
+
start: string | Date;
|
|
2314
|
+
end?: string | Date | undefined;
|
|
2315
|
+
}>>;
|
|
2316
|
+
spendLimit: z.ZodOptional<z.ZodDefault<z.ZodNullable<z.ZodOptional<z.ZodNumber>>>>;
|
|
2317
|
+
isSpendLimitEnabled: z.ZodOptional<z.ZodDefault<z.ZodOptional<z.ZodBoolean>>>;
|
|
2318
|
+
totalOrderLimit: z.ZodOptional<z.ZodDefault<z.ZodNullable<z.ZodOptional<z.ZodNumber>>>>;
|
|
2319
|
+
isTotalOrderLimitEnabled: z.ZodOptional<z.ZodDefault<z.ZodOptional<z.ZodBoolean>>>;
|
|
2320
|
+
minOrderValue: z.ZodOptional<z.ZodDefault<z.ZodNullable<z.ZodNumber>>>;
|
|
2321
|
+
secondaryCurrencyMinOrderValue: z.ZodOptional<z.ZodOptional<z.ZodNumber>>;
|
|
2322
|
+
isMinOrderValueEnabled: z.ZodOptional<z.ZodDefault<z.ZodOptional<z.ZodBoolean>>>;
|
|
2323
|
+
forNewUserOnly: z.ZodOptional<z.ZodDefault<z.ZodOptional<z.ZodBoolean>>>;
|
|
2324
|
+
status: z.ZodOptional<z.ZodDefault<z.ZodOptional<z.ZodNativeEnum<typeof import("@lyxa.ai/core/dist/utilities/enum").Status>>>>;
|
|
2325
|
+
expirationReason: z.ZodOptional<z.ZodDefault<z.ZodNullable<z.ZodOptional<z.ZodNativeEnum<typeof import("@lyxa.ai/core/dist/utilities/enum").CouponExpirationReason>>>>>;
|
|
2326
|
+
referringUser: z.ZodOptional<z.ZodOptional<z.ZodObject<{
|
|
2327
|
+
name: z.ZodOptional<z.ZodString> | z.ZodOptional<z.ZodEffects<z.ZodEffects<z.ZodString, string, string>, string, string>>;
|
|
2328
|
+
}, "strip", z.ZodTypeAny, {
|
|
2329
|
+
name?: string | undefined;
|
|
2330
|
+
}, {
|
|
2331
|
+
name?: string | undefined;
|
|
2332
|
+
}>>>;
|
|
2333
|
+
code: z.ZodOptional<z.ZodString | z.ZodEffects<z.ZodEffects<z.ZodString, string, string>, string, string>>;
|
|
2334
|
+
orderLimitPerUser: z.ZodOptional<z.ZodDefault<z.ZodNullable<z.ZodOptional<z.ZodNumber>>>>;
|
|
2335
|
+
isOrderLimitPerUserEnabled: z.ZodOptional<z.ZodDefault<z.ZodOptional<z.ZodBoolean>>>;
|
|
2336
|
+
createdBy: z.ZodOptional<z.ZodOptional<z.ZodUnion<[z.ZodEffects<z.ZodEffects<z.ZodString, string, string>, mongoose.Types.ObjectId, string>, z.ZodType<mongoose.Types.ObjectId, z.ZodTypeDef, mongoose.Types.ObjectId>]>>>;
|
|
2337
|
+
isExpired: z.ZodOptional<z.ZodOptional<z.ZodBoolean>>;
|
|
2338
|
+
_id: z.ZodOptional<z.ZodUnion<[z.ZodEffects<z.ZodEffects<z.ZodString, string, string>, mongoose.Types.ObjectId, string>, z.ZodType<mongoose.Types.ObjectId, z.ZodTypeDef, mongoose.Types.ObjectId>]>>;
|
|
2339
|
+
}, z.ZodTypeAny, "passthrough"> | z.objectInputType<{
|
|
2340
|
+
couponType: z.ZodOptional<z.ZodLiteral<import("@lyxa.ai/core/dist/utilities/enum").CouponType.INDIVIDUAL_USER>>;
|
|
2341
|
+
users: z.ZodOptional<z.ZodArray<z.ZodUnion<[z.ZodEffects<z.ZodEffects<z.ZodString, string, string>, mongoose.Types.ObjectId, string>, z.ZodType<mongoose.Types.ObjectId, z.ZodTypeDef, mongoose.Types.ObjectId>]>, "atleastone">>;
|
|
2342
|
+
itemTypes: z.ZodOptional<z.ZodDefault<z.ZodArray<z.ZodNativeEnum<typeof import("@lyxa.ai/core/dist/utilities/enum").ItemType>, "many">>>;
|
|
2343
|
+
shops: z.ZodOptional<z.ZodDefault<z.ZodArray<z.ZodUnion<[z.ZodEffects<z.ZodEffects<z.ZodString, string, string>, mongoose.Types.ObjectId, string>, z.ZodType<mongoose.Types.ObjectId, z.ZodTypeDef, mongoose.Types.ObjectId>]>, "many">>>;
|
|
2344
|
+
valueType: z.ZodOptional<z.ZodNativeEnum<typeof import("@lyxa.ai/core/dist/utilities/enum").ValueType>>;
|
|
2345
|
+
value: z.ZodOptional<z.ZodNumber>;
|
|
2346
|
+
secondaryCurrencyValue: z.ZodOptional<z.ZodOptional<z.ZodNumber>>;
|
|
2347
|
+
maxDiscountLimit: z.ZodOptional<z.ZodDefault<z.ZodNullable<z.ZodOptional<z.ZodNumber>>>>;
|
|
2348
|
+
secondaryCurrencyMaxDiscountLimit: z.ZodOptional<z.ZodOptional<z.ZodNumber>>;
|
|
2349
|
+
isMaxDiscountLimitEnabled: z.ZodOptional<z.ZodDefault<z.ZodOptional<z.ZodBoolean>>>;
|
|
2350
|
+
duration: z.ZodOptional<z.ZodEffects<z.ZodObject<{
|
|
2351
|
+
start: z.ZodEffects<z.ZodEffects<z.ZodUnion<[z.ZodEffects<z.ZodEffects<z.ZodString, string, string>, Date, string>, z.ZodDate]>, Date, string | Date>, Date, string | Date>;
|
|
2352
|
+
end: z.ZodOptional<z.ZodEffects<z.ZodEffects<z.ZodUnion<[z.ZodEffects<z.ZodEffects<z.ZodString, string, string>, Date, string>, z.ZodDate]>, Date, string | Date>, Date, string | Date>>;
|
|
2353
|
+
}, "strip", z.ZodTypeAny, {
|
|
2354
|
+
start: Date;
|
|
2355
|
+
end?: Date | undefined;
|
|
2356
|
+
}, {
|
|
2357
|
+
start: string | Date;
|
|
2358
|
+
end?: string | Date | undefined;
|
|
2359
|
+
}>, {
|
|
2360
|
+
start: Date;
|
|
2361
|
+
end?: Date | undefined;
|
|
2362
|
+
}, {
|
|
2363
|
+
start: string | Date;
|
|
2364
|
+
end?: string | Date | undefined;
|
|
2365
|
+
}>>;
|
|
2366
|
+
spendLimit: z.ZodOptional<z.ZodDefault<z.ZodNullable<z.ZodOptional<z.ZodNumber>>>>;
|
|
2367
|
+
isSpendLimitEnabled: z.ZodOptional<z.ZodDefault<z.ZodOptional<z.ZodBoolean>>>;
|
|
2368
|
+
totalOrderLimit: z.ZodOptional<z.ZodDefault<z.ZodNullable<z.ZodOptional<z.ZodNumber>>>>;
|
|
2369
|
+
isTotalOrderLimitEnabled: z.ZodOptional<z.ZodDefault<z.ZodOptional<z.ZodBoolean>>>;
|
|
2370
|
+
minOrderValue: z.ZodOptional<z.ZodDefault<z.ZodNullable<z.ZodNumber>>>;
|
|
2371
|
+
secondaryCurrencyMinOrderValue: z.ZodOptional<z.ZodOptional<z.ZodNumber>>;
|
|
2372
|
+
isMinOrderValueEnabled: z.ZodOptional<z.ZodDefault<z.ZodOptional<z.ZodBoolean>>>;
|
|
2373
|
+
forNewUserOnly: z.ZodOptional<z.ZodDefault<z.ZodOptional<z.ZodBoolean>>>;
|
|
2374
|
+
status: z.ZodOptional<z.ZodDefault<z.ZodOptional<z.ZodNativeEnum<typeof import("@lyxa.ai/core/dist/utilities/enum").Status>>>>;
|
|
2375
|
+
expirationReason: z.ZodOptional<z.ZodDefault<z.ZodNullable<z.ZodOptional<z.ZodNativeEnum<typeof import("@lyxa.ai/core/dist/utilities/enum").CouponExpirationReason>>>>>;
|
|
2376
|
+
referringUser: z.ZodOptional<z.ZodOptional<z.ZodObject<{
|
|
2377
|
+
name: z.ZodOptional<z.ZodString> | z.ZodOptional<z.ZodEffects<z.ZodEffects<z.ZodString, string, string>, string, string>>;
|
|
2378
|
+
}, "strip", z.ZodTypeAny, {
|
|
2379
|
+
name?: string | undefined;
|
|
2380
|
+
}, {
|
|
2381
|
+
name?: string | undefined;
|
|
2382
|
+
}>>>;
|
|
2383
|
+
code: z.ZodOptional<z.ZodString | z.ZodEffects<z.ZodEffects<z.ZodString, string, string>, string, string>>;
|
|
2384
|
+
orderLimitPerUser: z.ZodOptional<z.ZodDefault<z.ZodNullable<z.ZodOptional<z.ZodNumber>>>>;
|
|
2385
|
+
isOrderLimitPerUserEnabled: z.ZodOptional<z.ZodDefault<z.ZodOptional<z.ZodBoolean>>>;
|
|
2386
|
+
createdBy: z.ZodOptional<z.ZodOptional<z.ZodUnion<[z.ZodEffects<z.ZodEffects<z.ZodString, string, string>, mongoose.Types.ObjectId, string>, z.ZodType<mongoose.Types.ObjectId, z.ZodTypeDef, mongoose.Types.ObjectId>]>>>;
|
|
2387
|
+
isExpired: z.ZodOptional<z.ZodOptional<z.ZodBoolean>>;
|
|
2388
|
+
_id: z.ZodOptional<z.ZodUnion<[z.ZodEffects<z.ZodEffects<z.ZodString, string, string>, mongoose.Types.ObjectId, string>, z.ZodType<mongoose.Types.ObjectId, z.ZodTypeDef, mongoose.Types.ObjectId>]>>;
|
|
2389
|
+
}, z.ZodTypeAny, "passthrough"> | z.objectInputType<{
|
|
2390
|
+
couponType: z.ZodOptional<z.ZodLiteral<import("@lyxa.ai/core/dist/utilities/enum").CouponType.CUSTOM_COUPON>>;
|
|
2391
|
+
influencer: z.ZodOptional<z.ZodUnion<[z.ZodEffects<z.ZodEffects<z.ZodString, string, string>, mongoose.Types.ObjectId, string>, z.ZodType<mongoose.Types.ObjectId, z.ZodTypeDef, mongoose.Types.ObjectId>]>>;
|
|
2392
|
+
itemTypes: z.ZodOptional<z.ZodDefault<z.ZodArray<z.ZodNativeEnum<typeof import("@lyxa.ai/core/dist/utilities/enum").ItemType>, "many">>>;
|
|
2393
|
+
shops: z.ZodOptional<z.ZodDefault<z.ZodArray<z.ZodUnion<[z.ZodEffects<z.ZodEffects<z.ZodString, string, string>, mongoose.Types.ObjectId, string>, z.ZodType<mongoose.Types.ObjectId, z.ZodTypeDef, mongoose.Types.ObjectId>]>, "many">>>;
|
|
2394
|
+
valueType: z.ZodOptional<z.ZodNativeEnum<typeof import("@lyxa.ai/core/dist/utilities/enum").ValueType>>;
|
|
2395
|
+
value: z.ZodOptional<z.ZodNumber>;
|
|
2396
|
+
secondaryCurrencyValue: z.ZodOptional<z.ZodOptional<z.ZodNumber>>;
|
|
2397
|
+
maxDiscountLimit: z.ZodOptional<z.ZodDefault<z.ZodNullable<z.ZodOptional<z.ZodNumber>>>>;
|
|
2398
|
+
secondaryCurrencyMaxDiscountLimit: z.ZodOptional<z.ZodOptional<z.ZodNumber>>;
|
|
2399
|
+
isMaxDiscountLimitEnabled: z.ZodOptional<z.ZodDefault<z.ZodOptional<z.ZodBoolean>>>;
|
|
2400
|
+
duration: z.ZodOptional<z.ZodEffects<z.ZodObject<{
|
|
2401
|
+
start: z.ZodEffects<z.ZodEffects<z.ZodUnion<[z.ZodEffects<z.ZodEffects<z.ZodString, string, string>, Date, string>, z.ZodDate]>, Date, string | Date>, Date, string | Date>;
|
|
2402
|
+
end: z.ZodOptional<z.ZodEffects<z.ZodEffects<z.ZodUnion<[z.ZodEffects<z.ZodEffects<z.ZodString, string, string>, Date, string>, z.ZodDate]>, Date, string | Date>, Date, string | Date>>;
|
|
2403
|
+
}, "strip", z.ZodTypeAny, {
|
|
2404
|
+
start: Date;
|
|
2405
|
+
end?: Date | undefined;
|
|
2406
|
+
}, {
|
|
2407
|
+
start: string | Date;
|
|
2408
|
+
end?: string | Date | undefined;
|
|
2409
|
+
}>, {
|
|
2410
|
+
start: Date;
|
|
2411
|
+
end?: Date | undefined;
|
|
2412
|
+
}, {
|
|
2413
|
+
start: string | Date;
|
|
2414
|
+
end?: string | Date | undefined;
|
|
2415
|
+
}>>;
|
|
2416
|
+
spendLimit: z.ZodOptional<z.ZodDefault<z.ZodNullable<z.ZodOptional<z.ZodNumber>>>>;
|
|
2417
|
+
isSpendLimitEnabled: z.ZodOptional<z.ZodDefault<z.ZodOptional<z.ZodBoolean>>>;
|
|
2418
|
+
totalOrderLimit: z.ZodOptional<z.ZodDefault<z.ZodNullable<z.ZodOptional<z.ZodNumber>>>>;
|
|
2419
|
+
isTotalOrderLimitEnabled: z.ZodOptional<z.ZodDefault<z.ZodOptional<z.ZodBoolean>>>;
|
|
2420
|
+
minOrderValue: z.ZodOptional<z.ZodDefault<z.ZodNullable<z.ZodNumber>>>;
|
|
2421
|
+
secondaryCurrencyMinOrderValue: z.ZodOptional<z.ZodOptional<z.ZodNumber>>;
|
|
2422
|
+
isMinOrderValueEnabled: z.ZodOptional<z.ZodDefault<z.ZodOptional<z.ZodBoolean>>>;
|
|
2423
|
+
forNewUserOnly: z.ZodOptional<z.ZodDefault<z.ZodOptional<z.ZodBoolean>>>;
|
|
2424
|
+
status: z.ZodOptional<z.ZodDefault<z.ZodOptional<z.ZodNativeEnum<typeof import("@lyxa.ai/core/dist/utilities/enum").Status>>>>;
|
|
2425
|
+
expirationReason: z.ZodOptional<z.ZodDefault<z.ZodNullable<z.ZodOptional<z.ZodNativeEnum<typeof import("@lyxa.ai/core/dist/utilities/enum").CouponExpirationReason>>>>>;
|
|
2426
|
+
referringUser: z.ZodOptional<z.ZodOptional<z.ZodObject<{
|
|
2427
|
+
name: z.ZodOptional<z.ZodString> | z.ZodOptional<z.ZodEffects<z.ZodEffects<z.ZodString, string, string>, string, string>>;
|
|
2428
|
+
}, "strip", z.ZodTypeAny, {
|
|
2429
|
+
name?: string | undefined;
|
|
2430
|
+
}, {
|
|
2431
|
+
name?: string | undefined;
|
|
2432
|
+
}>>>;
|
|
2433
|
+
code: z.ZodOptional<z.ZodString | z.ZodEffects<z.ZodEffects<z.ZodString, string, string>, string, string>>;
|
|
2434
|
+
orderLimitPerUser: z.ZodOptional<z.ZodDefault<z.ZodNullable<z.ZodOptional<z.ZodNumber>>>>;
|
|
2435
|
+
isOrderLimitPerUserEnabled: z.ZodOptional<z.ZodDefault<z.ZodOptional<z.ZodBoolean>>>;
|
|
2436
|
+
createdBy: z.ZodOptional<z.ZodOptional<z.ZodUnion<[z.ZodEffects<z.ZodEffects<z.ZodString, string, string>, mongoose.Types.ObjectId, string>, z.ZodType<mongoose.Types.ObjectId, z.ZodTypeDef, mongoose.Types.ObjectId>]>>>;
|
|
2437
|
+
isExpired: z.ZodOptional<z.ZodOptional<z.ZodBoolean>>;
|
|
2438
|
+
_id: z.ZodOptional<z.ZodUnion<[z.ZodEffects<z.ZodEffects<z.ZodString, string, string>, mongoose.Types.ObjectId, string>, z.ZodType<mongoose.Types.ObjectId, z.ZodTypeDef, mongoose.Types.ObjectId>]>>;
|
|
2439
|
+
}, z.ZodTypeAny, "passthrough"> | {
|
|
2440
|
+
documents: (z.objectInputType<{
|
|
2441
|
+
couponType: z.ZodOptional<z.ZodLiteral<import("@lyxa.ai/core/dist/utilities/enum").CouponType.GLOBAL>>;
|
|
2442
|
+
valueType: z.ZodOptional<z.ZodNativeEnum<typeof import("@lyxa.ai/core/dist/utilities/enum").ValueType>>;
|
|
2443
|
+
value: z.ZodOptional<z.ZodNumber>;
|
|
2444
|
+
secondaryCurrencyValue: z.ZodOptional<z.ZodOptional<z.ZodNumber>>;
|
|
2445
|
+
maxDiscountLimit: z.ZodOptional<z.ZodDefault<z.ZodNullable<z.ZodOptional<z.ZodNumber>>>>;
|
|
2446
|
+
secondaryCurrencyMaxDiscountLimit: z.ZodOptional<z.ZodOptional<z.ZodNumber>>;
|
|
2447
|
+
isMaxDiscountLimitEnabled: z.ZodOptional<z.ZodDefault<z.ZodOptional<z.ZodBoolean>>>;
|
|
2448
|
+
duration: z.ZodOptional<z.ZodEffects<z.ZodObject<{
|
|
2449
|
+
start: z.ZodEffects<z.ZodEffects<z.ZodUnion<[z.ZodEffects<z.ZodEffects<z.ZodString, string, string>, Date, string>, z.ZodDate]>, Date, string | Date>, Date, string | Date>;
|
|
2450
|
+
end: z.ZodOptional<z.ZodEffects<z.ZodEffects<z.ZodUnion<[z.ZodEffects<z.ZodEffects<z.ZodString, string, string>, Date, string>, z.ZodDate]>, Date, string | Date>, Date, string | Date>>;
|
|
2451
|
+
}, "strip", z.ZodTypeAny, {
|
|
2452
|
+
start: Date;
|
|
2453
|
+
end?: Date | undefined;
|
|
2454
|
+
}, {
|
|
2455
|
+
start: string | Date;
|
|
2456
|
+
end?: string | Date | undefined;
|
|
2457
|
+
}>, {
|
|
2458
|
+
start: Date;
|
|
2459
|
+
end?: Date | undefined;
|
|
2460
|
+
}, {
|
|
2461
|
+
start: string | Date;
|
|
2462
|
+
end?: string | Date | undefined;
|
|
2463
|
+
}>>;
|
|
2464
|
+
spendLimit: z.ZodOptional<z.ZodDefault<z.ZodNullable<z.ZodOptional<z.ZodNumber>>>>;
|
|
2465
|
+
isSpendLimitEnabled: z.ZodOptional<z.ZodDefault<z.ZodOptional<z.ZodBoolean>>>;
|
|
2466
|
+
totalOrderLimit: z.ZodOptional<z.ZodDefault<z.ZodNullable<z.ZodOptional<z.ZodNumber>>>>;
|
|
2467
|
+
isTotalOrderLimitEnabled: z.ZodOptional<z.ZodDefault<z.ZodOptional<z.ZodBoolean>>>;
|
|
2468
|
+
minOrderValue: z.ZodOptional<z.ZodDefault<z.ZodNullable<z.ZodNumber>>>;
|
|
2469
|
+
secondaryCurrencyMinOrderValue: z.ZodOptional<z.ZodOptional<z.ZodNumber>>;
|
|
2470
|
+
isMinOrderValueEnabled: z.ZodOptional<z.ZodDefault<z.ZodOptional<z.ZodBoolean>>>;
|
|
2471
|
+
forNewUserOnly: z.ZodOptional<z.ZodDefault<z.ZodOptional<z.ZodBoolean>>>;
|
|
2472
|
+
status: z.ZodOptional<z.ZodDefault<z.ZodOptional<z.ZodNativeEnum<typeof import("@lyxa.ai/core/dist/utilities/enum").Status>>>>;
|
|
2473
|
+
expirationReason: z.ZodOptional<z.ZodDefault<z.ZodNullable<z.ZodOptional<z.ZodNativeEnum<typeof import("@lyxa.ai/core/dist/utilities/enum").CouponExpirationReason>>>>>;
|
|
2474
|
+
referringUser: z.ZodOptional<z.ZodOptional<z.ZodObject<{
|
|
2475
|
+
name: z.ZodOptional<z.ZodString> | z.ZodOptional<z.ZodEffects<z.ZodEffects<z.ZodString, string, string>, string, string>>;
|
|
2476
|
+
}, "strip", z.ZodTypeAny, {
|
|
2477
|
+
name?: string | undefined;
|
|
2478
|
+
}, {
|
|
2479
|
+
name?: string | undefined;
|
|
2480
|
+
}>>>;
|
|
2481
|
+
code: z.ZodOptional<z.ZodString | z.ZodEffects<z.ZodEffects<z.ZodString, string, string>, string, string>>;
|
|
2482
|
+
orderLimitPerUser: z.ZodOptional<z.ZodDefault<z.ZodNullable<z.ZodOptional<z.ZodNumber>>>>;
|
|
2483
|
+
isOrderLimitPerUserEnabled: z.ZodOptional<z.ZodDefault<z.ZodOptional<z.ZodBoolean>>>;
|
|
2484
|
+
createdBy: z.ZodOptional<z.ZodOptional<z.ZodUnion<[z.ZodEffects<z.ZodEffects<z.ZodString, string, string>, mongoose.Types.ObjectId, string>, z.ZodType<mongoose.Types.ObjectId, z.ZodTypeDef, mongoose.Types.ObjectId>]>>>;
|
|
2485
|
+
isExpired: z.ZodOptional<z.ZodOptional<z.ZodBoolean>>;
|
|
2486
|
+
_id: z.ZodOptional<z.ZodUnion<[z.ZodEffects<z.ZodEffects<z.ZodString, string, string>, mongoose.Types.ObjectId, string>, z.ZodType<mongoose.Types.ObjectId, z.ZodTypeDef, mongoose.Types.ObjectId>]>>;
|
|
2487
|
+
}, z.ZodTypeAny, "passthrough"> | z.objectInputType<{
|
|
2488
|
+
couponType: z.ZodOptional<z.ZodLiteral<import("@lyxa.ai/core/dist/utilities/enum").CouponType.REFERRAL_CODE>>;
|
|
2489
|
+
orderLimitPerUser: z.ZodOptional<z.ZodLiteral<1>>;
|
|
2490
|
+
referralUser: z.ZodOptional<z.ZodUnion<[z.ZodEffects<z.ZodEffects<z.ZodString, string, string>, mongoose.Types.ObjectId, string>, z.ZodType<mongoose.Types.ObjectId, z.ZodTypeDef, mongoose.Types.ObjectId>]>>;
|
|
2491
|
+
code: z.ZodOptional<z.ZodString | z.ZodEffects<z.ZodEffects<z.ZodString, string, string>, string, string>>;
|
|
2492
|
+
isOrderLimitPerUserEnabled: z.ZodOptional<z.ZodDefault<z.ZodOptional<z.ZodBoolean>>>;
|
|
2493
|
+
createdBy: z.ZodOptional<z.ZodOptional<z.ZodUnion<[z.ZodEffects<z.ZodEffects<z.ZodString, string, string>, mongoose.Types.ObjectId, string>, z.ZodType<mongoose.Types.ObjectId, z.ZodTypeDef, mongoose.Types.ObjectId>]>>>;
|
|
2494
|
+
isExpired: z.ZodOptional<z.ZodOptional<z.ZodBoolean>>;
|
|
2495
|
+
_id: z.ZodOptional<z.ZodUnion<[z.ZodEffects<z.ZodEffects<z.ZodString, string, string>, mongoose.Types.ObjectId, string>, z.ZodType<mongoose.Types.ObjectId, z.ZodTypeDef, mongoose.Types.ObjectId>]>>;
|
|
2496
|
+
}, z.ZodTypeAny, "passthrough"> | z.objectInputType<{
|
|
2497
|
+
couponType: z.ZodOptional<z.ZodLiteral<import("@lyxa.ai/core/dist/utilities/enum").CouponType.REFERRAL_REWARD>>;
|
|
2498
|
+
user: z.ZodOptional<z.ZodUnion<[z.ZodEffects<z.ZodEffects<z.ZodString, string, string>, mongoose.Types.ObjectId, string>, z.ZodType<mongoose.Types.ObjectId, z.ZodTypeDef, mongoose.Types.ObjectId>]>>;
|
|
2499
|
+
referralCodeUsedBy: z.ZodOptional<z.ZodUnion<[z.ZodEffects<z.ZodEffects<z.ZodString, string, string>, mongoose.Types.ObjectId, string>, z.ZodType<mongoose.Types.ObjectId, z.ZodTypeDef, mongoose.Types.ObjectId>]>>;
|
|
2500
|
+
referralCodeUsedOnOrder: z.ZodOptional<z.ZodUnion<[z.ZodEffects<z.ZodEffects<z.ZodString, string, string>, mongoose.Types.ObjectId, string>, z.ZodType<mongoose.Types.ObjectId, z.ZodTypeDef, mongoose.Types.ObjectId>]>>;
|
|
2501
|
+
valueType: z.ZodOptional<z.ZodNativeEnum<typeof import("@lyxa.ai/core/dist/utilities/enum").ValueType>>;
|
|
2502
|
+
value: z.ZodOptional<z.ZodNumber>;
|
|
2503
|
+
secondaryCurrencyValue: z.ZodOptional<z.ZodOptional<z.ZodNumber>>;
|
|
2504
|
+
maxDiscountLimit: z.ZodOptional<z.ZodDefault<z.ZodNullable<z.ZodOptional<z.ZodNumber>>>>;
|
|
2505
|
+
secondaryCurrencyMaxDiscountLimit: z.ZodOptional<z.ZodOptional<z.ZodNumber>>;
|
|
2506
|
+
isMaxDiscountLimitEnabled: z.ZodOptional<z.ZodDefault<z.ZodOptional<z.ZodBoolean>>>;
|
|
2507
|
+
duration: z.ZodOptional<z.ZodEffects<z.ZodObject<{
|
|
2508
|
+
start: z.ZodEffects<z.ZodEffects<z.ZodUnion<[z.ZodEffects<z.ZodEffects<z.ZodString, string, string>, Date, string>, z.ZodDate]>, Date, string | Date>, Date, string | Date>;
|
|
2509
|
+
end: z.ZodOptional<z.ZodEffects<z.ZodEffects<z.ZodUnion<[z.ZodEffects<z.ZodEffects<z.ZodString, string, string>, Date, string>, z.ZodDate]>, Date, string | Date>, Date, string | Date>>;
|
|
2510
|
+
}, "strip", z.ZodTypeAny, {
|
|
2511
|
+
start: Date;
|
|
2512
|
+
end?: Date | undefined;
|
|
2513
|
+
}, {
|
|
2514
|
+
start: string | Date;
|
|
2515
|
+
end?: string | Date | undefined;
|
|
2516
|
+
}>, {
|
|
2517
|
+
start: Date;
|
|
2518
|
+
end?: Date | undefined;
|
|
2519
|
+
}, {
|
|
2520
|
+
start: string | Date;
|
|
2521
|
+
end?: string | Date | undefined;
|
|
2522
|
+
}>>;
|
|
2523
|
+
spendLimit: z.ZodOptional<z.ZodDefault<z.ZodNullable<z.ZodOptional<z.ZodNumber>>>>;
|
|
2524
|
+
isSpendLimitEnabled: z.ZodOptional<z.ZodDefault<z.ZodOptional<z.ZodBoolean>>>;
|
|
2525
|
+
totalOrderLimit: z.ZodOptional<z.ZodDefault<z.ZodNullable<z.ZodOptional<z.ZodNumber>>>>;
|
|
2526
|
+
isTotalOrderLimitEnabled: z.ZodOptional<z.ZodDefault<z.ZodOptional<z.ZodBoolean>>>;
|
|
2527
|
+
minOrderValue: z.ZodOptional<z.ZodDefault<z.ZodNullable<z.ZodNumber>>>;
|
|
2528
|
+
secondaryCurrencyMinOrderValue: z.ZodOptional<z.ZodOptional<z.ZodNumber>>;
|
|
2529
|
+
isMinOrderValueEnabled: z.ZodOptional<z.ZodDefault<z.ZodOptional<z.ZodBoolean>>>;
|
|
2530
|
+
forNewUserOnly: z.ZodOptional<z.ZodDefault<z.ZodOptional<z.ZodBoolean>>>;
|
|
2531
|
+
status: z.ZodOptional<z.ZodDefault<z.ZodOptional<z.ZodNativeEnum<typeof import("@lyxa.ai/core/dist/utilities/enum").Status>>>>;
|
|
2532
|
+
expirationReason: z.ZodOptional<z.ZodDefault<z.ZodNullable<z.ZodOptional<z.ZodNativeEnum<typeof import("@lyxa.ai/core/dist/utilities/enum").CouponExpirationReason>>>>>;
|
|
2533
|
+
referringUser: z.ZodOptional<z.ZodOptional<z.ZodObject<{
|
|
2534
|
+
name: z.ZodOptional<z.ZodString> | z.ZodOptional<z.ZodEffects<z.ZodEffects<z.ZodString, string, string>, string, string>>;
|
|
2535
|
+
}, "strip", z.ZodTypeAny, {
|
|
2536
|
+
name?: string | undefined;
|
|
2537
|
+
}, {
|
|
2538
|
+
name?: string | undefined;
|
|
2539
|
+
}>>>;
|
|
2540
|
+
code: z.ZodOptional<z.ZodString | z.ZodEffects<z.ZodEffects<z.ZodString, string, string>, string, string>>;
|
|
2541
|
+
orderLimitPerUser: z.ZodOptional<z.ZodDefault<z.ZodNullable<z.ZodOptional<z.ZodNumber>>>>;
|
|
2542
|
+
isOrderLimitPerUserEnabled: z.ZodOptional<z.ZodDefault<z.ZodOptional<z.ZodBoolean>>>;
|
|
2543
|
+
createdBy: z.ZodOptional<z.ZodOptional<z.ZodUnion<[z.ZodEffects<z.ZodEffects<z.ZodString, string, string>, mongoose.Types.ObjectId, string>, z.ZodType<mongoose.Types.ObjectId, z.ZodTypeDef, mongoose.Types.ObjectId>]>>>;
|
|
2544
|
+
isExpired: z.ZodOptional<z.ZodOptional<z.ZodBoolean>>;
|
|
2545
|
+
_id: z.ZodOptional<z.ZodUnion<[z.ZodEffects<z.ZodEffects<z.ZodString, string, string>, mongoose.Types.ObjectId, string>, z.ZodType<mongoose.Types.ObjectId, z.ZodTypeDef, mongoose.Types.ObjectId>]>>;
|
|
2546
|
+
}, z.ZodTypeAny, "passthrough"> | z.objectInputType<{
|
|
2547
|
+
couponType: z.ZodOptional<z.ZodLiteral<import("@lyxa.ai/core/dist/utilities/enum").CouponType.SHOPS_CATEGORIES>>;
|
|
2548
|
+
itemTypes: z.ZodOptional<z.ZodDefault<z.ZodArray<z.ZodNativeEnum<typeof import("@lyxa.ai/core/dist/utilities/enum").ItemType>, "many">>>;
|
|
2549
|
+
shops: z.ZodOptional<z.ZodDefault<z.ZodArray<z.ZodUnion<[z.ZodEffects<z.ZodEffects<z.ZodString, string, string>, mongoose.Types.ObjectId, string>, z.ZodType<mongoose.Types.ObjectId, z.ZodTypeDef, mongoose.Types.ObjectId>]>, "many">>>;
|
|
2550
|
+
isShopCoverExpenses: z.ZodOptional<z.ZodDefault<z.ZodBoolean>>;
|
|
2551
|
+
firstOrderOnly: z.ZodOptional<z.ZodDefault<z.ZodBoolean>>;
|
|
2552
|
+
valueType: z.ZodOptional<z.ZodNativeEnum<typeof import("@lyxa.ai/core/dist/utilities/enum").ValueType>>;
|
|
2553
|
+
value: z.ZodOptional<z.ZodNumber>;
|
|
2554
|
+
secondaryCurrencyValue: z.ZodOptional<z.ZodOptional<z.ZodNumber>>;
|
|
2555
|
+
maxDiscountLimit: z.ZodOptional<z.ZodDefault<z.ZodNullable<z.ZodOptional<z.ZodNumber>>>>;
|
|
2556
|
+
secondaryCurrencyMaxDiscountLimit: z.ZodOptional<z.ZodOptional<z.ZodNumber>>;
|
|
2557
|
+
isMaxDiscountLimitEnabled: z.ZodOptional<z.ZodDefault<z.ZodOptional<z.ZodBoolean>>>;
|
|
2558
|
+
duration: z.ZodOptional<z.ZodEffects<z.ZodObject<{
|
|
2559
|
+
start: z.ZodEffects<z.ZodEffects<z.ZodUnion<[z.ZodEffects<z.ZodEffects<z.ZodString, string, string>, Date, string>, z.ZodDate]>, Date, string | Date>, Date, string | Date>;
|
|
2560
|
+
end: z.ZodOptional<z.ZodEffects<z.ZodEffects<z.ZodUnion<[z.ZodEffects<z.ZodEffects<z.ZodString, string, string>, Date, string>, z.ZodDate]>, Date, string | Date>, Date, string | Date>>;
|
|
2561
|
+
}, "strip", z.ZodTypeAny, {
|
|
2562
|
+
start: Date;
|
|
2563
|
+
end?: Date | undefined;
|
|
2564
|
+
}, {
|
|
2565
|
+
start: string | Date;
|
|
2566
|
+
end?: string | Date | undefined;
|
|
2567
|
+
}>, {
|
|
2568
|
+
start: Date;
|
|
2569
|
+
end?: Date | undefined;
|
|
2570
|
+
}, {
|
|
2571
|
+
start: string | Date;
|
|
2572
|
+
end?: string | Date | undefined;
|
|
2573
|
+
}>>;
|
|
2574
|
+
spendLimit: z.ZodOptional<z.ZodDefault<z.ZodNullable<z.ZodOptional<z.ZodNumber>>>>;
|
|
2575
|
+
isSpendLimitEnabled: z.ZodOptional<z.ZodDefault<z.ZodOptional<z.ZodBoolean>>>;
|
|
2576
|
+
totalOrderLimit: z.ZodOptional<z.ZodDefault<z.ZodNullable<z.ZodOptional<z.ZodNumber>>>>;
|
|
2577
|
+
isTotalOrderLimitEnabled: z.ZodOptional<z.ZodDefault<z.ZodOptional<z.ZodBoolean>>>;
|
|
2578
|
+
minOrderValue: z.ZodOptional<z.ZodDefault<z.ZodNullable<z.ZodNumber>>>;
|
|
2579
|
+
secondaryCurrencyMinOrderValue: z.ZodOptional<z.ZodOptional<z.ZodNumber>>;
|
|
2580
|
+
isMinOrderValueEnabled: z.ZodOptional<z.ZodDefault<z.ZodOptional<z.ZodBoolean>>>;
|
|
2581
|
+
forNewUserOnly: z.ZodOptional<z.ZodDefault<z.ZodOptional<z.ZodBoolean>>>;
|
|
2582
|
+
status: z.ZodOptional<z.ZodDefault<z.ZodOptional<z.ZodNativeEnum<typeof import("@lyxa.ai/core/dist/utilities/enum").Status>>>>;
|
|
2583
|
+
expirationReason: z.ZodOptional<z.ZodDefault<z.ZodNullable<z.ZodOptional<z.ZodNativeEnum<typeof import("@lyxa.ai/core/dist/utilities/enum").CouponExpirationReason>>>>>;
|
|
2584
|
+
referringUser: z.ZodOptional<z.ZodOptional<z.ZodObject<{
|
|
2585
|
+
name: z.ZodOptional<z.ZodString> | z.ZodOptional<z.ZodEffects<z.ZodEffects<z.ZodString, string, string>, string, string>>;
|
|
2586
|
+
}, "strip", z.ZodTypeAny, {
|
|
2587
|
+
name?: string | undefined;
|
|
2588
|
+
}, {
|
|
2589
|
+
name?: string | undefined;
|
|
2590
|
+
}>>>;
|
|
2591
|
+
code: z.ZodOptional<z.ZodString | z.ZodEffects<z.ZodEffects<z.ZodString, string, string>, string, string>>;
|
|
2592
|
+
orderLimitPerUser: z.ZodOptional<z.ZodDefault<z.ZodNullable<z.ZodOptional<z.ZodNumber>>>>;
|
|
2593
|
+
isOrderLimitPerUserEnabled: z.ZodOptional<z.ZodDefault<z.ZodOptional<z.ZodBoolean>>>;
|
|
2594
|
+
createdBy: z.ZodOptional<z.ZodOptional<z.ZodUnion<[z.ZodEffects<z.ZodEffects<z.ZodString, string, string>, mongoose.Types.ObjectId, string>, z.ZodType<mongoose.Types.ObjectId, z.ZodTypeDef, mongoose.Types.ObjectId>]>>>;
|
|
2595
|
+
isExpired: z.ZodOptional<z.ZodOptional<z.ZodBoolean>>;
|
|
2596
|
+
_id: z.ZodOptional<z.ZodUnion<[z.ZodEffects<z.ZodEffects<z.ZodString, string, string>, mongoose.Types.ObjectId, string>, z.ZodType<mongoose.Types.ObjectId, z.ZodTypeDef, mongoose.Types.ObjectId>]>>;
|
|
2597
|
+
}, z.ZodTypeAny, "passthrough"> | z.objectInputType<{
|
|
2598
|
+
couponType: z.ZodOptional<z.ZodLiteral<import("@lyxa.ai/core/dist/utilities/enum").CouponType.INDIVIDUAL_STORE>>;
|
|
2599
|
+
shop: z.ZodOptional<z.ZodUnion<[z.ZodEffects<z.ZodEffects<z.ZodString, string, string>, mongoose.Types.ObjectId, string>, z.ZodType<mongoose.Types.ObjectId, z.ZodTypeDef, mongoose.Types.ObjectId>]>>;
|
|
2600
|
+
isShopCoverExpenses: z.ZodOptional<z.ZodDefault<z.ZodBoolean>>;
|
|
2601
|
+
firstOrderOnly: z.ZodOptional<z.ZodDefault<z.ZodBoolean>>;
|
|
2602
|
+
valueType: z.ZodOptional<z.ZodNativeEnum<typeof import("@lyxa.ai/core/dist/utilities/enum").ValueType>>;
|
|
2603
|
+
value: z.ZodOptional<z.ZodNumber>;
|
|
2604
|
+
secondaryCurrencyValue: z.ZodOptional<z.ZodOptional<z.ZodNumber>>;
|
|
2605
|
+
maxDiscountLimit: z.ZodOptional<z.ZodDefault<z.ZodNullable<z.ZodOptional<z.ZodNumber>>>>;
|
|
2606
|
+
secondaryCurrencyMaxDiscountLimit: z.ZodOptional<z.ZodOptional<z.ZodNumber>>;
|
|
2607
|
+
isMaxDiscountLimitEnabled: z.ZodOptional<z.ZodDefault<z.ZodOptional<z.ZodBoolean>>>;
|
|
2608
|
+
duration: z.ZodOptional<z.ZodEffects<z.ZodObject<{
|
|
2609
|
+
start: z.ZodEffects<z.ZodEffects<z.ZodUnion<[z.ZodEffects<z.ZodEffects<z.ZodString, string, string>, Date, string>, z.ZodDate]>, Date, string | Date>, Date, string | Date>;
|
|
2610
|
+
end: z.ZodOptional<z.ZodEffects<z.ZodEffects<z.ZodUnion<[z.ZodEffects<z.ZodEffects<z.ZodString, string, string>, Date, string>, z.ZodDate]>, Date, string | Date>, Date, string | Date>>;
|
|
2611
|
+
}, "strip", z.ZodTypeAny, {
|
|
2612
|
+
start: Date;
|
|
2613
|
+
end?: Date | undefined;
|
|
2614
|
+
}, {
|
|
2615
|
+
start: string | Date;
|
|
2616
|
+
end?: string | Date | undefined;
|
|
2617
|
+
}>, {
|
|
2618
|
+
start: Date;
|
|
2619
|
+
end?: Date | undefined;
|
|
2620
|
+
}, {
|
|
2621
|
+
start: string | Date;
|
|
2622
|
+
end?: string | Date | undefined;
|
|
2623
|
+
}>>;
|
|
2624
|
+
spendLimit: z.ZodOptional<z.ZodDefault<z.ZodNullable<z.ZodOptional<z.ZodNumber>>>>;
|
|
2625
|
+
isSpendLimitEnabled: z.ZodOptional<z.ZodDefault<z.ZodOptional<z.ZodBoolean>>>;
|
|
2626
|
+
totalOrderLimit: z.ZodOptional<z.ZodDefault<z.ZodNullable<z.ZodOptional<z.ZodNumber>>>>;
|
|
2627
|
+
isTotalOrderLimitEnabled: z.ZodOptional<z.ZodDefault<z.ZodOptional<z.ZodBoolean>>>;
|
|
2628
|
+
minOrderValue: z.ZodOptional<z.ZodDefault<z.ZodNullable<z.ZodNumber>>>;
|
|
2629
|
+
secondaryCurrencyMinOrderValue: z.ZodOptional<z.ZodOptional<z.ZodNumber>>;
|
|
2630
|
+
isMinOrderValueEnabled: z.ZodOptional<z.ZodDefault<z.ZodOptional<z.ZodBoolean>>>;
|
|
2631
|
+
forNewUserOnly: z.ZodOptional<z.ZodDefault<z.ZodOptional<z.ZodBoolean>>>;
|
|
2632
|
+
status: z.ZodOptional<z.ZodDefault<z.ZodOptional<z.ZodNativeEnum<typeof import("@lyxa.ai/core/dist/utilities/enum").Status>>>>;
|
|
2633
|
+
expirationReason: z.ZodOptional<z.ZodDefault<z.ZodNullable<z.ZodOptional<z.ZodNativeEnum<typeof import("@lyxa.ai/core/dist/utilities/enum").CouponExpirationReason>>>>>;
|
|
2634
|
+
referringUser: z.ZodOptional<z.ZodOptional<z.ZodObject<{
|
|
2635
|
+
name: z.ZodOptional<z.ZodString> | z.ZodOptional<z.ZodEffects<z.ZodEffects<z.ZodString, string, string>, string, string>>;
|
|
2636
|
+
}, "strip", z.ZodTypeAny, {
|
|
2637
|
+
name?: string | undefined;
|
|
2638
|
+
}, {
|
|
2639
|
+
name?: string | undefined;
|
|
2640
|
+
}>>>;
|
|
2641
|
+
code: z.ZodOptional<z.ZodString | z.ZodEffects<z.ZodEffects<z.ZodString, string, string>, string, string>>;
|
|
2642
|
+
orderLimitPerUser: z.ZodOptional<z.ZodDefault<z.ZodNullable<z.ZodOptional<z.ZodNumber>>>>;
|
|
2643
|
+
isOrderLimitPerUserEnabled: z.ZodOptional<z.ZodDefault<z.ZodOptional<z.ZodBoolean>>>;
|
|
2644
|
+
createdBy: z.ZodOptional<z.ZodOptional<z.ZodUnion<[z.ZodEffects<z.ZodEffects<z.ZodString, string, string>, mongoose.Types.ObjectId, string>, z.ZodType<mongoose.Types.ObjectId, z.ZodTypeDef, mongoose.Types.ObjectId>]>>>;
|
|
2645
|
+
isExpired: z.ZodOptional<z.ZodOptional<z.ZodBoolean>>;
|
|
2646
|
+
_id: z.ZodOptional<z.ZodUnion<[z.ZodEffects<z.ZodEffects<z.ZodString, string, string>, mongoose.Types.ObjectId, string>, z.ZodType<mongoose.Types.ObjectId, z.ZodTypeDef, mongoose.Types.ObjectId>]>>;
|
|
2647
|
+
}, z.ZodTypeAny, "passthrough"> | z.objectInputType<{
|
|
2648
|
+
couponType: z.ZodOptional<z.ZodLiteral<import("@lyxa.ai/core/dist/utilities/enum").CouponType.INDIVIDUAL_USER>>;
|
|
2649
|
+
users: z.ZodOptional<z.ZodArray<z.ZodUnion<[z.ZodEffects<z.ZodEffects<z.ZodString, string, string>, mongoose.Types.ObjectId, string>, z.ZodType<mongoose.Types.ObjectId, z.ZodTypeDef, mongoose.Types.ObjectId>]>, "atleastone">>;
|
|
2650
|
+
itemTypes: z.ZodOptional<z.ZodDefault<z.ZodArray<z.ZodNativeEnum<typeof import("@lyxa.ai/core/dist/utilities/enum").ItemType>, "many">>>;
|
|
2651
|
+
shops: z.ZodOptional<z.ZodDefault<z.ZodArray<z.ZodUnion<[z.ZodEffects<z.ZodEffects<z.ZodString, string, string>, mongoose.Types.ObjectId, string>, z.ZodType<mongoose.Types.ObjectId, z.ZodTypeDef, mongoose.Types.ObjectId>]>, "many">>>;
|
|
2652
|
+
valueType: z.ZodOptional<z.ZodNativeEnum<typeof import("@lyxa.ai/core/dist/utilities/enum").ValueType>>;
|
|
2653
|
+
value: z.ZodOptional<z.ZodNumber>;
|
|
2654
|
+
secondaryCurrencyValue: z.ZodOptional<z.ZodOptional<z.ZodNumber>>;
|
|
2655
|
+
maxDiscountLimit: z.ZodOptional<z.ZodDefault<z.ZodNullable<z.ZodOptional<z.ZodNumber>>>>;
|
|
2656
|
+
secondaryCurrencyMaxDiscountLimit: z.ZodOptional<z.ZodOptional<z.ZodNumber>>;
|
|
2657
|
+
isMaxDiscountLimitEnabled: z.ZodOptional<z.ZodDefault<z.ZodOptional<z.ZodBoolean>>>;
|
|
2658
|
+
duration: z.ZodOptional<z.ZodEffects<z.ZodObject<{
|
|
2659
|
+
start: z.ZodEffects<z.ZodEffects<z.ZodUnion<[z.ZodEffects<z.ZodEffects<z.ZodString, string, string>, Date, string>, z.ZodDate]>, Date, string | Date>, Date, string | Date>;
|
|
2660
|
+
end: z.ZodOptional<z.ZodEffects<z.ZodEffects<z.ZodUnion<[z.ZodEffects<z.ZodEffects<z.ZodString, string, string>, Date, string>, z.ZodDate]>, Date, string | Date>, Date, string | Date>>;
|
|
2661
|
+
}, "strip", z.ZodTypeAny, {
|
|
2662
|
+
start: Date;
|
|
2663
|
+
end?: Date | undefined;
|
|
2664
|
+
}, {
|
|
2665
|
+
start: string | Date;
|
|
2666
|
+
end?: string | Date | undefined;
|
|
2667
|
+
}>, {
|
|
2668
|
+
start: Date;
|
|
2669
|
+
end?: Date | undefined;
|
|
2670
|
+
}, {
|
|
2671
|
+
start: string | Date;
|
|
2672
|
+
end?: string | Date | undefined;
|
|
2673
|
+
}>>;
|
|
2674
|
+
spendLimit: z.ZodOptional<z.ZodDefault<z.ZodNullable<z.ZodOptional<z.ZodNumber>>>>;
|
|
2675
|
+
isSpendLimitEnabled: z.ZodOptional<z.ZodDefault<z.ZodOptional<z.ZodBoolean>>>;
|
|
2676
|
+
totalOrderLimit: z.ZodOptional<z.ZodDefault<z.ZodNullable<z.ZodOptional<z.ZodNumber>>>>;
|
|
2677
|
+
isTotalOrderLimitEnabled: z.ZodOptional<z.ZodDefault<z.ZodOptional<z.ZodBoolean>>>;
|
|
2678
|
+
minOrderValue: z.ZodOptional<z.ZodDefault<z.ZodNullable<z.ZodNumber>>>;
|
|
2679
|
+
secondaryCurrencyMinOrderValue: z.ZodOptional<z.ZodOptional<z.ZodNumber>>;
|
|
2680
|
+
isMinOrderValueEnabled: z.ZodOptional<z.ZodDefault<z.ZodOptional<z.ZodBoolean>>>;
|
|
2681
|
+
forNewUserOnly: z.ZodOptional<z.ZodDefault<z.ZodOptional<z.ZodBoolean>>>;
|
|
2682
|
+
status: z.ZodOptional<z.ZodDefault<z.ZodOptional<z.ZodNativeEnum<typeof import("@lyxa.ai/core/dist/utilities/enum").Status>>>>;
|
|
2683
|
+
expirationReason: z.ZodOptional<z.ZodDefault<z.ZodNullable<z.ZodOptional<z.ZodNativeEnum<typeof import("@lyxa.ai/core/dist/utilities/enum").CouponExpirationReason>>>>>;
|
|
2684
|
+
referringUser: z.ZodOptional<z.ZodOptional<z.ZodObject<{
|
|
2685
|
+
name: z.ZodOptional<z.ZodString> | z.ZodOptional<z.ZodEffects<z.ZodEffects<z.ZodString, string, string>, string, string>>;
|
|
2686
|
+
}, "strip", z.ZodTypeAny, {
|
|
2687
|
+
name?: string | undefined;
|
|
2688
|
+
}, {
|
|
2689
|
+
name?: string | undefined;
|
|
2690
|
+
}>>>;
|
|
2691
|
+
code: z.ZodOptional<z.ZodString | z.ZodEffects<z.ZodEffects<z.ZodString, string, string>, string, string>>;
|
|
2692
|
+
orderLimitPerUser: z.ZodOptional<z.ZodDefault<z.ZodNullable<z.ZodOptional<z.ZodNumber>>>>;
|
|
2693
|
+
isOrderLimitPerUserEnabled: z.ZodOptional<z.ZodDefault<z.ZodOptional<z.ZodBoolean>>>;
|
|
2694
|
+
createdBy: z.ZodOptional<z.ZodOptional<z.ZodUnion<[z.ZodEffects<z.ZodEffects<z.ZodString, string, string>, mongoose.Types.ObjectId, string>, z.ZodType<mongoose.Types.ObjectId, z.ZodTypeDef, mongoose.Types.ObjectId>]>>>;
|
|
2695
|
+
isExpired: z.ZodOptional<z.ZodOptional<z.ZodBoolean>>;
|
|
2696
|
+
_id: z.ZodOptional<z.ZodUnion<[z.ZodEffects<z.ZodEffects<z.ZodString, string, string>, mongoose.Types.ObjectId, string>, z.ZodType<mongoose.Types.ObjectId, z.ZodTypeDef, mongoose.Types.ObjectId>]>>;
|
|
2697
|
+
}, z.ZodTypeAny, "passthrough"> | z.objectInputType<{
|
|
2698
|
+
couponType: z.ZodOptional<z.ZodLiteral<import("@lyxa.ai/core/dist/utilities/enum").CouponType.CUSTOM_COUPON>>;
|
|
2699
|
+
influencer: z.ZodOptional<z.ZodUnion<[z.ZodEffects<z.ZodEffects<z.ZodString, string, string>, mongoose.Types.ObjectId, string>, z.ZodType<mongoose.Types.ObjectId, z.ZodTypeDef, mongoose.Types.ObjectId>]>>;
|
|
2700
|
+
itemTypes: z.ZodOptional<z.ZodDefault<z.ZodArray<z.ZodNativeEnum<typeof import("@lyxa.ai/core/dist/utilities/enum").ItemType>, "many">>>;
|
|
2701
|
+
shops: z.ZodOptional<z.ZodDefault<z.ZodArray<z.ZodUnion<[z.ZodEffects<z.ZodEffects<z.ZodString, string, string>, mongoose.Types.ObjectId, string>, z.ZodType<mongoose.Types.ObjectId, z.ZodTypeDef, mongoose.Types.ObjectId>]>, "many">>>;
|
|
2702
|
+
valueType: z.ZodOptional<z.ZodNativeEnum<typeof import("@lyxa.ai/core/dist/utilities/enum").ValueType>>;
|
|
2703
|
+
value: z.ZodOptional<z.ZodNumber>;
|
|
2704
|
+
secondaryCurrencyValue: z.ZodOptional<z.ZodOptional<z.ZodNumber>>;
|
|
2705
|
+
maxDiscountLimit: z.ZodOptional<z.ZodDefault<z.ZodNullable<z.ZodOptional<z.ZodNumber>>>>;
|
|
2706
|
+
secondaryCurrencyMaxDiscountLimit: z.ZodOptional<z.ZodOptional<z.ZodNumber>>;
|
|
2707
|
+
isMaxDiscountLimitEnabled: z.ZodOptional<z.ZodDefault<z.ZodOptional<z.ZodBoolean>>>;
|
|
2708
|
+
duration: z.ZodOptional<z.ZodEffects<z.ZodObject<{
|
|
2709
|
+
start: z.ZodEffects<z.ZodEffects<z.ZodUnion<[z.ZodEffects<z.ZodEffects<z.ZodString, string, string>, Date, string>, z.ZodDate]>, Date, string | Date>, Date, string | Date>;
|
|
2710
|
+
end: z.ZodOptional<z.ZodEffects<z.ZodEffects<z.ZodUnion<[z.ZodEffects<z.ZodEffects<z.ZodString, string, string>, Date, string>, z.ZodDate]>, Date, string | Date>, Date, string | Date>>;
|
|
2711
|
+
}, "strip", z.ZodTypeAny, {
|
|
2712
|
+
start: Date;
|
|
2713
|
+
end?: Date | undefined;
|
|
2714
|
+
}, {
|
|
2715
|
+
start: string | Date;
|
|
2716
|
+
end?: string | Date | undefined;
|
|
2717
|
+
}>, {
|
|
2718
|
+
start: Date;
|
|
2719
|
+
end?: Date | undefined;
|
|
2720
|
+
}, {
|
|
2721
|
+
start: string | Date;
|
|
2722
|
+
end?: string | Date | undefined;
|
|
2723
|
+
}>>;
|
|
2724
|
+
spendLimit: z.ZodOptional<z.ZodDefault<z.ZodNullable<z.ZodOptional<z.ZodNumber>>>>;
|
|
2725
|
+
isSpendLimitEnabled: z.ZodOptional<z.ZodDefault<z.ZodOptional<z.ZodBoolean>>>;
|
|
2726
|
+
totalOrderLimit: z.ZodOptional<z.ZodDefault<z.ZodNullable<z.ZodOptional<z.ZodNumber>>>>;
|
|
2727
|
+
isTotalOrderLimitEnabled: z.ZodOptional<z.ZodDefault<z.ZodOptional<z.ZodBoolean>>>;
|
|
2728
|
+
minOrderValue: z.ZodOptional<z.ZodDefault<z.ZodNullable<z.ZodNumber>>>;
|
|
2729
|
+
secondaryCurrencyMinOrderValue: z.ZodOptional<z.ZodOptional<z.ZodNumber>>;
|
|
2730
|
+
isMinOrderValueEnabled: z.ZodOptional<z.ZodDefault<z.ZodOptional<z.ZodBoolean>>>;
|
|
2731
|
+
forNewUserOnly: z.ZodOptional<z.ZodDefault<z.ZodOptional<z.ZodBoolean>>>;
|
|
2732
|
+
status: z.ZodOptional<z.ZodDefault<z.ZodOptional<z.ZodNativeEnum<typeof import("@lyxa.ai/core/dist/utilities/enum").Status>>>>;
|
|
2733
|
+
expirationReason: z.ZodOptional<z.ZodDefault<z.ZodNullable<z.ZodOptional<z.ZodNativeEnum<typeof import("@lyxa.ai/core/dist/utilities/enum").CouponExpirationReason>>>>>;
|
|
2734
|
+
referringUser: z.ZodOptional<z.ZodOptional<z.ZodObject<{
|
|
2735
|
+
name: z.ZodOptional<z.ZodString> | z.ZodOptional<z.ZodEffects<z.ZodEffects<z.ZodString, string, string>, string, string>>;
|
|
2736
|
+
}, "strip", z.ZodTypeAny, {
|
|
2737
|
+
name?: string | undefined;
|
|
2738
|
+
}, {
|
|
2739
|
+
name?: string | undefined;
|
|
2740
|
+
}>>>;
|
|
2741
|
+
code: z.ZodOptional<z.ZodString | z.ZodEffects<z.ZodEffects<z.ZodString, string, string>, string, string>>;
|
|
2742
|
+
orderLimitPerUser: z.ZodOptional<z.ZodDefault<z.ZodNullable<z.ZodOptional<z.ZodNumber>>>>;
|
|
2743
|
+
isOrderLimitPerUserEnabled: z.ZodOptional<z.ZodDefault<z.ZodOptional<z.ZodBoolean>>>;
|
|
2744
|
+
createdBy: z.ZodOptional<z.ZodOptional<z.ZodUnion<[z.ZodEffects<z.ZodEffects<z.ZodString, string, string>, mongoose.Types.ObjectId, string>, z.ZodType<mongoose.Types.ObjectId, z.ZodTypeDef, mongoose.Types.ObjectId>]>>>;
|
|
2745
|
+
isExpired: z.ZodOptional<z.ZodOptional<z.ZodBoolean>>;
|
|
2746
|
+
_id: z.ZodOptional<z.ZodUnion<[z.ZodEffects<z.ZodEffects<z.ZodString, string, string>, mongoose.Types.ObjectId, string>, z.ZodType<mongoose.Types.ObjectId, z.ZodTypeDef, mongoose.Types.ObjectId>]>>;
|
|
2747
|
+
}, z.ZodTypeAny, "passthrough">)[];
|
|
2748
|
+
metadata?: {
|
|
2749
|
+
page: number;
|
|
2750
|
+
size: number;
|
|
2751
|
+
totalElements: number;
|
|
2752
|
+
totalPages: number;
|
|
2753
|
+
} | undefined;
|
|
2754
|
+
} | undefined;
|
|
2755
|
+
};
|
|
2756
|
+
meta: object;
|
|
2757
|
+
}>;
|
|
2127
2758
|
update: import("@trpc/server").TRPCMutationProcedure<{
|
|
2128
2759
|
input: {
|
|
2129
2760
|
_id: string | mongoose.Types.ObjectId;
|
|
@@ -4579,6 +5210,7 @@ export declare const couponRouter: import("@trpc/server").TRPCBuiltRouter<{
|
|
|
4579
5210
|
message: string;
|
|
4580
5211
|
success: boolean;
|
|
4581
5212
|
data?: {
|
|
5213
|
+
message?: string | undefined;
|
|
4582
5214
|
isValid?: boolean | undefined;
|
|
4583
5215
|
amountAfterCoupon?: number | undefined;
|
|
4584
5216
|
secondaryAmountAfterCoupon?: number | undefined;
|
|
@@ -4592,6 +5224,7 @@ export declare const couponRouter: import("@trpc/server").TRPCBuiltRouter<{
|
|
|
4592
5224
|
} | undefined;
|
|
4593
5225
|
} | {
|
|
4594
5226
|
documents: {
|
|
5227
|
+
message?: string | undefined;
|
|
4595
5228
|
isValid?: boolean | undefined;
|
|
4596
5229
|
amountAfterCoupon?: number | undefined;
|
|
4597
5230
|
secondaryAmountAfterCoupon?: number | undefined;
|
|
@@ -4626,6 +5259,7 @@ export declare const couponRouter: import("@trpc/server").TRPCBuiltRouter<{
|
|
|
4626
5259
|
message: string;
|
|
4627
5260
|
success: boolean;
|
|
4628
5261
|
data?: {
|
|
5262
|
+
message?: string | undefined;
|
|
4629
5263
|
isValid?: boolean | undefined;
|
|
4630
5264
|
amountAfterCoupon?: number | undefined;
|
|
4631
5265
|
secondaryAmountAfterCoupon?: number | undefined;
|
|
@@ -4639,6 +5273,7 @@ export declare const couponRouter: import("@trpc/server").TRPCBuiltRouter<{
|
|
|
4639
5273
|
} | undefined;
|
|
4640
5274
|
} | {
|
|
4641
5275
|
documents: {
|
|
5276
|
+
message?: string | undefined;
|
|
4642
5277
|
isValid?: boolean | undefined;
|
|
4643
5278
|
amountAfterCoupon?: number | undefined;
|
|
4644
5279
|
secondaryAmountAfterCoupon?: number | undefined;
|
|
@@ -4723,5 +5358,12 @@ export declare const couponRouter: import("@trpc/server").TRPCBuiltRouter<{
|
|
|
4723
5358
|
output: void;
|
|
4724
5359
|
meta: object;
|
|
4725
5360
|
}>;
|
|
5361
|
+
giveReferralRewardToReferrer: import("@trpc/server").TRPCMutationProcedure<{
|
|
5362
|
+
input: {
|
|
5363
|
+
orderId: string;
|
|
5364
|
+
};
|
|
5365
|
+
output: void;
|
|
5366
|
+
meta: object;
|
|
5367
|
+
}>;
|
|
4726
5368
|
}>>;
|
|
4727
5369
|
//# sourceMappingURL=coupon.router.d.ts.map
|