@@ -143,7 +143,7 @@ export class Browsers extends APIResource {
143143 *
144144 * @example
145145 * ```ts
146- * await client.browsers.uploadExtensions ('id', {
146+ * await client.browsers.loadExtensions ('id', {
147147 * extensions: [
148148 * {
149149 * name: 'name',
@@ -153,11 +153,7 @@ export class Browsers extends APIResource {
153153 * });
154154 * ```
155155 */
156- uploadExtensions (
157- id : string ,
158- body : BrowserUploadExtensionsParams ,
159- options ?: RequestOptions ,
160- ) : APIPromise < void > {
156+ loadExtensions ( id : string , body : BrowserLoadExtensionsParams , options ?: RequestOptions ) : APIPromise < void > {
161157 return this . _client . post (
162158 path `/browsers/${ id } /extensions` ,
163159 multipartFormRequestOptions (
@@ -259,6 +255,48 @@ export interface BrowserCreateResponse {
259255 * ID of the proxy associated with this browser session, if any.
260256 */
261257 proxy_id ?: string ;
258+
259+ /**
260+ * Initial browser window size in pixels with optional refresh rate. If omitted,
261+ * image defaults apply (commonly 1024x768@60). Only specific viewport
262+ * configurations are supported. The server will reject unsupported combinations.
263+ * Supported resolutions are: 2560x1440@10, 1920x1080@25, 1920x1200@25,
264+ * 1440x900@25, 1024x768@60 If refresh_rate is not provided, it will be
265+ * automatically determined from the width and height if they match a supported
266+ * configuration exactly. Note: Higher resolutions may affect the responsiveness of
267+ * live view browser
268+ */
269+ viewport ?: BrowserCreateResponse . Viewport ;
270+ }
271+
272+ export namespace BrowserCreateResponse {
273+ /**
274+ * Initial browser window size in pixels with optional refresh rate. If omitted,
275+ * image defaults apply (commonly 1024x768@60). Only specific viewport
276+ * configurations are supported. The server will reject unsupported combinations.
277+ * Supported resolutions are: 2560x1440@10, 1920x1080@25, 1920x1200@25,
278+ * 1440x900@25, 1024x768@60 If refresh_rate is not provided, it will be
279+ * automatically determined from the width and height if they match a supported
280+ * configuration exactly. Note: Higher resolutions may affect the responsiveness of
281+ * live view browser
282+ */
283+ export interface Viewport {
284+ /**
285+ * Browser window height in pixels.
286+ */
287+ height : number ;
288+
289+ /**
290+ * Browser window width in pixels.
291+ */
292+ width : number ;
293+
294+ /**
295+ * Display refresh rate in Hz. If omitted, automatically determined from width and
296+ * height.
297+ */
298+ refresh_rate ?: number ;
299+ }
262300}
263301
264302export interface BrowserRetrieveResponse {
@@ -312,6 +350,48 @@ export interface BrowserRetrieveResponse {
312350 * ID of the proxy associated with this browser session, if any.
313351 */
314352 proxy_id ?: string ;
353+
354+ /**
355+ * Initial browser window size in pixels with optional refresh rate. If omitted,
356+ * image defaults apply (commonly 1024x768@60). Only specific viewport
357+ * configurations are supported. The server will reject unsupported combinations.
358+ * Supported resolutions are: 2560x1440@10, 1920x1080@25, 1920x1200@25,
359+ * 1440x900@25, 1024x768@60 If refresh_rate is not provided, it will be
360+ * automatically determined from the width and height if they match a supported
361+ * configuration exactly. Note: Higher resolutions may affect the responsiveness of
362+ * live view browser
363+ */
364+ viewport ?: BrowserRetrieveResponse . Viewport ;
365+ }
366+
367+ export namespace BrowserRetrieveResponse {
368+ /**
369+ * Initial browser window size in pixels with optional refresh rate. If omitted,
370+ * image defaults apply (commonly 1024x768@60). Only specific viewport
371+ * configurations are supported. The server will reject unsupported combinations.
372+ * Supported resolutions are: 2560x1440@10, 1920x1080@25, 1920x1200@25,
373+ * 1440x900@25, 1024x768@60 If refresh_rate is not provided, it will be
374+ * automatically determined from the width and height if they match a supported
375+ * configuration exactly. Note: Higher resolutions may affect the responsiveness of
376+ * live view browser
377+ */
378+ export interface Viewport {
379+ /**
380+ * Browser window height in pixels.
381+ */
382+ height : number ;
383+
384+ /**
385+ * Browser window width in pixels.
386+ */
387+ width : number ;
388+
389+ /**
390+ * Display refresh rate in Hz. If omitted, automatically determined from width and
391+ * height.
392+ */
393+ refresh_rate ?: number ;
394+ }
315395}
316396
317397export type BrowserListResponse = Array < BrowserListResponse . BrowserListResponseItem > ;
@@ -368,6 +448,48 @@ export namespace BrowserListResponse {
368448 * ID of the proxy associated with this browser session, if any.
369449 */
370450 proxy_id ?: string ;
451+
452+ /**
453+ * Initial browser window size in pixels with optional refresh rate. If omitted,
454+ * image defaults apply (commonly 1024x768@60). Only specific viewport
455+ * configurations are supported. The server will reject unsupported combinations.
456+ * Supported resolutions are: 2560x1440@10, 1920x1080@25, 1920x1200@25,
457+ * 1440x900@25, 1024x768@60 If refresh_rate is not provided, it will be
458+ * automatically determined from the width and height if they match a supported
459+ * configuration exactly. Note: Higher resolutions may affect the responsiveness of
460+ * live view browser
461+ */
462+ viewport ?: BrowserListResponseItem . Viewport ;
463+ }
464+
465+ export namespace BrowserListResponseItem {
466+ /**
467+ * Initial browser window size in pixels with optional refresh rate. If omitted,
468+ * image defaults apply (commonly 1024x768@60). Only specific viewport
469+ * configurations are supported. The server will reject unsupported combinations.
470+ * Supported resolutions are: 2560x1440@10, 1920x1080@25, 1920x1200@25,
471+ * 1440x900@25, 1024x768@60 If refresh_rate is not provided, it will be
472+ * automatically determined from the width and height if they match a supported
473+ * configuration exactly. Note: Higher resolutions may affect the responsiveness of
474+ * live view browser
475+ */
476+ export interface Viewport {
477+ /**
478+ * Browser window height in pixels.
479+ */
480+ height : number ;
481+
482+ /**
483+ * Browser window width in pixels.
484+ */
485+ width : number ;
486+
487+ /**
488+ * Display refresh rate in Hz. If omitted, automatically determined from width and
489+ * height.
490+ */
491+ refresh_rate ?: number ;
492+ }
371493 }
372494}
373495
@@ -421,6 +543,18 @@ export interface BrowserCreateParams {
421543 * specified value.
422544 */
423545 timeout_seconds ?: number ;
546+
547+ /**
548+ * Initial browser window size in pixels with optional refresh rate. If omitted,
549+ * image defaults apply (commonly 1024x768@60). Only specific viewport
550+ * configurations are supported. The server will reject unsupported combinations.
551+ * Supported resolutions are: 2560x1440@10, 1920x1080@25, 1920x1200@25,
552+ * 1440x900@25, 1024x768@60 If refresh_rate is not provided, it will be
553+ * automatically determined from the width and height if they match a supported
554+ * configuration exactly. Note: Higher resolutions may affect the responsiveness of
555+ * live view browser
556+ */
557+ viewport ?: BrowserCreateParams . Viewport ;
424558}
425559
426560export namespace BrowserCreateParams {
@@ -464,6 +598,34 @@ export namespace BrowserCreateParams {
464598 */
465599 save_changes ?: boolean ;
466600 }
601+
602+ /**
603+ * Initial browser window size in pixels with optional refresh rate. If omitted,
604+ * image defaults apply (commonly 1024x768@60). Only specific viewport
605+ * configurations are supported. The server will reject unsupported combinations.
606+ * Supported resolutions are: 2560x1440@10, 1920x1080@25, 1920x1200@25,
607+ * 1440x900@25, 1024x768@60 If refresh_rate is not provided, it will be
608+ * automatically determined from the width and height if they match a supported
609+ * configuration exactly. Note: Higher resolutions may affect the responsiveness of
610+ * live view browser
611+ */
612+ export interface Viewport {
613+ /**
614+ * Browser window height in pixels.
615+ */
616+ height : number ;
617+
618+ /**
619+ * Browser window width in pixels.
620+ */
621+ width : number ;
622+
623+ /**
624+ * Display refresh rate in Hz. If omitted, automatically determined from width and
625+ * height.
626+ */
627+ refresh_rate ?: number ;
628+ }
467629}
468630
469631export interface BrowserDeleteParams {
@@ -473,14 +635,14 @@ export interface BrowserDeleteParams {
473635 persistent_id : string ;
474636}
475637
476- export interface BrowserUploadExtensionsParams {
638+ export interface BrowserLoadExtensionsParams {
477639 /**
478640 * List of extensions to upload and activate
479641 */
480- extensions : Array < BrowserUploadExtensionsParams . Extension > ;
642+ extensions : Array < BrowserLoadExtensionsParams . Extension > ;
481643}
482644
483- export namespace BrowserUploadExtensionsParams {
645+ export namespace BrowserLoadExtensionsParams {
484646 export interface Extension {
485647 /**
486648 * Folder name to place the extension under /home/kernel/extensions/<name>
@@ -509,7 +671,7 @@ export declare namespace Browsers {
509671 type BrowserListResponse as BrowserListResponse ,
510672 type BrowserCreateParams as BrowserCreateParams ,
511673 type BrowserDeleteParams as BrowserDeleteParams ,
512- type BrowserUploadExtensionsParams as BrowserUploadExtensionsParams ,
674+ type BrowserLoadExtensionsParams as BrowserLoadExtensionsParams ,
513675 } ;
514676
515677 export {
0 commit comments