@logto/cloud 0.2.5-98514d7 → 0.2.5-9c40a76

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.
@@ -1,7 +1,6 @@
1
1
  // Generated by dts-bundle-generator v9.3.1
2
2
 
3
3
  import { Json, JsonObject, RequestContext } from '@withtyped/server';
4
- import { InferModelType } from '@withtyped/server/model';
5
4
 
6
5
  export type WithAuthContext<Context = RequestContext> = Context & {
7
6
  auth: {
@@ -11,14 +10,6 @@ export type WithAuthContext<Context = RequestContext> = Context & {
11
10
  scopes: string[];
12
11
  };
13
12
  };
14
- declare enum VerificationCodeType {
15
- SignIn = "SignIn",
16
- Register = "Register",
17
- ForgotPassword = "ForgotPassword",
18
- Generic = "Generic",
19
- /** @deprecated Use `Generic` type template for sending test sms/email use case */
20
- Test = "Test"
21
- }
22
13
  declare enum TemplateType {
23
14
  /** The template for sending verification code when user is signing in. */
24
15
  SignIn = "SignIn",
@@ -29,7 +20,15 @@ declare enum TemplateType {
29
20
  /** The template for sending organization invitation. */
30
21
  OrganizationInvitation = "OrganizationInvitation",
31
22
  /** The template for generic usage. */
32
- Generic = "Generic"
23
+ Generic = "Generic",
24
+ /** The template for validating user permission for sensitive operations. */
25
+ UserPermissionValidation = "UserPermissionValidation",
26
+ /** The template for binding a new identifier to an existing account. */
27
+ BindNewIdentifier = "BindNewIdentifier",
28
+ /** The template for sending MFA verification code. */
29
+ MfaVerification = "MfaVerification",
30
+ /** The template for binding MFA verification. */
31
+ BindMfa = "BindMfa"
33
32
  }
34
33
  declare enum OrganizationInvitationStatus {
35
34
  Pending = "Pending",
@@ -69,30 +68,35 @@ declare enum TenantRole {
69
68
  /** Collaborator of the tenant, who has permissions to operate the tenant data, but not the tenant settings. */
70
69
  Collaborator = "collaborator"
71
70
  }
71
+ declare const availableReportableUsageKeys: readonly [
72
+ "tokenLimit",
73
+ "machineToMachineLimit",
74
+ "resourcesLimit",
75
+ "enterpriseSsoLimit",
76
+ "hooksLimit",
77
+ "tenantMembersLimit",
78
+ "mfaEnabled",
79
+ "organizationsEnabled",
80
+ "organizationsLimit",
81
+ "securityFeaturesEnabled",
82
+ "userRolesLimit",
83
+ "machineToMachineRolesLimit",
84
+ "thirdPartyApplicationsLimit",
85
+ "samlApplicationsLimit",
86
+ "customDomainsLimit"
87
+ ];
88
+ export type ReportableUsageKey = (typeof availableReportableUsageKeys)[number];
89
+ export type RealtimeReportableUsageKey = Exclude<ReportableUsageKey, "tokenLimit">;
72
90
  declare enum LogtoSkuType {
73
91
  Basic = "Basic",
74
92
  AddOn = "AddOn"
75
93
  }
76
- declare const AffiliateProperties: import("@withtyped/server/lib/model/index.js").default<"affiliate_properties", {
77
- createdAt: Date;
78
- affiliateId: string;
79
- type: "hostname" | "query";
80
- value: string;
81
- }, "createdAt", "createdAt">;
82
- export type AffiliateProperty = InferModelType<typeof AffiliateProperties>;
83
- declare const Affiliates: import("@withtyped/server/lib/model/index.js").default<"affiliates", {
84
- name: string;
85
- createdAt: Date;
86
- id: string;
87
- }, "id" | "createdAt", "id" | "createdAt">;
88
- export type Affiliate = InferModelType<typeof Affiliates>;
89
- declare enum RegionName {
90
- EU = "EU",
91
- US = "US"
94
+ declare enum DatabaseRegionAccessRole {
95
+ /** Instance administrator - can manage collaborators and create tenants */
96
+ Admin = "admin",
97
+ /** Collaborator user - can only create tenants in the instance */
98
+ Collaborator = "collaborator"
92
99
  }
93
- export type AffiliateData = Affiliate & {
94
- properties: Array<Pick<AffiliateProperty, "type" | "value">>;
95
- };
96
100
  declare const router: import("@withtyped/server").Router<RequestContext, WithAuthContext<Omit<import("@withtyped/server").BaseContext & {
97
101
  request: {
98
102
  id?: string | undefined;
@@ -112,7 +116,7 @@ declare const router: import("@withtyped/server").Router<RequestContext, WithAut
112
116
  body?: Json | undefined;
113
117
  bodyRaw?: Buffer | undefined;
114
118
  };
115
- }>, import("@withtyped/server").MergeRoutes<import("@withtyped/server").MergeRoutes<import("@withtyped/server").MergeRoutes<import("@withtyped/server").MergeRoutes<import("@withtyped/server").MergeRoutes<import("@withtyped/server").MergeRoutes<import("@withtyped/server").MergeRoutes<import("@withtyped/server").MergeRoutes<import("@withtyped/server").MergeRoutes<import("@withtyped/server").MergeRoutes<import("@withtyped/server").BaseRoutes, import("@withtyped/server").RoutesWithPrefix<{
119
+ }>, import("@withtyped/server").MergeRoutes<import("@withtyped/server").MergeRoutes<import("@withtyped/server").MergeRoutes<import("@withtyped/server").MergeRoutes<import("@withtyped/server").MergeRoutes<import("@withtyped/server").MergeRoutes<import("@withtyped/server").MergeRoutes<import("@withtyped/server").MergeRoutes<import("@withtyped/server").MergeRoutes<import("@withtyped/server").MergeRoutes<import("@withtyped/server").MergeRoutes<import("@withtyped/server").BaseRoutes, import("@withtyped/server").RoutesWithPrefix<{
116
120
  patch: {
117
121
  "/tenants/:tenantId": import("@withtyped/server").PathGuard<"/:tenantId", unknown, {
118
122
  name?: string | undefined;
@@ -120,9 +124,12 @@ declare const router: import("@withtyped/server").Router<RequestContext, WithAut
120
124
  id: string;
121
125
  name: string;
122
126
  createdAt: Date;
127
+ quota: {
128
+ mauLimit: number | null;
129
+ tokenLimit: number | null;
130
+ };
123
131
  usage: {
124
132
  activeUsers: number;
125
- cost: number;
126
133
  tokenUsage: number;
127
134
  };
128
135
  indicator: string;
@@ -133,14 +140,22 @@ declare const router: import("@withtyped/server").Router<RequestContext, WithAut
133
140
  planId: string;
134
141
  currentPeriodStart: Date;
135
142
  currentPeriodEnd: Date;
143
+ isEnterprisePlan: boolean;
144
+ quotaScope: "dedicated" | "shared";
136
145
  id?: string | undefined;
146
+ upcomingInvoice?: {
147
+ subtotal: number;
148
+ subtotalExcludingTax: number | null;
149
+ total: number;
150
+ totalExcludingTax: number | null;
151
+ } | null | undefined;
137
152
  };
138
- regionName: RegionName;
153
+ regionName: string;
139
154
  tag: TenantTag;
140
155
  openInvoices: {
141
- status: "void" | "open" | "draft" | "paid" | "uncollectible" | null;
142
156
  id: string;
143
157
  createdAt: Date;
158
+ status: "void" | "open" | "draft" | "paid" | "uncollectible" | null;
144
159
  updatedAt: Date;
145
160
  customerId: string | null;
146
161
  billingReason: string | null;
@@ -148,10 +163,16 @@ declare const router: import("@withtyped/server").Router<RequestContext, WithAut
148
163
  periodEnd: Date;
149
164
  amountDue: number;
150
165
  amountPaid: number;
166
+ basicSkuId: string | null;
151
167
  subscriptionId: string | null;
152
168
  hostedInvoiceUrl: string | null;
153
169
  invoicePdf: string | null;
170
+ collectionMethod: "charge_automatically" | "send_invoice" | null;
171
+ dueDate: Date | null;
154
172
  }[];
173
+ featureFlags?: {
174
+ isMultipleCustomDomainsEnabled?: boolean | undefined;
175
+ } | undefined;
155
176
  }>;
156
177
  };
157
178
  options: {};
@@ -160,9 +181,12 @@ declare const router: import("@withtyped/server").Router<RequestContext, WithAut
160
181
  id: string;
161
182
  name: string;
162
183
  createdAt: Date;
184
+ quota: {
185
+ mauLimit: number | null;
186
+ tokenLimit: number | null;
187
+ };
163
188
  usage: {
164
189
  activeUsers: number;
165
- cost: number;
166
190
  tokenUsage: number;
167
191
  };
168
192
  indicator: string;
@@ -173,14 +197,22 @@ declare const router: import("@withtyped/server").Router<RequestContext, WithAut
173
197
  planId: string;
174
198
  currentPeriodStart: Date;
175
199
  currentPeriodEnd: Date;
200
+ isEnterprisePlan: boolean;
201
+ quotaScope: "dedicated" | "shared";
176
202
  id?: string | undefined;
203
+ upcomingInvoice?: {
204
+ subtotal: number;
205
+ subtotalExcludingTax: number | null;
206
+ total: number;
207
+ totalExcludingTax: number | null;
208
+ } | null | undefined;
177
209
  };
178
- regionName: RegionName;
210
+ regionName: string;
179
211
  tag: TenantTag;
180
212
  openInvoices: {
181
- status: "void" | "open" | "draft" | "paid" | "uncollectible" | null;
182
213
  id: string;
183
214
  createdAt: Date;
215
+ status: "void" | "open" | "draft" | "paid" | "uncollectible" | null;
184
216
  updatedAt: Date;
185
217
  customerId: string | null;
186
218
  billingReason: string | null;
@@ -188,24 +220,34 @@ declare const router: import("@withtyped/server").Router<RequestContext, WithAut
188
220
  periodEnd: Date;
189
221
  amountDue: number;
190
222
  amountPaid: number;
223
+ basicSkuId: string | null;
191
224
  subscriptionId: string | null;
192
225
  hostedInvoiceUrl: string | null;
193
226
  invoicePdf: string | null;
227
+ collectionMethod: "charge_automatically" | "send_invoice" | null;
228
+ dueDate: Date | null;
194
229
  }[];
230
+ featureFlags?: {
231
+ isMultipleCustomDomainsEnabled?: boolean | undefined;
232
+ } | undefined;
195
233
  }[]>;
196
234
  };
197
235
  post: {
198
236
  "/tenants": import("@withtyped/server").PathGuard<"/", unknown, {
237
+ id?: string | undefined;
199
238
  name?: string | undefined;
239
+ regionName?: string | undefined;
200
240
  tag?: TenantTag | undefined;
201
- regionName?: RegionName | undefined;
202
241
  }, {
203
242
  id: string;
204
243
  name: string;
205
244
  createdAt: Date;
245
+ quota: {
246
+ mauLimit: number | null;
247
+ tokenLimit: number | null;
248
+ };
206
249
  usage: {
207
250
  activeUsers: number;
208
- cost: number;
209
251
  tokenUsage: number;
210
252
  };
211
253
  indicator: string;
@@ -216,14 +258,22 @@ declare const router: import("@withtyped/server").Router<RequestContext, WithAut
216
258
  planId: string;
217
259
  currentPeriodStart: Date;
218
260
  currentPeriodEnd: Date;
261
+ isEnterprisePlan: boolean;
262
+ quotaScope: "dedicated" | "shared";
219
263
  id?: string | undefined;
264
+ upcomingInvoice?: {
265
+ subtotal: number;
266
+ subtotalExcludingTax: number | null;
267
+ total: number;
268
+ totalExcludingTax: number | null;
269
+ } | null | undefined;
220
270
  };
221
- regionName: RegionName;
271
+ regionName: string;
222
272
  tag: TenantTag;
223
273
  openInvoices: {
224
- status: "void" | "open" | "draft" | "paid" | "uncollectible" | null;
225
274
  id: string;
226
275
  createdAt: Date;
276
+ status: "void" | "open" | "draft" | "paid" | "uncollectible" | null;
227
277
  updatedAt: Date;
228
278
  customerId: string | null;
229
279
  billingReason: string | null;
@@ -231,11 +281,27 @@ declare const router: import("@withtyped/server").Router<RequestContext, WithAut
231
281
  periodEnd: Date;
232
282
  amountDue: number;
233
283
  amountPaid: number;
284
+ basicSkuId: string | null;
234
285
  subscriptionId: string | null;
235
286
  hostedInvoiceUrl: string | null;
236
287
  invoicePdf: string | null;
288
+ collectionMethod: "charge_automatically" | "send_invoice" | null;
289
+ dueDate: Date | null;
237
290
  }[];
291
+ featureFlags?: {
292
+ isMultipleCustomDomainsEnabled?: boolean | undefined;
293
+ } | undefined;
238
294
  }>;
295
+ } & {
296
+ "/tenants/subscriptions/plan": import("@withtyped/server").PathGuard<"/subscriptions/plan", unknown, {
297
+ planId: string;
298
+ tenantIds: string[];
299
+ }, {
300
+ tenantId: string;
301
+ success: boolean;
302
+ error?: string | undefined;
303
+ updatedLineItems?: unknown[] | undefined;
304
+ }[]>;
239
305
  };
240
306
  put: {};
241
307
  delete: {
@@ -248,120 +314,336 @@ declare const router: import("@withtyped/server").Router<RequestContext, WithAut
248
314
  options: {};
249
315
  get: {
250
316
  "/tenants/my/subscription": import("@withtyped/server").PathGuard<"/my/subscription", unknown, unknown, {
251
- status: "incomplete" | "incomplete_expired" | "trialing" | "active" | "past_due" | "canceled" | "unpaid" | "paused";
252
317
  planId: string;
318
+ status: "incomplete" | "incomplete_expired" | "trialing" | "active" | "past_due" | "canceled" | "unpaid" | "paused";
253
319
  currentPeriodStart: Date;
254
320
  currentPeriodEnd: Date;
321
+ quota: {
322
+ auditLogsRetentionDays: number | null;
323
+ mauLimit: number | null;
324
+ applicationsLimit: number | null;
325
+ thirdPartyApplicationsLimit: number | null;
326
+ scopesPerResourceLimit: number | null;
327
+ socialConnectorsLimit: number | null;
328
+ userRolesLimit: number | null;
329
+ machineToMachineRolesLimit: number | null;
330
+ scopesPerRoleLimit: number | null;
331
+ hooksLimit: number | null;
332
+ customJwtEnabled: boolean;
333
+ subjectTokenEnabled: boolean;
334
+ bringYourUiEnabled: boolean;
335
+ collectUserProfileEnabled: boolean;
336
+ tokenLimit: number | null;
337
+ machineToMachineLimit: number | null;
338
+ resourcesLimit: number | null;
339
+ enterpriseSsoLimit: number | null;
340
+ tenantMembersLimit: number | null;
341
+ mfaEnabled: boolean;
342
+ organizationsEnabled: boolean;
343
+ organizationsLimit: number | null;
344
+ securityFeaturesEnabled: boolean;
345
+ idpInitiatedSsoEnabled: boolean;
346
+ samlApplicationsLimit: number | null;
347
+ customDomainsLimit: number | null;
348
+ };
349
+ quotaScope: "dedicated" | "shared";
350
+ isEnterprisePlan: boolean;
351
+ systemLimit: {
352
+ applicationsLimit?: number | undefined;
353
+ thirdPartyApplicationsLimit?: number | undefined;
354
+ scopesPerResourceLimit?: number | undefined;
355
+ socialConnectorsLimit?: number | undefined;
356
+ userRolesLimit?: number | undefined;
357
+ machineToMachineRolesLimit?: number | undefined;
358
+ scopesPerRoleLimit?: number | undefined;
359
+ hooksLimit?: number | undefined;
360
+ machineToMachineLimit?: number | undefined;
361
+ resourcesLimit?: number | undefined;
362
+ enterpriseSsoLimit?: number | undefined;
363
+ tenantMembersLimit?: number | undefined;
364
+ organizationsLimit?: number | undefined;
365
+ samlApplicationsLimit?: number | undefined;
366
+ customDomainsLimit?: number | undefined;
367
+ usersPerOrganizationLimit?: number | undefined;
368
+ organizationUserRolesLimit?: number | undefined;
369
+ organizationMachineToMachineRolesLimit?: number | undefined;
370
+ organizationScopesLimit?: number | undefined;
371
+ };
255
372
  id?: string | undefined;
373
+ upcomingInvoice?: {
374
+ subtotal: number;
375
+ subtotalExcludingTax: number | null;
376
+ total: number;
377
+ totalExcludingTax: number | null;
378
+ } | null | undefined;
256
379
  }>;
257
380
  } & {
258
- "/tenants/my/subscription/quota": import("@withtyped/server").PathGuard<"/my/subscription/quota", unknown, unknown, {
259
- mauLimit: number | null;
260
- tokenLimit: number | null;
261
- applicationsLimit: number | null;
262
- machineToMachineLimit: number | null;
263
- resourcesLimit: number | null;
264
- scopesPerResourceLimit: number | null;
265
- socialConnectorsLimit: number | null;
266
- machineToMachineRolesLimit: number | null;
267
- scopesPerRoleLimit: number | null;
268
- hooksLimit: number | null;
269
- auditLogsRetentionDays: number | null;
270
- mfaEnabled: boolean;
271
- organizationsEnabled: boolean;
272
- thirdPartyApplicationsLimit: number | null;
273
- tenantMembersLimit: number | null;
274
- customJwtEnabled: boolean;
275
- subjectTokenEnabled: boolean;
276
- userRolesLimit: number | null;
277
- enterpriseSsoLimit: number | null;
381
+ "/tenants/my/subscription-usage": import("@withtyped/server").PathGuard<"/my/subscription-usage", unknown, unknown, {
382
+ quota: {
383
+ auditLogsRetentionDays: number | null;
384
+ mauLimit: number | null;
385
+ applicationsLimit: number | null;
386
+ thirdPartyApplicationsLimit: number | null;
387
+ scopesPerResourceLimit: number | null;
388
+ socialConnectorsLimit: number | null;
389
+ userRolesLimit: number | null;
390
+ machineToMachineRolesLimit: number | null;
391
+ scopesPerRoleLimit: number | null;
392
+ hooksLimit: number | null;
393
+ customJwtEnabled: boolean;
394
+ subjectTokenEnabled: boolean;
395
+ bringYourUiEnabled: boolean;
396
+ collectUserProfileEnabled: boolean;
397
+ tokenLimit: number | null;
398
+ machineToMachineLimit: number | null;
399
+ resourcesLimit: number | null;
400
+ enterpriseSsoLimit: number | null;
401
+ tenantMembersLimit: number | null;
402
+ mfaEnabled: boolean;
403
+ organizationsEnabled: boolean;
404
+ organizationsLimit: number | null;
405
+ securityFeaturesEnabled: boolean;
406
+ idpInitiatedSsoEnabled: boolean;
407
+ samlApplicationsLimit: number | null;
408
+ customDomainsLimit: number | null;
409
+ };
410
+ usage: {
411
+ applicationsLimit: number;
412
+ thirdPartyApplicationsLimit: number;
413
+ scopesPerResourceLimit: number;
414
+ socialConnectorsLimit: number;
415
+ userRolesLimit: number;
416
+ machineToMachineRolesLimit: number;
417
+ scopesPerRoleLimit: number;
418
+ hooksLimit: number;
419
+ customJwtEnabled: boolean;
420
+ subjectTokenEnabled: boolean;
421
+ bringYourUiEnabled: boolean;
422
+ collectUserProfileEnabled: boolean;
423
+ machineToMachineLimit: number;
424
+ resourcesLimit: number;
425
+ enterpriseSsoLimit: number;
426
+ tenantMembersLimit: number;
427
+ mfaEnabled: boolean;
428
+ organizationsEnabled: boolean;
429
+ organizationsLimit: number;
430
+ securityFeaturesEnabled: boolean;
431
+ idpInitiatedSsoEnabled: boolean;
432
+ samlApplicationsLimit: number;
433
+ customDomainsLimit: number;
434
+ };
435
+ resources: Record<string, number>;
436
+ roles: Record<string, number>;
437
+ basicQuota: {
438
+ auditLogsRetentionDays: number | null;
439
+ mauLimit: number | null;
440
+ applicationsLimit: number | null;
441
+ thirdPartyApplicationsLimit: number | null;
442
+ scopesPerResourceLimit: number | null;
443
+ socialConnectorsLimit: number | null;
444
+ userRolesLimit: number | null;
445
+ machineToMachineRolesLimit: number | null;
446
+ scopesPerRoleLimit: number | null;
447
+ hooksLimit: number | null;
448
+ customJwtEnabled: boolean;
449
+ subjectTokenEnabled: boolean;
450
+ bringYourUiEnabled: boolean;
451
+ collectUserProfileEnabled: boolean;
452
+ tokenLimit: number | null;
453
+ machineToMachineLimit: number | null;
454
+ resourcesLimit: number | null;
455
+ enterpriseSsoLimit: number | null;
456
+ tenantMembersLimit: number | null;
457
+ mfaEnabled: boolean;
458
+ organizationsEnabled: boolean;
459
+ organizationsLimit: number | null;
460
+ securityFeaturesEnabled: boolean;
461
+ idpInitiatedSsoEnabled: boolean;
462
+ samlApplicationsLimit: number | null;
463
+ customDomainsLimit: number | null;
464
+ };
278
465
  }>;
279
- } & {
280
- "/tenants/my/subscription/usage": import("@withtyped/server").PathGuard<"/my/subscription/usage", unknown, unknown, {
281
- mauLimit: number;
282
- tokenLimit: number;
283
- applicationsLimit: number;
284
- machineToMachineLimit: number;
285
- resourcesLimit: number;
286
- scopesPerResourceLimit: number;
287
- socialConnectorsLimit: number;
288
- machineToMachineRolesLimit: number;
289
- scopesPerRoleLimit: number;
290
- hooksLimit: number;
291
- mfaEnabled: boolean;
292
- organizationsEnabled: boolean;
293
- thirdPartyApplicationsLimit: number;
294
- tenantMembersLimit: number;
295
- customJwtEnabled: boolean;
296
- subjectTokenEnabled: boolean;
297
- userRolesLimit: number;
298
- enterpriseSsoLimit: number;
466
+ };
467
+ post: {
468
+ "/tenants/my/subscription/item-updates": import("@withtyped/server").PathGuard<"/my/subscription/item-updates", unknown, {
469
+ usageKey: RealtimeReportableUsageKey;
470
+ }, {
471
+ message: string;
299
472
  }>;
300
- } & {
301
- "/tenants/my/subscription/usage/:entityName/scopes": import("@withtyped/server").PathGuard<"/my/subscription/usage/:entityName/scopes", {
302
- entityId?: string | undefined;
303
- }, unknown, Record<string, number>>;
304
- } & {
473
+ };
474
+ put: {};
475
+ delete: {};
476
+ copy: {};
477
+ head: {};
478
+ }, "/api">>, import("@withtyped/server").RoutesWithPrefix<{
479
+ patch: {};
480
+ options: {};
481
+ get: {};
482
+ post: {
483
+ "/tenants/subscription-cache/invalidate": import("@withtyped/server").PathGuard<"/subscription-cache/invalidate", unknown, {
484
+ tenantIds: string[];
485
+ }, unknown>;
486
+ };
487
+ put: {};
488
+ delete: {};
489
+ copy: {};
490
+ head: {};
491
+ }, "/api">>, import("@withtyped/server").RoutesWithPrefix<{
492
+ patch: {};
493
+ options: {};
494
+ get: {
305
495
  "/tenants/:tenantId/subscription": import("@withtyped/server").PathGuard<"/:tenantId/subscription", unknown, unknown, {
306
496
  status: "incomplete" | "incomplete_expired" | "trialing" | "active" | "past_due" | "canceled" | "unpaid" | "paused";
307
497
  planId: string;
308
498
  currentPeriodStart: Date;
309
499
  currentPeriodEnd: Date;
500
+ isEnterprisePlan: boolean;
501
+ quotaScope: "dedicated" | "shared";
310
502
  id?: string | undefined;
503
+ upcomingInvoice?: {
504
+ subtotal: number;
505
+ subtotalExcludingTax: number | null;
506
+ total: number;
507
+ totalExcludingTax: number | null;
508
+ } | null | undefined;
311
509
  }>;
312
510
  } & {
313
- "/tenants/:tenantId/subscription/quota": import("@withtyped/server").PathGuard<"/:tenantId/subscription/quota", unknown, unknown, {
314
- mauLimit: number | null;
315
- tokenLimit: number | null;
316
- applicationsLimit: number | null;
317
- machineToMachineLimit: number | null;
318
- resourcesLimit: number | null;
319
- scopesPerResourceLimit: number | null;
320
- socialConnectorsLimit: number | null;
321
- machineToMachineRolesLimit: number | null;
322
- scopesPerRoleLimit: number | null;
323
- hooksLimit: number | null;
324
- auditLogsRetentionDays: number | null;
325
- mfaEnabled: boolean;
326
- organizationsEnabled: boolean;
327
- thirdPartyApplicationsLimit: number | null;
328
- tenantMembersLimit: number | null;
329
- customJwtEnabled: boolean;
330
- subjectTokenEnabled: boolean;
331
- userRolesLimit: number | null;
332
- enterpriseSsoLimit: number | null;
511
+ "/tenants/:tenantId/subscription-usage": import("@withtyped/server").PathGuard<"/:tenantId/subscription-usage", unknown, unknown, {
512
+ quota: {
513
+ auditLogsRetentionDays: number | null;
514
+ mauLimit: number | null;
515
+ applicationsLimit: number | null;
516
+ thirdPartyApplicationsLimit: number | null;
517
+ scopesPerResourceLimit: number | null;
518
+ socialConnectorsLimit: number | null;
519
+ userRolesLimit: number | null;
520
+ machineToMachineRolesLimit: number | null;
521
+ scopesPerRoleLimit: number | null;
522
+ hooksLimit: number | null;
523
+ customJwtEnabled: boolean;
524
+ subjectTokenEnabled: boolean;
525
+ bringYourUiEnabled: boolean;
526
+ collectUserProfileEnabled: boolean;
527
+ tokenLimit: number | null;
528
+ machineToMachineLimit: number | null;
529
+ resourcesLimit: number | null;
530
+ enterpriseSsoLimit: number | null;
531
+ tenantMembersLimit: number | null;
532
+ mfaEnabled: boolean;
533
+ organizationsEnabled: boolean;
534
+ organizationsLimit: number | null;
535
+ securityFeaturesEnabled: boolean;
536
+ idpInitiatedSsoEnabled: boolean;
537
+ samlApplicationsLimit: number | null;
538
+ customDomainsLimit: number | null;
539
+ };
540
+ usage: {
541
+ applicationsLimit: number;
542
+ thirdPartyApplicationsLimit: number;
543
+ scopesPerResourceLimit: number;
544
+ socialConnectorsLimit: number;
545
+ userRolesLimit: number;
546
+ machineToMachineRolesLimit: number;
547
+ scopesPerRoleLimit: number;
548
+ hooksLimit: number;
549
+ customJwtEnabled: boolean;
550
+ subjectTokenEnabled: boolean;
551
+ bringYourUiEnabled: boolean;
552
+ collectUserProfileEnabled: boolean;
553
+ machineToMachineLimit: number;
554
+ resourcesLimit: number;
555
+ enterpriseSsoLimit: number;
556
+ tenantMembersLimit: number;
557
+ mfaEnabled: boolean;
558
+ organizationsEnabled: boolean;
559
+ organizationsLimit: number;
560
+ securityFeaturesEnabled: boolean;
561
+ idpInitiatedSsoEnabled: boolean;
562
+ samlApplicationsLimit: number;
563
+ customDomainsLimit: number;
564
+ };
565
+ resources: Record<string, number>;
566
+ roles: Record<string, number>;
567
+ basicQuota: {
568
+ auditLogsRetentionDays: number | null;
569
+ mauLimit: number | null;
570
+ applicationsLimit: number | null;
571
+ thirdPartyApplicationsLimit: number | null;
572
+ scopesPerResourceLimit: number | null;
573
+ socialConnectorsLimit: number | null;
574
+ userRolesLimit: number | null;
575
+ machineToMachineRolesLimit: number | null;
576
+ scopesPerRoleLimit: number | null;
577
+ hooksLimit: number | null;
578
+ customJwtEnabled: boolean;
579
+ subjectTokenEnabled: boolean;
580
+ bringYourUiEnabled: boolean;
581
+ collectUserProfileEnabled: boolean;
582
+ tokenLimit: number | null;
583
+ machineToMachineLimit: number | null;
584
+ resourcesLimit: number | null;
585
+ enterpriseSsoLimit: number | null;
586
+ tenantMembersLimit: number | null;
587
+ mfaEnabled: boolean;
588
+ organizationsEnabled: boolean;
589
+ organizationsLimit: number | null;
590
+ securityFeaturesEnabled: boolean;
591
+ idpInitiatedSsoEnabled: boolean;
592
+ samlApplicationsLimit: number | null;
593
+ customDomainsLimit: number | null;
594
+ };
333
595
  }>;
334
596
  } & {
335
- "/tenants/:tenantId/subscription/usage": import("@withtyped/server").PathGuard<"/:tenantId/subscription/usage", unknown, unknown, {
597
+ "/tenants/:tenantId/subscription/periodic-usage": import("@withtyped/server").PathGuard<"/:tenantId/subscription/periodic-usage", unknown, unknown, {
336
598
  mauLimit: number;
337
599
  tokenLimit: number;
338
- applicationsLimit: number;
339
- machineToMachineLimit: number;
340
- resourcesLimit: number;
341
- scopesPerResourceLimit: number;
342
- socialConnectorsLimit: number;
343
- machineToMachineRolesLimit: number;
344
- scopesPerRoleLimit: number;
345
- hooksLimit: number;
346
- mfaEnabled: boolean;
347
- organizationsEnabled: boolean;
348
- thirdPartyApplicationsLimit: number;
349
- tenantMembersLimit: number;
350
- customJwtEnabled: boolean;
351
- subjectTokenEnabled: boolean;
352
- userRolesLimit: number;
353
- enterpriseSsoLimit: number;
354
600
  }>;
355
601
  } & {
356
- "/tenants/:tenantId/subscription/usage/:entityName/scopes": import("@withtyped/server").PathGuard<"/:tenantId/subscription/usage/:entityName/scopes", {
357
- entityId?: string | undefined;
358
- }, unknown, Record<string, number>>;
602
+ "/tenants/:tenantId/subscription/add-on-skus": import("@withtyped/server").PathGuard<"/:tenantId/subscription/add-on-skus", unknown, unknown, Partial<Record<"tokenLimit" | "machineToMachineLimit" | "resourcesLimit" | "enterpriseSsoLimit" | "hooksLimit" | "tenantMembersLimit" | "mfaEnabled" | "organizationsEnabled" | "organizationsLimit" | "securityFeaturesEnabled" | "userRolesLimit" | "machineToMachineRolesLimit" | "thirdPartyApplicationsLimit" | "samlApplicationsLimit" | "customDomainsLimit", {
603
+ id: string;
604
+ name: string | null;
605
+ createdAt: Date;
606
+ defaultPriceId: string | null;
607
+ unitPrice: number | null;
608
+ type: LogtoSkuType;
609
+ quota: {
610
+ auditLogsRetentionDays?: number | null | undefined;
611
+ mauLimit?: number | null | undefined;
612
+ applicationsLimit?: number | null | undefined;
613
+ thirdPartyApplicationsLimit?: number | null | undefined;
614
+ scopesPerResourceLimit?: number | null | undefined;
615
+ socialConnectorsLimit?: number | null | undefined;
616
+ userRolesLimit?: number | null | undefined;
617
+ machineToMachineRolesLimit?: number | null | undefined;
618
+ scopesPerRoleLimit?: number | null | undefined;
619
+ hooksLimit?: number | null | undefined;
620
+ customJwtEnabled?: boolean | undefined;
621
+ subjectTokenEnabled?: boolean | undefined;
622
+ bringYourUiEnabled?: boolean | undefined;
623
+ collectUserProfileEnabled?: boolean | undefined;
624
+ tokenLimit?: number | null | undefined;
625
+ machineToMachineLimit?: number | null | undefined;
626
+ resourcesLimit?: number | null | undefined;
627
+ enterpriseSsoLimit?: number | null | undefined;
628
+ tenantMembersLimit?: number | null | undefined;
629
+ mfaEnabled?: boolean | undefined;
630
+ organizationsEnabled?: boolean | undefined;
631
+ organizationsLimit?: number | null | undefined;
632
+ securityFeaturesEnabled?: boolean | undefined;
633
+ idpInitiatedSsoEnabled?: boolean | undefined;
634
+ samlApplicationsLimit?: number | null | undefined;
635
+ customDomainsLimit?: number | null | undefined;
636
+ };
637
+ isDefault: boolean;
638
+ updatedAt: Date;
639
+ productId: string | null;
640
+ }>>>;
359
641
  } & {
360
642
  "/tenants/:tenantId/invoices": import("@withtyped/server").PathGuard<"/:tenantId/invoices", unknown, unknown, {
361
643
  invoices: {
362
- status: "void" | "open" | "draft" | "paid" | "uncollectible" | null;
363
644
  id: string;
364
645
  createdAt: Date;
646
+ status: "void" | "open" | "draft" | "paid" | "uncollectible" | null;
365
647
  updatedAt: Date;
366
648
  customerId: string | null;
367
649
  billingReason: string | null;
@@ -369,22 +651,62 @@ declare const router: import("@withtyped/server").Router<RequestContext, WithAut
369
651
  periodEnd: Date;
370
652
  amountDue: number;
371
653
  amountPaid: number;
654
+ basicSkuId: string | null;
372
655
  subscriptionId: string | null;
373
656
  hostedInvoiceUrl: string | null;
374
657
  invoicePdf: string | null;
658
+ collectionMethod: "charge_automatically" | "send_invoice" | null;
659
+ dueDate: Date | null;
375
660
  planName: string | null;
661
+ skuId?: string | null | undefined;
376
662
  }[];
377
663
  }>;
664
+ } & {
665
+ "/tenants/:tenantId/available-skus": import("@withtyped/server").PathGuard<"/:tenantId/available-skus", {
666
+ type?: LogtoSkuType | undefined;
667
+ }, unknown, {
668
+ id: string;
669
+ name: string | null;
670
+ createdAt: Date;
671
+ defaultPriceId: string | null;
672
+ unitPrice: number | null;
673
+ type: LogtoSkuType;
674
+ quota: {
675
+ auditLogsRetentionDays?: number | null | undefined;
676
+ mauLimit?: number | null | undefined;
677
+ applicationsLimit?: number | null | undefined;
678
+ thirdPartyApplicationsLimit?: number | null | undefined;
679
+ scopesPerResourceLimit?: number | null | undefined;
680
+ socialConnectorsLimit?: number | null | undefined;
681
+ userRolesLimit?: number | null | undefined;
682
+ machineToMachineRolesLimit?: number | null | undefined;
683
+ scopesPerRoleLimit?: number | null | undefined;
684
+ hooksLimit?: number | null | undefined;
685
+ customJwtEnabled?: boolean | undefined;
686
+ subjectTokenEnabled?: boolean | undefined;
687
+ bringYourUiEnabled?: boolean | undefined;
688
+ collectUserProfileEnabled?: boolean | undefined;
689
+ tokenLimit?: number | null | undefined;
690
+ machineToMachineLimit?: number | null | undefined;
691
+ resourcesLimit?: number | null | undefined;
692
+ enterpriseSsoLimit?: number | null | undefined;
693
+ tenantMembersLimit?: number | null | undefined;
694
+ mfaEnabled?: boolean | undefined;
695
+ organizationsEnabled?: boolean | undefined;
696
+ organizationsLimit?: number | null | undefined;
697
+ securityFeaturesEnabled?: boolean | undefined;
698
+ idpInitiatedSsoEnabled?: boolean | undefined;
699
+ samlApplicationsLimit?: number | null | undefined;
700
+ customDomainsLimit?: number | null | undefined;
701
+ };
702
+ isDefault: boolean;
703
+ updatedAt: Date;
704
+ productId: string | null;
705
+ }[]>;
378
706
  } & {
379
707
  "/tenants/:tenantId/invoices/:invoiceId/hosted-invoice-url": import("@withtyped/server").PathGuard<"/:tenantId/invoices/:invoiceId/hosted-invoice-url", unknown, unknown, {
380
708
  hostedInvoiceUrl: string;
381
709
  }>;
382
- } & {
383
- "/tenants/:tenantId/usage": import("@withtyped/server").PathGuard<"/:tenantId/usage", unknown, unknown, {
384
- activeUsers: number;
385
- cost: number;
386
- tokenUsage: number;
387
- }>;
388
710
  };
389
711
  post: {
390
712
  "/tenants/:tenantId/stripe-customer-portal": import("@withtyped/server").PathGuard<"/:tenantId/stripe-customer-portal", unknown, {
@@ -412,11 +734,15 @@ declare const router: import("@withtyped/server").Router<RequestContext, WithAut
412
734
  post: {
413
735
  "/services/mails": import("@withtyped/server").PathGuard<"/mails", unknown, {
414
736
  data: {
415
- type: TemplateType | VerificationCodeType;
737
+ type: TemplateType;
416
738
  payload: {
417
- code?: string | undefined;
418
739
  link?: string | undefined;
419
- } & Record<string, string> & {
740
+ code?: string | undefined;
741
+ locale?: string | undefined;
742
+ uiLocales?: string | undefined;
743
+ } & {
744
+ [k: string]: unknown;
745
+ } & {
420
746
  senderName?: string | undefined;
421
747
  companyInformation?: string | undefined;
422
748
  appLogo?: string | undefined;
@@ -427,27 +753,31 @@ declare const router: import("@withtyped/server").Router<RequestContext, WithAut
427
753
  } & {
428
754
  "/services/send-sms": import("@withtyped/server").PathGuard<"/send-sms", unknown, {
429
755
  data: {
430
- type: TemplateType | VerificationCodeType;
756
+ type: TemplateType;
431
757
  to: string;
432
758
  payload: {
433
759
  code?: string | undefined;
434
760
  link?: string | undefined;
435
- } & Record<string, string>;
761
+ locale?: string | undefined;
762
+ uiLocales?: string | undefined;
763
+ } & {
764
+ [k: string]: unknown;
765
+ };
436
766
  };
437
767
  }, unknown>;
438
768
  } & {
439
769
  "/services/custom-jwt": import("@withtyped/server").PathGuard<"/custom-jwt", {
440
770
  isTest?: string | undefined;
441
771
  }, {
772
+ token: Record<string, Json>;
442
773
  context: Record<string, Json>;
443
- script: string;
444
774
  tokenType: LogtoJwtTokenKeyType.AccessToken;
445
- token: Record<string, Json>;
775
+ script: string;
446
776
  environmentVariables?: Record<string, string> | undefined;
447
777
  } | {
448
- script: string;
449
- tokenType: LogtoJwtTokenKeyType.ClientCredentials;
450
778
  token: Record<string, Json>;
779
+ tokenType: LogtoJwtTokenKeyType.ClientCredentials;
780
+ script: string;
451
781
  environmentVariables?: Record<string, string> | undefined;
452
782
  }, Record<string, unknown>>;
453
783
  };
@@ -472,66 +802,87 @@ declare const router: import("@withtyped/server").Router<RequestContext, WithAut
472
802
  patch: {};
473
803
  options: {};
474
804
  get: {
475
- "/subscription-plans": import("@withtyped/server").PathGuard<"/", unknown, unknown, {
805
+ "/skus": import("@withtyped/server").PathGuard<"/", {
806
+ type?: LogtoSkuType | undefined;
807
+ }, unknown, {
476
808
  id: string;
809
+ name: string | null;
477
810
  createdAt: Date;
478
- name: string;
479
- updatedAt: Date;
811
+ defaultPriceId: string | null;
812
+ unitPrice: number | null;
813
+ type: LogtoSkuType;
480
814
  quota: {
481
- mauLimit: number | null;
482
- tokenLimit: number | null;
483
- applicationsLimit: number | null;
484
- machineToMachineLimit: number | null;
485
- resourcesLimit: number | null;
486
- scopesPerResourceLimit: number | null;
487
- customDomainEnabled: boolean;
488
- omniSignInEnabled: boolean;
489
- builtInEmailConnectorEnabled: boolean;
490
- socialConnectorsLimit: number | null;
491
- standardConnectorsLimit: number | null;
492
- rolesLimit: number | null;
493
- machineToMachineRolesLimit: number | null;
494
- scopesPerRoleLimit: number | null;
495
- hooksLimit: number | null;
496
- auditLogsRetentionDays: number | null;
497
- mfaEnabled: boolean;
498
- organizationsEnabled: boolean;
499
- ssoEnabled: boolean;
500
- thirdPartyApplicationsLimit: number | null;
501
- tenantMembersLimit: number | null;
502
- customJwtEnabled: boolean;
503
- subjectTokenEnabled: boolean;
815
+ auditLogsRetentionDays?: number | null | undefined;
816
+ mauLimit?: number | null | undefined;
817
+ applicationsLimit?: number | null | undefined;
818
+ thirdPartyApplicationsLimit?: number | null | undefined;
819
+ scopesPerResourceLimit?: number | null | undefined;
820
+ socialConnectorsLimit?: number | null | undefined;
821
+ userRolesLimit?: number | null | undefined;
822
+ machineToMachineRolesLimit?: number | null | undefined;
823
+ scopesPerRoleLimit?: number | null | undefined;
824
+ hooksLimit?: number | null | undefined;
825
+ customJwtEnabled?: boolean | undefined;
826
+ subjectTokenEnabled?: boolean | undefined;
827
+ bringYourUiEnabled?: boolean | undefined;
828
+ collectUserProfileEnabled?: boolean | undefined;
829
+ tokenLimit?: number | null | undefined;
830
+ machineToMachineLimit?: number | null | undefined;
831
+ resourcesLimit?: number | null | undefined;
832
+ enterpriseSsoLimit?: number | null | undefined;
833
+ tenantMembersLimit?: number | null | undefined;
834
+ mfaEnabled?: boolean | undefined;
835
+ organizationsEnabled?: boolean | undefined;
836
+ organizationsLimit?: number | null | undefined;
837
+ securityFeaturesEnabled?: boolean | undefined;
838
+ idpInitiatedSsoEnabled?: boolean | undefined;
839
+ samlApplicationsLimit?: number | null | undefined;
840
+ customDomainsLimit?: number | null | undefined;
504
841
  };
505
- stripeProducts: {
506
- type: "flat" | "tier1" | "tier2" | "tier3";
507
- id: string;
508
- name: string;
509
- price: {
510
- id: string;
511
- unitAmountDecimal: string;
512
- quantity?: 1 | undefined;
513
- unitAmount?: number | null | undefined;
514
- };
515
- description?: string | undefined;
516
- }[];
842
+ isDefault: boolean;
843
+ updatedAt: Date;
844
+ productId: string | null;
517
845
  }[]>;
518
846
  };
519
- post: {};
520
- put: {};
521
- delete: {};
522
- copy: {};
523
- head: {};
524
- }, "/api">>, import("@withtyped/server").RoutesWithPrefix<{
525
- patch: {};
526
- options: {};
527
- get: {
528
- "/skus": import("@withtyped/server").PathGuard<"/", {
529
- type?: LogtoSkuType | undefined;
530
- }, unknown, {
847
+ post: {
848
+ "/skus": import("@withtyped/server").PathGuard<"/", unknown, {
849
+ quota: {
850
+ tokenLimit?: number | null | undefined;
851
+ machineToMachineLimit?: number | null | undefined;
852
+ resourcesLimit?: number | null | undefined;
853
+ enterpriseSsoLimit?: number | null | undefined;
854
+ hooksLimit?: number | null | undefined;
855
+ tenantMembersLimit?: number | null | undefined;
856
+ mfaEnabled?: boolean | undefined;
857
+ organizationsEnabled?: boolean | undefined;
858
+ organizationsLimit?: number | null | undefined;
859
+ securityFeaturesEnabled?: boolean | undefined;
860
+ userRolesLimit?: number | null | undefined;
861
+ machineToMachineRolesLimit?: number | null | undefined;
862
+ thirdPartyApplicationsLimit?: number | null | undefined;
863
+ samlApplicationsLimit?: number | null | undefined;
864
+ customDomainsLimit?: number | null | undefined;
865
+ auditLogsRetentionDays?: number | null | undefined;
866
+ mauLimit?: number | null | undefined;
867
+ applicationsLimit?: number | null | undefined;
868
+ scopesPerResourceLimit?: number | null | undefined;
869
+ socialConnectorsLimit?: number | null | undefined;
870
+ scopesPerRoleLimit?: number | null | undefined;
871
+ customJwtEnabled?: boolean | undefined;
872
+ subjectTokenEnabled?: boolean | undefined;
873
+ bringYourUiEnabled?: boolean | undefined;
874
+ collectUserProfileEnabled?: boolean | undefined;
875
+ idpInitiatedSsoEnabled?: boolean | undefined;
876
+ };
531
877
  type: LogtoSkuType;
878
+ id?: string | undefined;
879
+ isDefault?: boolean | undefined;
880
+ }, {
881
+ createdAt: Date;
882
+ updatedAt: Date;
532
883
  id: string;
533
- name: string | null;
534
884
  quota: {
885
+ auditLogsRetentionDays?: number | null | undefined;
535
886
  mauLimit?: number | null | undefined;
536
887
  applicationsLimit?: number | null | undefined;
537
888
  thirdPartyApplicationsLimit?: number | null | undefined;
@@ -541,9 +892,10 @@ declare const router: import("@withtyped/server").Router<RequestContext, WithAut
541
892
  machineToMachineRolesLimit?: number | null | undefined;
542
893
  scopesPerRoleLimit?: number | null | undefined;
543
894
  hooksLimit?: number | null | undefined;
544
- auditLogsRetentionDays?: number | null | undefined;
545
895
  customJwtEnabled?: boolean | undefined;
546
896
  subjectTokenEnabled?: boolean | undefined;
897
+ bringYourUiEnabled?: boolean | undefined;
898
+ collectUserProfileEnabled?: boolean | undefined;
547
899
  tokenLimit?: number | null | undefined;
548
900
  machineToMachineLimit?: number | null | undefined;
549
901
  resourcesLimit?: number | null | undefined;
@@ -551,15 +903,40 @@ declare const router: import("@withtyped/server").Router<RequestContext, WithAut
551
903
  tenantMembersLimit?: number | null | undefined;
552
904
  mfaEnabled?: boolean | undefined;
553
905
  organizationsEnabled?: boolean | undefined;
906
+ organizationsLimit?: number | null | undefined;
907
+ securityFeaturesEnabled?: boolean | undefined;
908
+ idpInitiatedSsoEnabled?: boolean | undefined;
909
+ samlApplicationsLimit?: number | null | undefined;
910
+ customDomainsLimit?: number | null | undefined;
554
911
  };
555
- createdAt: Date;
556
- updatedAt: Date;
557
- unitPrice: number | null;
558
- }[]>;
912
+ type: LogtoSkuType;
913
+ isDefault: boolean;
914
+ }>;
915
+ } & {
916
+ "/skus/:skuId/products": import("@withtyped/server").PathGuard<"/:skuId/products", {
917
+ isOneTime?: string | undefined;
918
+ }, {
919
+ name: string;
920
+ unitPrice: number;
921
+ }, {
922
+ productId: string;
923
+ }>;
924
+ } & {
925
+ "/skus/:basicSkuId/usage-add-on-relations": import("@withtyped/server").PathGuard<"/:basicSkuId/usage-add-on-relations", unknown, {
926
+ usageKey: "tokenLimit" | "machineToMachineLimit" | "resourcesLimit" | "enterpriseSsoLimit" | "hooksLimit" | "tenantMembersLimit" | "mfaEnabled" | "organizationsEnabled" | "organizationsLimit" | "securityFeaturesEnabled" | "userRolesLimit" | "machineToMachineRolesLimit" | "thirdPartyApplicationsLimit" | "samlApplicationsLimit" | "customDomainsLimit";
927
+ addOnSkuId: string;
928
+ }, {
929
+ usageKey: "tokenLimit" | "machineToMachineLimit" | "resourcesLimit" | "enterpriseSsoLimit" | "hooksLimit" | "tenantMembersLimit" | "mfaEnabled" | "organizationsEnabled" | "organizationsLimit" | "securityFeaturesEnabled" | "userRolesLimit" | "machineToMachineRolesLimit" | "thirdPartyApplicationsLimit" | "samlApplicationsLimit" | "customDomainsLimit";
930
+ basicSkuId: string;
931
+ addOnSkuId: string;
932
+ }>;
559
933
  };
560
- post: {};
561
934
  put: {};
562
- delete: {};
935
+ delete: {
936
+ "/skus/:skuId": import("@withtyped/server").PathGuard<"/:skuId", unknown, unknown, unknown>;
937
+ } & {
938
+ "/skus/:basicSkuId/usage-add-on-relations/:usageKey": import("@withtyped/server").PathGuard<"/:basicSkuId/usage-add-on-relations/:usageKey", unknown, unknown, unknown>;
939
+ };
563
940
  copy: {};
564
941
  head: {};
565
942
  }, "/api">>, import("@withtyped/server").RoutesWithPrefix<{
@@ -567,25 +944,25 @@ declare const router: import("@withtyped/server").Router<RequestContext, WithAut
567
944
  options: {};
568
945
  get: {
569
946
  "/checkout-session/:id": import("@withtyped/server").PathGuard<"/:id", unknown, unknown, {
570
- id: string;
571
- createdAt: Date;
572
- userId: string;
573
- status: "open" | "complete" | "expired";
574
947
  tenantId: string | null;
948
+ planId: string | null;
949
+ skuId: string | null;
950
+ createdAt: Date;
575
951
  updatedAt: Date;
576
- planId: string;
952
+ id: string;
953
+ status: "open" | "complete" | "expired";
954
+ userId: string;
577
955
  }>;
578
956
  };
579
957
  post: {
580
958
  "/checkout-session": import("@withtyped/server").PathGuard<"/", unknown, {
581
- planId: string;
582
959
  successCallbackUrl: string;
583
960
  tenantId?: string | undefined;
584
961
  skuId?: string | undefined;
585
- cancelCallbackUrl?: string | undefined;
586
- tenantTag?: TenantTag | undefined;
587
962
  tenantName?: string | undefined;
588
- tenantRegionName?: RegionName | undefined;
963
+ tenantTag?: TenantTag | undefined;
964
+ tenantRegionName?: string | undefined;
965
+ cancelCallbackUrl?: string | undefined;
589
966
  }, {
590
967
  sessionId: string;
591
968
  redirectUri?: string | null | undefined;
@@ -595,66 +972,6 @@ declare const router: import("@withtyped/server").Router<RequestContext, WithAut
595
972
  delete: {};
596
973
  copy: {};
597
974
  head: {};
598
- }, "/api">>, import("@withtyped/server").RoutesWithPrefix<{
599
- patch: {};
600
- options: {};
601
- get: {
602
- "/affiliates": import("@withtyped/server").PathGuard<"/", unknown, unknown, AffiliateData[]>;
603
- };
604
- post: {
605
- "/affiliates": import("@withtyped/server").PathGuard<"/", unknown, {
606
- name: string;
607
- }, {
608
- id: string;
609
- createdAt: Date;
610
- name: string;
611
- }>;
612
- } & {
613
- "/affiliates/:id/properties": import("@withtyped/server").PathGuard<"/:id/properties", unknown, {
614
- type: "hostname" | "query";
615
- value: string;
616
- }, {
617
- createdAt: Date;
618
- affiliateId: string;
619
- type: "hostname" | "query";
620
- value: string;
621
- }>;
622
- };
623
- put: {};
624
- delete: {
625
- "/affiliates/:id/properties": import("@withtyped/server").PathGuard<"/:id/properties", unknown, {
626
- type: "hostname" | "query";
627
- value: string;
628
- }, unknown>;
629
- };
630
- copy: {};
631
- head: {};
632
- }, "/api">>, import("@withtyped/server").RoutesWithPrefix<{
633
- patch: {};
634
- options: {};
635
- get: {};
636
- post: {
637
- "/affiliate-logs": import("@withtyped/server").PathGuard<"/", unknown, {
638
- createdAt: string;
639
- userId: string;
640
- hostname?: string | undefined;
641
- query?: string | undefined;
642
- }, {
643
- id: string;
644
- createdAt: Date;
645
- affiliateId: string | null;
646
- userId: string;
647
- createdVia: {
648
- createdAt: string;
649
- hostname?: string | undefined;
650
- query?: string | undefined;
651
- };
652
- }>;
653
- };
654
- put: {};
655
- delete: {};
656
- copy: {};
657
- head: {};
658
975
  }, "/api">>, import("@withtyped/server").RoutesWithPrefix<{
659
976
  patch: {
660
977
  "/invitations/:invitationId/status": import("@withtyped/server").PathGuard<"/:invitationId/status", unknown, {
@@ -664,11 +981,11 @@ declare const router: import("@withtyped/server").Router<RequestContext, WithAut
664
981
  options: {};
665
982
  get: {
666
983
  "/invitations": import("@withtyped/server").PathGuard<"/", unknown, unknown, ({
667
- id: string;
668
- createdAt: number;
669
- status: OrganizationInvitationStatus;
670
984
  tenantId: string;
985
+ createdAt: number;
671
986
  updatedAt: number;
987
+ id: string;
988
+ status: OrganizationInvitationStatus;
672
989
  inviterId: string | null;
673
990
  invitee: string;
674
991
  acceptedUserId: string | null;
@@ -681,11 +998,11 @@ declare const router: import("@withtyped/server").Router<RequestContext, WithAut
681
998
  })[]>;
682
999
  } & {
683
1000
  "/invitations/:invitationId": import("@withtyped/server").PathGuard<"/:invitationId", unknown, unknown, {
684
- id: string;
685
- createdAt: number;
686
- status: OrganizationInvitationStatus;
687
1001
  tenantId: string;
1002
+ createdAt: number;
688
1003
  updatedAt: number;
1004
+ id: string;
1005
+ status: OrganizationInvitationStatus;
689
1006
  inviterId: string | null;
690
1007
  invitee: string;
691
1008
  acceptedUserId: string | null;
@@ -699,6 +1016,189 @@ declare const router: import("@withtyped/server").Router<RequestContext, WithAut
699
1016
  delete: {};
700
1017
  copy: {};
701
1018
  head: {};
1019
+ }, "/api">>, import("@withtyped/server").RoutesWithPrefix<{
1020
+ patch: {
1021
+ "/system-limits/:id": import("@withtyped/server").PathGuard<"/:id", unknown, {
1022
+ limits: {
1023
+ machineToMachineLimit?: number | undefined;
1024
+ resourcesLimit?: number | undefined;
1025
+ enterpriseSsoLimit?: number | undefined;
1026
+ hooksLimit?: number | undefined;
1027
+ tenantMembersLimit?: number | undefined;
1028
+ organizationsLimit?: number | undefined;
1029
+ userRolesLimit?: number | undefined;
1030
+ machineToMachineRolesLimit?: number | undefined;
1031
+ thirdPartyApplicationsLimit?: number | undefined;
1032
+ samlApplicationsLimit?: number | undefined;
1033
+ customDomainsLimit?: number | undefined;
1034
+ applicationsLimit?: number | undefined;
1035
+ scopesPerResourceLimit?: number | undefined;
1036
+ socialConnectorsLimit?: number | undefined;
1037
+ scopesPerRoleLimit?: number | undefined;
1038
+ usersPerOrganizationLimit?: number | undefined;
1039
+ organizationUserRolesLimit?: number | undefined;
1040
+ organizationMachineToMachineRolesLimit?: number | undefined;
1041
+ organizationScopesLimit?: number | undefined;
1042
+ };
1043
+ }, {
1044
+ createdAt: Date;
1045
+ updatedAt: Date;
1046
+ id: string;
1047
+ limits: {
1048
+ applicationsLimit?: number | undefined;
1049
+ thirdPartyApplicationsLimit?: number | undefined;
1050
+ scopesPerResourceLimit?: number | undefined;
1051
+ socialConnectorsLimit?: number | undefined;
1052
+ userRolesLimit?: number | undefined;
1053
+ machineToMachineRolesLimit?: number | undefined;
1054
+ scopesPerRoleLimit?: number | undefined;
1055
+ hooksLimit?: number | undefined;
1056
+ machineToMachineLimit?: number | undefined;
1057
+ resourcesLimit?: number | undefined;
1058
+ enterpriseSsoLimit?: number | undefined;
1059
+ tenantMembersLimit?: number | undefined;
1060
+ organizationsLimit?: number | undefined;
1061
+ samlApplicationsLimit?: number | undefined;
1062
+ customDomainsLimit?: number | undefined;
1063
+ usersPerOrganizationLimit?: number | undefined;
1064
+ organizationUserRolesLimit?: number | undefined;
1065
+ organizationMachineToMachineRolesLimit?: number | undefined;
1066
+ organizationScopesLimit?: number | undefined;
1067
+ };
1068
+ }>;
1069
+ };
1070
+ options: {};
1071
+ get: {
1072
+ "/system-limits": import("@withtyped/server").PathGuard<"/", {
1073
+ basicSkuId?: string | undefined;
1074
+ }, unknown, {
1075
+ createdAt: Date;
1076
+ updatedAt: Date;
1077
+ id: string;
1078
+ limits: {
1079
+ applicationsLimit?: number | undefined;
1080
+ thirdPartyApplicationsLimit?: number | undefined;
1081
+ scopesPerResourceLimit?: number | undefined;
1082
+ socialConnectorsLimit?: number | undefined;
1083
+ userRolesLimit?: number | undefined;
1084
+ machineToMachineRolesLimit?: number | undefined;
1085
+ scopesPerRoleLimit?: number | undefined;
1086
+ hooksLimit?: number | undefined;
1087
+ machineToMachineLimit?: number | undefined;
1088
+ resourcesLimit?: number | undefined;
1089
+ enterpriseSsoLimit?: number | undefined;
1090
+ tenantMembersLimit?: number | undefined;
1091
+ organizationsLimit?: number | undefined;
1092
+ samlApplicationsLimit?: number | undefined;
1093
+ customDomainsLimit?: number | undefined;
1094
+ usersPerOrganizationLimit?: number | undefined;
1095
+ organizationUserRolesLimit?: number | undefined;
1096
+ organizationMachineToMachineRolesLimit?: number | undefined;
1097
+ organizationScopesLimit?: number | undefined;
1098
+ };
1099
+ basicSkuIds: string[];
1100
+ }[]>;
1101
+ } & {
1102
+ "/system-limits/:id": import("@withtyped/server").PathGuard<"/:id", unknown, unknown, {
1103
+ createdAt: Date;
1104
+ updatedAt: Date;
1105
+ id: string;
1106
+ limits: {
1107
+ applicationsLimit?: number | undefined;
1108
+ thirdPartyApplicationsLimit?: number | undefined;
1109
+ scopesPerResourceLimit?: number | undefined;
1110
+ socialConnectorsLimit?: number | undefined;
1111
+ userRolesLimit?: number | undefined;
1112
+ machineToMachineRolesLimit?: number | undefined;
1113
+ scopesPerRoleLimit?: number | undefined;
1114
+ hooksLimit?: number | undefined;
1115
+ machineToMachineLimit?: number | undefined;
1116
+ resourcesLimit?: number | undefined;
1117
+ enterpriseSsoLimit?: number | undefined;
1118
+ tenantMembersLimit?: number | undefined;
1119
+ organizationsLimit?: number | undefined;
1120
+ samlApplicationsLimit?: number | undefined;
1121
+ customDomainsLimit?: number | undefined;
1122
+ usersPerOrganizationLimit?: number | undefined;
1123
+ organizationUserRolesLimit?: number | undefined;
1124
+ organizationMachineToMachineRolesLimit?: number | undefined;
1125
+ organizationScopesLimit?: number | undefined;
1126
+ };
1127
+ basicSkuIds: string[];
1128
+ }>;
1129
+ };
1130
+ post: {
1131
+ "/system-limits": import("@withtyped/server").PathGuard<"/", unknown, {
1132
+ limits: {
1133
+ machineToMachineLimit?: number | undefined;
1134
+ resourcesLimit?: number | undefined;
1135
+ enterpriseSsoLimit?: number | undefined;
1136
+ hooksLimit?: number | undefined;
1137
+ tenantMembersLimit?: number | undefined;
1138
+ organizationsLimit?: number | undefined;
1139
+ userRolesLimit?: number | undefined;
1140
+ machineToMachineRolesLimit?: number | undefined;
1141
+ thirdPartyApplicationsLimit?: number | undefined;
1142
+ samlApplicationsLimit?: number | undefined;
1143
+ customDomainsLimit?: number | undefined;
1144
+ applicationsLimit?: number | undefined;
1145
+ scopesPerResourceLimit?: number | undefined;
1146
+ socialConnectorsLimit?: number | undefined;
1147
+ scopesPerRoleLimit?: number | undefined;
1148
+ usersPerOrganizationLimit?: number | undefined;
1149
+ organizationUserRolesLimit?: number | undefined;
1150
+ organizationMachineToMachineRolesLimit?: number | undefined;
1151
+ organizationScopesLimit?: number | undefined;
1152
+ };
1153
+ id?: string | undefined;
1154
+ }, {
1155
+ createdAt: Date;
1156
+ updatedAt: Date;
1157
+ id: string;
1158
+ limits: {
1159
+ applicationsLimit?: number | undefined;
1160
+ thirdPartyApplicationsLimit?: number | undefined;
1161
+ scopesPerResourceLimit?: number | undefined;
1162
+ socialConnectorsLimit?: number | undefined;
1163
+ userRolesLimit?: number | undefined;
1164
+ machineToMachineRolesLimit?: number | undefined;
1165
+ scopesPerRoleLimit?: number | undefined;
1166
+ hooksLimit?: number | undefined;
1167
+ machineToMachineLimit?: number | undefined;
1168
+ resourcesLimit?: number | undefined;
1169
+ enterpriseSsoLimit?: number | undefined;
1170
+ tenantMembersLimit?: number | undefined;
1171
+ organizationsLimit?: number | undefined;
1172
+ samlApplicationsLimit?: number | undefined;
1173
+ customDomainsLimit?: number | undefined;
1174
+ usersPerOrganizationLimit?: number | undefined;
1175
+ organizationUserRolesLimit?: number | undefined;
1176
+ organizationMachineToMachineRolesLimit?: number | undefined;
1177
+ organizationScopesLimit?: number | undefined;
1178
+ };
1179
+ }>;
1180
+ } & {
1181
+ "/system-limits/:systemLimitId/basic-sku-relations": import("@withtyped/server").PathGuard<"/:systemLimitId/basic-sku-relations", unknown, {
1182
+ basicSkuIds: string[];
1183
+ }, {
1184
+ relations: {
1185
+ createdAt: Date;
1186
+ updatedAt: Date;
1187
+ basicSkuId: string;
1188
+ systemLimitId: string;
1189
+ }[];
1190
+ }>;
1191
+ };
1192
+ put: {};
1193
+ delete: {
1194
+ "/system-limits/:id": import("@withtyped/server").PathGuard<"/:id", unknown, unknown, unknown>;
1195
+ } & {
1196
+ "/system-limits/:systemLimitId/basic-sku-relations": import("@withtyped/server").PathGuard<"/:systemLimitId/basic-sku-relations", unknown, {
1197
+ basicSkuIds: string[];
1198
+ }, unknown>;
1199
+ };
1200
+ copy: {};
1201
+ head: {};
702
1202
  }, "/api">>, import("@withtyped/server").RoutesWithPrefix<{
703
1203
  patch: {};
704
1204
  options: {};
@@ -710,6 +1210,56 @@ declare const router: import("@withtyped/server").Router<RequestContext, WithAut
710
1210
  };
711
1211
  copy: {};
712
1212
  head: {};
1213
+ }, "/api">>, import("@withtyped/server").RoutesWithPrefix<{
1214
+ patch: {
1215
+ "/me/regions/:regionName/users/:userId": import("@withtyped/server").PathGuard<"/:regionName/users/:userId", unknown, {
1216
+ role: DatabaseRegionAccessRole;
1217
+ }, {
1218
+ role: DatabaseRegionAccessRole;
1219
+ userId: string;
1220
+ }>;
1221
+ };
1222
+ options: {};
1223
+ get: {
1224
+ "/me/regions": import("@withtyped/server").PathGuard<"/", unknown, unknown, {
1225
+ regions: {
1226
+ id: string;
1227
+ name: string;
1228
+ country: string;
1229
+ displayName: string;
1230
+ tags: TenantTag[];
1231
+ isPrivate: boolean;
1232
+ tenantLimits: {
1233
+ skuId: string;
1234
+ regionName: string;
1235
+ tenantLimit: number | null;
1236
+ tag: TenantTag;
1237
+ }[];
1238
+ }[];
1239
+ }>;
1240
+ } & {
1241
+ "/me/regions/:regionName/users": import("@withtyped/server").PathGuard<"/:regionName/users", unknown, unknown, {
1242
+ users: {
1243
+ role: DatabaseRegionAccessRole;
1244
+ userId: string;
1245
+ }[];
1246
+ }>;
1247
+ };
1248
+ post: {
1249
+ "/me/regions/:regionName/users": import("@withtyped/server").PathGuard<"/:regionName/users", unknown, {
1250
+ role: DatabaseRegionAccessRole;
1251
+ userId: string;
1252
+ }, {
1253
+ role: DatabaseRegionAccessRole;
1254
+ userId: string;
1255
+ }>;
1256
+ };
1257
+ put: {};
1258
+ delete: {
1259
+ "/me/regions/:regionName/users/:userId": import("@withtyped/server").PathGuard<"/:regionName/users/:userId", unknown, unknown, unknown>;
1260
+ };
1261
+ copy: {};
1262
+ head: {};
713
1263
  }, "/api">>, "/api">;
714
1264
  export declare const tenantAuthRouter: import("@withtyped/server").Router<RequestContext, import("@withtyped/server").WithBodyContext<import("@withtyped/server").BaseContext & {
715
1265
  request: {
@@ -724,11 +1274,11 @@ export declare const tenantAuthRouter: import("@withtyped/server").Router<Reques
724
1274
  "/:tenantId/invitations/:invitationId/status": import("@withtyped/server").PathGuard<"/:tenantId/invitations/:invitationId/status", unknown, {
725
1275
  status: OrganizationInvitationStatus.Revoked;
726
1276
  }, {
727
- id: string;
728
- createdAt: number;
729
- status: OrganizationInvitationStatus;
730
1277
  tenantId: string;
1278
+ createdAt: number;
731
1279
  updatedAt: number;
1280
+ id: string;
1281
+ status: OrganizationInvitationStatus;
732
1282
  inviterId: string | null;
733
1283
  invitee: string;
734
1284
  acceptedUserId: string | null;
@@ -752,11 +1302,11 @@ export declare const tenantAuthRouter: import("@withtyped/server").Router<Reques
752
1302
  "/:tenantId/members/:userId/scopes": import("@withtyped/server").PathGuard<"/:tenantId/members/:userId/scopes", unknown, unknown, OrganizationScope[]>;
753
1303
  } & {
754
1304
  "/:tenantId/invitations": import("@withtyped/server").PathGuard<"/:tenantId/invitations", unknown, unknown, ({
755
- id: string;
756
- createdAt: number;
757
- status: OrganizationInvitationStatus;
758
1305
  tenantId: string;
1306
+ createdAt: number;
759
1307
  updatedAt: number;
1308
+ id: string;
1309
+ status: OrganizationInvitationStatus;
760
1310
  inviterId: string | null;
761
1311
  invitee: string;
762
1312
  acceptedUserId: string | null;
@@ -769,22 +1319,34 @@ export declare const tenantAuthRouter: import("@withtyped/server").Router<Reques
769
1319
  };
770
1320
  post: {
771
1321
  "/:tenantId/invitations": import("@withtyped/server").PathGuard<"/:tenantId/invitations", unknown, {
772
- invitee: string;
1322
+ invitee: string | string[];
773
1323
  roleName: TenantRole;
774
1324
  expiresAt?: number | undefined;
775
1325
  }, {
776
- id: string;
1326
+ tenantId: string;
777
1327
  createdAt: number;
1328
+ updatedAt: number;
1329
+ id: string;
778
1330
  status: OrganizationInvitationStatus;
1331
+ inviterId: string | null;
1332
+ invitee: string;
1333
+ acceptedUserId: string | null;
1334
+ organizationId: string;
1335
+ expiresAt: number;
1336
+ organizationRoles: OrganizationRoleEntity[];
1337
+ } | {
779
1338
  tenantId: string;
1339
+ createdAt: number;
780
1340
  updatedAt: number;
1341
+ id: string;
1342
+ status: OrganizationInvitationStatus;
781
1343
  inviterId: string | null;
782
1344
  invitee: string;
783
1345
  acceptedUserId: string | null;
784
1346
  organizationId: string;
785
1347
  expiresAt: number;
786
1348
  organizationRoles: OrganizationRoleEntity[];
787
- }>;
1349
+ }[]>;
788
1350
  } & {
789
1351
  "/:tenantId/invitations/:invitationId/message": import("@withtyped/server").PathGuard<"/:tenantId/invitations/:invitationId/message", unknown, unknown, unknown>;
790
1352
  };