@onkernel/sdk 0.87.1 → 0.90.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.
Files changed (95) hide show
  1. package/CHANGELOG.md +25 -1
  2. package/client.d.mts +6 -3
  3. package/client.d.mts.map +1 -1
  4. package/client.d.ts +6 -3
  5. package/client.d.ts.map +1 -1
  6. package/client.js +6 -1
  7. package/client.js.map +1 -1
  8. package/client.mjs +6 -1
  9. package/client.mjs.map +1 -1
  10. package/package.json +1 -1
  11. package/resources/auth/auth.d.mts +2 -2
  12. package/resources/auth/auth.d.mts.map +1 -1
  13. package/resources/auth/auth.d.ts +2 -2
  14. package/resources/auth/auth.d.ts.map +1 -1
  15. package/resources/auth/auth.js.map +1 -1
  16. package/resources/auth/auth.mjs.map +1 -1
  17. package/resources/auth/connections.d.mts +238 -88
  18. package/resources/auth/connections.d.mts.map +1 -1
  19. package/resources/auth/connections.d.ts +238 -88
  20. package/resources/auth/connections.d.ts.map +1 -1
  21. package/resources/auth/connections.js.map +1 -1
  22. package/resources/auth/connections.mjs.map +1 -1
  23. package/resources/auth/index.d.mts +1 -1
  24. package/resources/auth/index.d.mts.map +1 -1
  25. package/resources/auth/index.d.ts +1 -1
  26. package/resources/auth/index.d.ts.map +1 -1
  27. package/resources/auth/index.js.map +1 -1
  28. package/resources/auth/index.mjs.map +1 -1
  29. package/resources/browser-pools.d.mts +46 -1
  30. package/resources/browser-pools.d.mts.map +1 -1
  31. package/resources/browser-pools.d.ts +46 -1
  32. package/resources/browser-pools.d.ts.map +1 -1
  33. package/resources/browsers/browsers.d.mts +194 -13
  34. package/resources/browsers/browsers.d.mts.map +1 -1
  35. package/resources/browsers/browsers.d.ts +194 -13
  36. package/resources/browsers/browsers.d.ts.map +1 -1
  37. package/resources/browsers/browsers.js.map +1 -1
  38. package/resources/browsers/browsers.mjs.map +1 -1
  39. package/resources/browsers/index.d.mts +1 -1
  40. package/resources/browsers/index.d.mts.map +1 -1
  41. package/resources/browsers/index.d.ts +1 -1
  42. package/resources/browsers/index.d.ts.map +1 -1
  43. package/resources/browsers/index.js.map +1 -1
  44. package/resources/browsers/index.mjs.map +1 -1
  45. package/resources/index.d.mts +1 -1
  46. package/resources/index.d.mts.map +1 -1
  47. package/resources/index.d.ts +1 -1
  48. package/resources/index.d.ts.map +1 -1
  49. package/resources/index.js.map +1 -1
  50. package/resources/index.mjs.map +1 -1
  51. package/resources/invocations.d.mts +15 -1
  52. package/resources/invocations.d.mts.map +1 -1
  53. package/resources/invocations.d.ts +15 -1
  54. package/resources/invocations.d.ts.map +1 -1
  55. package/resources/organization/limits.d.mts +18 -3
  56. package/resources/organization/limits.d.mts.map +1 -1
  57. package/resources/organization/limits.d.ts +18 -3
  58. package/resources/organization/limits.d.ts.map +1 -1
  59. package/resources/organization/limits.js +1 -3
  60. package/resources/organization/limits.js.map +1 -1
  61. package/resources/organization/limits.mjs +1 -3
  62. package/resources/organization/limits.mjs.map +1 -1
  63. package/resources/projects/limits.d.mts +4 -4
  64. package/resources/projects/limits.d.mts.map +1 -1
  65. package/resources/projects/limits.d.ts +4 -4
  66. package/resources/projects/limits.d.ts.map +1 -1
  67. package/resources/projects/limits.js +6 -6
  68. package/resources/projects/limits.js.map +1 -1
  69. package/resources/projects/limits.mjs +6 -6
  70. package/resources/projects/limits.mjs.map +1 -1
  71. package/resources/projects/projects.d.mts +12 -10
  72. package/resources/projects/projects.d.mts.map +1 -1
  73. package/resources/projects/projects.d.ts +12 -10
  74. package/resources/projects/projects.d.ts.map +1 -1
  75. package/resources/projects/projects.js +11 -9
  76. package/resources/projects/projects.js.map +1 -1
  77. package/resources/projects/projects.mjs +11 -9
  78. package/resources/projects/projects.mjs.map +1 -1
  79. package/src/client.ts +17 -0
  80. package/src/resources/auth/auth.ts +2 -0
  81. package/src/resources/auth/connections.ts +286 -87
  82. package/src/resources/auth/index.ts +1 -0
  83. package/src/resources/browser-pools.ts +55 -1
  84. package/src/resources/browsers/browsers.ts +222 -12
  85. package/src/resources/browsers/index.ts +4 -0
  86. package/src/resources/index.ts +4 -0
  87. package/src/resources/invocations.ts +18 -1
  88. package/src/resources/organization/limits.ts +21 -3
  89. package/src/resources/projects/limits.ts +6 -6
  90. package/src/resources/projects/projects.ts +15 -13
  91. package/src/version.ts +1 -1
  92. package/version.d.mts +1 -1
  93. package/version.d.ts +1 -1
  94. package/version.js +1 -1
  95. package/version.mjs +1 -1
@@ -196,6 +196,11 @@ export interface BrowserPool {
196
196
  */
197
197
  extension_ids: Array<string>;
198
198
 
199
+ /**
200
+ * Geographic region of the browser pool. Fixed once the pool is created.
201
+ */
202
+ region: 'us-east' | 'eu-west';
203
+
199
204
  /**
200
205
  * Browser pool name, if set
201
206
  */
@@ -258,6 +263,12 @@ export namespace BrowserPool {
258
263
  */
259
264
  name?: string;
260
265
 
266
+ /**
267
+ * Network configuration applied to browsers in this pool, if any. Omitted when the
268
+ * pool has no network configuration.
269
+ */
270
+ network?: BrowsersAPI.BrowserNetworkConfig;
271
+
261
272
  /**
262
273
  * Profile configuration for browsers in a pool. Provide either id or name.
263
274
  * Profiles must be created beforehand. Unlike single browser sessions, pools load
@@ -363,6 +374,11 @@ export interface BrowserPoolAcquireResponse {
363
374
  */
364
375
  headless: boolean;
365
376
 
377
+ /**
378
+ * Geographic region of the browser session. Fixed once the session is created.
379
+ */
380
+ region: 'us-east' | 'eu-west';
381
+
366
382
  /**
367
383
  * Unique identifier for the browser session
368
384
  */
@@ -422,6 +438,12 @@ export interface BrowserPoolAcquireResponse {
422
438
  */
423
439
  name?: string;
424
440
 
441
+ /**
442
+ * Network configuration the session was created with, if any. Omitted when the
443
+ * session has no network configuration.
444
+ */
445
+ network?: BrowsersAPI.BrowserNetworkConfig;
446
+
425
447
  /**
426
448
  * Browser pool this session was acquired from, if any.
427
449
  */
@@ -439,7 +461,13 @@ export interface BrowserPoolAcquireResponse {
439
461
  profile_save_changes?: boolean;
440
462
 
441
463
  /**
442
- * ID of the proxy associated with this browser session, if any.
464
+ * Resolved proxy configuration for this browser session.
465
+ */
466
+ proxy?: BrowsersAPI.BrowserProxy;
467
+
468
+ /**
469
+ * @deprecated ID of the proxy associated with this browser session, if any.
470
+ * Deprecated in favor of proxy.
443
471
  */
444
472
  proxy_id?: string;
445
473
 
@@ -530,6 +558,11 @@ export interface BrowserPoolCreateParams {
530
558
  */
531
559
  name?: string;
532
560
 
561
+ /**
562
+ * Network configuration applied to browsers in this pool.
563
+ */
564
+ network?: BrowsersAPI.BrowserNetworkConfig;
565
+
533
566
  /**
534
567
  * Profile configuration for browsers in a pool. Provide either id or name.
535
568
  * Profiles must be created beforehand. Unlike single browser sessions, pools load
@@ -552,6 +585,13 @@ export interface BrowserPoolCreateParams {
552
585
  */
553
586
  refresh_on_profile_update?: boolean;
554
587
 
588
+ /**
589
+ * Geographic region for the browser pool. It is fixed once the pool is created.
590
+ * Region selection requires a Start-Up or Enterprise plan, defaults to us-east
591
+ * when omitted on create.
592
+ */
593
+ region?: 'us-east' | 'eu-west';
594
+
555
595
  /**
556
596
  * Optional URL to navigate to when a new browser is warmed into the pool.
557
597
  * Best-effort: failures to navigate do not fail pool fill. Only applied to
@@ -764,6 +804,15 @@ export interface BrowserPoolUpdateParams {
764
804
  */
765
805
  name?: string;
766
806
 
807
+ /**
808
+ * If provided, replaces the pool's network configuration. Omit to leave the
809
+ * existing configuration unchanged; an empty object ({}) removes it, while
810
+ * network: {private_hosts: []} sets an explicit empty list. Only applied to
811
+ * browsers created in the pool after the update; browsers already in the pool keep
812
+ * their configuration until discarded (see discard_all_idle).
813
+ */
814
+ network?: BrowsersAPI.BrowserNetworkConfig;
815
+
767
816
  /**
768
817
  * Profile configuration for browsers in a pool. Provide either id or name.
769
818
  * Profiles must be created beforehand. Unlike single browser sessions, pools load
@@ -970,6 +1019,11 @@ export interface BrowserPoolListParams extends OffsetPaginationParams {
970
1019
  * value.
971
1020
  */
972
1021
  query?: string;
1022
+
1023
+ /**
1024
+ * Filter pools by geographic region. Omit to list pools in all regions.
1025
+ */
1026
+ region?: 'us-east' | 'eu-west';
973
1027
  }
974
1028
 
975
1029
  export interface BrowserPoolDeleteParams {
@@ -281,6 +281,37 @@ export type BrowserListResponsesOffsetPagination = OffsetPagination<BrowserListR
281
281
 
282
282
  export type ProfilesOffsetPagination = OffsetPagination<Profile>;
283
283
 
284
+ /**
285
+ * Network configuration for a browser session or browser pool.
286
+ */
287
+ export interface BrowserNetworkConfig {
288
+ /**
289
+ * Destinations the browser reaches directly through the session's own network
290
+ * instead of through Kernel-managed egress — for private hosts reachable over a
291
+ * VPN or tunnel the session has joined (e.g. a Tailscale tailnet). By default,
292
+ * private IP ranges already route directly: RFC1918 (10.0.0.0/8, 172.16.0.0/12,
293
+ * 192.168.0.0/16), CGNAT/Tailscale (100.64.0.0/10), and IPv6 ULA (fc00::/7). An
294
+ * explicitly supplied list replaces those defaults with exactly the entries given,
295
+ * and an empty list ([]) disables them so all traffic uses Kernel-managed egress;
296
+ * omit private_hosts to keep the defaults. Entries are hostname patterns
297
+ * ("_.example.ts.net", "preview.internal") or IP/CIDR literals ("100.64.0.0/10",
298
+ * "10.1.30.63"). IP and CIDR entries only match URLs written with a literal IP
299
+ * address; they never match hostnames that resolve into the range, so private DNS
300
+ * names need a hostname entry even when they resolve inside the default ranges.
301
+ * CIDRs must be in canonical masked form (host bits zero), and only the private
302
+ * ranges listed above are accepted; public, loopback, link-local, and unspecified
303
+ * ranges are rejected. Exact IPv6 addresses must be bracketed ("[fd00::1]"); IPv6
304
+ * CIDR ranges are unbracketed ("fd00::/8"). Wildcards are limited to one leading
305
+ * "_." over a suffix with at least two labels that is not a public suffix (so
306
+ * "_.co.uk" or "_.ts.net" are rejected, while "\*.example.ts.net" is accepted).
307
+ * Hostname and IP entries may carry a port; CIDR ranges may not. Hostname entries
308
+ * are not resolved during validation, so callers must ensure they identify private
309
+ * destinations. Not related to a proxy's bypass_hosts, which selects between
310
+ * upstream-proxy and Kernel-managed direct egress and cannot reach into a VPN.
311
+ */
312
+ private_hosts?: Array<string>;
313
+ }
314
+
284
315
  /**
285
316
  * Browser pool this session was acquired from, if any.
286
317
  */
@@ -296,6 +327,72 @@ export interface BrowserPoolRef {
296
327
  name?: string;
297
328
  }
298
329
 
330
+ /**
331
+ * Resolved proxy configuration for a browser session. Selected proxies are
332
+ * returned by stable ID.
333
+ */
334
+ export interface BrowserProxy {
335
+ /**
336
+ * Selected proxy ID.
337
+ */
338
+ id?: string;
339
+
340
+ /**
341
+ * Proxy egress mode. direct forces no proxy regardless of stealth. default uses
342
+ * the browser's stealth-derived default: Kernel's default stealth proxy when
343
+ * stealth=true, or direct egress when stealth=false. default is primarily useful
344
+ * on browser update to restore the browser default after selected-proxy egress.
345
+ */
346
+ mode?: BrowserProxyMode;
347
+
348
+ /**
349
+ * Selected proxy name.
350
+ */
351
+ name?: string;
352
+ }
353
+
354
+ /**
355
+ * Browser proxy configuration. Provide exactly one of mode, id, or name; an empty
356
+ * object is invalid. Set mode to direct for no proxy regardless of stealth. Set
357
+ * mode to default to use the browser's stealth-derived default: Kernel's default
358
+ * stealth proxy when stealth=true, or direct egress when stealth=false. Select id
359
+ * or name to use that proxy regardless of stealth. The selected proxy must be in
360
+ * the same project as the browser. Names must match exactly one active proxy; use
361
+ * id for stable references. Proxy configuration changes only egress and does not
362
+ * change stealth or CAPTCHA solver behavior. A stealth browser using mode=direct
363
+ * still runs in stealth mode with the CAPTCHA solver enabled. When proxy is
364
+ * omitted on browser creation, stealth browsers use Kernel's default stealth proxy
365
+ * and non-stealth browsers use direct egress. When omitted on update, the current
366
+ * configuration is unchanged.
367
+ */
368
+ export interface BrowserProxyConfig {
369
+ /**
370
+ * Proxy ID.
371
+ */
372
+ id?: string;
373
+
374
+ /**
375
+ * Proxy egress mode. direct forces no proxy regardless of stealth. default uses
376
+ * the browser's stealth-derived default: Kernel's default stealth proxy when
377
+ * stealth=true, or direct egress when stealth=false. default is primarily useful
378
+ * on browser update to restore the browser default after selected-proxy egress.
379
+ */
380
+ mode?: BrowserProxyMode;
381
+
382
+ /**
383
+ * Proxy name. Must match exactly one active proxy in the project.
384
+ */
385
+ name?: string;
386
+ }
387
+
388
+ /**
389
+ * Proxy egress mode. direct forces no proxy regardless of stealth. default uses
390
+ * the browser's stealth-derived default: Kernel's default stealth proxy when
391
+ * stealth=true, or direct egress when stealth=false. default is primarily useful
392
+ * on browser update to restore the browser default after selected-proxy egress.
393
+ */
394
+ export type BrowserProxyMode = 'direct' | 'default';
395
+
299
396
  /**
300
397
  * Session usage metrics.
301
398
  */
@@ -357,6 +454,11 @@ export interface BrowserCreateResponse {
357
454
  */
358
455
  headless: boolean;
359
456
 
457
+ /**
458
+ * Geographic region of the browser session. Fixed once the session is created.
459
+ */
460
+ region: 'us-east' | 'eu-west';
461
+
360
462
  /**
361
463
  * Unique identifier for the browser session
362
464
  */
@@ -416,6 +518,12 @@ export interface BrowserCreateResponse {
416
518
  */
417
519
  name?: string;
418
520
 
521
+ /**
522
+ * Network configuration the session was created with, if any. Omitted when the
523
+ * session has no network configuration.
524
+ */
525
+ network?: BrowserNetworkConfig;
526
+
419
527
  /**
420
528
  * Browser pool this session was acquired from, if any.
421
529
  */
@@ -433,7 +541,13 @@ export interface BrowserCreateResponse {
433
541
  profile_save_changes?: boolean;
434
542
 
435
543
  /**
436
- * ID of the proxy associated with this browser session, if any.
544
+ * Resolved proxy configuration for this browser session.
545
+ */
546
+ proxy?: BrowserProxy;
547
+
548
+ /**
549
+ * @deprecated ID of the proxy associated with this browser session, if any.
550
+ * Deprecated in favor of proxy.
437
551
  */
438
552
  proxy_id?: string;
439
553
 
@@ -495,6 +609,11 @@ export interface BrowserRetrieveResponse {
495
609
  */
496
610
  headless: boolean;
497
611
 
612
+ /**
613
+ * Geographic region of the browser session. Fixed once the session is created.
614
+ */
615
+ region: 'us-east' | 'eu-west';
616
+
498
617
  /**
499
618
  * Unique identifier for the browser session
500
619
  */
@@ -554,6 +673,12 @@ export interface BrowserRetrieveResponse {
554
673
  */
555
674
  name?: string;
556
675
 
676
+ /**
677
+ * Network configuration the session was created with, if any. Omitted when the
678
+ * session has no network configuration.
679
+ */
680
+ network?: BrowserNetworkConfig;
681
+
557
682
  /**
558
683
  * Browser pool this session was acquired from, if any.
559
684
  */
@@ -571,7 +696,13 @@ export interface BrowserRetrieveResponse {
571
696
  profile_save_changes?: boolean;
572
697
 
573
698
  /**
574
- * ID of the proxy associated with this browser session, if any.
699
+ * Resolved proxy configuration for this browser session.
700
+ */
701
+ proxy?: BrowserProxy;
702
+
703
+ /**
704
+ * @deprecated ID of the proxy associated with this browser session, if any.
705
+ * Deprecated in favor of proxy.
575
706
  */
576
707
  proxy_id?: string;
577
708
 
@@ -633,6 +764,11 @@ export interface BrowserUpdateResponse {
633
764
  */
634
765
  headless: boolean;
635
766
 
767
+ /**
768
+ * Geographic region of the browser session. Fixed once the session is created.
769
+ */
770
+ region: 'us-east' | 'eu-west';
771
+
636
772
  /**
637
773
  * Unique identifier for the browser session
638
774
  */
@@ -692,6 +828,12 @@ export interface BrowserUpdateResponse {
692
828
  */
693
829
  name?: string;
694
830
 
831
+ /**
832
+ * Network configuration the session was created with, if any. Omitted when the
833
+ * session has no network configuration.
834
+ */
835
+ network?: BrowserNetworkConfig;
836
+
695
837
  /**
696
838
  * Browser pool this session was acquired from, if any.
697
839
  */
@@ -709,7 +851,13 @@ export interface BrowserUpdateResponse {
709
851
  profile_save_changes?: boolean;
710
852
 
711
853
  /**
712
- * ID of the proxy associated with this browser session, if any.
854
+ * Resolved proxy configuration for this browser session.
855
+ */
856
+ proxy?: BrowserProxy;
857
+
858
+ /**
859
+ * @deprecated ID of the proxy associated with this browser session, if any.
860
+ * Deprecated in favor of proxy.
713
861
  */
714
862
  proxy_id?: string;
715
863
 
@@ -771,6 +919,11 @@ export interface BrowserListResponse {
771
919
  */
772
920
  headless: boolean;
773
921
 
922
+ /**
923
+ * Geographic region of the browser session. Fixed once the session is created.
924
+ */
925
+ region: 'us-east' | 'eu-west';
926
+
774
927
  /**
775
928
  * Unique identifier for the browser session
776
929
  */
@@ -830,6 +983,12 @@ export interface BrowserListResponse {
830
983
  */
831
984
  name?: string;
832
985
 
986
+ /**
987
+ * Network configuration the session was created with, if any. Omitted when the
988
+ * session has no network configuration.
989
+ */
990
+ network?: BrowserNetworkConfig;
991
+
833
992
  /**
834
993
  * Browser pool this session was acquired from, if any.
835
994
  */
@@ -847,7 +1006,13 @@ export interface BrowserListResponse {
847
1006
  profile_save_changes?: boolean;
848
1007
 
849
1008
  /**
850
- * ID of the proxy associated with this browser session, if any.
1009
+ * Resolved proxy configuration for this browser session.
1010
+ */
1011
+ proxy?: BrowserProxy;
1012
+
1013
+ /**
1014
+ * @deprecated ID of the proxy associated with this browser session, if any.
1015
+ * Deprecated in favor of proxy.
851
1016
  */
852
1017
  proxy_id?: string;
853
1018
 
@@ -962,6 +1127,11 @@ export interface BrowserCreateParams {
962
1127
  */
963
1128
  name?: string;
964
1129
 
1130
+ /**
1131
+ * Network configuration for the browser session. Cannot be changed after creation.
1132
+ */
1133
+ network?: BrowserNetworkConfig;
1134
+
965
1135
  /**
966
1136
  * Profile selection for the browser session. Provide either id or name. If
967
1137
  * specified, the matching profile will be loaded into the browser session.
@@ -970,11 +1140,29 @@ export interface BrowserCreateParams {
970
1140
  profile?: Shared.BrowserProfile;
971
1141
 
972
1142
  /**
973
- * Optional proxy to associate to the browser session. Must reference a proxy in
974
- * the same project as the browser session.
1143
+ * Proxy configuration for the browser session. Cannot be combined with proxy_id.
1144
+ * Omit to use the browser default: stealth browsers use Kernel's default stealth
1145
+ * proxy, while non-stealth browsers use direct egress. Set mode to direct to force
1146
+ * direct egress regardless of stealth. Set mode to default to explicitly use the
1147
+ * browser default: Kernel's default stealth proxy when stealth=true, or direct
1148
+ * egress when stealth=false. Select id or name to use that proxy regardless of
1149
+ * stealth. Proxy selection does not change stealth or CAPTCHA solver behavior.
1150
+ */
1151
+ proxy?: BrowserProxyConfig;
1152
+
1153
+ /**
1154
+ * @deprecated Optional proxy to associate to the browser session. Must reference a
1155
+ * proxy in the same project as the browser session. Deprecated in favor of proxy.
975
1156
  */
976
1157
  proxy_id?: string;
977
1158
 
1159
+ /**
1160
+ * Geographic region for the browser session. It is fixed once the session is
1161
+ * created. Region selection requires a Start-Up or Enterprise plan, defaults to
1162
+ * us-east when omitted on create.
1163
+ */
1164
+ region?: 'us-east' | 'eu-west';
1165
+
978
1166
  /**
979
1167
  * Optional URL to open when the browser session is created. Navigation is
980
1168
  * best-effort, so navigation failures do not prevent the session from being
@@ -983,8 +1171,11 @@ export interface BrowserCreateParams {
983
1171
  start_url?: string;
984
1172
 
985
1173
  /**
986
- * If true, launches the browser in stealth mode to reduce detection by anti-bot
987
- * mechanisms.
1174
+ * If true, launches the browser in stealth mode and enables the CAPTCHA solver.
1175
+ * Defaults to false. When proxy is omitted, stealth browsers use Kernel's default
1176
+ * stealth proxy and non-stealth browsers use direct egress. An explicit proxy
1177
+ * configuration changes only egress; it does not enable or disable stealth or the
1178
+ * CAPTCHA solver.
988
1179
  */
989
1180
  stealth?: boolean;
990
1181
 
@@ -1132,8 +1323,8 @@ export interface BrowserRetrieveParams {
1132
1323
 
1133
1324
  export interface BrowserUpdateParams {
1134
1325
  /**
1135
- * If true, stealth browsers connect directly instead of using the default stealth
1136
- * proxy.
1326
+ * @deprecated If true, stealth browsers connect directly instead of using the
1327
+ * default stealth proxy. Deprecated in favor of proxy.mode.
1137
1328
  */
1138
1329
  disable_default_proxy?: boolean;
1139
1330
 
@@ -1151,8 +1342,18 @@ export interface BrowserUpdateParams {
1151
1342
  profile?: Shared.BrowserProfile;
1152
1343
 
1153
1344
  /**
1154
- * ID of the proxy to use. Omit to leave unchanged, set to empty string to remove
1155
- * proxy.
1345
+ * Proxy configuration to apply. Omit to leave the current configuration unchanged.
1346
+ * Cannot be combined with proxy_id or disable_default_proxy. Set mode to direct to
1347
+ * switch to direct egress regardless of stealth. Set mode to default to restore
1348
+ * the browser default after using a selected proxy: Kernel's default stealth proxy
1349
+ * for a stealth browser, or direct egress for a non-stealth browser. Updating
1350
+ * proxy does not change stealth or CAPTCHA solver behavior.
1351
+ */
1352
+ proxy?: BrowserProxyConfig;
1353
+
1354
+ /**
1355
+ * @deprecated ID of the proxy to use. Omit to leave unchanged, set to empty string
1356
+ * to remove proxy. Deprecated in favor of proxy.
1156
1357
  */
1157
1358
  proxy_id?: string | null;
1158
1359
 
@@ -1296,6 +1497,11 @@ export interface BrowserListParams extends OffsetPaginationParams {
1296
1497
  */
1297
1498
  query?: string;
1298
1499
 
1500
+ /**
1501
+ * Filter sessions by geographic region. Omit to list sessions in all regions.
1502
+ */
1503
+ region?: 'us-east' | 'eu-west';
1504
+
1299
1505
  /**
1300
1506
  * Filter sessions by status. "active" returns only active sessions (default),
1301
1507
  * "deleted" returns only soft-deleted sessions, "all" returns both.
@@ -1374,7 +1580,11 @@ Browsers.Playwright = Playwright;
1374
1580
 
1375
1581
  export declare namespace Browsers {
1376
1582
  export {
1583
+ type BrowserNetworkConfig as BrowserNetworkConfig,
1377
1584
  type BrowserPoolRef as BrowserPoolRef,
1585
+ type BrowserProxy as BrowserProxy,
1586
+ type BrowserProxyConfig as BrowserProxyConfig,
1587
+ type BrowserProxyMode as BrowserProxyMode,
1378
1588
  type BrowserUsage as BrowserUsage,
1379
1589
  type Profile as Profile,
1380
1590
  type Tags as Tags,
@@ -2,7 +2,11 @@
2
2
 
3
3
  export {
4
4
  Browsers,
5
+ type BrowserNetworkConfig,
5
6
  type BrowserPoolRef,
7
+ type BrowserProxy,
8
+ type BrowserProxyConfig,
9
+ type BrowserProxyMode,
6
10
  type BrowserUsage,
7
11
  type Profile,
8
12
  type Tags,
@@ -40,7 +40,11 @@ export {
40
40
  } from './browser-pools';
41
41
  export {
42
42
  Browsers,
43
+ type BrowserNetworkConfig,
43
44
  type BrowserPoolRef,
45
+ type BrowserProxy,
46
+ type BrowserProxyConfig,
47
+ type BrowserProxyMode,
44
48
  type BrowserUsage,
45
49
  type Profile,
46
50
  type Tags,
@@ -434,6 +434,11 @@ export namespace InvocationListBrowsersResponse {
434
434
  */
435
435
  headless: boolean;
436
436
 
437
+ /**
438
+ * Geographic region of the browser session. Fixed once the session is created.
439
+ */
440
+ region: 'us-east' | 'eu-west';
441
+
437
442
  /**
438
443
  * Unique identifier for the browser session
439
444
  */
@@ -493,6 +498,12 @@ export namespace InvocationListBrowsersResponse {
493
498
  */
494
499
  name?: string;
495
500
 
501
+ /**
502
+ * Network configuration the session was created with, if any. Omitted when the
503
+ * session has no network configuration.
504
+ */
505
+ network?: BrowsersAPI.BrowserNetworkConfig;
506
+
496
507
  /**
497
508
  * Browser pool this session was acquired from, if any.
498
509
  */
@@ -510,7 +521,13 @@ export namespace InvocationListBrowsersResponse {
510
521
  profile_save_changes?: boolean;
511
522
 
512
523
  /**
513
- * ID of the proxy associated with this browser session, if any.
524
+ * Resolved proxy configuration for this browser session.
525
+ */
526
+ proxy?: BrowsersAPI.BrowserProxy;
527
+
528
+ /**
529
+ * @deprecated ID of the proxy associated with this browser session, if any.
530
+ * Deprecated in favor of proxy.
514
531
  */
515
532
  proxy_id?: string;
516
533
 
@@ -9,9 +9,7 @@ import { RequestOptions } from '../../internal/request-options';
9
9
  */
10
10
  export class Limits extends APIResource {
11
11
  /**
12
- * Get the organization's concurrency limit the maximum browsers running at once
13
- * across on-demand sessions and browser pool reservations — and the default
14
- * per-project concurrency cap applied to projects without an explicit override.
12
+ * Get the organization's effective limits and managed auth usage.
15
13
  */
16
14
  retrieve(options?: RequestOptions): APIPromise<OrgLimits> {
17
15
  return this._client.get('/org/limits', options);
@@ -28,6 +26,26 @@ export class Limits extends APIResource {
28
26
  }
29
27
 
30
28
  export interface OrgLimits {
29
+ /**
30
+ * The organization's current non-deleted managed auth connections, counted
31
+ * org-wide across every project. Compare against max_auth_connections to show
32
+ * remaining capacity before a create is rejected with 403 insufficient_plan.
33
+ */
34
+ auth_connections_used: number;
35
+
36
+ /**
37
+ * Maximum managed auth connections the organization's plan allows. Null means
38
+ * unlimited. Counted org-wide, so it cannot be multiplied across projects.
39
+ */
40
+ max_auth_connections: number | null;
41
+
42
+ /**
43
+ * Smallest health_check_interval the organization's plan accepts on a managed auth
44
+ * connection. Requests below this are rejected with 400. Existing connections
45
+ * stored below the floor are grandfathered until edited.
46
+ */
47
+ min_health_check_interval_seconds: number;
48
+
31
49
  /**
32
50
  * Default maximum concurrent browsers applied to every project that has no
33
51
  * explicit per-project override. Null means no org-level default, so such projects
@@ -18,12 +18,12 @@ export class Limits extends APIResource {
18
18
  * @example
19
19
  * ```ts
20
20
  * const projectLimits = await client.projects.limits.retrieve(
21
- * 'id',
21
+ * 'id_or_name',
22
22
  * );
23
23
  * ```
24
24
  */
25
- retrieve(id: string, options?: RequestOptions): APIPromise<ProjectLimits> {
26
- return this._client.get(path`/org/projects/${id}/limits`, options);
25
+ retrieve(idOrName: string, options?: RequestOptions): APIPromise<ProjectLimits> {
26
+ return this._client.get(path`/org/projects/${idOrName}/limits`, options);
27
27
  }
28
28
 
29
29
  /**
@@ -34,12 +34,12 @@ export class Limits extends APIResource {
34
34
  * @example
35
35
  * ```ts
36
36
  * const projectLimits = await client.projects.limits.update(
37
- * 'id',
37
+ * 'id_or_name',
38
38
  * );
39
39
  * ```
40
40
  */
41
- update(id: string, body: LimitUpdateParams, options?: RequestOptions): APIPromise<ProjectLimits> {
42
- return this._client.patch(path`/org/projects/${id}/limits`, { body, ...options });
41
+ update(idOrName: string, body: LimitUpdateParams, options?: RequestOptions): APIPromise<ProjectLimits> {
42
+ return this._client.patch(path`/org/projects/${idOrName}/limits`, { body, ...options });
43
43
  }
44
44
  }
45
45