pgbeam 0.1.0 → 0.2.0

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.
@@ -2,224 +2,280 @@
2
2
  * Generated by Kubb (https://kubb.dev/).
3
3
  * Do not edit manually.
4
4
  */
5
+ /**
6
+ * @description Full account data export for privacy and data-portability requests.
7
+ */
5
8
  type AccountExport = {
6
9
  /**
10
+ * @description Core user profile data.
7
11
  * @type object
8
12
  */
9
13
  user: {
10
14
  /**
15
+ * @description User identifier.
11
16
  * @type string
12
17
  */
13
18
  id: string;
14
19
  /**
20
+ * @description Display name for the user.
15
21
  * @type string
16
22
  */
17
23
  name: string;
18
24
  /**
25
+ * @description Primary account email address.
19
26
  * @type string, email
20
27
  */
21
28
  email: string;
22
29
  /**
30
+ * @description Whether the email address has been verified.
23
31
  * @type boolean
24
32
  */
25
33
  email_verified: boolean;
26
34
  /**
35
+ * @description Avatar image URL, if present.
27
36
  * @type string | undefined
28
37
  */
29
38
  image?: string;
30
39
  /**
40
+ * @description When the user account was created.
31
41
  * @type string, date-time
32
42
  */
33
43
  created_at: string;
34
44
  /**
45
+ * @description When the user profile was last updated.
35
46
  * @type string, date-time
36
47
  */
37
48
  updated_at: string;
38
49
  };
39
50
  /**
51
+ * @description Organizations the user belongs to.
40
52
  * @type array
41
53
  */
42
54
  organizations: {
43
55
  /**
56
+ * @description Organization identifier.
44
57
  * @type string
45
58
  */
46
59
  id: string;
47
60
  /**
61
+ * @description Organization display name.
48
62
  * @type string
49
63
  */
50
64
  name: string;
51
65
  /**
66
+ * @description Organization slug used in URLs and routing.
52
67
  * @type string
53
68
  */
54
69
  slug: string;
55
70
  /**
71
+ * @description User role within the organization.
56
72
  * @type string
57
73
  */
58
74
  role: string;
59
75
  /**
76
+ * @description When the organization membership was created.
60
77
  * @type string, date-time
61
78
  */
62
79
  created_at: string;
63
80
  }[];
64
81
  /**
82
+ * @description Projects owned through the user\'s organizations.
65
83
  * @type array
66
84
  */
67
85
  projects: {
68
86
  /**
87
+ * @description Project identifier.
69
88
  * @type string
70
89
  */
71
90
  id: string;
72
91
  /**
92
+ * @description Owning organization identifier.
73
93
  * @type string
74
94
  */
75
95
  org_id: string;
76
96
  /**
97
+ * @description Project display name.
77
98
  * @type string
78
99
  */
79
100
  name: string;
80
101
  /**
102
+ * @description Project description at export time.
81
103
  * @type string
82
104
  */
83
105
  description: string;
84
106
  /**
107
+ * @description Project lifecycle status.
85
108
  * @type string
86
109
  */
87
110
  status: string;
88
111
  /**
112
+ * @description When the project was created.
89
113
  * @type string, date-time
90
114
  */
91
115
  created_at: string;
92
116
  }[];
93
117
  /**
118
+ * @description Databases registered under the exported projects.
94
119
  * @type array
95
120
  */
96
121
  databases: {
97
122
  /**
123
+ * @description Database identifier.
98
124
  * @type string
99
125
  */
100
126
  id: string;
101
127
  /**
128
+ * @description Owning project identifier.
102
129
  * @type string
103
130
  */
104
131
  project_id: string;
105
132
  /**
133
+ * @description Upstream PostgreSQL host.
106
134
  * @type string
107
135
  */
108
136
  host: string;
109
137
  /**
138
+ * @description Upstream PostgreSQL port.
110
139
  * @type integer
111
140
  */
112
141
  port: number;
113
142
  /**
143
+ * @description Upstream PostgreSQL database name.
114
144
  * @type string
115
145
  */
116
146
  name: string;
117
147
  /**
148
+ * @description PostgreSQL SSL mode in use for the database.
118
149
  * @type string
119
150
  */
120
151
  ssl_mode: string;
121
152
  /**
153
+ * @description Database role within the project.
122
154
  * @type string
123
155
  */
124
156
  role: string;
125
157
  /**
158
+ * @description When the database registration was created.
126
159
  * @type string, date-time
127
160
  */
128
161
  created_at: string;
129
162
  }[];
130
163
  /**
164
+ * @description Auth sessions associated with the user.
131
165
  * @type array
132
166
  */
133
167
  sessions: {
134
168
  /**
169
+ * @description Session identifier.
135
170
  * @type string
136
171
  */
137
172
  id: string;
138
173
  /**
174
+ * @description When the session expires.
139
175
  * @type string, date-time
140
176
  */
141
177
  expires_at: string;
142
178
  /**
179
+ * @description When the session was created.
143
180
  * @type string, date-time
144
181
  */
145
182
  created_at: string;
146
183
  /**
184
+ * @description IP address used to create the session, if known.
147
185
  * @type string | undefined
148
186
  */
149
187
  ip_address?: string;
150
188
  /**
189
+ * @description User agent captured for the session, if known.
151
190
  * @type string | undefined
152
191
  */
153
192
  user_agent?: string;
154
193
  }[];
155
194
  /**
195
+ * @description User communication preferences.
156
196
  * @type object
157
197
  */
158
198
  email_preferences: {
159
199
  /**
200
+ * @description Whether marketing emails are enabled.
160
201
  * @type boolean | undefined
161
202
  */
162
203
  marketing_emails?: boolean;
163
204
  /**
205
+ * @description Whether usage alert emails are enabled.
164
206
  * @type boolean | undefined
165
207
  */
166
208
  usage_limit_alerts?: boolean;
167
209
  };
168
210
  /**
211
+ * @description Recorded legal-document acceptances for the user.
169
212
  * @type array
170
213
  */
171
214
  consents: {
172
215
  /**
216
+ * @description Consent record identifier.
173
217
  * @type string
174
218
  */
175
219
  id: string;
176
220
  /**
221
+ * @description Legal document type accepted by the user.
177
222
  * @type string
178
223
  */
179
224
  document_type: string;
180
225
  /**
226
+ * @description Accepted document version.
181
227
  * @type string
182
228
  */
183
229
  document_version: string;
184
230
  /**
231
+ * @description When the document was accepted.
185
232
  * @type string, date-time
186
233
  */
187
234
  accepted_at: string;
188
235
  /**
236
+ * @description IP address captured when consent was recorded.
189
237
  * @type string | undefined
190
238
  */
191
239
  ip_address?: string;
192
240
  }[];
193
241
  /**
242
+ * @description Recent audit log entries associated with the account.
194
243
  * @type array
195
244
  */
196
245
  audit_logs: {
197
246
  /**
247
+ * @description Audit log entry identifier.
198
248
  * @type string
199
249
  */
200
250
  id: string;
201
251
  /**
252
+ * @description Action captured by the audit log entry.
202
253
  * @type string
203
254
  */
204
255
  action: string;
205
256
  /**
257
+ * @description Type of resource affected by the action.
206
258
  * @type string | undefined
207
259
  */
208
260
  resource_type?: string;
209
261
  /**
262
+ * @description Identifier of the affected resource.
210
263
  * @type string | undefined
211
264
  */
212
265
  resource_id?: string;
213
266
  /**
267
+ * @description IP address associated with the action, if known.
214
268
  * @type string | undefined
215
269
  */
216
270
  ip_address?: string;
217
271
  /**
272
+ * @description When the audit log entry was recorded.
218
273
  * @type string, date-time
219
274
  */
220
275
  created_at: string;
221
276
  }[];
222
277
  /**
278
+ * @description When the export was generated.
223
279
  * @type string, date-time
224
280
  */
225
281
  exported_at: string;
@@ -240,48 +296,62 @@ type ExportAccountDataQueryResponse = ExportAccountData200;
240
296
  * Generated by Kubb (https://kubb.dev/).
241
297
  * Do not edit manually.
242
298
  */
299
+ /**
300
+ * @description Recent activity snapshot for a project in an organization.
301
+ */
243
302
  type ActivityEntry = {
244
303
  /**
304
+ * @description Unique activity snapshot identifier.
245
305
  * @type string
246
306
  */
247
307
  id: string;
248
308
  /**
309
+ * @description Project that produced the activity snapshot.
249
310
  * @type string
250
311
  */
251
312
  project_id: string;
252
313
  /**
314
+ * @description Project display name at the time of the snapshot.
253
315
  * @type string
254
316
  */
255
317
  project_name: string;
256
318
  /**
319
+ * @description Region where the activity was observed.
257
320
  * @type string
258
321
  */
259
322
  region: string;
260
323
  /**
324
+ * @description Total queries observed in the snapshot interval.
261
325
  * @type integer, int64
262
326
  */
263
327
  queries_total: number;
264
328
  /**
329
+ * @description Number of cache hits during the interval.
265
330
  * @type integer, int64
266
331
  */
267
332
  cache_hits: number;
268
333
  /**
334
+ * @description Number of cache misses during the interval.
269
335
  * @type integer, int64
270
336
  */
271
337
  cache_misses: number;
272
338
  /**
339
+ * @description Average query latency in milliseconds.
273
340
  * @type number, double
274
341
  */
275
342
  avg_latency_ms: number;
276
343
  /**
344
+ * @description 99th percentile query latency in milliseconds.
277
345
  * @type number, double
278
346
  */
279
347
  p99_latency_ms: number;
280
348
  /**
349
+ * @description Number of active proxy connections during the interval.
281
350
  * @type integer
282
351
  */
283
352
  active_connections: number;
284
353
  /**
354
+ * @description When the activity snapshot was recorded.
285
355
  * @type string, date-time
286
356
  */
287
357
  created_at: string;
@@ -292,8 +362,12 @@ type ActivityEntry = {
292
362
  * Do not edit manually.
293
363
  */
294
364
 
365
+ /**
366
+ * @description Response envelope for organization activity queries.
367
+ */
295
368
  type ActivityResponse = {
296
369
  /**
370
+ * @description Recent activity snapshots for projects in the organization.
297
371
  * @type array
298
372
  */
299
373
  entries: ActivityEntry[];
@@ -306,14 +380,17 @@ type ActivityResponse = {
306
380
 
307
381
  type GetOrganizationActivityPathParams = {
308
382
  /**
383
+ * @description Unique organization identifier.
384
+ * @pattern ^[a-zA-Z0-9_.-]+$
309
385
  * @type string
310
386
  */
311
387
  org_id: string;
312
388
  };
313
389
  type GetOrganizationActivityQueryParams = {
314
390
  /**
391
+ * @description Maximum number of activity entries to return.
315
392
  * @minLength 1
316
- * @maxLength 500
393
+ * @maxLength 1000
317
394
  * @default 100
318
395
  * @type integer | undefined
319
396
  */
@@ -334,6 +411,9 @@ type GetOrganizationActivityQueryResponse = GetOrganizationActivity200;
334
411
  * Generated by Kubb (https://kubb.dev/).
335
412
  * Do not edit manually.
336
413
  */
414
+ /**
415
+ * @description Effective usage limits enforced for an organization plan.
416
+ */
337
417
  type PlanLimits = {
338
418
  /**
339
419
  * @description Maximum queries per day across all projects. 0 means unlimited.
@@ -365,6 +445,16 @@ type PlanLimits = {
365
445
  * @type integer, int64
366
446
  */
367
447
  bytes_per_month: number;
448
+ /**
449
+ * @description Maximum query shapes in cache rules. 0 means unlimited.
450
+ * @type integer
451
+ */
452
+ max_query_shapes: number;
453
+ /**
454
+ * @description Number of seats included in the plan.
455
+ * @type integer
456
+ */
457
+ included_seats: number;
368
458
  };
369
459
 
370
460
  /**
@@ -372,6 +462,9 @@ type PlanLimits = {
372
462
  * Do not edit manually.
373
463
  */
374
464
 
465
+ /**
466
+ * @description Publicly visible plan metadata and limits.
467
+ */
375
468
  type PlanInfo = {
376
469
  /**
377
470
  * @description Plan tier name (starter, pro, scale).
@@ -409,6 +502,7 @@ type PlanInfo = {
409
502
  */
410
503
  trial_days?: number;
411
504
  /**
505
+ * @description Effective usage limits enforced for an organization plan.
412
506
  * @type object
413
507
  */
414
508
  limits: PlanLimits;
@@ -419,8 +513,12 @@ type PlanInfo = {
419
513
  * Do not edit manually.
420
514
  */
421
515
 
516
+ /**
517
+ * @description Response envelope for listing available billing plans.
518
+ */
422
519
  type ListPlansResponse = {
423
520
  /**
521
+ * @description Billing plans available for self-serve signups.
424
522
  * @type array
425
523
  */
426
524
  plans: PlanInfo[];
@@ -446,8 +544,15 @@ declare const organizationPlanPlanEnum: {
446
544
  readonly starter: "starter";
447
545
  readonly pro: "pro";
448
546
  readonly scale: "scale";
547
+ readonly enterprise: "enterprise";
449
548
  };
450
549
  type OrganizationPlanPlanEnumKey = (typeof organizationPlanPlanEnum)[keyof typeof organizationPlanPlanEnum];
550
+ declare const organizationPlanBillingProviderEnum: {
551
+ readonly stripe: "stripe";
552
+ readonly vercel: "vercel";
553
+ readonly aws: "aws";
554
+ };
555
+ type OrganizationPlanBillingProviderEnumKey = (typeof organizationPlanBillingProviderEnum)[keyof typeof organizationPlanBillingProviderEnum];
451
556
  declare const organizationPlanSubscriptionStatusEnum: {
452
557
  readonly none: "none";
453
558
  readonly active: "active";
@@ -460,8 +565,12 @@ declare const organizationPlanSubscriptionStatusEnum: {
460
565
  readonly paused: "paused";
461
566
  };
462
567
  type OrganizationPlanSubscriptionStatusEnumKey = (typeof organizationPlanSubscriptionStatusEnum)[keyof typeof organizationPlanSubscriptionStatusEnum];
568
+ /**
569
+ * @description Billing state and plan limits for an organization.
570
+ */
463
571
  type OrganizationPlan = {
464
572
  /**
573
+ * @description Organization identifier the plan applies to.
465
574
  * @type string
466
575
  */
467
576
  org_id: string;
@@ -470,6 +579,11 @@ type OrganizationPlan = {
470
579
  * @type string
471
580
  */
472
581
  plan: OrganizationPlanPlanEnumKey;
582
+ /**
583
+ * @description Which billing provider manages this organization\'s subscription.
584
+ * @type string | undefined
585
+ */
586
+ billing_provider?: OrganizationPlanBillingProviderEnumKey;
473
587
  /**
474
588
  * @description Stripe subscription status.
475
589
  * @type string | undefined
@@ -486,14 +600,27 @@ type OrganizationPlan = {
486
600
  */
487
601
  enabled?: boolean;
488
602
  /**
603
+ * @description Whether the organization has custom enterprise pricing.
604
+ * @type boolean | undefined
605
+ */
606
+ custom_pricing?: boolean;
607
+ /**
608
+ * @description Monthly spend limit in dollars. Null means no limit.
609
+ * @type number, double
610
+ */
611
+ spend_limit?: number | null;
612
+ /**
613
+ * @description Effective usage limits enforced for an organization plan.
489
614
  * @type object
490
615
  */
491
616
  limits: PlanLimits;
492
617
  /**
618
+ * @description When the billing record was created.
493
619
  * @type string | undefined, date-time
494
620
  */
495
621
  created_at?: string;
496
622
  /**
623
+ * @description When the billing record was last updated.
497
624
  * @type string | undefined, date-time
498
625
  */
499
626
  updated_at?: string;
@@ -506,6 +633,8 @@ type OrganizationPlan = {
506
633
 
507
634
  type GetOrganizationPlanPathParams = {
508
635
  /**
636
+ * @description Unique organization identifier.
637
+ * @pattern ^[a-zA-Z0-9_.-]+$
509
638
  * @type string
510
639
  */
511
640
  org_id: string;
@@ -520,20 +649,93 @@ type GetOrganizationPlanQueryResponse = GetOrganizationPlan200;
520
649
  * Generated by Kubb (https://kubb.dev/).
521
650
  * Do not edit manually.
522
651
  */
523
- declare const queryCatalogEntryQueryTypeEnum: {
652
+ /**
653
+ * @description Request body for updating an organization\'s monthly spend cap.
654
+ */
655
+ type UpdateSpendLimitRequest = {
656
+ /**
657
+ * @description Monthly spend limit in dollars. Null to remove the limit.
658
+ * @type number, double
659
+ */
660
+ spend_limit?: number | null;
661
+ };
662
+
663
+ /**
664
+ * Generated by Kubb (https://kubb.dev/).
665
+ * Do not edit manually.
666
+ */
667
+
668
+ type UpdateSpendLimitPathParams = {
669
+ /**
670
+ * @description Unique organization identifier.
671
+ * @pattern ^[a-zA-Z0-9_.-]+$
672
+ * @type string
673
+ */
674
+ org_id: string;
675
+ };
676
+ /**
677
+ * @description Spend limit updated.
678
+ */
679
+ type UpdateSpendLimit200 = OrganizationPlan;
680
+ type UpdateSpendLimitMutationRequest = UpdateSpendLimitRequest;
681
+ type UpdateSpendLimitMutationResponse = UpdateSpendLimit200;
682
+
683
+ /**
684
+ * Generated by Kubb (https://kubb.dev/).
685
+ * Do not edit manually.
686
+ */
687
+ /**
688
+ * @description Request body for capturing cancellation feedback from a user.
689
+ */
690
+ type CancellationFeedbackRequest = {
691
+ /**
692
+ * @description Predefined cancellation reason.
693
+ * @type string | undefined
694
+ */
695
+ reason?: string;
696
+ /**
697
+ * @description Free-text feedback from the user.
698
+ * @type string | undefined
699
+ */
700
+ feedback?: string;
701
+ };
702
+
703
+ /**
704
+ * Generated by Kubb (https://kubb.dev/).
705
+ * Do not edit manually.
706
+ */
707
+
708
+ type SubmitCancellationFeedbackPathParams = {
709
+ /**
710
+ * @description Unique organization identifier.
711
+ * @pattern ^[a-zA-Z0-9_.-]+$
712
+ * @type string
713
+ */
714
+ org_id: string;
715
+ };
716
+ type SubmitCancellationFeedbackMutationRequest = CancellationFeedbackRequest;
717
+
718
+ /**
719
+ * Generated by Kubb (https://kubb.dev/).
720
+ * Do not edit manually.
721
+ */
722
+ declare const cacheRuleEntryQueryTypeEnum: {
524
723
  readonly read: "read";
525
724
  readonly write: "write";
526
725
  readonly other: "other";
527
726
  };
528
- type QueryCatalogEntryQueryTypeEnumKey = (typeof queryCatalogEntryQueryTypeEnum)[keyof typeof queryCatalogEntryQueryTypeEnum];
529
- declare const queryCatalogEntryRecommendationEnum: {
727
+ type CacheRuleEntryQueryTypeEnumKey = (typeof cacheRuleEntryQueryTypeEnum)[keyof typeof cacheRuleEntryQueryTypeEnum];
728
+ declare const cacheRuleEntryRecommendationEnum: {
530
729
  readonly great: "great";
531
730
  readonly good: "good";
532
731
  readonly fair: "fair";
533
732
  readonly poor: "poor";
534
733
  };
535
- type QueryCatalogEntryRecommendationEnumKey = (typeof queryCatalogEntryRecommendationEnum)[keyof typeof queryCatalogEntryRecommendationEnum];
536
- type QueryCatalogEntry = {
734
+ type CacheRuleEntryRecommendationEnumKey = (typeof cacheRuleEntryRecommendationEnum)[keyof typeof cacheRuleEntryRecommendationEnum];
735
+ /**
736
+ * @description Observed query shape and its cache recommendation for a database.
737
+ */
738
+ type CacheRuleEntry = {
537
739
  /**
538
740
  * @description xxhash64 hex of the normalized SQL.
539
741
  * @type string
@@ -548,7 +750,7 @@ type QueryCatalogEntry = {
548
750
  * @description Query classification.
549
751
  * @type string
550
752
  */
551
- query_type: QueryCatalogEntryQueryTypeEnumKey;
753
+ query_type: CacheRuleEntryQueryTypeEnumKey;
552
754
  /**
553
755
  * @description Whether caching is enabled for this query shape.
554
756
  * @type boolean
@@ -595,7 +797,7 @@ type QueryCatalogEntry = {
595
797
  * @description Cache recommendation based on frequency, latency, and stability.
596
798
  * @type string
597
799
  */
598
- recommendation: QueryCatalogEntryRecommendationEnumKey;
800
+ recommendation: CacheRuleEntryRecommendationEnumKey;
599
801
  /**
600
802
  * @description When this query was first observed.
601
803
  * @type string, date-time
@@ -613,11 +815,15 @@ type QueryCatalogEntry = {
613
815
  * Do not edit manually.
614
816
  */
615
817
 
616
- type ListQueryCatalogResponse = {
818
+ /**
819
+ * @description Cursor-paginated cache-rule entries for a database.
820
+ */
821
+ type ListCacheRulesResponse = {
617
822
  /**
823
+ * @description Query shapes returned for the current page.
618
824
  * @type array
619
825
  */
620
- entries: QueryCatalogEntry[];
826
+ entries: CacheRuleEntry[];
621
827
  /**
622
828
  * @description Opaque token for cursor-based pagination.
623
829
  * @type string | undefined
@@ -630,7 +836,7 @@ type ListQueryCatalogResponse = {
630
836
  * Do not edit manually.
631
837
  */
632
838
 
633
- type ListQueryCatalogPathParams = {
839
+ type ListCacheRulesPathParams = {
634
840
  /**
635
841
  * @description Unique project identifier (prefixed, e.g. prj_xxx).
636
842
  * @pattern ^[a-zA-Z0-9_.-]+$
@@ -644,7 +850,7 @@ type ListQueryCatalogPathParams = {
644
850
  */
645
851
  database_id: string;
646
852
  };
647
- type ListQueryCatalogQueryParams = {
853
+ type ListCacheRulesQueryParams = {
648
854
  /**
649
855
  * @description Maximum number of items to return (1-100, default 20).
650
856
  * @minLength 1
@@ -661,15 +867,18 @@ type ListQueryCatalogQueryParams = {
661
867
  page_token?: string;
662
868
  };
663
869
  /**
664
- * @description Query catalog entries.
870
+ * @description Cache rule entries.
665
871
  */
666
- type ListQueryCatalog200 = ListQueryCatalogResponse;
667
- type ListQueryCatalogQueryResponse = ListQueryCatalog200;
872
+ type ListCacheRules200 = ListCacheRulesResponse;
873
+ type ListCacheRulesQueryResponse = ListCacheRules200;
668
874
 
669
875
  /**
670
876
  * Generated by Kubb (https://kubb.dev/).
671
877
  * Do not edit manually.
672
878
  */
879
+ /**
880
+ * @description Request body for updating cache behavior of a query shape.
881
+ */
673
882
  type UpdateCacheRuleRequest = {
674
883
  /**
675
884
  * @description Whether to enable caching for this query shape.
@@ -697,11 +906,15 @@ type UpdateCacheRuleRequest = {
697
906
  * Do not edit manually.
698
907
  */
699
908
 
909
+ /**
910
+ * @description Response returned after updating a cache rule.
911
+ */
700
912
  type UpdateCacheRuleResponse = {
701
913
  /**
914
+ * @description Observed query shape and its cache recommendation for a database.
702
915
  * @type object
703
916
  */
704
- entry: QueryCatalogEntry;
917
+ entry: CacheRuleEntry;
705
918
  };
706
919
 
707
920
  /**
@@ -863,6 +1076,9 @@ type SSLMode = SSLModeEnumKey;
863
1076
  * Do not edit manually.
864
1077
  */
865
1078
 
1079
+ /**
1080
+ * @description Registered upstream PostgreSQL database for a project.
1081
+ */
866
1082
  type Database = {
867
1083
  /**
868
1084
  * @description Unique database identifier (prefixed).
@@ -928,10 +1144,12 @@ type Database = {
928
1144
  */
929
1145
  pool_config: PoolConfig;
930
1146
  /**
1147
+ * @description When the database registration was created.
931
1148
  * @type string, date-time
932
1149
  */
933
1150
  created_at: string;
934
1151
  /**
1152
+ * @description When the database registration was last updated.
935
1153
  * @type string, date-time
936
1154
  */
937
1155
  updated_at: string;
@@ -942,8 +1160,12 @@ type Database = {
942
1160
  * Do not edit manually.
943
1161
  */
944
1162
 
1163
+ /**
1164
+ * @description Cursor-paginated list of databases attached to a project.
1165
+ */
945
1166
  type ListDatabasesResponse = {
946
1167
  /**
1168
+ * @description Databases on the current page.
947
1169
  * @type array
948
1170
  */
949
1171
  databases: Database[];
@@ -994,6 +1216,9 @@ type ListDatabasesQueryResponse = ListDatabases200;
994
1216
  * Do not edit manually.
995
1217
  */
996
1218
 
1219
+ /**
1220
+ * @description Request body for registering an upstream database.
1221
+ */
997
1222
  type CreateDatabaseRequest = {
998
1223
  /**
999
1224
  * @description PostgreSQL host.
@@ -1108,6 +1333,9 @@ type GetDatabaseQueryResponse = GetDatabase200;
1108
1333
  * Do not edit manually.
1109
1334
  */
1110
1335
 
1336
+ /**
1337
+ * @description Request body for partially updating an upstream database.
1338
+ */
1111
1339
  type UpdateDatabaseRequest = {
1112
1340
  /**
1113
1341
  * @description Updated PostgreSQL host.
@@ -1219,6 +1447,9 @@ type DeleteDatabasePathParams = {
1219
1447
  * Generated by Kubb (https://kubb.dev/).
1220
1448
  * Do not edit manually.
1221
1449
  */
1450
+ /**
1451
+ * @description Result of testing connectivity to an upstream database.
1452
+ */
1222
1453
  type TestConnectionResult = {
1223
1454
  /**
1224
1455
  * @description Whether the connection test succeeded.
@@ -1271,6 +1502,9 @@ type TestDatabaseConnectionMutationResponse = TestDatabaseConnection200;
1271
1502
  * Generated by Kubb (https://kubb.dev/).
1272
1503
  * Do not edit manually.
1273
1504
  */
1505
+ /**
1506
+ * @description Custom database hostname attached to a project.
1507
+ */
1274
1508
  type CustomDomain = {
1275
1509
  /**
1276
1510
  * @description Unique domain identifier (prefixed).
@@ -1344,10 +1578,12 @@ type CustomDomain = {
1344
1578
  acme_cname_target?: string;
1345
1579
  };
1346
1580
  /**
1581
+ * @description When the custom domain was created.
1347
1582
  * @type string, date-time
1348
1583
  */
1349
1584
  created_at: string;
1350
1585
  /**
1586
+ * @description When the custom domain was last updated.
1351
1587
  * @type string, date-time
1352
1588
  */
1353
1589
  updated_at: string;
@@ -1358,8 +1594,12 @@ type CustomDomain = {
1358
1594
  * Do not edit manually.
1359
1595
  */
1360
1596
 
1597
+ /**
1598
+ * @description Cursor-paginated list of custom domains for a project.
1599
+ */
1361
1600
  type ListCustomDomainsResponse = {
1362
1601
  /**
1602
+ * @description Custom domains on the current page.
1363
1603
  * @type array
1364
1604
  */
1365
1605
  domains: CustomDomain[];
@@ -1409,6 +1649,9 @@ type ListCustomDomainsQueryResponse = ListCustomDomains200;
1409
1649
  * Generated by Kubb (https://kubb.dev/).
1410
1650
  * Do not edit manually.
1411
1651
  */
1652
+ /**
1653
+ * @description Request body for attaching a custom domain to a project.
1654
+ */
1412
1655
  type CreateCustomDomainRequest = {
1413
1656
  /**
1414
1657
  * @description The custom domain name to add (e.g., db.example.com).
@@ -1465,6 +1708,9 @@ type DeleteCustomDomainPathParams = {
1465
1708
  * Do not edit manually.
1466
1709
  */
1467
1710
 
1711
+ /**
1712
+ * @description Result of checking DNS ownership for a custom domain.
1713
+ */
1468
1714
  type VerifyCustomDomainResponse = {
1469
1715
  /**
1470
1716
  * @description Whether DNS verification succeeded.
@@ -1477,6 +1723,7 @@ type VerifyCustomDomainResponse = {
1477
1723
  */
1478
1724
  error?: string;
1479
1725
  /**
1726
+ * @description Custom database hostname attached to a project.
1480
1727
  * @type object | undefined
1481
1728
  */
1482
1729
  domain?: CustomDomain;
@@ -1516,6 +1763,9 @@ declare const healthResponseStatusEnum: {
1516
1763
  readonly degraded: "degraded";
1517
1764
  };
1518
1765
  type HealthResponseStatusEnumKey = (typeof healthResponseStatusEnum)[keyof typeof healthResponseStatusEnum];
1766
+ /**
1767
+ * @description Health status and build metadata for the API service.
1768
+ */
1519
1769
  type HealthResponse = {
1520
1770
  /**
1521
1771
  * @description Overall service health.
@@ -1554,12 +1804,17 @@ type GetHealthQueryResponse = GetHealth200;
1554
1804
  * Generated by Kubb (https://kubb.dev/).
1555
1805
  * Do not edit manually.
1556
1806
  */
1807
+ /**
1808
+ * @description Aggregate cache performance metrics for the selected time range.
1809
+ */
1557
1810
  type CacheSummary = {
1558
1811
  /**
1812
+ * @description Total number of cache hits in the selected time range.
1559
1813
  * @type integer, int64
1560
1814
  */
1561
1815
  total_hits: number;
1562
1816
  /**
1817
+ * @description Total number of cache misses in the selected time range.
1563
1818
  * @type integer, int64
1564
1819
  */
1565
1820
  total_misses: number;
@@ -1574,6 +1829,9 @@ type CacheSummary = {
1574
1829
  * Generated by Kubb (https://kubb.dev/).
1575
1830
  * Do not edit manually.
1576
1831
  */
1832
+ /**
1833
+ * @description Aggregate latency metrics for the selected time range.
1834
+ */
1577
1835
  type LatencySummary = {
1578
1836
  /**
1579
1837
  * @description Average latency in milliseconds across all queries.
@@ -1591,6 +1849,9 @@ type LatencySummary = {
1591
1849
  * Generated by Kubb (https://kubb.dev/).
1592
1850
  * Do not edit manually.
1593
1851
  */
1852
+ /**
1853
+ * @description Aggregated analytics for a normalized SQL query shape.
1854
+ */
1594
1855
  type QueryInsight = {
1595
1856
  /**
1596
1857
  * @description xxhash64 of the normalized SQL pattern (hex).
@@ -1608,10 +1869,12 @@ type QueryInsight = {
1608
1869
  */
1609
1870
  total_count: number;
1610
1871
  /**
1872
+ * @description Total cache hits attributed to the query shape.
1611
1873
  * @type integer, int64
1612
1874
  */
1613
1875
  total_cache_hits: number;
1614
1876
  /**
1877
+ * @description Total cache misses attributed to the query shape.
1615
1878
  * @type integer, int64
1616
1879
  */
1617
1880
  total_cache_misses: number;
@@ -1632,16 +1895,22 @@ type QueryInsight = {
1632
1895
  * Do not edit manually.
1633
1896
  */
1634
1897
 
1898
+ /**
1899
+ * @description Query insights, cache performance, and latency for a project.
1900
+ */
1635
1901
  type ProjectInsights = {
1636
1902
  /**
1903
+ * @description Top query shapes observed for the project.
1637
1904
  * @type array
1638
1905
  */
1639
1906
  queries: QueryInsight[];
1640
1907
  /**
1908
+ * @description Aggregate cache performance metrics for the selected time range.
1641
1909
  * @type object
1642
1910
  */
1643
1911
  cache: CacheSummary;
1644
1912
  /**
1913
+ * @description Aggregate latency metrics for the selected time range.
1645
1914
  * @type object
1646
1915
  */
1647
1916
  latency: LatencySummary;
@@ -1693,6 +1962,9 @@ type GetProjectInsightsQueryResponse = GetProjectInsights200;
1693
1962
  * Generated by Kubb (https://kubb.dev/).
1694
1963
  * Do not edit manually.
1695
1964
  */
1965
+ /**
1966
+ * @description Progress state for the dashboard onboarding checklist.
1967
+ */
1696
1968
  type OnboardingProgress = {
1697
1969
  /**
1698
1970
  * @description Organization ID this onboarding belongs to.
@@ -1751,9 +2023,9 @@ type OnboardingProgress = {
1751
2023
  steps_total: number;
1752
2024
  /**
1753
2025
  * @description When onboarding was completed. Null if not yet completed.
1754
- * @type string | undefined, date-time
2026
+ * @type string, date-time
1755
2027
  */
1756
- completed_at?: string;
2028
+ completed_at?: string | null;
1757
2029
  };
1758
2030
 
1759
2031
  /**
@@ -1763,8 +2035,8 @@ type OnboardingProgress = {
1763
2035
 
1764
2036
  type GetOnboardingProgressPathParams = {
1765
2037
  /**
1766
- * @description Organization ID.
1767
- * @pattern ^[\x20-\x7E]+$
2038
+ * @description Unique organization identifier.
2039
+ * @pattern ^[a-zA-Z0-9_.-]+$
1768
2040
  * @type string
1769
2041
  */
1770
2042
  org_id: string;
@@ -1787,6 +2059,9 @@ declare const updateOnboardingRequestStepEnum: {
1787
2059
  readonly first_query_run: "first_query_run";
1788
2060
  };
1789
2061
  type UpdateOnboardingRequestStepEnumKey = (typeof updateOnboardingRequestStepEnum)[keyof typeof updateOnboardingRequestStepEnum];
2062
+ /**
2063
+ * @description Request body for advancing or dismissing onboarding.
2064
+ */
1790
2065
  type UpdateOnboardingRequest = {
1791
2066
  /**
1792
2067
  * @description The onboarding step to mark as complete.
@@ -1807,8 +2082,8 @@ type UpdateOnboardingRequest = {
1807
2082
 
1808
2083
  type UpdateOnboardingProgressPathParams = {
1809
2084
  /**
1810
- * @description Organization ID.
1811
- * @pattern ^[\x20-\x7E]+$
2085
+ * @description Unique organization identifier.
2086
+ * @pattern ^[a-zA-Z0-9_.-]+$
1812
2087
  * @type string
1813
2088
  */
1814
2089
  org_id: string;
@@ -1840,6 +2115,9 @@ type ProjectStatus = ProjectStatusEnumKey;
1840
2115
  * Do not edit manually.
1841
2116
  */
1842
2117
 
2118
+ /**
2119
+ * @description Project configuration and current control-plane state.
2120
+ */
1843
2121
  type Project = {
1844
2122
  /**
1845
2123
  * @description Unique project identifier (prefixed).
@@ -1865,6 +2143,7 @@ type Project = {
1865
2143
  */
1866
2144
  description?: string;
1867
2145
  /**
2146
+ * @description User-defined labels applied to the project.
1868
2147
  * @type array | undefined
1869
2148
  */
1870
2149
  tags?: string[];
@@ -1910,10 +2189,12 @@ type Project = {
1910
2189
  */
1911
2190
  status: ProjectStatus;
1912
2191
  /**
2192
+ * @description When the project was created.
1913
2193
  * @type string, date-time
1914
2194
  */
1915
2195
  created_at: string;
1916
2196
  /**
2197
+ * @description When the project was last updated.
1917
2198
  * @type string, date-time
1918
2199
  */
1919
2200
  updated_at: string;
@@ -1924,8 +2205,12 @@ type Project = {
1924
2205
  * Do not edit manually.
1925
2206
  */
1926
2207
 
2208
+ /**
2209
+ * @description Cursor-paginated list of projects for an organization.
2210
+ */
1927
2211
  type ListProjectsResponse = {
1928
2212
  /**
2213
+ * @description Projects on the current page.
1929
2214
  * @type array
1930
2215
  */
1931
2216
  projects: Project[];
@@ -1991,6 +2276,9 @@ type ListProjectsQueryResponse = ListProjects200;
1991
2276
  * Do not edit manually.
1992
2277
  */
1993
2278
 
2279
+ /**
2280
+ * @description Request body for creating a project and its primary database.
2281
+ */
1994
2282
  type CreateProjectRequest = {
1995
2283
  /**
1996
2284
  * @description Human-readable project name.
@@ -2002,21 +2290,24 @@ type CreateProjectRequest = {
2002
2290
  name: string;
2003
2291
  /**
2004
2292
  * @description Better Auth organization ID.
2005
- * @pattern ^[^\x00]*$
2293
+ * @minLength 1
2294
+ * @pattern ^[^\x00]+$
2006
2295
  * @type string
2007
2296
  */
2008
2297
  org_id: string;
2009
2298
  /**
2299
+ * @description Optional project description.
2010
2300
  * @maxLength 500
2011
2301
  * @type string | undefined
2012
2302
  */
2013
2303
  description?: string;
2014
2304
  /**
2305
+ * @description User-defined labels to attach to the project.
2015
2306
  * @type array | undefined
2016
2307
  */
2017
2308
  tags?: string[];
2018
2309
  /**
2019
- * @description Primary database. Created atomically with the project.
2310
+ * @description Request body for registering an upstream database.
2020
2311
  * @type object
2021
2312
  */
2022
2313
  database: CreateDatabaseRequest;
@@ -2027,12 +2318,17 @@ type CreateProjectRequest = {
2027
2318
  * Do not edit manually.
2028
2319
  */
2029
2320
 
2321
+ /**
2322
+ * @description Response returned after creating a project and its primary database.
2323
+ */
2030
2324
  type CreateProjectResponse = {
2031
2325
  /**
2326
+ * @description Project configuration and current control-plane state.
2032
2327
  * @type object
2033
2328
  */
2034
2329
  project: Project;
2035
2330
  /**
2331
+ * @description Registered upstream PostgreSQL database for a project.
2036
2332
  * @type object | undefined
2037
2333
  */
2038
2334
  database?: Database;
@@ -2074,6 +2370,9 @@ type GetProjectQueryResponse = GetProject200;
2074
2370
  * Do not edit manually.
2075
2371
  */
2076
2372
 
2373
+ /**
2374
+ * @description Request body for partially updating a project.
2375
+ */
2077
2376
  type UpdateProjectRequest = {
2078
2377
  /**
2079
2378
  * @description Updated project name.
@@ -2084,11 +2383,13 @@ type UpdateProjectRequest = {
2084
2383
  */
2085
2384
  name?: string;
2086
2385
  /**
2386
+ * @description Updated project description.
2087
2387
  * @maxLength 500
2088
2388
  * @type string | undefined
2089
2389
  */
2090
2390
  description?: string;
2091
2391
  /**
2392
+ * @description Replacement set of user-defined project labels.
2092
2393
  * @type array | undefined
2093
2394
  */
2094
2395
  tags?: string[];
@@ -2158,40 +2459,52 @@ type DeleteProjectPathParams = {
2158
2459
  * Generated by Kubb (https://kubb.dev/).
2159
2460
  * Do not edit manually.
2160
2461
  */
2462
+ /**
2463
+ * @description Aggregated project metrics captured for a point in time.
2464
+ */
2161
2465
  type MetricsSnapshot = {
2162
2466
  /**
2467
+ * @description Unique metrics snapshot identifier.
2163
2468
  * @type string
2164
2469
  */
2165
2470
  id: string;
2166
2471
  /**
2472
+ * @description Project that produced the metrics snapshot.
2167
2473
  * @type string
2168
2474
  */
2169
2475
  project_id: string;
2170
2476
  /**
2477
+ * @description Region where the traffic was served.
2171
2478
  * @type string
2172
2479
  */
2173
2480
  region: string;
2174
2481
  /**
2482
+ * @description Total queries served during the snapshot interval.
2175
2483
  * @type integer, int64
2176
2484
  */
2177
2485
  queries_total: number;
2178
2486
  /**
2487
+ * @description Number of queries served from cache.
2179
2488
  * @type integer, int64
2180
2489
  */
2181
2490
  cache_hits: number;
2182
2491
  /**
2492
+ * @description Number of queries forwarded upstream.
2183
2493
  * @type integer, int64
2184
2494
  */
2185
2495
  cache_misses: number;
2186
2496
  /**
2497
+ * @description Current active proxy connections.
2187
2498
  * @type integer
2188
2499
  */
2189
2500
  active_connections: number;
2190
2501
  /**
2502
+ * @description Average end-to-end query latency in milliseconds.
2191
2503
  * @type number, double
2192
2504
  */
2193
2505
  avg_latency_ms: number;
2194
2506
  /**
2507
+ * @description 99th percentile end-to-end query latency in milliseconds.
2195
2508
  * @type number, double
2196
2509
  */
2197
2510
  p99_latency_ms: number;
@@ -2206,11 +2519,28 @@ type MetricsSnapshot = {
2206
2519
  */
2207
2520
  avg_query_ms?: number;
2208
2521
  /**
2522
+ * @description When the snapshot was recorded.
2209
2523
  * @type string, date-time
2210
2524
  */
2211
2525
  created_at: string;
2212
2526
  };
2213
2527
 
2528
+ /**
2529
+ * Generated by Kubb (https://kubb.dev/).
2530
+ * Do not edit manually.
2531
+ */
2532
+
2533
+ /**
2534
+ * @description Response envelope for recent project metrics snapshots.
2535
+ */
2536
+ type ProjectMetricsResponse = {
2537
+ /**
2538
+ * @description Metrics snapshots ordered from newest to oldest.
2539
+ * @type array
2540
+ */
2541
+ snapshots: MetricsSnapshot[];
2542
+ };
2543
+
2214
2544
  /**
2215
2545
  * Generated by Kubb (https://kubb.dev/).
2216
2546
  * Do not edit manually.
@@ -2226,6 +2556,7 @@ type GetProjectMetricsPathParams = {
2226
2556
  };
2227
2557
  type GetProjectMetricsQueryParams = {
2228
2558
  /**
2559
+ * @description Maximum number of recent snapshots to return.
2229
2560
  * @minLength 1
2230
2561
  * @maxLength 1000
2231
2562
  * @default 60
@@ -2241,12 +2572,7 @@ type GetProjectMetricsQueryParams = {
2241
2572
  /**
2242
2573
  * @description Metrics snapshots
2243
2574
  */
2244
- type GetProjectMetrics200 = {
2245
- /**
2246
- * @type array
2247
- */
2248
- snapshots: MetricsSnapshot[];
2249
- };
2575
+ type GetProjectMetrics200 = ProjectMetricsResponse;
2250
2576
  type GetProjectMetricsQueryResponse = GetProjectMetrics200;
2251
2577
 
2252
2578
  /**
@@ -2259,6 +2585,9 @@ declare const regionStatusEnum: {
2259
2585
  readonly inactive: "inactive";
2260
2586
  };
2261
2587
  type RegionStatusEnumKey = (typeof regionStatusEnum)[keyof typeof regionStatusEnum];
2588
+ /**
2589
+ * @description Data plane region available for PgBeam traffic.
2590
+ */
2262
2591
  type Region = {
2263
2592
  /**
2264
2593
  * @description Region identifier (e.g. us-east-1).
@@ -2281,14 +2610,17 @@ type Region = {
2281
2610
  */
2282
2611
  status: RegionStatusEnumKey;
2283
2612
  /**
2613
+ * @description Whether new projects can currently be assigned to the region.
2284
2614
  * @type boolean
2285
2615
  */
2286
2616
  available: boolean;
2287
2617
  /**
2618
+ * @description Continent where the region is located.
2288
2619
  * @type string | undefined
2289
2620
  */
2290
2621
  continent?: string;
2291
2622
  /**
2623
+ * @description Country where the region is located.
2292
2624
  * @type string | undefined
2293
2625
  */
2294
2626
  country?: string;
@@ -2299,8 +2631,12 @@ type Region = {
2299
2631
  * Do not edit manually.
2300
2632
  */
2301
2633
 
2634
+ /**
2635
+ * @description Response envelope for available region queries.
2636
+ */
2302
2637
  type ListRegionsResponse = {
2303
2638
  /**
2639
+ * @description Regions currently known to the control plane.
2304
2640
  * @type array
2305
2641
  */
2306
2642
  regions: Region[];
@@ -2322,6 +2658,9 @@ type ListRegionsQueryResponse = ListRegions200;
2322
2658
  * Do not edit manually.
2323
2659
  */
2324
2660
 
2661
+ /**
2662
+ * @description Read replica registered for a primary database.
2663
+ */
2325
2664
  type Replica = {
2326
2665
  /**
2327
2666
  * @description Unique replica identifier (prefixed).
@@ -2351,10 +2690,12 @@ type Replica = {
2351
2690
  */
2352
2691
  ssl_mode: SSLMode;
2353
2692
  /**
2693
+ * @description When the replica was created.
2354
2694
  * @type string, date-time
2355
2695
  */
2356
2696
  created_at: string;
2357
2697
  /**
2698
+ * @description When the replica was last updated.
2358
2699
  * @type string, date-time
2359
2700
  */
2360
2701
  updated_at: string;
@@ -2365,8 +2706,12 @@ type Replica = {
2365
2706
  * Do not edit manually.
2366
2707
  */
2367
2708
 
2709
+ /**
2710
+ * @description Response envelope for listing registered replicas.
2711
+ */
2368
2712
  type ListReplicasResponse = {
2369
2713
  /**
2714
+ * @description Read replicas attached to the database.
2370
2715
  * @type array
2371
2716
  */
2372
2717
  replicas: Replica[];
@@ -2396,6 +2741,9 @@ type ListReplicasQueryResponse = ListReplicas200;
2396
2741
  * Do not edit manually.
2397
2742
  */
2398
2743
 
2744
+ /**
2745
+ * @description Request body for adding a read replica to a database.
2746
+ */
2399
2747
  type CreateReplicaRequest = {
2400
2748
  /**
2401
2749
  * @description PostgreSQL replica host.
@@ -2462,24 +2810,32 @@ type DeleteReplicaPathParams = {
2462
2810
  * Generated by Kubb (https://kubb.dev/).
2463
2811
  * Do not edit manually.
2464
2812
  */
2813
+ /**
2814
+ * @description Daily usage totals aggregated across all projects in an organization.
2815
+ */
2465
2816
  type DailyUsage = {
2466
2817
  /**
2818
+ * @description Usage date in UTC.
2467
2819
  * @type string, date
2468
2820
  */
2469
2821
  day: string;
2470
2822
  /**
2823
+ * @description Total queries served on the day.
2471
2824
  * @type integer, int64
2472
2825
  */
2473
2826
  queries_total: number;
2474
2827
  /**
2828
+ * @description Total cache hits on the day.
2475
2829
  * @type integer, int64
2476
2830
  */
2477
2831
  cache_hits: number;
2478
2832
  /**
2833
+ * @description Total cache misses on the day.
2479
2834
  * @type integer, int64
2480
2835
  */
2481
2836
  cache_misses: number;
2482
2837
  /**
2838
+ * @description Total proxy connection time consumed on the day.
2483
2839
  * @type integer, int64
2484
2840
  */
2485
2841
  connection_seconds: number;
@@ -2495,8 +2851,12 @@ type DailyUsage = {
2495
2851
  * Do not edit manually.
2496
2852
  */
2497
2853
 
2854
+ /**
2855
+ * @description Response envelope for organization usage queries.
2856
+ */
2498
2857
  type UsageResponse = {
2499
2858
  /**
2859
+ * @description Daily usage entries aggregated across the organization.
2500
2860
  * @type array
2501
2861
  */
2502
2862
  usage: DailyUsage[];
@@ -2509,6 +2869,8 @@ type UsageResponse = {
2509
2869
 
2510
2870
  type GetOrganizationUsagePathParams = {
2511
2871
  /**
2872
+ * @description Unique organization identifier.
2873
+ * @pattern ^[a-zA-Z0-9_.-]+$
2512
2874
  * @type string
2513
2875
  */
2514
2876
  org_id: string;
@@ -2535,28 +2897,37 @@ type GetOrganizationUsageQueryResponse = GetOrganizationUsage200;
2535
2897
  * Generated by Kubb (https://kubb.dev/).
2536
2898
  * Do not edit manually.
2537
2899
  */
2900
+ /**
2901
+ * @description Daily usage totals for a single project and region.
2902
+ */
2538
2903
  type ProjectDailyUsage = {
2539
2904
  /**
2905
+ * @description Usage date in UTC.
2540
2906
  * @type string, date
2541
2907
  */
2542
2908
  day: string;
2543
2909
  /**
2910
+ * @description Region where the traffic was served.
2544
2911
  * @type string
2545
2912
  */
2546
2913
  region: string;
2547
2914
  /**
2915
+ * @description Total queries served on the day.
2548
2916
  * @type integer, int64
2549
2917
  */
2550
2918
  queries_total: number;
2551
2919
  /**
2920
+ * @description Total cache hits on the day.
2552
2921
  * @type integer, int64
2553
2922
  */
2554
2923
  cache_hits: number;
2555
2924
  /**
2925
+ * @description Total cache misses on the day.
2556
2926
  * @type integer, int64
2557
2927
  */
2558
2928
  cache_misses: number;
2559
2929
  /**
2930
+ * @description Total proxy connection time consumed on the day.
2560
2931
  * @type integer, int64
2561
2932
  */
2562
2933
  connection_seconds: number;
@@ -2572,8 +2943,12 @@ type ProjectDailyUsage = {
2572
2943
  * Do not edit manually.
2573
2944
  */
2574
2945
 
2946
+ /**
2947
+ * @description Response envelope for project usage queries.
2948
+ */
2575
2949
  type ProjectUsageResponse = {
2576
2950
  /**
2951
+ * @description Daily usage entries grouped by region for the project.
2577
2952
  * @type array
2578
2953
  */
2579
2954
  usage: ProjectDailyUsage[];
@@ -2610,84 +2985,6 @@ type GetProjectUsageQueryParams = {
2610
2985
  type GetProjectUsage200 = ProjectUsageResponse;
2611
2986
  type GetProjectUsageQueryResponse = GetProjectUsage200;
2612
2987
 
2613
- /**
2614
- * Generated by Kubb (https://kubb.dev/).
2615
- * Do not edit manually.
2616
- */
2617
- type JoinWaitlistRequest = {
2618
- /**
2619
- * @type string, email
2620
- */
2621
- email: string;
2622
- /**
2623
- * @type string | undefined
2624
- */
2625
- name?: string;
2626
- /**
2627
- * @type string | undefined
2628
- */
2629
- company?: string;
2630
- };
2631
-
2632
- /**
2633
- * Generated by Kubb (https://kubb.dev/).
2634
- * Do not edit manually.
2635
- */
2636
- type WaitlistEntry = {
2637
- /**
2638
- * @type string
2639
- */
2640
- id: string;
2641
- /**
2642
- * @type string, email
2643
- */
2644
- email: string;
2645
- /**
2646
- * @type string
2647
- */
2648
- name: string;
2649
- /**
2650
- * @type string
2651
- */
2652
- company: string;
2653
- /**
2654
- * @type boolean
2655
- */
2656
- invited: boolean;
2657
- /**
2658
- * @type string, date-time
2659
- */
2660
- created_at: string;
2661
- /**
2662
- * @type string | undefined, date-time
2663
- */
2664
- invited_at?: string;
2665
- };
2666
-
2667
- /**
2668
- * Generated by Kubb (https://kubb.dev/).
2669
- * Do not edit manually.
2670
- */
2671
-
2672
- type JoinWaitlistResponse = {
2673
- /**
2674
- * @type object
2675
- */
2676
- entry: WaitlistEntry;
2677
- };
2678
-
2679
- /**
2680
- * Generated by Kubb (https://kubb.dev/).
2681
- * Do not edit manually.
2682
- */
2683
-
2684
- /**
2685
- * @description Successfully joined or already on the waitlist.
2686
- */
2687
- type JoinWaitlist200 = JoinWaitlistResponse;
2688
- type JoinWaitlistMutationRequest = JoinWaitlistRequest;
2689
- type JoinWaitlistMutationResponse = JoinWaitlist200;
2690
-
2691
2988
  /**
2692
2989
  * Generated by scripts/generate-maps.ts — do not edit manually.
2693
2990
  * Run: pnpm --filter pgbeam generate
@@ -2699,8 +2996,16 @@ declare const operationsByTag: {
2699
2996
  readonly method: "GET";
2700
2997
  readonly path: "/v1/account/export";
2701
2998
  };
2999
+ readonly getOnboardingProgress: {
3000
+ readonly method: "GET";
3001
+ readonly path: "/v1/organizations/{org_id}/onboarding";
3002
+ };
3003
+ readonly updateOnboardingProgress: {
3004
+ readonly method: "PATCH";
3005
+ readonly path: "/v1/organizations/{org_id}/onboarding";
3006
+ };
2702
3007
  };
2703
- readonly usage: {
3008
+ readonly analytics: {
2704
3009
  readonly getOrganizationActivity: {
2705
3010
  readonly method: "GET";
2706
3011
  readonly path: "/v1/organizations/{org_id}/activity";
@@ -2713,6 +3018,14 @@ declare const operationsByTag: {
2713
3018
  readonly method: "GET";
2714
3019
  readonly path: "/v1/organizations/{org_id}/plan";
2715
3020
  };
3021
+ readonly updateSpendLimit: {
3022
+ readonly method: "PUT";
3023
+ readonly path: "/v1/organizations/{org_id}/spend-limit";
3024
+ };
3025
+ readonly submitCancellationFeedback: {
3026
+ readonly method: "POST";
3027
+ readonly path: "/v1/organizations/{org_id}/cancellation-feedback";
3028
+ };
2716
3029
  readonly getProjectInsights: {
2717
3030
  readonly method: "GET";
2718
3031
  readonly path: "/v1/projects/{project_id}/insights";
@@ -2726,43 +3039,15 @@ declare const operationsByTag: {
2726
3039
  readonly path: "/v1/projects/{project_id}/usage";
2727
3040
  };
2728
3041
  };
2729
- readonly catalog: {
2730
- readonly listQueryCatalog: {
3042
+ readonly projects: {
3043
+ readonly listCacheRules: {
2731
3044
  readonly method: "GET";
2732
- readonly path: "/v1/projects/{project_id}/databases/{database_id}/catalog";
3045
+ readonly path: "/v1/projects/{project_id}/databases/{database_id}/cache-rules";
2733
3046
  };
2734
3047
  readonly updateCacheRule: {
2735
3048
  readonly method: "PUT";
2736
- readonly path: "/v1/projects/{project_id}/databases/{database_id}/catalog/{query_hash}/cache-rule";
2737
- };
2738
- };
2739
- readonly databases: {
2740
- readonly listDatabases: {
2741
- readonly method: "GET";
2742
- readonly path: "/v1/projects/{project_id}/databases";
2743
- };
2744
- readonly createDatabase: {
2745
- readonly method: "POST";
2746
- readonly path: "/v1/projects/{project_id}/databases";
2747
- };
2748
- readonly getDatabase: {
2749
- readonly method: "GET";
2750
- readonly path: "/v1/projects/{project_id}/databases/{database_id}";
2751
- };
2752
- readonly updateDatabase: {
2753
- readonly method: "PATCH";
2754
- readonly path: "/v1/projects/{project_id}/databases/{database_id}";
3049
+ readonly path: "/v1/projects/{project_id}/databases/{database_id}/cache-rules/{query_hash}";
2755
3050
  };
2756
- readonly deleteDatabase: {
2757
- readonly method: "DELETE";
2758
- readonly path: "/v1/projects/{project_id}/databases/{database_id}";
2759
- };
2760
- readonly testDatabaseConnection: {
2761
- readonly method: "POST";
2762
- readonly path: "/v1/projects/{project_id}/databases/{database_id}/test-connection";
2763
- };
2764
- };
2765
- readonly domains: {
2766
3051
  readonly listCustomDomains: {
2767
3052
  readonly method: "GET";
2768
3053
  readonly path: "/v1/projects/{project_id}/domains";
@@ -2779,24 +3064,6 @@ declare const operationsByTag: {
2779
3064
  readonly method: "POST";
2780
3065
  readonly path: "/v1/projects/{project_id}/domains/{domain_id}/verify";
2781
3066
  };
2782
- };
2783
- readonly health: {
2784
- readonly getHealth: {
2785
- readonly method: "GET";
2786
- readonly path: "/v1/health";
2787
- };
2788
- };
2789
- readonly onboarding: {
2790
- readonly getOnboardingProgress: {
2791
- readonly method: "GET";
2792
- readonly path: "/v1/organizations/{org_id}/onboarding";
2793
- };
2794
- readonly updateOnboardingProgress: {
2795
- readonly method: "PATCH";
2796
- readonly path: "/v1/organizations/{org_id}/onboarding";
2797
- };
2798
- };
2799
- readonly projects: {
2800
3067
  readonly listProjects: {
2801
3068
  readonly method: "GET";
2802
3069
  readonly path: "/v1/projects";
@@ -2821,14 +3088,6 @@ declare const operationsByTag: {
2821
3088
  readonly method: "GET";
2822
3089
  readonly path: "/v1/projects/{project_id}/metrics";
2823
3090
  };
2824
- };
2825
- readonly regions: {
2826
- readonly listRegions: {
2827
- readonly method: "GET";
2828
- readonly path: "/v1/regions";
2829
- };
2830
- };
2831
- readonly replicas: {
2832
3091
  readonly listReplicas: {
2833
3092
  readonly method: "GET";
2834
3093
  readonly path: "/v1/databases/{database_id}/replicas";
@@ -2842,10 +3101,40 @@ declare const operationsByTag: {
2842
3101
  readonly path: "/v1/databases/{database_id}/replicas/{replica_id}";
2843
3102
  };
2844
3103
  };
2845
- readonly waitlist: {
2846
- readonly joinWaitlist: {
3104
+ readonly databases: {
3105
+ readonly listDatabases: {
3106
+ readonly method: "GET";
3107
+ readonly path: "/v1/projects/{project_id}/databases";
3108
+ };
3109
+ readonly createDatabase: {
2847
3110
  readonly method: "POST";
2848
- readonly path: "/v1/waitlist";
3111
+ readonly path: "/v1/projects/{project_id}/databases";
3112
+ };
3113
+ readonly getDatabase: {
3114
+ readonly method: "GET";
3115
+ readonly path: "/v1/projects/{project_id}/databases/{database_id}";
3116
+ };
3117
+ readonly updateDatabase: {
3118
+ readonly method: "PATCH";
3119
+ readonly path: "/v1/projects/{project_id}/databases/{database_id}";
3120
+ };
3121
+ readonly deleteDatabase: {
3122
+ readonly method: "DELETE";
3123
+ readonly path: "/v1/projects/{project_id}/databases/{database_id}";
3124
+ };
3125
+ readonly testDatabaseConnection: {
3126
+ readonly method: "POST";
3127
+ readonly path: "/v1/projects/{project_id}/databases/{database_id}/test-connection";
3128
+ };
3129
+ };
3130
+ readonly platform: {
3131
+ readonly getHealth: {
3132
+ readonly method: "GET";
3133
+ readonly path: "/v1/health";
3134
+ };
3135
+ readonly listRegions: {
3136
+ readonly method: "GET";
3137
+ readonly path: "/v1/regions";
2849
3138
  };
2850
3139
  };
2851
3140
  };
@@ -2870,14 +3159,24 @@ declare const operationsByPath: {
2870
3159
  readonly path: "/v1/organizations/{org_id}/plan";
2871
3160
  readonly operationId: "getOrganizationPlan";
2872
3161
  };
2873
- readonly "GET /v1/projects/{project_id}/databases/{database_id}/catalog": {
3162
+ readonly "PUT /v1/organizations/{org_id}/spend-limit": {
3163
+ readonly method: "PUT";
3164
+ readonly path: "/v1/organizations/{org_id}/spend-limit";
3165
+ readonly operationId: "updateSpendLimit";
3166
+ };
3167
+ readonly "POST /v1/organizations/{org_id}/cancellation-feedback": {
3168
+ readonly method: "POST";
3169
+ readonly path: "/v1/organizations/{org_id}/cancellation-feedback";
3170
+ readonly operationId: "submitCancellationFeedback";
3171
+ };
3172
+ readonly "GET /v1/projects/{project_id}/databases/{database_id}/cache-rules": {
2874
3173
  readonly method: "GET";
2875
- readonly path: "/v1/projects/{project_id}/databases/{database_id}/catalog";
2876
- readonly operationId: "listQueryCatalog";
3174
+ readonly path: "/v1/projects/{project_id}/databases/{database_id}/cache-rules";
3175
+ readonly operationId: "listCacheRules";
2877
3176
  };
2878
- readonly "PUT /v1/projects/{project_id}/databases/{database_id}/catalog/{query_hash}/cache-rule": {
3177
+ readonly "PUT /v1/projects/{project_id}/databases/{database_id}/cache-rules/{query_hash}": {
2879
3178
  readonly method: "PUT";
2880
- readonly path: "/v1/projects/{project_id}/databases/{database_id}/catalog/{query_hash}/cache-rule";
3179
+ readonly path: "/v1/projects/{project_id}/databases/{database_id}/cache-rules/{query_hash}";
2881
3180
  readonly operationId: "updateCacheRule";
2882
3181
  };
2883
3182
  readonly "GET /v1/projects/{project_id}/databases": {
@@ -3010,17 +3309,19 @@ declare const operationsByPath: {
3010
3309
  readonly path: "/v1/projects/{project_id}/usage";
3011
3310
  readonly operationId: "getProjectUsage";
3012
3311
  };
3013
- readonly "POST /v1/waitlist": {
3014
- readonly method: "POST";
3015
- readonly path: "/v1/waitlist";
3016
- readonly operationId: "joinWaitlist";
3017
- };
3018
3312
  };
3019
3313
  interface ApiOperations {
3020
3314
  account: {
3021
3315
  exportAccountData(): Promise<ExportAccountDataQueryResponse>;
3316
+ getOnboardingProgress(params: {
3317
+ pathParams: GetOnboardingProgressPathParams;
3318
+ }): Promise<GetOnboardingProgressQueryResponse>;
3319
+ updateOnboardingProgress(params: {
3320
+ pathParams: UpdateOnboardingProgressPathParams;
3321
+ body: UpdateOnboardingProgressMutationRequest;
3322
+ }): Promise<UpdateOnboardingProgressMutationResponse>;
3022
3323
  };
3023
- usage: {
3324
+ analytics: {
3024
3325
  getOrganizationActivity(params: {
3025
3326
  pathParams: GetOrganizationActivityPathParams;
3026
3327
  queryParams?: GetOrganizationActivityQueryParams;
@@ -3029,6 +3330,14 @@ interface ApiOperations {
3029
3330
  getOrganizationPlan(params: {
3030
3331
  pathParams: GetOrganizationPlanPathParams;
3031
3332
  }): Promise<GetOrganizationPlanQueryResponse>;
3333
+ updateSpendLimit(params: {
3334
+ pathParams: UpdateSpendLimitPathParams;
3335
+ body: UpdateSpendLimitMutationRequest;
3336
+ }): Promise<UpdateSpendLimitMutationResponse>;
3337
+ submitCancellationFeedback(params: {
3338
+ pathParams: SubmitCancellationFeedbackPathParams;
3339
+ body: SubmitCancellationFeedbackMutationRequest;
3340
+ }): Promise<void>;
3032
3341
  getProjectInsights(params: {
3033
3342
  pathParams: GetProjectInsightsPathParams;
3034
3343
  queryParams?: GetProjectInsightsQueryParams;
@@ -3042,40 +3351,15 @@ interface ApiOperations {
3042
3351
  queryParams: GetProjectUsageQueryParams;
3043
3352
  }): Promise<GetProjectUsageQueryResponse>;
3044
3353
  };
3045
- catalog: {
3046
- listQueryCatalog(params: {
3047
- pathParams: ListQueryCatalogPathParams;
3048
- queryParams?: ListQueryCatalogQueryParams;
3049
- }): Promise<ListQueryCatalogQueryResponse>;
3354
+ projects: {
3355
+ listCacheRules(params: {
3356
+ pathParams: ListCacheRulesPathParams;
3357
+ queryParams?: ListCacheRulesQueryParams;
3358
+ }): Promise<ListCacheRulesQueryResponse>;
3050
3359
  updateCacheRule(params: {
3051
3360
  pathParams: UpdateCacheRulePathParams;
3052
3361
  body: UpdateCacheRuleMutationRequest;
3053
3362
  }): Promise<UpdateCacheRuleMutationResponse>;
3054
- };
3055
- databases: {
3056
- listDatabases(params: {
3057
- pathParams: ListDatabasesPathParams;
3058
- queryParams?: ListDatabasesQueryParams;
3059
- }): Promise<ListDatabasesQueryResponse>;
3060
- createDatabase(params: {
3061
- pathParams: CreateDatabasePathParams;
3062
- body: CreateDatabaseMutationRequest;
3063
- }): Promise<CreateDatabaseMutationResponse>;
3064
- getDatabase(params: {
3065
- pathParams: GetDatabasePathParams;
3066
- }): Promise<GetDatabaseQueryResponse>;
3067
- updateDatabase(params: {
3068
- pathParams: UpdateDatabasePathParams;
3069
- body: UpdateDatabaseMutationRequest;
3070
- }): Promise<UpdateDatabaseMutationResponse>;
3071
- deleteDatabase(params: {
3072
- pathParams: DeleteDatabasePathParams;
3073
- }): Promise<void>;
3074
- testDatabaseConnection(params: {
3075
- pathParams: TestDatabaseConnectionPathParams;
3076
- }): Promise<TestDatabaseConnectionMutationResponse>;
3077
- };
3078
- domains: {
3079
3363
  listCustomDomains(params: {
3080
3364
  pathParams: ListCustomDomainsPathParams;
3081
3365
  queryParams?: ListCustomDomainsQueryParams;
@@ -3090,20 +3374,6 @@ interface ApiOperations {
3090
3374
  verifyCustomDomain(params: {
3091
3375
  pathParams: VerifyCustomDomainPathParams;
3092
3376
  }): Promise<VerifyCustomDomainMutationResponse>;
3093
- };
3094
- health: {
3095
- getHealth(): Promise<GetHealthQueryResponse>;
3096
- };
3097
- onboarding: {
3098
- getOnboardingProgress(params: {
3099
- pathParams: GetOnboardingProgressPathParams;
3100
- }): Promise<GetOnboardingProgressQueryResponse>;
3101
- updateOnboardingProgress(params: {
3102
- pathParams: UpdateOnboardingProgressPathParams;
3103
- body: UpdateOnboardingProgressMutationRequest;
3104
- }): Promise<UpdateOnboardingProgressMutationResponse>;
3105
- };
3106
- projects: {
3107
3377
  listProjects(params: {
3108
3378
  queryParams: ListProjectsQueryParams;
3109
3379
  }): Promise<ListProjectsQueryResponse>;
@@ -3124,11 +3394,6 @@ interface ApiOperations {
3124
3394
  pathParams: GetProjectMetricsPathParams;
3125
3395
  queryParams?: GetProjectMetricsQueryParams;
3126
3396
  }): Promise<GetProjectMetricsQueryResponse>;
3127
- };
3128
- regions: {
3129
- listRegions(): Promise<ListRegionsQueryResponse>;
3130
- };
3131
- replicas: {
3132
3397
  listReplicas(params: {
3133
3398
  pathParams: ListReplicasPathParams;
3134
3399
  }): Promise<ListReplicasQueryResponse>;
@@ -3140,10 +3405,32 @@ interface ApiOperations {
3140
3405
  pathParams: DeleteReplicaPathParams;
3141
3406
  }): Promise<void>;
3142
3407
  };
3143
- waitlist: {
3144
- joinWaitlist(params: {
3145
- body: JoinWaitlistMutationRequest;
3146
- }): Promise<JoinWaitlistMutationResponse>;
3408
+ databases: {
3409
+ listDatabases(params: {
3410
+ pathParams: ListDatabasesPathParams;
3411
+ queryParams?: ListDatabasesQueryParams;
3412
+ }): Promise<ListDatabasesQueryResponse>;
3413
+ createDatabase(params: {
3414
+ pathParams: CreateDatabasePathParams;
3415
+ body: CreateDatabaseMutationRequest;
3416
+ }): Promise<CreateDatabaseMutationResponse>;
3417
+ getDatabase(params: {
3418
+ pathParams: GetDatabasePathParams;
3419
+ }): Promise<GetDatabaseQueryResponse>;
3420
+ updateDatabase(params: {
3421
+ pathParams: UpdateDatabasePathParams;
3422
+ body: UpdateDatabaseMutationRequest;
3423
+ }): Promise<UpdateDatabaseMutationResponse>;
3424
+ deleteDatabase(params: {
3425
+ pathParams: DeleteDatabasePathParams;
3426
+ }): Promise<void>;
3427
+ testDatabaseConnection(params: {
3428
+ pathParams: TestDatabaseConnectionPathParams;
3429
+ }): Promise<TestDatabaseConnectionMutationResponse>;
3430
+ };
3431
+ platform: {
3432
+ getHealth(): Promise<GetHealthQueryResponse>;
3433
+ listRegions(): Promise<ListRegionsQueryResponse>;
3147
3434
  };
3148
3435
  }
3149
3436
  interface RequestMap {
@@ -3168,14 +3455,28 @@ interface RequestMap {
3168
3455
  };
3169
3456
  response: GetOrganizationPlanQueryResponse;
3170
3457
  };
3171
- "GET /v1/projects/{project_id}/databases/{database_id}/catalog": {
3458
+ "PUT /v1/organizations/{org_id}/spend-limit": {
3172
3459
  params: {
3173
- pathParams: ListQueryCatalogPathParams;
3174
- queryParams?: ListQueryCatalogQueryParams;
3460
+ pathParams: UpdateSpendLimitPathParams;
3461
+ body: UpdateSpendLimitMutationRequest;
3175
3462
  };
3176
- response: ListQueryCatalogQueryResponse;
3463
+ response: UpdateSpendLimitMutationResponse;
3464
+ };
3465
+ "POST /v1/organizations/{org_id}/cancellation-feedback": {
3466
+ params: {
3467
+ pathParams: SubmitCancellationFeedbackPathParams;
3468
+ body: SubmitCancellationFeedbackMutationRequest;
3469
+ };
3470
+ response: void;
3177
3471
  };
3178
- "PUT /v1/projects/{project_id}/databases/{database_id}/catalog/{query_hash}/cache-rule": {
3472
+ "GET /v1/projects/{project_id}/databases/{database_id}/cache-rules": {
3473
+ params: {
3474
+ pathParams: ListCacheRulesPathParams;
3475
+ queryParams?: ListCacheRulesQueryParams;
3476
+ };
3477
+ response: ListCacheRulesQueryResponse;
3478
+ };
3479
+ "PUT /v1/projects/{project_id}/databases/{database_id}/cache-rules/{query_hash}": {
3179
3480
  params: {
3180
3481
  pathParams: UpdateCacheRulePathParams;
3181
3482
  body: UpdateCacheRuleMutationRequest;
@@ -3346,12 +3647,6 @@ interface RequestMap {
3346
3647
  };
3347
3648
  response: GetProjectUsageQueryResponse;
3348
3649
  };
3349
- "POST /v1/waitlist": {
3350
- params: {
3351
- body: JoinWaitlistMutationRequest;
3352
- };
3353
- response: JoinWaitlistMutationResponse;
3354
- };
3355
3650
  }
3356
3651
  type ApiTag = keyof ApiOperations;
3357
3652
  type Route = keyof RequestMap;