@logto/cloud 0.2.5-d9576f9 → 0.2.5-da1425a

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.
Files changed (3) hide show
  1. package/README.md +63 -0
  2. package/lib/routes/index.d.ts +1236 -182
  3. package/package.json +14 -17
@@ -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",
@@ -37,6 +36,20 @@ declare enum OrganizationInvitationStatus {
37
36
  Expired = "Expired",
38
37
  Revoked = "Revoked"
39
38
  }
39
+ /** The scopes (permissions) defined by the organization template. */
40
+ export type OrganizationScope = {
41
+ tenantId: string;
42
+ /** The globally unique identifier of the organization scope. */
43
+ id: string;
44
+ /** The organization scope's name, unique within the organization template. */
45
+ name: string;
46
+ /** A brief description of the organization scope. */
47
+ description: string | null;
48
+ };
49
+ declare enum LogtoJwtTokenKeyType {
50
+ AccessToken = "access-token",
51
+ ClientCredentials = "client-credentials"
52
+ }
40
53
  /**
41
54
  * The simplified organization role entity that is returned in the `roles` field
42
55
  * of the organization.
@@ -52,27 +65,56 @@ declare enum TenantTag {
52
65
  declare enum TenantRole {
53
66
  /** Admin of the tenant, who has all permissions. */
54
67
  Admin = "admin",
55
- /** Member of the tenant, who has permissions to operate the tenant data, but not the tenant settings. */
56
- Member = "member"
68
+ /** Collaborator of the tenant, who has permissions to operate the tenant data, but not the tenant settings. */
69
+ Collaborator = "collaborator"
70
+ }
71
+ declare const availableReportableUsageKeys: readonly [
72
+ "tokenLimit",
73
+ "mauLimit",
74
+ "machineToMachineLimit",
75
+ "resourcesLimit",
76
+ "enterpriseSsoLimit",
77
+ "hooksLimit",
78
+ "tenantMembersLimit",
79
+ "mfaEnabled",
80
+ "organizationsEnabled",
81
+ "organizationsLimit",
82
+ "securityFeaturesEnabled",
83
+ "userRolesLimit",
84
+ "machineToMachineRolesLimit",
85
+ "thirdPartyApplicationsLimit",
86
+ "samlApplicationsLimit",
87
+ "customDomainsLimit"
88
+ ];
89
+ export type ReportableUsageKey = (typeof availableReportableUsageKeys)[number];
90
+ export type RealtimeReportableUsageKey = Exclude<ReportableUsageKey, "tokenLimit" | "mauLimit">;
91
+ declare enum LogtoSkuType {
92
+ Basic = "Basic",
93
+ AddOn = "AddOn"
94
+ }
95
+ declare enum UsageReportingType {
96
+ TokenUsage = "tokenUsage",
97
+ MauUsageWithM2MTokens = "mauUsageWithM2MTokens"
98
+ }
99
+ declare enum DatabaseRegionAccessRole {
100
+ /** Instance administrator - can manage collaborators and create tenants */
101
+ Admin = "admin",
102
+ /** Collaborator user - can only create tenants in the instance */
103
+ Collaborator = "collaborator"
104
+ }
105
+ declare enum QuotaScope {
106
+ /**
107
+ * Shared quota across multiple regions or tenants under the same enterprise.
108
+ */
109
+ Shared = "shared",
110
+ /**
111
+ * Tenant level dedicated quota.
112
+ */
113
+ Dedicated = "dedicated"
57
114
  }
58
- declare const AffiliateProperties: import("@withtyped/server/lib/model/index.js").default<"affiliate_properties", {
59
- createdAt: Date;
60
- affiliateId: string;
61
- type: "hostname" | "query";
62
- value: string;
63
- }, "createdAt", "createdAt">;
64
- export type AffiliateProperty = InferModelType<typeof AffiliateProperties>;
65
- declare const Affiliates: import("@withtyped/server/lib/model/index.js").default<"affiliates", {
66
- id: string;
67
- createdAt: Date;
68
- name: string;
69
- }, "createdAt" | "id", "createdAt" | "id">;
70
- export type Affiliate = InferModelType<typeof Affiliates>;
71
- export type AffiliateData = Affiliate & {
72
- properties: Array<Pick<AffiliateProperty, "type" | "value">>;
73
- };
74
115
  declare const router: import("@withtyped/server").Router<RequestContext, WithAuthContext<Omit<import("@withtyped/server").BaseContext & {
75
116
  request: {
117
+ id?: string | undefined;
76
118
  method?: import("@withtyped/server").RequestMethod | undefined;
77
119
  headers: import("http").IncomingHttpHeaders;
78
120
  url: URL;
@@ -80,6 +122,7 @@ declare const router: import("@withtyped/server").Router<RequestContext, WithAut
80
122
  };
81
123
  }, "request"> & {
82
124
  request: Record<string, unknown> & {
125
+ id?: string | undefined;
83
126
  method?: import("@withtyped/server").RequestMethod | undefined;
84
127
  headers: import("http").IncomingHttpHeaders;
85
128
  url: URL;
@@ -88,18 +131,23 @@ declare const router: import("@withtyped/server").Router<RequestContext, WithAut
88
131
  body?: Json | undefined;
89
132
  bodyRaw?: Buffer | undefined;
90
133
  };
91
- }>, 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<{
92
- options: {};
134
+ }>, 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").MergeRoutes<import("@withtyped/server").BaseRoutes, import("@withtyped/server").RoutesWithPrefix<{
93
135
  patch: {
94
136
  "/tenants/:tenantId": import("@withtyped/server").PathGuard<"/:tenantId", unknown, {
95
137
  name?: string | undefined;
96
138
  }, {
97
139
  id: string;
98
140
  name: string;
141
+ createdAt: Date;
142
+ quota: {
143
+ mauLimit: number | null;
144
+ tokenLimit: number | null;
145
+ };
99
146
  usage: {
100
- activeUsers: number;
101
- cost: number;
147
+ userTokenUsage: number;
148
+ m2mTokenUsage: number;
102
149
  tokenUsage: number;
150
+ activeUsers: number;
103
151
  };
104
152
  indicator: string;
105
153
  isSuspended: boolean;
@@ -109,12 +157,22 @@ declare const router: import("@withtyped/server").Router<RequestContext, WithAut
109
157
  planId: string;
110
158
  currentPeriodStart: Date;
111
159
  currentPeriodEnd: Date;
160
+ isEnterprisePlan: boolean;
161
+ quotaScope: "dedicated" | "shared";
162
+ id?: string | undefined;
163
+ upcomingInvoice?: {
164
+ subtotal: number;
165
+ subtotalExcludingTax: number | null;
166
+ total: number;
167
+ totalExcludingTax: number | null;
168
+ } | null | undefined;
112
169
  };
170
+ regionName: string;
113
171
  tag: TenantTag;
114
172
  openInvoices: {
115
- status: "void" | "open" | "draft" | "paid" | "uncollectible" | null;
116
- createdAt: Date;
117
173
  id: string;
174
+ createdAt: Date;
175
+ status: "open" | "void" | "draft" | "paid" | "uncollectible" | null;
118
176
  updatedAt: Date;
119
177
  customerId: string | null;
120
178
  billingReason: string | null;
@@ -122,20 +180,33 @@ declare const router: import("@withtyped/server").Router<RequestContext, WithAut
122
180
  periodEnd: Date;
123
181
  amountDue: number;
124
182
  amountPaid: number;
183
+ basicSkuId: string | null;
125
184
  subscriptionId: string | null;
126
185
  hostedInvoiceUrl: string | null;
127
186
  invoicePdf: string | null;
187
+ collectionMethod: "charge_automatically" | "send_invoice" | null;
188
+ dueDate: Date | null;
128
189
  }[];
190
+ featureFlags?: {
191
+ isMultipleCustomDomainsEnabled?: boolean | undefined;
192
+ } | undefined;
129
193
  }>;
130
194
  };
195
+ options: {};
131
196
  get: {
132
197
  "/tenants": import("@withtyped/server").PathGuard<"/", unknown, unknown, {
133
198
  id: string;
134
199
  name: string;
200
+ createdAt: Date;
201
+ quota: {
202
+ mauLimit: number | null;
203
+ tokenLimit: number | null;
204
+ };
135
205
  usage: {
136
- activeUsers: number;
137
- cost: number;
206
+ userTokenUsage: number;
207
+ m2mTokenUsage: number;
138
208
  tokenUsage: number;
209
+ activeUsers: number;
139
210
  };
140
211
  indicator: string;
141
212
  isSuspended: boolean;
@@ -145,12 +216,22 @@ declare const router: import("@withtyped/server").Router<RequestContext, WithAut
145
216
  planId: string;
146
217
  currentPeriodStart: Date;
147
218
  currentPeriodEnd: Date;
219
+ isEnterprisePlan: boolean;
220
+ quotaScope: "dedicated" | "shared";
221
+ id?: string | undefined;
222
+ upcomingInvoice?: {
223
+ subtotal: number;
224
+ subtotalExcludingTax: number | null;
225
+ total: number;
226
+ totalExcludingTax: number | null;
227
+ } | null | undefined;
148
228
  };
229
+ regionName: string;
149
230
  tag: TenantTag;
150
231
  openInvoices: {
151
- status: "void" | "open" | "draft" | "paid" | "uncollectible" | null;
152
- createdAt: Date;
153
232
  id: string;
233
+ createdAt: Date;
234
+ status: "open" | "void" | "draft" | "paid" | "uncollectible" | null;
154
235
  updatedAt: Date;
155
236
  customerId: string | null;
156
237
  billingReason: string | null;
@@ -158,23 +239,37 @@ declare const router: import("@withtyped/server").Router<RequestContext, WithAut
158
239
  periodEnd: Date;
159
240
  amountDue: number;
160
241
  amountPaid: number;
242
+ basicSkuId: string | null;
161
243
  subscriptionId: string | null;
162
244
  hostedInvoiceUrl: string | null;
163
245
  invoicePdf: string | null;
246
+ collectionMethod: "charge_automatically" | "send_invoice" | null;
247
+ dueDate: Date | null;
164
248
  }[];
249
+ featureFlags?: {
250
+ isMultipleCustomDomainsEnabled?: boolean | undefined;
251
+ } | undefined;
165
252
  }[]>;
166
253
  };
167
254
  post: {
168
255
  "/tenants": import("@withtyped/server").PathGuard<"/", unknown, {
256
+ id?: string | undefined;
169
257
  name?: string | undefined;
258
+ regionName?: string | undefined;
170
259
  tag?: TenantTag | undefined;
171
260
  }, {
172
261
  id: string;
173
262
  name: string;
263
+ createdAt: Date;
264
+ quota: {
265
+ mauLimit: number | null;
266
+ tokenLimit: number | null;
267
+ };
174
268
  usage: {
175
- activeUsers: number;
176
- cost: number;
269
+ userTokenUsage: number;
270
+ m2mTokenUsage: number;
177
271
  tokenUsage: number;
272
+ activeUsers: number;
178
273
  };
179
274
  indicator: string;
180
275
  isSuspended: boolean;
@@ -184,12 +279,22 @@ declare const router: import("@withtyped/server").Router<RequestContext, WithAut
184
279
  planId: string;
185
280
  currentPeriodStart: Date;
186
281
  currentPeriodEnd: Date;
282
+ isEnterprisePlan: boolean;
283
+ quotaScope: "dedicated" | "shared";
284
+ id?: string | undefined;
285
+ upcomingInvoice?: {
286
+ subtotal: number;
287
+ subtotalExcludingTax: number | null;
288
+ total: number;
289
+ totalExcludingTax: number | null;
290
+ } | null | undefined;
187
291
  };
292
+ regionName: string;
188
293
  tag: TenantTag;
189
294
  openInvoices: {
190
- status: "void" | "open" | "draft" | "paid" | "uncollectible" | null;
191
- createdAt: Date;
192
295
  id: string;
296
+ createdAt: Date;
297
+ status: "open" | "void" | "draft" | "paid" | "uncollectible" | null;
193
298
  updatedAt: Date;
194
299
  customerId: string | null;
195
300
  billingReason: string | null;
@@ -197,11 +302,27 @@ declare const router: import("@withtyped/server").Router<RequestContext, WithAut
197
302
  periodEnd: Date;
198
303
  amountDue: number;
199
304
  amountPaid: number;
305
+ basicSkuId: string | null;
200
306
  subscriptionId: string | null;
201
307
  hostedInvoiceUrl: string | null;
202
308
  invoicePdf: string | null;
309
+ collectionMethod: "charge_automatically" | "send_invoice" | null;
310
+ dueDate: Date | null;
203
311
  }[];
312
+ featureFlags?: {
313
+ isMultipleCustomDomainsEnabled?: boolean | undefined;
314
+ } | undefined;
204
315
  }>;
316
+ } & {
317
+ "/tenants/subscriptions/plan": import("@withtyped/server").PathGuard<"/subscriptions/plan", unknown, {
318
+ planId: string;
319
+ tenantIds: string[];
320
+ }, {
321
+ tenantId: string;
322
+ success: boolean;
323
+ error?: string | undefined;
324
+ updatedLineItems?: unknown[] | undefined;
325
+ }[]>;
205
326
  };
206
327
  put: {};
207
328
  delete: {
@@ -210,28 +331,339 @@ declare const router: import("@withtyped/server").Router<RequestContext, WithAut
210
331
  copy: {};
211
332
  head: {};
212
333
  }, "/api">>, import("@withtyped/server").RoutesWithPrefix<{
213
- options: {};
214
334
  patch: {};
335
+ options: {};
215
336
  get: {
216
337
  "/tenants/my/subscription": import("@withtyped/server").PathGuard<"/my/subscription", unknown, unknown, {
217
338
  status: "incomplete" | "incomplete_expired" | "trialing" | "active" | "past_due" | "canceled" | "unpaid" | "paused";
339
+ quota: {
340
+ auditLogsRetentionDays: number | null;
341
+ subjectTokenEnabled: boolean;
342
+ mauLimit: number | null;
343
+ applicationsLimit: number | null;
344
+ thirdPartyApplicationsLimit: number | null;
345
+ scopesPerResourceLimit: number | null;
346
+ socialConnectorsLimit: number | null;
347
+ userRolesLimit: number | null;
348
+ machineToMachineRolesLimit: number | null;
349
+ scopesPerRoleLimit: number | null;
350
+ hooksLimit: number | null;
351
+ customJwtEnabled: boolean;
352
+ bringYourUiEnabled: boolean;
353
+ collectUserProfileEnabled: boolean;
354
+ tokenLimit: number | null;
355
+ machineToMachineLimit: number | null;
356
+ resourcesLimit: number | null;
357
+ enterpriseSsoLimit: number | null;
358
+ tenantMembersLimit: number | null;
359
+ mfaEnabled: boolean;
360
+ organizationsEnabled: boolean;
361
+ organizationsLimit: number | null;
362
+ securityFeaturesEnabled: boolean;
363
+ idpInitiatedSsoEnabled: boolean;
364
+ samlApplicationsLimit: number | null;
365
+ customDomainsLimit: number | null;
366
+ };
218
367
  planId: string;
219
368
  currentPeriodStart: Date;
220
369
  currentPeriodEnd: Date;
370
+ quotaScope: "dedicated" | "shared";
371
+ isEnterprisePlan: boolean;
372
+ systemLimit: {
373
+ applicationsLimit?: number | undefined;
374
+ thirdPartyApplicationsLimit?: number | undefined;
375
+ scopesPerResourceLimit?: number | undefined;
376
+ socialConnectorsLimit?: number | undefined;
377
+ userRolesLimit?: number | undefined;
378
+ machineToMachineRolesLimit?: number | undefined;
379
+ scopesPerRoleLimit?: number | undefined;
380
+ hooksLimit?: number | undefined;
381
+ machineToMachineLimit?: number | undefined;
382
+ resourcesLimit?: number | undefined;
383
+ enterpriseSsoLimit?: number | undefined;
384
+ tenantMembersLimit?: number | undefined;
385
+ organizationsLimit?: number | undefined;
386
+ samlApplicationsLimit?: number | undefined;
387
+ customDomainsLimit?: number | undefined;
388
+ usersPerOrganizationLimit?: number | undefined;
389
+ organizationUserRolesLimit?: number | undefined;
390
+ organizationMachineToMachineRolesLimit?: number | undefined;
391
+ organizationScopesLimit?: number | undefined;
392
+ };
393
+ id?: string | undefined;
394
+ upcomingInvoice?: {
395
+ subtotal: number;
396
+ subtotalExcludingTax: number | null;
397
+ total: number;
398
+ totalExcludingTax: number | null;
399
+ } | null | undefined;
221
400
  }>;
222
401
  } & {
402
+ "/tenants/my/subscription-usage": import("@withtyped/server").PathGuard<"/my/subscription-usage", unknown, unknown, {
403
+ quota: {
404
+ auditLogsRetentionDays: number | null;
405
+ subjectTokenEnabled: boolean;
406
+ mauLimit: number | null;
407
+ applicationsLimit: number | null;
408
+ thirdPartyApplicationsLimit: number | null;
409
+ scopesPerResourceLimit: number | null;
410
+ socialConnectorsLimit: number | null;
411
+ userRolesLimit: number | null;
412
+ machineToMachineRolesLimit: number | null;
413
+ scopesPerRoleLimit: number | null;
414
+ hooksLimit: number | null;
415
+ customJwtEnabled: boolean;
416
+ bringYourUiEnabled: boolean;
417
+ collectUserProfileEnabled: boolean;
418
+ tokenLimit: number | null;
419
+ machineToMachineLimit: number | null;
420
+ resourcesLimit: number | null;
421
+ enterpriseSsoLimit: number | null;
422
+ tenantMembersLimit: number | null;
423
+ mfaEnabled: boolean;
424
+ organizationsEnabled: boolean;
425
+ organizationsLimit: number | null;
426
+ securityFeaturesEnabled: boolean;
427
+ idpInitiatedSsoEnabled: boolean;
428
+ samlApplicationsLimit: number | null;
429
+ customDomainsLimit: number | null;
430
+ };
431
+ usage: {
432
+ applicationsLimit: number;
433
+ thirdPartyApplicationsLimit: number;
434
+ scopesPerResourceLimit: number;
435
+ socialConnectorsLimit: number;
436
+ userRolesLimit: number;
437
+ machineToMachineRolesLimit: number;
438
+ scopesPerRoleLimit: number;
439
+ hooksLimit: number;
440
+ customJwtEnabled: boolean;
441
+ bringYourUiEnabled: boolean;
442
+ collectUserProfileEnabled: boolean;
443
+ machineToMachineLimit: number;
444
+ resourcesLimit: number;
445
+ enterpriseSsoLimit: number;
446
+ tenantMembersLimit: number;
447
+ mfaEnabled: boolean;
448
+ organizationsEnabled: boolean;
449
+ organizationsLimit: number;
450
+ securityFeaturesEnabled: boolean;
451
+ idpInitiatedSsoEnabled: boolean;
452
+ samlApplicationsLimit: number;
453
+ customDomainsLimit: number;
454
+ };
455
+ basicQuota: {
456
+ auditLogsRetentionDays: number | null;
457
+ subjectTokenEnabled: boolean;
458
+ mauLimit: number | null;
459
+ applicationsLimit: number | null;
460
+ thirdPartyApplicationsLimit: number | null;
461
+ scopesPerResourceLimit: number | null;
462
+ socialConnectorsLimit: number | null;
463
+ userRolesLimit: number | null;
464
+ machineToMachineRolesLimit: number | null;
465
+ scopesPerRoleLimit: number | null;
466
+ hooksLimit: number | null;
467
+ customJwtEnabled: boolean;
468
+ bringYourUiEnabled: boolean;
469
+ collectUserProfileEnabled: boolean;
470
+ tokenLimit: number | null;
471
+ machineToMachineLimit: number | null;
472
+ resourcesLimit: number | null;
473
+ enterpriseSsoLimit: number | null;
474
+ tenantMembersLimit: number | null;
475
+ mfaEnabled: boolean;
476
+ organizationsEnabled: boolean;
477
+ organizationsLimit: number | null;
478
+ securityFeaturesEnabled: boolean;
479
+ idpInitiatedSsoEnabled: boolean;
480
+ samlApplicationsLimit: number | null;
481
+ customDomainsLimit: number | null;
482
+ };
483
+ }>;
484
+ };
485
+ post: {
486
+ "/tenants/my/subscription/item-updates": import("@withtyped/server").PathGuard<"/my/subscription/item-updates", unknown, {
487
+ usageKey: RealtimeReportableUsageKey;
488
+ }, {
489
+ message: string;
490
+ }>;
491
+ };
492
+ put: {};
493
+ delete: {};
494
+ copy: {};
495
+ head: {};
496
+ }, "/api">>, import("@withtyped/server").RoutesWithPrefix<{
497
+ patch: {};
498
+ options: {};
499
+ get: {};
500
+ post: {
501
+ "/tenants/subscription-cache/invalidate": import("@withtyped/server").PathGuard<"/subscription-cache/invalidate", unknown, {
502
+ tenantIds: string[];
503
+ }, unknown>;
504
+ };
505
+ put: {};
506
+ delete: {};
507
+ copy: {};
508
+ head: {};
509
+ }, "/api">>, import("@withtyped/server").RoutesWithPrefix<{
510
+ patch: {};
511
+ options: {};
512
+ get: {
223
513
  "/tenants/:tenantId/subscription": import("@withtyped/server").PathGuard<"/:tenantId/subscription", unknown, unknown, {
224
514
  status: "incomplete" | "incomplete_expired" | "trialing" | "active" | "past_due" | "canceled" | "unpaid" | "paused";
225
515
  planId: string;
226
516
  currentPeriodStart: Date;
227
517
  currentPeriodEnd: Date;
518
+ isEnterprisePlan: boolean;
519
+ quotaScope: "dedicated" | "shared";
520
+ id?: string | undefined;
521
+ upcomingInvoice?: {
522
+ subtotal: number;
523
+ subtotalExcludingTax: number | null;
524
+ total: number;
525
+ totalExcludingTax: number | null;
526
+ } | null | undefined;
228
527
  }>;
528
+ } & {
529
+ "/tenants/:tenantId/subscription-usage": import("@withtyped/server").PathGuard<"/:tenantId/subscription-usage", unknown, unknown, {
530
+ quota: {
531
+ auditLogsRetentionDays: number | null;
532
+ subjectTokenEnabled: boolean;
533
+ mauLimit: number | null;
534
+ applicationsLimit: number | null;
535
+ thirdPartyApplicationsLimit: number | null;
536
+ scopesPerResourceLimit: number | null;
537
+ socialConnectorsLimit: number | null;
538
+ userRolesLimit: number | null;
539
+ machineToMachineRolesLimit: number | null;
540
+ scopesPerRoleLimit: number | null;
541
+ hooksLimit: number | null;
542
+ customJwtEnabled: boolean;
543
+ bringYourUiEnabled: boolean;
544
+ collectUserProfileEnabled: boolean;
545
+ tokenLimit: number | null;
546
+ machineToMachineLimit: number | null;
547
+ resourcesLimit: number | null;
548
+ enterpriseSsoLimit: number | null;
549
+ tenantMembersLimit: number | null;
550
+ mfaEnabled: boolean;
551
+ organizationsEnabled: boolean;
552
+ organizationsLimit: number | null;
553
+ securityFeaturesEnabled: boolean;
554
+ idpInitiatedSsoEnabled: boolean;
555
+ samlApplicationsLimit: number | null;
556
+ customDomainsLimit: number | null;
557
+ };
558
+ usage: {
559
+ applicationsLimit: number;
560
+ thirdPartyApplicationsLimit: number;
561
+ scopesPerResourceLimit: number;
562
+ socialConnectorsLimit: number;
563
+ userRolesLimit: number;
564
+ machineToMachineRolesLimit: number;
565
+ scopesPerRoleLimit: number;
566
+ hooksLimit: number;
567
+ customJwtEnabled: boolean;
568
+ bringYourUiEnabled: boolean;
569
+ collectUserProfileEnabled: boolean;
570
+ machineToMachineLimit: number;
571
+ resourcesLimit: number;
572
+ enterpriseSsoLimit: number;
573
+ tenantMembersLimit: number;
574
+ mfaEnabled: boolean;
575
+ organizationsEnabled: boolean;
576
+ organizationsLimit: number;
577
+ securityFeaturesEnabled: boolean;
578
+ idpInitiatedSsoEnabled: boolean;
579
+ samlApplicationsLimit: number;
580
+ customDomainsLimit: number;
581
+ };
582
+ resources: Record<string, number>;
583
+ roles: Record<string, number>;
584
+ basicQuota: {
585
+ auditLogsRetentionDays: number | null;
586
+ subjectTokenEnabled: boolean;
587
+ mauLimit: number | null;
588
+ applicationsLimit: number | null;
589
+ thirdPartyApplicationsLimit: number | null;
590
+ scopesPerResourceLimit: number | null;
591
+ socialConnectorsLimit: number | null;
592
+ userRolesLimit: number | null;
593
+ machineToMachineRolesLimit: number | null;
594
+ scopesPerRoleLimit: number | null;
595
+ hooksLimit: number | null;
596
+ customJwtEnabled: boolean;
597
+ bringYourUiEnabled: boolean;
598
+ collectUserProfileEnabled: boolean;
599
+ tokenLimit: number | null;
600
+ machineToMachineLimit: number | null;
601
+ resourcesLimit: number | null;
602
+ enterpriseSsoLimit: number | null;
603
+ tenantMembersLimit: number | null;
604
+ mfaEnabled: boolean;
605
+ organizationsEnabled: boolean;
606
+ organizationsLimit: number | null;
607
+ securityFeaturesEnabled: boolean;
608
+ idpInitiatedSsoEnabled: boolean;
609
+ samlApplicationsLimit: number | null;
610
+ customDomainsLimit: number | null;
611
+ };
612
+ }>;
613
+ } & {
614
+ "/tenants/:tenantId/subscription/periodic-usage": import("@withtyped/server").PathGuard<"/:tenantId/subscription/periodic-usage", unknown, unknown, {
615
+ mauLimit: number;
616
+ tokenLimit: number;
617
+ userTokenLimit: number;
618
+ m2mTokenLimit: number;
619
+ }>;
620
+ } & {
621
+ "/tenants/:tenantId/subscription/add-on-skus": import("@withtyped/server").PathGuard<"/:tenantId/subscription/add-on-skus", unknown, unknown, Partial<Record<"mauLimit" | "thirdPartyApplicationsLimit" | "userRolesLimit" | "machineToMachineRolesLimit" | "hooksLimit" | "tokenLimit" | "machineToMachineLimit" | "resourcesLimit" | "enterpriseSsoLimit" | "tenantMembersLimit" | "mfaEnabled" | "organizationsEnabled" | "organizationsLimit" | "securityFeaturesEnabled" | "samlApplicationsLimit" | "customDomainsLimit", {
622
+ id: string;
623
+ name: string | null;
624
+ createdAt: Date;
625
+ defaultPriceId: string | null;
626
+ unitPrice: number | null;
627
+ type: LogtoSkuType;
628
+ quota: {
629
+ auditLogsRetentionDays?: number | null | undefined;
630
+ subjectTokenEnabled?: boolean | undefined;
631
+ mauLimit?: number | null | undefined;
632
+ applicationsLimit?: number | null | undefined;
633
+ thirdPartyApplicationsLimit?: number | null | undefined;
634
+ scopesPerResourceLimit?: number | null | undefined;
635
+ socialConnectorsLimit?: number | null | undefined;
636
+ userRolesLimit?: number | null | undefined;
637
+ machineToMachineRolesLimit?: number | null | undefined;
638
+ scopesPerRoleLimit?: number | null | undefined;
639
+ hooksLimit?: number | null | undefined;
640
+ customJwtEnabled?: boolean | undefined;
641
+ bringYourUiEnabled?: boolean | undefined;
642
+ collectUserProfileEnabled?: boolean | undefined;
643
+ tokenLimit?: number | null | undefined;
644
+ machineToMachineLimit?: number | null | undefined;
645
+ resourcesLimit?: number | null | undefined;
646
+ enterpriseSsoLimit?: number | null | undefined;
647
+ tenantMembersLimit?: number | null | undefined;
648
+ mfaEnabled?: boolean | undefined;
649
+ organizationsEnabled?: boolean | undefined;
650
+ organizationsLimit?: number | null | undefined;
651
+ securityFeaturesEnabled?: boolean | undefined;
652
+ idpInitiatedSsoEnabled?: boolean | undefined;
653
+ samlApplicationsLimit?: number | null | undefined;
654
+ customDomainsLimit?: number | null | undefined;
655
+ };
656
+ isDefault: boolean;
657
+ isDevPlan: boolean;
658
+ updatedAt: Date;
659
+ productId: string | null;
660
+ }>>>;
229
661
  } & {
230
662
  "/tenants/:tenantId/invoices": import("@withtyped/server").PathGuard<"/:tenantId/invoices", unknown, unknown, {
231
663
  invoices: {
232
- status: "void" | "open" | "draft" | "paid" | "uncollectible" | null;
233
- createdAt: Date;
234
664
  id: string;
665
+ createdAt: Date;
666
+ status: "open" | "void" | "draft" | "paid" | "uncollectible" | null;
235
667
  updatedAt: Date;
236
668
  customerId: string | null;
237
669
  billingReason: string | null;
@@ -239,22 +671,63 @@ declare const router: import("@withtyped/server").Router<RequestContext, WithAut
239
671
  periodEnd: Date;
240
672
  amountDue: number;
241
673
  amountPaid: number;
674
+ basicSkuId: string | null;
242
675
  subscriptionId: string | null;
243
676
  hostedInvoiceUrl: string | null;
244
677
  invoicePdf: string | null;
678
+ collectionMethod: "charge_automatically" | "send_invoice" | null;
679
+ dueDate: Date | null;
245
680
  planName: string | null;
681
+ skuId?: string | null | undefined;
246
682
  }[];
247
683
  }>;
684
+ } & {
685
+ "/tenants/:tenantId/available-skus": import("@withtyped/server").PathGuard<"/:tenantId/available-skus", {
686
+ type?: LogtoSkuType | undefined;
687
+ }, unknown, {
688
+ id: string;
689
+ name: string | null;
690
+ createdAt: Date;
691
+ defaultPriceId: string | null;
692
+ unitPrice: number | null;
693
+ type: LogtoSkuType;
694
+ quota: {
695
+ auditLogsRetentionDays?: number | null | undefined;
696
+ subjectTokenEnabled?: boolean | undefined;
697
+ mauLimit?: number | null | undefined;
698
+ applicationsLimit?: number | null | undefined;
699
+ thirdPartyApplicationsLimit?: number | null | undefined;
700
+ scopesPerResourceLimit?: number | null | undefined;
701
+ socialConnectorsLimit?: number | null | undefined;
702
+ userRolesLimit?: number | null | undefined;
703
+ machineToMachineRolesLimit?: number | null | undefined;
704
+ scopesPerRoleLimit?: number | null | undefined;
705
+ hooksLimit?: number | null | undefined;
706
+ customJwtEnabled?: boolean | undefined;
707
+ bringYourUiEnabled?: boolean | undefined;
708
+ collectUserProfileEnabled?: boolean | undefined;
709
+ tokenLimit?: number | null | undefined;
710
+ machineToMachineLimit?: number | null | undefined;
711
+ resourcesLimit?: number | null | undefined;
712
+ enterpriseSsoLimit?: number | null | undefined;
713
+ tenantMembersLimit?: number | null | undefined;
714
+ mfaEnabled?: boolean | undefined;
715
+ organizationsEnabled?: boolean | undefined;
716
+ organizationsLimit?: number | null | undefined;
717
+ securityFeaturesEnabled?: boolean | undefined;
718
+ idpInitiatedSsoEnabled?: boolean | undefined;
719
+ samlApplicationsLimit?: number | null | undefined;
720
+ customDomainsLimit?: number | null | undefined;
721
+ };
722
+ isDefault: boolean;
723
+ isDevPlan: boolean;
724
+ updatedAt: Date;
725
+ productId: string | null;
726
+ }[]>;
248
727
  } & {
249
728
  "/tenants/:tenantId/invoices/:invoiceId/hosted-invoice-url": import("@withtyped/server").PathGuard<"/:tenantId/invoices/:invoiceId/hosted-invoice-url", unknown, unknown, {
250
729
  hostedInvoiceUrl: string;
251
730
  }>;
252
- } & {
253
- "/tenants/:tenantId/usage": import("@withtyped/server").PathGuard<"/:tenantId/usage", unknown, unknown, {
254
- activeUsers: number;
255
- cost: number;
256
- tokenUsage: number;
257
- }>;
258
731
  };
259
732
  post: {
260
733
  "/tenants/:tenantId/stripe-customer-portal": import("@withtyped/server").PathGuard<"/:tenantId/stripe-customer-portal", unknown, {
@@ -270,8 +743,8 @@ declare const router: import("@withtyped/server").Router<RequestContext, WithAut
270
743
  copy: {};
271
744
  head: {};
272
745
  }, "/api">>, import("@withtyped/server").RoutesWithPrefix<{
273
- options: {};
274
746
  patch: {};
747
+ options: {};
275
748
  get: {
276
749
  "/services/mails/usage": import("@withtyped/server").PathGuard<"/mails/usage", {
277
750
  from?: string | undefined;
@@ -282,122 +755,295 @@ declare const router: import("@withtyped/server").Router<RequestContext, WithAut
282
755
  post: {
283
756
  "/services/mails": import("@withtyped/server").PathGuard<"/mails", unknown, {
284
757
  data: {
285
- type: TemplateType | VerificationCodeType;
758
+ type: TemplateType;
286
759
  payload: {
287
- code?: string | undefined;
288
760
  link?: string | undefined;
761
+ code?: string | undefined;
762
+ locale?: string | undefined;
763
+ uiLocales?: string | undefined;
764
+ } & {
765
+ [k: string]: unknown;
766
+ } & {
289
767
  senderName?: string | undefined;
290
768
  companyInformation?: string | undefined;
291
769
  appLogo?: string | undefined;
770
+ } & {
771
+ organization?: {
772
+ id: string;
773
+ name: string;
774
+ branding: {
775
+ logoUrl?: string | undefined;
776
+ darkLogoUrl?: string | undefined;
777
+ favicon?: string | undefined;
778
+ darkFavicon?: string | undefined;
779
+ };
780
+ } | undefined;
781
+ inviter?: {
782
+ id: string;
783
+ name: string | null;
784
+ username: string | null;
785
+ primaryEmail: string | null;
786
+ primaryPhone: string | null;
787
+ avatar: string | null;
788
+ profile: Partial<{
789
+ familyName: string;
790
+ givenName: string;
791
+ middleName: string;
792
+ nickname: string;
793
+ preferredUsername: string;
794
+ profile: string;
795
+ website: string;
796
+ gender: string;
797
+ birthdate: string;
798
+ zoneinfo: string;
799
+ locale: string;
800
+ address: Partial<{
801
+ formatted: string;
802
+ streetAddress: string;
803
+ locality: string;
804
+ region: string;
805
+ postalCode: string;
806
+ country: string;
807
+ }>;
808
+ }>;
809
+ } | undefined;
292
810
  };
293
811
  to: string;
812
+ ip?: string | undefined;
294
813
  };
295
814
  }, unknown>;
296
815
  } & {
297
816
  "/services/send-sms": import("@withtyped/server").PathGuard<"/send-sms", unknown, {
298
817
  data: {
299
- type: TemplateType | VerificationCodeType;
818
+ type: TemplateType;
300
819
  to: string;
301
820
  payload: {
302
821
  code?: string | undefined;
303
822
  link?: string | undefined;
823
+ locale?: string | undefined;
824
+ uiLocales?: string | undefined;
825
+ } & {
826
+ [k: string]: unknown;
304
827
  };
828
+ ip?: string | undefined;
305
829
  };
306
830
  }, unknown>;
831
+ } & {
832
+ "/services/custom-jwt": import("@withtyped/server").PathGuard<"/custom-jwt", {
833
+ isTest?: string | undefined;
834
+ }, {
835
+ token: Record<string, Json>;
836
+ context: Record<string, Json>;
837
+ tokenType: LogtoJwtTokenKeyType.AccessToken;
838
+ script: string;
839
+ environmentVariables?: Record<string, string> | undefined;
840
+ } | {
841
+ token: Record<string, Json>;
842
+ tokenType: LogtoJwtTokenKeyType.ClientCredentials;
843
+ script: string;
844
+ environmentVariables?: Record<string, string> | undefined;
845
+ }, Record<string, unknown>>;
846
+ };
847
+ put: {
848
+ "/services/custom-jwt/worker": import("@withtyped/server").PathGuard<"/custom-jwt/worker", unknown, {
849
+ "jwt.accessToken"?: {
850
+ production?: string | undefined;
851
+ test?: string | undefined;
852
+ } | undefined;
853
+ "jwt.clientCredentials"?: {
854
+ production?: string | undefined;
855
+ test?: string | undefined;
856
+ } | undefined;
857
+ }, unknown>;
858
+ };
859
+ delete: {
860
+ "/services/custom-jwt/worker": import("@withtyped/server").PathGuard<"/custom-jwt/worker", unknown, unknown, unknown>;
307
861
  };
308
- put: {};
309
- delete: {};
310
862
  copy: {};
311
863
  head: {};
312
864
  }, "/api">>, import("@withtyped/server").RoutesWithPrefix<{
313
- options: {};
314
865
  patch: {};
866
+ options: {};
315
867
  get: {
316
- "/subscription-plans": import("@withtyped/server").PathGuard<"/", unknown, unknown, {
317
- createdAt: Date;
868
+ "/skus": import("@withtyped/server").PathGuard<"/", {
869
+ type?: LogtoSkuType | undefined;
870
+ }, unknown, {
318
871
  id: string;
319
- name: string;
872
+ name: string | null;
873
+ createdAt: Date;
874
+ defaultPriceId: string | null;
875
+ unitPrice: number | null;
876
+ type: LogtoSkuType;
320
877
  quota: {
321
- mauLimit: number | null;
322
- tokenLimit: number | null;
323
- applicationsLimit: number | null;
324
- machineToMachineLimit: number | null;
325
- resourcesLimit: number | null;
326
- scopesPerResourceLimit: number | null;
327
- customDomainEnabled: boolean;
328
- omniSignInEnabled: boolean;
329
- builtInEmailConnectorEnabled: boolean;
330
- socialConnectorsLimit: number | null;
331
- standardConnectorsLimit: number | null;
332
- rolesLimit: number | null;
333
- machineToMachineRolesLimit: number | null;
334
- scopesPerRoleLimit: number | null;
335
- hooksLimit: number | null;
336
- auditLogsRetentionDays: number | null;
337
- mfaEnabled: boolean;
338
- organizationsEnabled: boolean;
339
- ssoEnabled: boolean;
340
- thirdPartyApplicationsLimit: number | null;
878
+ auditLogsRetentionDays?: number | null | undefined;
879
+ subjectTokenEnabled?: boolean | undefined;
880
+ mauLimit?: number | null | undefined;
881
+ applicationsLimit?: number | null | undefined;
882
+ thirdPartyApplicationsLimit?: number | null | undefined;
883
+ scopesPerResourceLimit?: number | null | undefined;
884
+ socialConnectorsLimit?: number | null | undefined;
885
+ userRolesLimit?: number | null | undefined;
886
+ machineToMachineRolesLimit?: number | null | undefined;
887
+ scopesPerRoleLimit?: number | null | undefined;
888
+ hooksLimit?: number | null | undefined;
889
+ customJwtEnabled?: boolean | undefined;
890
+ bringYourUiEnabled?: boolean | undefined;
891
+ collectUserProfileEnabled?: boolean | undefined;
892
+ tokenLimit?: number | null | undefined;
893
+ machineToMachineLimit?: number | null | undefined;
894
+ resourcesLimit?: number | null | undefined;
895
+ enterpriseSsoLimit?: number | null | undefined;
896
+ tenantMembersLimit?: number | null | undefined;
897
+ mfaEnabled?: boolean | undefined;
898
+ organizationsEnabled?: boolean | undefined;
899
+ organizationsLimit?: number | null | undefined;
900
+ securityFeaturesEnabled?: boolean | undefined;
901
+ idpInitiatedSsoEnabled?: boolean | undefined;
902
+ samlApplicationsLimit?: number | null | undefined;
903
+ customDomainsLimit?: number | null | undefined;
341
904
  };
342
- stripeProducts: {
343
- type: "flat" | "tier1" | "tier2" | "tier3";
344
- id: string;
345
- name: string;
346
- price: {
347
- id: string;
348
- unitAmountDecimal: string;
349
- quantity?: 1 | undefined;
350
- unitAmount?: number | null | undefined;
351
- };
352
- description?: string | undefined;
353
- }[];
905
+ isDefault: boolean;
906
+ isDevPlan: boolean;
354
907
  updatedAt: Date;
908
+ productId: string | null;
355
909
  }[]>;
910
+ } & {
911
+ "/skus/:basicSkuId/usage-reporting-type": import("@withtyped/server").PathGuard<"/:basicSkuId/usage-reporting-type", unknown, unknown, {
912
+ basicSkuId: string;
913
+ usageReportingType: UsageReportingType | null;
914
+ }>;
356
915
  };
357
- post: {};
358
- put: {};
359
- delete: {};
360
- copy: {};
361
- head: {};
362
- }, "/api">>, import("@withtyped/server").RoutesWithPrefix<{
363
- options: {};
364
- patch: {};
365
- get: {
366
- "/my/tenant": import("@withtyped/server").PathGuard<"/tenant", unknown, unknown, {
367
- name: string;
916
+ post: {
917
+ "/skus": import("@withtyped/server").PathGuard<"/", unknown, {
918
+ type: LogtoSkuType;
919
+ quota: {
920
+ mauLimit?: number | null | undefined;
921
+ applicationsLimit?: number | null | undefined;
922
+ thirdPartyApplicationsLimit?: number | null | undefined;
923
+ scopesPerResourceLimit?: number | null | undefined;
924
+ socialConnectorsLimit?: number | null | undefined;
925
+ userRolesLimit?: number | null | undefined;
926
+ machineToMachineRolesLimit?: number | null | undefined;
927
+ scopesPerRoleLimit?: number | null | undefined;
928
+ hooksLimit?: number | null | undefined;
929
+ auditLogsRetentionDays?: number | null | undefined;
930
+ customJwtEnabled?: boolean | undefined;
931
+ subjectTokenEnabled?: boolean | undefined;
932
+ bringYourUiEnabled?: boolean | undefined;
933
+ collectUserProfileEnabled?: boolean | undefined;
934
+ tokenLimit?: number | null | undefined;
935
+ machineToMachineLimit?: number | null | undefined;
936
+ resourcesLimit?: number | null | undefined;
937
+ enterpriseSsoLimit?: number | null | undefined;
938
+ tenantMembersLimit?: number | null | undefined;
939
+ mfaEnabled?: boolean | undefined;
940
+ organizationsEnabled?: boolean | undefined;
941
+ organizationsLimit?: number | null | undefined;
942
+ securityFeaturesEnabled?: boolean | undefined;
943
+ idpInitiatedSsoEnabled?: boolean | undefined;
944
+ samlApplicationsLimit?: number | null | undefined;
945
+ customDomainsLimit?: number | null | undefined;
946
+ };
947
+ id?: string | undefined;
948
+ isDefault?: boolean | undefined;
949
+ isDevPlan?: boolean | undefined;
950
+ usageReportingType?: UsageReportingType | undefined;
951
+ }, {
952
+ createdAt: Date;
368
953
  id: string;
369
- indicator: string;
370
- isSuspended: boolean;
371
- tag: TenantTag;
954
+ type: LogtoSkuType;
955
+ isDefault: boolean;
956
+ isDevPlan: boolean;
957
+ updatedAt: Date;
958
+ quota: {
959
+ auditLogsRetentionDays?: number | null | undefined;
960
+ subjectTokenEnabled?: boolean | undefined;
961
+ mauLimit?: number | null | undefined;
962
+ applicationsLimit?: number | null | undefined;
963
+ thirdPartyApplicationsLimit?: number | null | undefined;
964
+ scopesPerResourceLimit?: number | null | undefined;
965
+ socialConnectorsLimit?: number | null | undefined;
966
+ userRolesLimit?: number | null | undefined;
967
+ machineToMachineRolesLimit?: number | null | undefined;
968
+ scopesPerRoleLimit?: number | null | undefined;
969
+ hooksLimit?: number | null | undefined;
970
+ customJwtEnabled?: boolean | undefined;
971
+ bringYourUiEnabled?: boolean | undefined;
972
+ collectUserProfileEnabled?: boolean | undefined;
973
+ tokenLimit?: number | null | undefined;
974
+ machineToMachineLimit?: number | null | undefined;
975
+ resourcesLimit?: number | null | undefined;
976
+ enterpriseSsoLimit?: number | null | undefined;
977
+ tenantMembersLimit?: number | null | undefined;
978
+ mfaEnabled?: boolean | undefined;
979
+ organizationsEnabled?: boolean | undefined;
980
+ organizationsLimit?: number | null | undefined;
981
+ securityFeaturesEnabled?: boolean | undefined;
982
+ idpInitiatedSsoEnabled?: boolean | undefined;
983
+ samlApplicationsLimit?: number | null | undefined;
984
+ customDomainsLimit?: number | null | undefined;
985
+ };
986
+ }>;
987
+ } & {
988
+ "/skus/:skuId/products": import("@withtyped/server").PathGuard<"/:skuId/products", {
989
+ isOneTime?: string | undefined;
990
+ }, {
991
+ name: string;
992
+ unitPrice: number;
993
+ }, {
994
+ productId: string;
995
+ }>;
996
+ } & {
997
+ "/skus/:basicSkuId/usage-add-on-relations": import("@withtyped/server").PathGuard<"/:basicSkuId/usage-add-on-relations", unknown, {
998
+ usageKey: "mauLimit" | "thirdPartyApplicationsLimit" | "userRolesLimit" | "machineToMachineRolesLimit" | "hooksLimit" | "tokenLimit" | "machineToMachineLimit" | "resourcesLimit" | "enterpriseSsoLimit" | "tenantMembersLimit" | "mfaEnabled" | "organizationsEnabled" | "organizationsLimit" | "securityFeaturesEnabled" | "samlApplicationsLimit" | "customDomainsLimit";
999
+ addOnSkuId: string;
1000
+ }, {
1001
+ usageKey: "mauLimit" | "thirdPartyApplicationsLimit" | "userRolesLimit" | "machineToMachineRolesLimit" | "hooksLimit" | "tokenLimit" | "machineToMachineLimit" | "resourcesLimit" | "enterpriseSsoLimit" | "tenantMembersLimit" | "mfaEnabled" | "organizationsEnabled" | "organizationsLimit" | "securityFeaturesEnabled" | "samlApplicationsLimit" | "customDomainsLimit";
1002
+ basicSkuId: string;
1003
+ addOnSkuId: string;
372
1004
  }>;
373
1005
  };
374
- post: {};
375
- put: {};
376
- delete: {};
1006
+ put: {
1007
+ "/skus/:basicSkuId/usage-reporting-type": import("@withtyped/server").PathGuard<"/:basicSkuId/usage-reporting-type", unknown, {
1008
+ usageReportingType: UsageReportingType;
1009
+ }, {
1010
+ basicSkuId: string;
1011
+ usageReportingType: UsageReportingType;
1012
+ }>;
1013
+ };
1014
+ delete: {
1015
+ "/skus/:skuId": import("@withtyped/server").PathGuard<"/:skuId", unknown, unknown, unknown>;
1016
+ } & {
1017
+ "/skus/:basicSkuId/usage-add-on-relations/:usageKey": import("@withtyped/server").PathGuard<"/:basicSkuId/usage-add-on-relations/:usageKey", unknown, unknown, unknown>;
1018
+ } & {
1019
+ "/skus/:basicSkuId/usage-reporting-type": import("@withtyped/server").PathGuard<"/:basicSkuId/usage-reporting-type", unknown, unknown, unknown>;
1020
+ };
377
1021
  copy: {};
378
1022
  head: {};
379
1023
  }, "/api">>, import("@withtyped/server").RoutesWithPrefix<{
380
- options: {};
381
1024
  patch: {};
1025
+ options: {};
382
1026
  get: {
383
1027
  "/checkout-session/:id": import("@withtyped/server").PathGuard<"/:id", unknown, unknown, {
384
- status: "open" | "complete" | "expired";
1028
+ tenantId: string | null;
385
1029
  createdAt: Date;
386
1030
  id: string;
387
- userId: string;
1031
+ status: "open" | "complete" | "expired";
388
1032
  updatedAt: Date;
389
- tenantId: string | null;
390
- planId: string;
1033
+ planId: string | null;
1034
+ skuId: string | null;
1035
+ userId: string;
391
1036
  }>;
392
1037
  };
393
1038
  post: {
394
1039
  "/checkout-session": import("@withtyped/server").PathGuard<"/", unknown, {
395
- planId: string;
396
1040
  successCallbackUrl: string;
397
1041
  tenantId?: string | undefined;
398
- cancelCallbackUrl?: string | undefined;
1042
+ skuId?: string | undefined;
399
1043
  tenantTag?: TenantTag | undefined;
400
1044
  tenantName?: string | undefined;
1045
+ tenantRegionName?: string | undefined;
1046
+ cancelCallbackUrl?: string | undefined;
401
1047
  }, {
402
1048
  sessionId: string;
403
1049
  redirectUri?: string | null | undefined;
@@ -408,89 +1054,480 @@ declare const router: import("@withtyped/server").Router<RequestContext, WithAut
408
1054
  copy: {};
409
1055
  head: {};
410
1056
  }, "/api">>, import("@withtyped/server").RoutesWithPrefix<{
1057
+ patch: {
1058
+ "/invitations/:invitationId/status": import("@withtyped/server").PathGuard<"/:invitationId/status", unknown, {
1059
+ status: OrganizationInvitationStatus.Accepted;
1060
+ }, unknown>;
1061
+ };
411
1062
  options: {};
412
- patch: {};
413
1063
  get: {
414
- "/affiliates": import("@withtyped/server").PathGuard<"/", unknown, unknown, AffiliateData[]>;
1064
+ "/invitations": import("@withtyped/server").PathGuard<"/", unknown, unknown, ({
1065
+ tenantId: string;
1066
+ createdAt: number;
1067
+ id: string;
1068
+ status: OrganizationInvitationStatus;
1069
+ updatedAt: number;
1070
+ inviterId: string | null;
1071
+ invitee: string;
1072
+ acceptedUserId: string | null;
1073
+ organizationId: string;
1074
+ expiresAt: number;
1075
+ organizationRoles: OrganizationRoleEntity[];
1076
+ } & {
1077
+ tenantTag: TenantTag;
1078
+ tenantName: string;
1079
+ })[]>;
1080
+ } & {
1081
+ "/invitations/:invitationId": import("@withtyped/server").PathGuard<"/:invitationId", unknown, unknown, {
1082
+ tenantId: string;
1083
+ createdAt: number;
1084
+ id: string;
1085
+ status: OrganizationInvitationStatus;
1086
+ updatedAt: number;
1087
+ inviterId: string | null;
1088
+ invitee: string;
1089
+ acceptedUserId: string | null;
1090
+ organizationId: string;
1091
+ expiresAt: number;
1092
+ organizationRoles: OrganizationRoleEntity[];
1093
+ }>;
415
1094
  };
416
- post: {
417
- "/affiliates": import("@withtyped/server").PathGuard<"/", unknown, {
418
- name: string;
1095
+ post: {};
1096
+ put: {};
1097
+ delete: {};
1098
+ copy: {};
1099
+ head: {};
1100
+ }, "/api">>, import("@withtyped/server").RoutesWithPrefix<{
1101
+ patch: {
1102
+ "/system-limits/:id": import("@withtyped/server").PathGuard<"/:id", unknown, {
1103
+ limits: {
1104
+ applicationsLimit?: number | undefined;
1105
+ thirdPartyApplicationsLimit?: number | undefined;
1106
+ scopesPerResourceLimit?: number | undefined;
1107
+ socialConnectorsLimit?: number | undefined;
1108
+ userRolesLimit?: number | undefined;
1109
+ machineToMachineRolesLimit?: number | undefined;
1110
+ scopesPerRoleLimit?: number | undefined;
1111
+ hooksLimit?: number | undefined;
1112
+ machineToMachineLimit?: number | undefined;
1113
+ resourcesLimit?: number | undefined;
1114
+ enterpriseSsoLimit?: number | undefined;
1115
+ tenantMembersLimit?: number | undefined;
1116
+ organizationsLimit?: number | undefined;
1117
+ samlApplicationsLimit?: number | undefined;
1118
+ customDomainsLimit?: number | undefined;
1119
+ usersPerOrganizationLimit?: number | undefined;
1120
+ organizationUserRolesLimit?: number | undefined;
1121
+ organizationMachineToMachineRolesLimit?: number | undefined;
1122
+ organizationScopesLimit?: number | undefined;
1123
+ };
419
1124
  }, {
420
1125
  createdAt: Date;
421
1126
  id: string;
422
- name: string;
1127
+ updatedAt: Date;
1128
+ limits: {
1129
+ applicationsLimit?: number | undefined;
1130
+ thirdPartyApplicationsLimit?: number | undefined;
1131
+ scopesPerResourceLimit?: number | undefined;
1132
+ socialConnectorsLimit?: number | undefined;
1133
+ userRolesLimit?: number | undefined;
1134
+ machineToMachineRolesLimit?: number | undefined;
1135
+ scopesPerRoleLimit?: number | undefined;
1136
+ hooksLimit?: number | undefined;
1137
+ machineToMachineLimit?: number | undefined;
1138
+ resourcesLimit?: number | undefined;
1139
+ enterpriseSsoLimit?: number | undefined;
1140
+ tenantMembersLimit?: number | undefined;
1141
+ organizationsLimit?: number | undefined;
1142
+ samlApplicationsLimit?: number | undefined;
1143
+ customDomainsLimit?: number | undefined;
1144
+ usersPerOrganizationLimit?: number | undefined;
1145
+ organizationUserRolesLimit?: number | undefined;
1146
+ organizationMachineToMachineRolesLimit?: number | undefined;
1147
+ organizationScopesLimit?: number | undefined;
1148
+ };
423
1149
  }>;
1150
+ };
1151
+ options: {};
1152
+ get: {
1153
+ "/system-limits": import("@withtyped/server").PathGuard<"/", {
1154
+ basicSkuId?: string | undefined;
1155
+ }, unknown, {
1156
+ createdAt: Date;
1157
+ id: string;
1158
+ updatedAt: Date;
1159
+ limits: {
1160
+ applicationsLimit?: number | undefined;
1161
+ thirdPartyApplicationsLimit?: number | undefined;
1162
+ scopesPerResourceLimit?: number | undefined;
1163
+ socialConnectorsLimit?: number | undefined;
1164
+ userRolesLimit?: number | undefined;
1165
+ machineToMachineRolesLimit?: number | undefined;
1166
+ scopesPerRoleLimit?: number | undefined;
1167
+ hooksLimit?: number | undefined;
1168
+ machineToMachineLimit?: number | undefined;
1169
+ resourcesLimit?: number | undefined;
1170
+ enterpriseSsoLimit?: number | undefined;
1171
+ tenantMembersLimit?: number | undefined;
1172
+ organizationsLimit?: number | undefined;
1173
+ samlApplicationsLimit?: number | undefined;
1174
+ customDomainsLimit?: number | undefined;
1175
+ usersPerOrganizationLimit?: number | undefined;
1176
+ organizationUserRolesLimit?: number | undefined;
1177
+ organizationMachineToMachineRolesLimit?: number | undefined;
1178
+ organizationScopesLimit?: number | undefined;
1179
+ };
1180
+ basicSkuIds: string[];
1181
+ }[]>;
424
1182
  } & {
425
- "/affiliates/:id/properties": import("@withtyped/server").PathGuard<"/:id/properties", unknown, {
426
- value: string;
427
- type: "hostname" | "query";
1183
+ "/system-limits/:id": import("@withtyped/server").PathGuard<"/:id", unknown, unknown, {
1184
+ createdAt: Date;
1185
+ id: string;
1186
+ updatedAt: Date;
1187
+ limits: {
1188
+ applicationsLimit?: number | undefined;
1189
+ thirdPartyApplicationsLimit?: number | undefined;
1190
+ scopesPerResourceLimit?: number | undefined;
1191
+ socialConnectorsLimit?: number | undefined;
1192
+ userRolesLimit?: number | undefined;
1193
+ machineToMachineRolesLimit?: number | undefined;
1194
+ scopesPerRoleLimit?: number | undefined;
1195
+ hooksLimit?: number | undefined;
1196
+ machineToMachineLimit?: number | undefined;
1197
+ resourcesLimit?: number | undefined;
1198
+ enterpriseSsoLimit?: number | undefined;
1199
+ tenantMembersLimit?: number | undefined;
1200
+ organizationsLimit?: number | undefined;
1201
+ samlApplicationsLimit?: number | undefined;
1202
+ customDomainsLimit?: number | undefined;
1203
+ usersPerOrganizationLimit?: number | undefined;
1204
+ organizationUserRolesLimit?: number | undefined;
1205
+ organizationMachineToMachineRolesLimit?: number | undefined;
1206
+ organizationScopesLimit?: number | undefined;
1207
+ };
1208
+ basicSkuIds: string[];
1209
+ }>;
1210
+ };
1211
+ post: {
1212
+ "/system-limits": import("@withtyped/server").PathGuard<"/", unknown, {
1213
+ limits: {
1214
+ applicationsLimit?: number | undefined;
1215
+ thirdPartyApplicationsLimit?: number | undefined;
1216
+ scopesPerResourceLimit?: number | undefined;
1217
+ socialConnectorsLimit?: number | undefined;
1218
+ userRolesLimit?: number | undefined;
1219
+ machineToMachineRolesLimit?: number | undefined;
1220
+ scopesPerRoleLimit?: number | undefined;
1221
+ hooksLimit?: number | undefined;
1222
+ machineToMachineLimit?: number | undefined;
1223
+ resourcesLimit?: number | undefined;
1224
+ enterpriseSsoLimit?: number | undefined;
1225
+ tenantMembersLimit?: number | undefined;
1226
+ organizationsLimit?: number | undefined;
1227
+ samlApplicationsLimit?: number | undefined;
1228
+ customDomainsLimit?: number | undefined;
1229
+ usersPerOrganizationLimit?: number | undefined;
1230
+ organizationUserRolesLimit?: number | undefined;
1231
+ organizationMachineToMachineRolesLimit?: number | undefined;
1232
+ organizationScopesLimit?: number | undefined;
1233
+ };
1234
+ id?: string | undefined;
428
1235
  }, {
429
- value: string;
430
- type: "hostname" | "query";
431
1236
  createdAt: Date;
432
- affiliateId: string;
1237
+ id: string;
1238
+ updatedAt: Date;
1239
+ limits: {
1240
+ applicationsLimit?: number | undefined;
1241
+ thirdPartyApplicationsLimit?: number | undefined;
1242
+ scopesPerResourceLimit?: number | undefined;
1243
+ socialConnectorsLimit?: number | undefined;
1244
+ userRolesLimit?: number | undefined;
1245
+ machineToMachineRolesLimit?: number | undefined;
1246
+ scopesPerRoleLimit?: number | undefined;
1247
+ hooksLimit?: number | undefined;
1248
+ machineToMachineLimit?: number | undefined;
1249
+ resourcesLimit?: number | undefined;
1250
+ enterpriseSsoLimit?: number | undefined;
1251
+ tenantMembersLimit?: number | undefined;
1252
+ organizationsLimit?: number | undefined;
1253
+ samlApplicationsLimit?: number | undefined;
1254
+ customDomainsLimit?: number | undefined;
1255
+ usersPerOrganizationLimit?: number | undefined;
1256
+ organizationUserRolesLimit?: number | undefined;
1257
+ organizationMachineToMachineRolesLimit?: number | undefined;
1258
+ organizationScopesLimit?: number | undefined;
1259
+ };
1260
+ }>;
1261
+ } & {
1262
+ "/system-limits/:systemLimitId/basic-sku-relations": import("@withtyped/server").PathGuard<"/:systemLimitId/basic-sku-relations", unknown, {
1263
+ basicSkuIds: string[];
1264
+ }, {
1265
+ relations: {
1266
+ createdAt: Date;
1267
+ updatedAt: Date;
1268
+ basicSkuId: string;
1269
+ systemLimitId: string;
1270
+ }[];
433
1271
  }>;
434
1272
  };
435
1273
  put: {};
436
1274
  delete: {
437
- "/affiliates/:id/properties": import("@withtyped/server").PathGuard<"/:id/properties", unknown, {
438
- value: string;
439
- type: "hostname" | "query";
1275
+ "/system-limits/:id": import("@withtyped/server").PathGuard<"/:id", unknown, unknown, unknown>;
1276
+ } & {
1277
+ "/system-limits/:systemLimitId/basic-sku-relations": import("@withtyped/server").PathGuard<"/:systemLimitId/basic-sku-relations", unknown, {
1278
+ basicSkuIds: string[];
440
1279
  }, unknown>;
441
1280
  };
442
1281
  copy: {};
443
1282
  head: {};
444
1283
  }, "/api">>, import("@withtyped/server").RoutesWithPrefix<{
445
- options: {};
446
1284
  patch: {};
1285
+ options: {};
447
1286
  get: {};
1287
+ post: {};
1288
+ put: {};
1289
+ delete: {
1290
+ "/me": import("@withtyped/server").PathGuard<"/", unknown, unknown, unknown>;
1291
+ };
1292
+ copy: {};
1293
+ head: {};
1294
+ }, "/api">>, import("@withtyped/server").RoutesWithPrefix<{
1295
+ patch: {
1296
+ "/me/regions/:regionName/users/:userId": import("@withtyped/server").PathGuard<"/:regionName/users/:userId", unknown, {
1297
+ role: DatabaseRegionAccessRole;
1298
+ }, {
1299
+ role: DatabaseRegionAccessRole;
1300
+ userId: string;
1301
+ }>;
1302
+ };
1303
+ options: {};
1304
+ get: {
1305
+ "/me/regions": import("@withtyped/server").PathGuard<"/", unknown, unknown, {
1306
+ regions: {
1307
+ id: string;
1308
+ name: string;
1309
+ country: string;
1310
+ displayName: string;
1311
+ tags: TenantTag[];
1312
+ isPrivate: boolean;
1313
+ }[];
1314
+ }>;
1315
+ } & {
1316
+ "/me/regions/:regionName/users": import("@withtyped/server").PathGuard<"/:regionName/users", unknown, unknown, {
1317
+ users: {
1318
+ role: DatabaseRegionAccessRole;
1319
+ userId: string;
1320
+ }[];
1321
+ }>;
1322
+ };
448
1323
  post: {
449
- "/affiliate-logs": import("@withtyped/server").PathGuard<"/", unknown, {
450
- createdAt: string;
1324
+ "/me/regions/:regionName/users": import("@withtyped/server").PathGuard<"/:regionName/users", unknown, {
1325
+ role: DatabaseRegionAccessRole;
451
1326
  userId: string;
452
- hostname?: string | undefined;
453
- query?: string | undefined;
454
1327
  }, {
455
- createdAt: Date;
456
- id: string;
457
- affiliateId: string | null;
1328
+ role: DatabaseRegionAccessRole;
458
1329
  userId: string;
459
- createdVia: {
460
- createdAt: string;
461
- hostname?: string | undefined;
462
- query?: string | undefined;
463
- };
464
1330
  }>;
465
1331
  };
466
1332
  put: {};
467
- delete: {};
1333
+ delete: {
1334
+ "/me/regions/:regionName/users/:userId": import("@withtyped/server").PathGuard<"/:regionName/users/:userId", unknown, unknown, unknown>;
1335
+ };
468
1336
  copy: {};
469
1337
  head: {};
470
1338
  }, "/api">>, import("@withtyped/server").RoutesWithPrefix<{
471
- options: {};
472
1339
  patch: {};
473
- get: {};
474
- post: {};
475
- put: {};
476
- delete: {
477
- "/logs/expired": import("@withtyped/server").PathGuard<"/expired", {
478
- dryRun?: string | undefined;
1340
+ options: {};
1341
+ get: {
1342
+ "/me/logto-enterprises": import("@withtyped/server").PathGuard<"/", unknown, unknown, {
1343
+ logtoEnterprises: {
1344
+ createdAt: Date;
1345
+ id: string;
1346
+ name: string | null;
1347
+ updatedAt: Date;
1348
+ quotaScope: QuotaScope;
1349
+ }[];
1350
+ }>;
1351
+ } & {
1352
+ "/me/logto-enterprises/:id": import("@withtyped/server").PathGuard<"/:id", {
1353
+ includeSharedQuota?: string | undefined;
1354
+ includeUsages?: string | undefined;
1355
+ includeSkuItems?: string | undefined;
479
1356
  }, unknown, {
480
- affectedRows: number;
1357
+ createdAt: Date;
1358
+ id: string;
1359
+ name: string | null;
1360
+ updatedAt: Date;
1361
+ regionNames: string[];
1362
+ quotaScope: QuotaScope;
1363
+ quota?: {
1364
+ usageReportingType: UsageReportingType;
1365
+ basicQuota: {
1366
+ auditLogsRetentionDays: number | null;
1367
+ subjectTokenEnabled: boolean;
1368
+ mauLimit: number | null;
1369
+ applicationsLimit: number | null;
1370
+ thirdPartyApplicationsLimit: number | null;
1371
+ scopesPerResourceLimit: number | null;
1372
+ socialConnectorsLimit: number | null;
1373
+ userRolesLimit: number | null;
1374
+ machineToMachineRolesLimit: number | null;
1375
+ scopesPerRoleLimit: number | null;
1376
+ hooksLimit: number | null;
1377
+ customJwtEnabled: boolean;
1378
+ bringYourUiEnabled: boolean;
1379
+ collectUserProfileEnabled: boolean;
1380
+ tokenLimit: number | null;
1381
+ machineToMachineLimit: number | null;
1382
+ resourcesLimit: number | null;
1383
+ enterpriseSsoLimit: number | null;
1384
+ tenantMembersLimit: number | null;
1385
+ mfaEnabled: boolean;
1386
+ organizationsEnabled: boolean;
1387
+ organizationsLimit: number | null;
1388
+ securityFeaturesEnabled: boolean;
1389
+ idpInitiatedSsoEnabled: boolean;
1390
+ samlApplicationsLimit: number | null;
1391
+ customDomainsLimit: number | null;
1392
+ };
1393
+ aggregatedQuota: {
1394
+ auditLogsRetentionDays: number | null;
1395
+ subjectTokenEnabled: boolean;
1396
+ mauLimit: number | null;
1397
+ applicationsLimit: number | null;
1398
+ thirdPartyApplicationsLimit: number | null;
1399
+ scopesPerResourceLimit: number | null;
1400
+ socialConnectorsLimit: number | null;
1401
+ userRolesLimit: number | null;
1402
+ machineToMachineRolesLimit: number | null;
1403
+ scopesPerRoleLimit: number | null;
1404
+ hooksLimit: number | null;
1405
+ customJwtEnabled: boolean;
1406
+ bringYourUiEnabled: boolean;
1407
+ collectUserProfileEnabled: boolean;
1408
+ tokenLimit: number | null;
1409
+ machineToMachineLimit: number | null;
1410
+ resourcesLimit: number | null;
1411
+ enterpriseSsoLimit: number | null;
1412
+ tenantMembersLimit: number | null;
1413
+ mfaEnabled: boolean;
1414
+ organizationsEnabled: boolean;
1415
+ organizationsLimit: number | null;
1416
+ securityFeaturesEnabled: boolean;
1417
+ idpInitiatedSsoEnabled: boolean;
1418
+ samlApplicationsLimit: number | null;
1419
+ customDomainsLimit: number | null;
1420
+ };
1421
+ } | undefined;
1422
+ subscription?: {
1423
+ status: "incomplete" | "incomplete_expired" | "trialing" | "active" | "past_due" | "canceled" | "unpaid" | "paused";
1424
+ currentPeriodStart: Date;
1425
+ currentPeriodEnd: Date;
1426
+ quotaScope: "dedicated" | "shared";
1427
+ isEnterprisePlan: boolean;
1428
+ id?: string | undefined;
1429
+ upcomingInvoice?: {
1430
+ subtotal: number;
1431
+ subtotalExcludingTax: number | null;
1432
+ total: number;
1433
+ totalExcludingTax: number | null;
1434
+ } | null | undefined;
1435
+ } | undefined;
1436
+ usages?: {
1437
+ mauLimit: number;
1438
+ applicationsLimit: number;
1439
+ thirdPartyApplicationsLimit: number;
1440
+ socialConnectorsLimit: number;
1441
+ userRolesLimit: number;
1442
+ machineToMachineRolesLimit: number;
1443
+ hooksLimit: number;
1444
+ customJwtEnabled: boolean;
1445
+ bringYourUiEnabled: boolean;
1446
+ collectUserProfileEnabled: boolean;
1447
+ tokenLimit: number;
1448
+ machineToMachineLimit: number;
1449
+ resourcesLimit: number;
1450
+ enterpriseSsoLimit: number;
1451
+ tenantMembersLimit: number;
1452
+ mfaEnabled: boolean;
1453
+ organizationsEnabled: boolean;
1454
+ organizationsLimit: number;
1455
+ securityFeaturesEnabled: boolean;
1456
+ idpInitiatedSsoEnabled: boolean;
1457
+ samlApplicationsLimit: number;
1458
+ customDomainsLimit: number;
1459
+ userTokenLimit: number;
1460
+ m2mTokenLimit: number;
1461
+ } | undefined;
1462
+ subscriptionSkuItems?: {
1463
+ count: number;
1464
+ logtoSkuId: string;
1465
+ type: LogtoSkuType;
1466
+ isDevPlan: boolean;
1467
+ quota: {
1468
+ auditLogsRetentionDays?: number | null | undefined;
1469
+ subjectTokenEnabled?: boolean | undefined;
1470
+ mauLimit?: number | null | undefined;
1471
+ applicationsLimit?: number | null | undefined;
1472
+ thirdPartyApplicationsLimit?: number | null | undefined;
1473
+ scopesPerResourceLimit?: number | null | undefined;
1474
+ socialConnectorsLimit?: number | null | undefined;
1475
+ userRolesLimit?: number | null | undefined;
1476
+ machineToMachineRolesLimit?: number | null | undefined;
1477
+ scopesPerRoleLimit?: number | null | undefined;
1478
+ hooksLimit?: number | null | undefined;
1479
+ customJwtEnabled?: boolean | undefined;
1480
+ bringYourUiEnabled?: boolean | undefined;
1481
+ collectUserProfileEnabled?: boolean | undefined;
1482
+ tokenLimit?: number | null | undefined;
1483
+ machineToMachineLimit?: number | null | undefined;
1484
+ resourcesLimit?: number | null | undefined;
1485
+ enterpriseSsoLimit?: number | null | undefined;
1486
+ tenantMembersLimit?: number | null | undefined;
1487
+ mfaEnabled?: boolean | undefined;
1488
+ organizationsEnabled?: boolean | undefined;
1489
+ organizationsLimit?: number | null | undefined;
1490
+ securityFeaturesEnabled?: boolean | undefined;
1491
+ idpInitiatedSsoEnabled?: boolean | undefined;
1492
+ samlApplicationsLimit?: number | null | undefined;
1493
+ customDomainsLimit?: number | null | undefined;
1494
+ };
1495
+ unitPrice?: number | null | undefined;
1496
+ }[] | undefined;
1497
+ }>;
1498
+ } & {
1499
+ "/me/logto-enterprises/:id/invoices": import("@withtyped/server").PathGuard<"/:id/invoices", unknown, unknown, {
1500
+ invoices: {
1501
+ createdAt: Date;
1502
+ id: string;
1503
+ status: "open" | "void" | "draft" | "paid" | "uncollectible" | null;
1504
+ updatedAt: Date;
1505
+ customerId: string | null;
1506
+ basicSkuId: string | null;
1507
+ billingReason: string | null;
1508
+ periodStart: Date;
1509
+ periodEnd: Date;
1510
+ amountDue: number;
1511
+ amountPaid: number;
1512
+ subscriptionId: string | null;
1513
+ hostedInvoiceUrl: string | null;
1514
+ invoicePdf: string | null;
1515
+ collectionMethod: "charge_automatically" | "send_invoice" | null;
1516
+ dueDate: Date | null;
1517
+ }[];
1518
+ }>;
1519
+ } & {
1520
+ "/me/logto-enterprises/:enterpriseId/invoices/:invoiceId/hosted-invoice-url": import("@withtyped/server").PathGuard<"/:enterpriseId/invoices/:invoiceId/hosted-invoice-url", unknown, unknown, {
1521
+ hostedInvoiceUrl: string;
481
1522
  }>;
482
1523
  };
483
- copy: {};
484
- head: {};
485
- }, "/api">>, import("@withtyped/server").RoutesWithPrefix<{
486
- options: {};
487
- patch: {
488
- "/invitations/:invitationId/status": import("@withtyped/server").PathGuard<"/:invitationId/status", unknown, {
489
- status: OrganizationInvitationStatus.Accepted;
490
- }, unknown>;
1524
+ post: {
1525
+ "/me/logto-enterprises/:id/stripe-customer-portal": import("@withtyped/server").PathGuard<"/:id/stripe-customer-portal", unknown, {
1526
+ callbackUrl?: string | undefined;
1527
+ }, {
1528
+ redirectUri: string;
1529
+ }>;
491
1530
  };
492
- get: {};
493
- post: {};
494
1531
  put: {};
495
1532
  delete: {};
496
1533
  copy: {};
@@ -498,30 +1535,31 @@ declare const router: import("@withtyped/server").Router<RequestContext, WithAut
498
1535
  }, "/api">>, "/api">;
499
1536
  export declare const tenantAuthRouter: import("@withtyped/server").Router<RequestContext, import("@withtyped/server").WithBodyContext<import("@withtyped/server").BaseContext & {
500
1537
  request: {
1538
+ id?: string | undefined;
501
1539
  method?: import("@withtyped/server").RequestMethod | undefined;
502
1540
  headers: import("http").IncomingHttpHeaders;
503
1541
  url: URL;
504
1542
  body?: unknown;
505
1543
  };
506
1544
  }>, import("@withtyped/server").MergeRoutes<import("@withtyped/server").BaseRoutes, import("@withtyped/server").RoutesWithPrefix<{
507
- options: {};
508
1545
  patch: {
509
1546
  "/:tenantId/invitations/:invitationId/status": import("@withtyped/server").PathGuard<"/:tenantId/invitations/:invitationId/status", unknown, {
510
1547
  status: OrganizationInvitationStatus.Revoked;
511
1548
  }, {
512
- status: OrganizationInvitationStatus;
1549
+ tenantId: string;
513
1550
  createdAt: number;
514
1551
  id: string;
1552
+ status: OrganizationInvitationStatus;
515
1553
  updatedAt: number;
516
- tenantId: string;
517
- organizationId: string;
518
1554
  inviterId: string | null;
519
- expiresAt: number;
520
- organizationRoles: OrganizationRoleEntity[];
521
1555
  invitee: string;
522
1556
  acceptedUserId: string | null;
1557
+ organizationId: string;
1558
+ expiresAt: number;
1559
+ organizationRoles: OrganizationRoleEntity[];
523
1560
  }>;
524
1561
  };
1562
+ options: {};
525
1563
  get: {
526
1564
  "/:tenantId/members": import("@withtyped/server").PathGuard<"/:tenantId/members", unknown, unknown, {
527
1565
  id: string;
@@ -533,38 +1571,54 @@ export declare const tenantAuthRouter: import("@withtyped/server").Router<Reques
533
1571
  organizationRoles: OrganizationRoleEntity[];
534
1572
  }[]>;
535
1573
  } & {
536
- "/:tenantId/invitations": import("@withtyped/server").PathGuard<"/:tenantId/invitations", unknown, unknown, {
537
- status: OrganizationInvitationStatus;
1574
+ "/:tenantId/members/:userId/scopes": import("@withtyped/server").PathGuard<"/:tenantId/members/:userId/scopes", unknown, unknown, OrganizationScope[]>;
1575
+ } & {
1576
+ "/:tenantId/invitations": import("@withtyped/server").PathGuard<"/:tenantId/invitations", unknown, unknown, ({
1577
+ tenantId: string;
538
1578
  createdAt: number;
539
1579
  id: string;
1580
+ status: OrganizationInvitationStatus;
540
1581
  updatedAt: number;
541
- tenantId: string;
542
- organizationId: string;
543
1582
  inviterId: string | null;
544
- expiresAt: number;
545
- organizationRoles: OrganizationRoleEntity[];
546
1583
  invitee: string;
547
1584
  acceptedUserId: string | null;
548
- }[]>;
1585
+ organizationId: string;
1586
+ expiresAt: number;
1587
+ organizationRoles: OrganizationRoleEntity[];
1588
+ } & {
1589
+ inviterName?: string | undefined;
1590
+ })[]>;
549
1591
  };
550
1592
  post: {
551
1593
  "/:tenantId/invitations": import("@withtyped/server").PathGuard<"/:tenantId/invitations", unknown, {
1594
+ invitee: string | string[];
552
1595
  roleName: TenantRole;
553
- invitee: string;
554
1596
  expiresAt?: number | undefined;
555
1597
  }, {
556
- status: OrganizationInvitationStatus;
1598
+ tenantId: string;
557
1599
  createdAt: number;
558
1600
  id: string;
1601
+ status: OrganizationInvitationStatus;
559
1602
  updatedAt: number;
560
- tenantId: string;
561
- organizationId: string;
562
1603
  inviterId: string | null;
1604
+ invitee: string;
1605
+ acceptedUserId: string | null;
1606
+ organizationId: string;
563
1607
  expiresAt: number;
564
1608
  organizationRoles: OrganizationRoleEntity[];
1609
+ } | {
1610
+ tenantId: string;
1611
+ createdAt: number;
1612
+ id: string;
1613
+ status: OrganizationInvitationStatus;
1614
+ updatedAt: number;
1615
+ inviterId: string | null;
565
1616
  invitee: string;
566
1617
  acceptedUserId: string | null;
567
- }>;
1618
+ organizationId: string;
1619
+ expiresAt: number;
1620
+ organizationRoles: OrganizationRoleEntity[];
1621
+ }[]>;
568
1622
  } & {
569
1623
  "/:tenantId/invitations/:invitationId/message": import("@withtyped/server").PathGuard<"/:tenantId/invitations/:invitationId/message", unknown, unknown, unknown>;
570
1624
  };