import{Schema as e}from"mongoose";const t=new e({type:{type:String,required:!0,enum:[`PREMIUM`,`ENTERPRISE`]},period:{type:String,required:!0,enum:[`MONTHLY`,`YEARLY`],default:`MONTHLY`},creatorId:{type:e.Types.ObjectId,ref:`User`,required:!0},subscriptionId:{type:String,required:!0},customerId:{type:String,required:!0},priceId:{type:String,required:!0},status:{type:String,required:!0,enum:[`active`,`canceled`,`past_due`,`unpaid`,`incomplete`,`incomplete_expired`,`paused`,`trialing`]}},{timestamps:!0,toJSON:{virtuals:!0,versionKey:!1,transform(e,t){let{_id:n,...r}=t;return{...r,id:n.toString()}}},toObject:{virtuals:!0,transform(e,t){let{_id:n,...r}=t;return{...r,id:n}}}});export{t as planSchema};
//# sourceMappingURL=plans.schema.mjs.map