@brimble/models 3.8.2 → 3.8.4

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.
@@ -0,0 +1,31 @@
1
+ import { model, Schema } from "mongoose";
2
+
3
+ import { ICashierSubscription } from "./types";
4
+
5
+ const cashierSubscriptionSchema: Schema = new Schema(
6
+ {
7
+ user_id: { type: String, required: true },
8
+ type: { type: String, default: "default" },
9
+ stripe_id: { type: String, required: true },
10
+ stripe_status: { type: String, required: true },
11
+ stripe_price: { type: String, default: null },
12
+ quantity: { type: Number, default: null },
13
+ trial_ends_at: { type: Date, default: null },
14
+ ends_at: { type: Date, default: null },
15
+ team_id: { type: String, default: null },
16
+ plan_type: { type: String, default: null },
17
+ domain_id: { type: String, default: null },
18
+ },
19
+ {
20
+ timestamps: {
21
+ createdAt: "created_at",
22
+ updatedAt: "updated_at",
23
+ },
24
+ collection: "cashier_subscriptions",
25
+ },
26
+ );
27
+
28
+ export default model<ICashierSubscription>(
29
+ "CashierSubscription",
30
+ cashierSubscriptionSchema,
31
+ );
@@ -0,0 +1,25 @@
1
+ import { model, Schema } from "mongoose";
2
+
3
+ import { ICashierSubscriptionItem } from "./types";
4
+
5
+ const cashierSubscriptionItemSchema: Schema = new Schema(
6
+ {
7
+ subscription_id: { type: String, required: true },
8
+ stripe_id: { type: String, required: true },
9
+ stripe_product: { type: String, default: null },
10
+ stripe_price: { type: String, required: true },
11
+ quantity: { type: Number, default: null },
12
+ },
13
+ {
14
+ timestamps: {
15
+ createdAt: "created_at",
16
+ updatedAt: "updated_at",
17
+ },
18
+ collection: "cashier_subscription_items",
19
+ },
20
+ );
21
+
22
+ export default model<ICashierSubscriptionItem>(
23
+ "CashierSubscriptionItem",
24
+ cashierSubscriptionItemSchema,
25
+ );
@@ -0,0 +1,30 @@
1
+ /// <reference types="mongoose/types/aggregate" />
2
+ /// <reference types="mongoose/types/callback" />
3
+ /// <reference types="mongoose/types/collection" />
4
+ /// <reference types="mongoose/types/connection" />
5
+ /// <reference types="mongoose/types/cursor" />
6
+ /// <reference types="mongoose/types/document" />
7
+ /// <reference types="mongoose/types/error" />
8
+ /// <reference types="mongoose/types/expressions" />
9
+ /// <reference types="mongoose/types/helpers" />
10
+ /// <reference types="mongoose/types/middlewares" />
11
+ /// <reference types="mongoose/types/indexes" />
12
+ /// <reference types="mongoose/types/models" />
13
+ /// <reference types="mongoose/types/mongooseoptions" />
14
+ /// <reference types="mongoose/types/pipelinestage" />
15
+ /// <reference types="mongoose/types/populate" />
16
+ /// <reference types="mongoose/types/query" />
17
+ /// <reference types="mongoose/types/schemaoptions" />
18
+ /// <reference types="mongoose/types/schematypes" />
19
+ /// <reference types="mongoose/types/session" />
20
+ /// <reference types="mongoose/types/types" />
21
+ /// <reference types="mongoose/types/utility" />
22
+ /// <reference types="mongoose/types/validation" />
23
+ /// <reference types="mongoose/types/virtuals" />
24
+ /// <reference types="mongoose" />
25
+ /// <reference types="mongoose/types/inferschematype" />
26
+ import { ICashierSubscription } from "./types";
27
+ declare const _default: import("mongoose").Model<ICashierSubscription, {}, {}, {}, import("mongoose").Document<unknown, {}, ICashierSubscription> & ICashierSubscription & {
28
+ _id: import("mongoose").Types.ObjectId;
29
+ }, any>;
30
+ export default _default;
@@ -0,0 +1,23 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ const mongoose_1 = require("mongoose");
4
+ const cashierSubscriptionSchema = new mongoose_1.Schema({
5
+ user_id: { type: String, required: true },
6
+ type: { type: String, default: "default" },
7
+ stripe_id: { type: String, required: true },
8
+ stripe_status: { type: String, required: true },
9
+ stripe_price: { type: String, default: null },
10
+ quantity: { type: Number, default: null },
11
+ trial_ends_at: { type: Date, default: null },
12
+ ends_at: { type: Date, default: null },
13
+ team_id: { type: String, default: null },
14
+ plan_type: { type: String, default: null },
15
+ domain_id: { type: String, default: null },
16
+ }, {
17
+ timestamps: {
18
+ createdAt: "created_at",
19
+ updatedAt: "updated_at",
20
+ },
21
+ collection: "cashier_subscriptions",
22
+ });
23
+ exports.default = (0, mongoose_1.model)("CashierSubscription", cashierSubscriptionSchema);
@@ -0,0 +1,30 @@
1
+ /// <reference types="mongoose/types/aggregate" />
2
+ /// <reference types="mongoose/types/callback" />
3
+ /// <reference types="mongoose/types/collection" />
4
+ /// <reference types="mongoose/types/connection" />
5
+ /// <reference types="mongoose/types/cursor" />
6
+ /// <reference types="mongoose/types/document" />
7
+ /// <reference types="mongoose/types/error" />
8
+ /// <reference types="mongoose/types/expressions" />
9
+ /// <reference types="mongoose/types/helpers" />
10
+ /// <reference types="mongoose/types/middlewares" />
11
+ /// <reference types="mongoose/types/indexes" />
12
+ /// <reference types="mongoose/types/models" />
13
+ /// <reference types="mongoose/types/mongooseoptions" />
14
+ /// <reference types="mongoose/types/pipelinestage" />
15
+ /// <reference types="mongoose/types/populate" />
16
+ /// <reference types="mongoose/types/query" />
17
+ /// <reference types="mongoose/types/schemaoptions" />
18
+ /// <reference types="mongoose/types/schematypes" />
19
+ /// <reference types="mongoose/types/session" />
20
+ /// <reference types="mongoose/types/types" />
21
+ /// <reference types="mongoose/types/utility" />
22
+ /// <reference types="mongoose/types/validation" />
23
+ /// <reference types="mongoose/types/virtuals" />
24
+ /// <reference types="mongoose" />
25
+ /// <reference types="mongoose/types/inferschematype" />
26
+ import { ICashierSubscriptionItem } from "./types";
27
+ declare const _default: import("mongoose").Model<ICashierSubscriptionItem, {}, {}, {}, import("mongoose").Document<unknown, {}, ICashierSubscriptionItem> & ICashierSubscriptionItem & {
28
+ _id: import("mongoose").Types.ObjectId;
29
+ }, any>;
30
+ export default _default;
@@ -0,0 +1,17 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ const mongoose_1 = require("mongoose");
4
+ const cashierSubscriptionItemSchema = new mongoose_1.Schema({
5
+ subscription_id: { type: String, required: true },
6
+ stripe_id: { type: String, required: true },
7
+ stripe_product: { type: String, default: null },
8
+ stripe_price: { type: String, required: true },
9
+ quantity: { type: Number, default: null },
10
+ }, {
11
+ timestamps: {
12
+ createdAt: "created_at",
13
+ updatedAt: "updated_at",
14
+ },
15
+ collection: "cashier_subscription_items",
16
+ });
17
+ exports.default = (0, mongoose_1.model)("CashierSubscriptionItem", cashierSubscriptionItemSchema);
@@ -62,6 +62,10 @@ const domainSchema = new mongoose_1.Schema({
62
62
  ref: "Subscription",
63
63
  type: mongoose_1.Schema.Types.ObjectId,
64
64
  },
65
+ cashier_subscription_id: {
66
+ type: String,
67
+ default: null,
68
+ },
65
69
  nameservers: {
66
70
  type: Array,
67
71
  required: false,
package/dist/index.d.ts CHANGED
@@ -47,7 +47,9 @@ export { default as AppMessage } from "./app-message";
47
47
  export { default as Invoice } from "./invoice";
48
48
  export { default as Tag } from "./tag";
49
49
  export { default as ProjectTagAssignment } from "./project-tag-assignment";
50
- export { IUser, IGit, IProject, IPreview, IProjectConnection, IFollowing, IIntegration, IEnv, IServer, IDomain, IToken, IMember, ITeam, IInstalledIntegration, ILog, ISubscription, ICard, IDns, IRole, IPermission, IMemberPermission, IWallet, IDbImage, IJob, ILicense, IPlanConfiguration, IAutoScalingGroup, IComputeChange, IRegion, IVolume, IFramework, BrimbleFrameworkType, ISettings, ILoadBalancerPort, IDomainRenewal, IDomainTransfer, IWebhookCategory, IWebhookEvent, IWebhookSetting, IIntention, IProvider, IBranch, ICollabAnnotation, ICollabComment, ICollabAttachment, ICollabIntegration, ICollabSettings, ICollabShareToken, ICollabPushSubscription, IAppMessage, IInvoice, ITag, IProjectTagAssignment, } from "./types";
50
+ export { default as CashierSubscription } from "./cashier_subscription";
51
+ export { default as CashierSubscriptionItem } from "./cashier_subscription_item";
52
+ export { IUser, IGit, IProject, IPreview, IProjectConnection, IFollowing, IIntegration, IEnv, IServer, IDomain, IToken, IMember, ITeam, IInstalledIntegration, ILog, ISubscription, ICard, IDns, IRole, IPermission, IMemberPermission, IWallet, IDbImage, IJob, ILicense, IPlanConfiguration, IAutoScalingGroup, IComputeChange, IRegion, IVolume, IFramework, BrimbleFrameworkType, ISettings, ILoadBalancerPort, IDomainRenewal, IDomainTransfer, IWebhookCategory, IWebhookEvent, IWebhookSetting, IIntention, IProvider, IBranch, ICollabAnnotation, ICollabComment, ICollabAttachment, ICollabIntegration, ICollabSettings, ICollabShareToken, ICollabPushSubscription, IAppMessage, IInvoice, ITag, IProjectTagAssignment, ICashierSubscription, ICashierSubscriptionItem, } from "./types";
51
53
  export { GIT_TYPE, INTEGRATION_TYPES, INTEGRATION_PROVIDERS, OAUTH_PERMISSIONS, ENVIRONMENT, SERVER_STATUS, ROLES, SUBSCRIPTION_PLAN_TYPE, PROJECT_STATUS, SUBSCRIPTION_STATUS, CARD_TYPES, DNS_TYPE, PERMISSION_TYPE, REQUEST_TYPE, ServiceType, DatabaseEngine, JobStatus, LicenseStatus, REGION_CONTINENT, BUILD_DISABLED_BY, SERVER_PROTOCOL, FrameworkApplicationType, DomainRenewalStatus, DomainTransferProvider, DomainTransferDirection, DomainTransferStatus, NomadDeploymentStatus, BRANCH_TYPE, COLLAB_ANNOTATION_STATUS, COLLAB_INTEGRATION_TYPE, COLLAB_THEME, COLLAB_TOOLBAR_POSITION, INVOICE_STATUS, INVOICE_PAYMENT_STATUS, INVOICE_TYPE } from "./enum";
52
54
  import mongoose from "mongoose";
53
55
  export declare const connectToMongo: (mongoUrl: string, config?: mongoose.ConnectOptions) => Promise<void>;
package/dist/index.js CHANGED
@@ -13,7 +13,7 @@ var __importDefault = (this && this.__importDefault) || function (mod) {
13
13
  };
14
14
  Object.defineProperty(exports, "__esModule", { value: true });
15
15
  exports.ProjectTagAssignment = exports.Tag = exports.Invoice = exports.AppMessage = exports.CollabPushSubscription = exports.CollabShareToken = exports.CollabSettings = exports.CollabIntegration = exports.CollabComment = exports.CollabAnnotation = exports.Branch = exports.Provider = exports.Intention = exports.WebhookSetting = exports.WebhookEvent = exports.WebhookCategory = exports.DomainTransfer = exports.DomainRenewal = exports.LoadBalancerPort = exports.Settings = exports.Framework = exports.Volume = exports.Region = exports.ComputeChange = exports.AutoScalingGroup = exports.PlanConfiguration = exports.Liscense = exports.Job = exports.DbImage = exports.Wallet = exports.Server = exports.Card = exports.Subscription = exports.Log = exports.Role = exports.MemberPermission = exports.Permission = exports.Member = exports.Team = exports.Token = exports.Env = exports.Dns = exports.Domain = exports.Integration = exports.Following = exports.ProjectConnection = exports.Preview = exports.DeletedProject = exports.Project = exports.User = void 0;
16
- exports.healthCheckMongo = exports.closeMongo = exports.db = exports.connectToMongo = exports.INVOICE_TYPE = exports.INVOICE_PAYMENT_STATUS = exports.INVOICE_STATUS = exports.COLLAB_TOOLBAR_POSITION = exports.COLLAB_THEME = exports.COLLAB_INTEGRATION_TYPE = exports.COLLAB_ANNOTATION_STATUS = exports.BRANCH_TYPE = exports.NomadDeploymentStatus = exports.DomainTransferStatus = exports.DomainTransferDirection = exports.DomainTransferProvider = exports.DomainRenewalStatus = exports.FrameworkApplicationType = exports.SERVER_PROTOCOL = exports.BUILD_DISABLED_BY = exports.REGION_CONTINENT = exports.LicenseStatus = exports.JobStatus = exports.DatabaseEngine = exports.ServiceType = exports.REQUEST_TYPE = exports.PERMISSION_TYPE = exports.DNS_TYPE = exports.CARD_TYPES = exports.SUBSCRIPTION_STATUS = exports.PROJECT_STATUS = exports.SUBSCRIPTION_PLAN_TYPE = exports.ROLES = exports.SERVER_STATUS = exports.ENVIRONMENT = exports.OAUTH_PERMISSIONS = exports.INTEGRATION_PROVIDERS = exports.INTEGRATION_TYPES = exports.GIT_TYPE = void 0;
16
+ exports.healthCheckMongo = exports.closeMongo = exports.db = exports.connectToMongo = exports.INVOICE_TYPE = exports.INVOICE_PAYMENT_STATUS = exports.INVOICE_STATUS = exports.COLLAB_TOOLBAR_POSITION = exports.COLLAB_THEME = exports.COLLAB_INTEGRATION_TYPE = exports.COLLAB_ANNOTATION_STATUS = exports.BRANCH_TYPE = exports.NomadDeploymentStatus = exports.DomainTransferStatus = exports.DomainTransferDirection = exports.DomainTransferProvider = exports.DomainRenewalStatus = exports.FrameworkApplicationType = exports.SERVER_PROTOCOL = exports.BUILD_DISABLED_BY = exports.REGION_CONTINENT = exports.LicenseStatus = exports.JobStatus = exports.DatabaseEngine = exports.ServiceType = exports.REQUEST_TYPE = exports.PERMISSION_TYPE = exports.DNS_TYPE = exports.CARD_TYPES = exports.SUBSCRIPTION_STATUS = exports.PROJECT_STATUS = exports.SUBSCRIPTION_PLAN_TYPE = exports.ROLES = exports.SERVER_STATUS = exports.ENVIRONMENT = exports.OAUTH_PERMISSIONS = exports.INTEGRATION_PROVIDERS = exports.INTEGRATION_TYPES = exports.GIT_TYPE = exports.CashierSubscriptionItem = exports.CashierSubscription = void 0;
17
17
  var user_1 = require("./user");
18
18
  Object.defineProperty(exports, "User", { enumerable: true, get: function () { return __importDefault(user_1).default; } });
19
19
  var project_1 = require("./project");
@@ -113,6 +113,10 @@ var tag_1 = require("./tag");
113
113
  Object.defineProperty(exports, "Tag", { enumerable: true, get: function () { return __importDefault(tag_1).default; } });
114
114
  var project_tag_assignment_1 = require("./project-tag-assignment");
115
115
  Object.defineProperty(exports, "ProjectTagAssignment", { enumerable: true, get: function () { return __importDefault(project_tag_assignment_1).default; } });
116
+ var cashier_subscription_1 = require("./cashier_subscription");
117
+ Object.defineProperty(exports, "CashierSubscription", { enumerable: true, get: function () { return __importDefault(cashier_subscription_1).default; } });
118
+ var cashier_subscription_item_1 = require("./cashier_subscription_item");
119
+ Object.defineProperty(exports, "CashierSubscriptionItem", { enumerable: true, get: function () { return __importDefault(cashier_subscription_item_1).default; } });
116
120
  var enum_1 = require("./enum");
117
121
  Object.defineProperty(exports, "GIT_TYPE", { enumerable: true, get: function () { return enum_1.GIT_TYPE; } });
118
122
  Object.defineProperty(exports, "INTEGRATION_TYPES", { enumerable: true, get: function () { return enum_1.INTEGRATION_TYPES; } });
@@ -35,5 +35,6 @@ const PlanConfigurationSchema = new mongoose_1.Schema({
35
35
  custom_domain: { type: Boolean, required: true, default: false },
36
36
  webhook_enabled: { type: Boolean, required: true, default: false },
37
37
  can_deploy_all_applications: { type: Boolean, required: true, default: false },
38
+ stripe_prices: { type: mongoose_1.Schema.Types.Mixed, required: false, default: {} },
38
39
  }, { timestamps: true });
39
40
  exports.default = (0, mongoose_1.model)("PlanConfigurations", PlanConfigurationSchema, "plan_configurations");
@@ -0,0 +1,25 @@
1
+ import { Document } from "mongoose";
2
+ export interface ICashierSubscription extends Document {
3
+ user_id: string;
4
+ type: string;
5
+ stripe_id: string;
6
+ stripe_status: string;
7
+ stripe_price: string | null;
8
+ quantity: number | null;
9
+ trial_ends_at: Date | null;
10
+ ends_at: Date | null;
11
+ team_id: string | null;
12
+ plan_type: string | null;
13
+ domain_id: string | null;
14
+ created_at: Date;
15
+ updated_at: Date;
16
+ }
17
+ export interface ICashierSubscriptionItem extends Document {
18
+ subscription_id: string;
19
+ stripe_id: string;
20
+ stripe_product: string | null;
21
+ stripe_price: string;
22
+ quantity: number | null;
23
+ created_at: Date;
24
+ updated_at: Date;
25
+ }
@@ -0,0 +1,2 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
@@ -10,6 +10,7 @@ export interface IDomain extends Document {
10
10
  preview: IPreview;
11
11
  provider: string;
12
12
  subscription: ISubscription;
13
+ cashier_subscription_id: string | null;
13
14
  auto_renewal: boolean;
14
15
  renewal_duration: number;
15
16
  is_discounted: boolean;
@@ -49,3 +49,4 @@ export type { IAppMessage } from "./app-message";
49
49
  export type { IInvoice } from "./invoice";
50
50
  export type { IProjectTagAssignment } from "./project-tag-assignment";
51
51
  export type { ITag } from "./tag";
52
+ export type { ICashierSubscription, ICashierSubscriptionItem } from "./cashier_subscription";
@@ -30,4 +30,5 @@ export interface IPlanConfiguration extends Document {
30
30
  unlimited_projects: boolean;
31
31
  webhook_enabled: boolean;
32
32
  can_deploy_all_applications: boolean;
33
+ stripe_prices?: Record<string, string>;
33
34
  }
@@ -27,6 +27,7 @@ export interface IUser extends Document {
27
27
  build_disabled: boolean;
28
28
  build_disabled_by: BUILD_DISABLED_BY;
29
29
  spending_limit: number;
30
+ build_minutes: number;
30
31
  disabled: boolean;
31
32
  disabled_at: Date;
32
33
  notifications: {
package/dist/user.js CHANGED
@@ -42,6 +42,7 @@ const userSchema = new mongoose_1.Schema({
42
42
  tenant: { type: mongoose_1.Schema.Types.ObjectId, ref: "Tenancy", required: false },
43
43
  is_waitlist: { type: Boolean, default: true },
44
44
  spending_limit: { type: Number },
45
+ build_minutes: { type: Number, default: 0 },
45
46
  notifications: Object,
46
47
  disabled: Boolean,
47
48
  disabled_at: Date,
package/domain/index.ts CHANGED
@@ -63,6 +63,10 @@ const domainSchema = new Schema(
63
63
  ref: "Subscription",
64
64
  type: Schema.Types.ObjectId,
65
65
  },
66
+ cashier_subscription_id: {
67
+ type: String,
68
+ default: null,
69
+ },
66
70
  nameservers: {
67
71
  type: Array,
68
72
  required: false,
package/index.ts CHANGED
@@ -47,6 +47,8 @@ export { default as AppMessage } from "./app-message";
47
47
  export { default as Invoice } from "./invoice";
48
48
  export { default as Tag } from "./tag";
49
49
  export { default as ProjectTagAssignment } from "./project-tag-assignment";
50
+ export { default as CashierSubscription } from "./cashier_subscription";
51
+ export { default as CashierSubscriptionItem } from "./cashier_subscription_item";
50
52
 
51
53
  export {
52
54
  IUser,
@@ -102,6 +104,8 @@ export {
102
104
  IInvoice,
103
105
  ITag,
104
106
  IProjectTagAssignment,
107
+ ICashierSubscription,
108
+ ICashierSubscriptionItem,
105
109
  } from "./types";
106
110
  export {
107
111
  GIT_TYPE,
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@brimble/models",
3
- "version": "3.8.2",
3
+ "version": "3.8.4",
4
4
  "description": "Brimble models",
5
5
  "main": "dist/index.js",
6
6
  "types": "dist/index.d.ts",
@@ -36,6 +36,7 @@ const PlanConfigurationSchema = new Schema<IPlanConfiguration>(
36
36
  custom_domain: { type: Boolean, required: true, default: false },
37
37
  webhook_enabled: { type: Boolean, required: true, default: false },
38
38
  can_deploy_all_applications: { type: Boolean, required: true, default: false },
39
+ stripe_prices: { type: Schema.Types.Mixed, required: false, default: {} },
39
40
  },
40
41
  { timestamps: true },
41
42
  );
@@ -0,0 +1,27 @@
1
+ import { Document } from "mongoose";
2
+
3
+ export interface ICashierSubscription extends Document {
4
+ user_id: string;
5
+ type: string;
6
+ stripe_id: string;
7
+ stripe_status: string;
8
+ stripe_price: string | null;
9
+ quantity: number | null;
10
+ trial_ends_at: Date | null;
11
+ ends_at: Date | null;
12
+ team_id: string | null;
13
+ plan_type: string | null;
14
+ domain_id: string | null;
15
+ created_at: Date;
16
+ updated_at: Date;
17
+ }
18
+
19
+ export interface ICashierSubscriptionItem extends Document {
20
+ subscription_id: string;
21
+ stripe_id: string;
22
+ stripe_product: string | null;
23
+ stripe_price: string;
24
+ quantity: number | null;
25
+ created_at: Date;
26
+ updated_at: Date;
27
+ }
@@ -11,6 +11,7 @@ export interface IDomain extends Document {
11
11
  preview: IPreview;
12
12
  provider: string;
13
13
  subscription: ISubscription;
14
+ cashier_subscription_id: string | null;
14
15
  auto_renewal: boolean;
15
16
  renewal_duration: number;
16
17
  is_discounted: boolean;
package/types/index.ts CHANGED
@@ -49,3 +49,4 @@ export type { IAppMessage } from "./app-message";
49
49
  export type { IInvoice } from "./invoice";
50
50
  export type { IProjectTagAssignment } from "./project-tag-assignment";
51
51
  export type { ITag } from "./tag";
52
+ export type { ICashierSubscription, ICashierSubscriptionItem } from "./cashier_subscription";
@@ -31,4 +31,5 @@ export interface IPlanConfiguration extends Document {
31
31
  unlimited_projects: boolean;
32
32
  webhook_enabled: boolean;
33
33
  can_deploy_all_applications: boolean;
34
+ stripe_prices?: Record<string, string>;
34
35
  }
package/types/user.ts CHANGED
@@ -28,6 +28,7 @@ export interface IUser extends Document {
28
28
  build_disabled: boolean;
29
29
  build_disabled_by: BUILD_DISABLED_BY;
30
30
  spending_limit: number;
31
+ build_minutes: number;
31
32
  disabled: boolean;
32
33
  disabled_at: Date;
33
34
  notifications: {
package/user.ts CHANGED
@@ -44,6 +44,7 @@ const userSchema: Schema = new Schema(
44
44
  tenant: { type: Schema.Types.ObjectId, ref: "Tenancy", required: false },
45
45
  is_waitlist: { type: Boolean, default: true },
46
46
  spending_limit: { type: Number },
47
+ build_minutes: { type: Number, default: 0 },
47
48
  notifications: Object,
48
49
  disabled: Boolean,
49
50
  disabled_at: Date,