Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 4 additions & 0 deletions packages/openapi/src/usage/get-space-usage.ts
Original file line number Diff line number Diff line change
Expand Up @@ -9,13 +9,15 @@ export enum UsageFeature {
AttachmentSize = 'attachmentSize',
NumDatabaseConnections = 'numDatabaseConnections',
NumCollaborators = 'numCollaborators',
NumAutomationSendEmail = 'numAutomationSendEmail',
}

export const usageFeatureSchema = z.object({
[UsageFeature.NumRows]: z.number(),
[UsageFeature.AttachmentSize]: z.number(),
[UsageFeature.NumDatabaseConnections]: z.number(),
[UsageFeature.NumCollaborators]: z.number(),
[UsageFeature.NumAutomationSendEmail]: z.number(),
});

export enum UsageFeatureLimit {
Expand All @@ -41,6 +43,7 @@ export enum UsageFeatureLimit {
ChatAIEnable = 'chatAIEnable',
AppEnable = 'appEnable',
CustomDomainEnable = 'customDomainEnable',
MaxNumAutomationSendEmail = 'maxNumAutomationSendEmail',
}

export const usageFeatureLimitSchema = z.object({
Expand All @@ -66,6 +69,7 @@ export const usageFeatureLimitSchema = z.object({
[UsageFeatureLimit.ChatAIEnable]: z.boolean(),
[UsageFeatureLimit.AppEnable]: z.boolean(),
[UsageFeatureLimit.CustomDomainEnable]: z.boolean(),
[UsageFeatureLimit.MaxNumAutomationSendEmail]: z.number(),
});

export const usageVoSchema = z.object({
Expand Down