import { RenameId } from "../utils/mongoDB/types.js";
import { User } from "./user.types.js";
import { Plan } from "./plan.types.js";
import { Document, Model, ObjectIdToString, Types } from "mongoose";

//#region src/types/organization.types.d.ts
type OrganizationCreationData = {
  name: Organization['name'];
};
type OrganizationData = {
  name: string;
  membersIds: User['id'][];
  adminsIds: User['id'][];
};
type Organization = OrganizationData & {
  id: Types.ObjectId;
  creatorId: User['id'];
  plan?: Plan;
  createdAt: number;
  updatedAt: number;
};
type OrganizationAPI = ObjectIdToString<Organization>;
type OrganizationSchema = RenameId<Organization>;
type OrganizationModelType = Model<Organization>;
type OrganizationDocument = Document<unknown, {}, Organization> & Organization;
//#endregion
export { Organization, OrganizationAPI, OrganizationCreationData, OrganizationData, OrganizationDocument, OrganizationModelType, OrganizationSchema };
//# sourceMappingURL=organization.types.d.ts.map