> For clean Markdown of any page, append .md to the page URL. > For a complete documentation index, see https://docs.airtop.ai/api-reference/airtop-api/extras/get-window-info-for-puppeteer-page/llms.txt. > For AI client integration (Claude Code, Cursor, etc.), connect to the MCP server at https://docs.airtop.ai/_mcp/server. Get the window information for a Puppeteer Page instance. > **Note** > > This functionality is only available on the Typescript SDK. ### Parameters **`session`** `ExternalSessionWithConnectionInfo` — required The session object containing connection information and session details. #### + Show 2 properties **`id`** `string` — required The unique identifier of the session. --- **`chromedriverUrl`** `string` — required The URL of the chromedriver instance associated with this session. --- --- **`page`** `puppeteer.Page` — required The Puppeteer Page instance to get window information for. --- **`request`** `GetWindowInfoRequest` Configuration options for the window info request. #### + Show 3 properties **`includeNavigationBar`** `boolean` Affects the live view configuration. A navigation bar is not shown in the live view of a browser by default. Set this to true to configure the returned liveViewUrl so that a navigation bar is rendered, allowing users to easily navigate the browser to other pages from the live view. --- **`disableResize`** `boolean` Affects the live view configuration. Set to true to configure the returned liveViewUrl so that the ability to resize the browser window from the live view is disabled (resizing is allowed by default). Note that, at initial load, the live view will automatically fill the parent frame (or local window if loaded directly) and cause the browser window to be resized to match. This parameter does not affect that initial load behavior. --- **`screenResolution`** `string` Affects the live view configuration. By default, a live view will fill the parent frame (or local window if loaded directly) when initially loaded, causing the browser window to be resized to match. This parameter can be used to instead configure the returned liveViewUrl so that the live view is loaded with fixed dimensions (e.g. 1280x720), resizing the browser window to match, and then disallows any further resizing from the live view. --- --- **`requestOptions`** `Windows.RequestOptions` Additional options to customize the request behavior. #### + Show 3 properties **`timeoutInSeconds`** `number` The maximum time to wait for a response in seconds. --- **`maxRetries`** `number` The number of times to retry the request. Defaults to 2. --- **`abortSignal`** `AbortSignal` A hook to abort the request. --- --- ### Returns Returns a Promise that resolves with the window information for the specified Puppeteer page. **`data`** `object` The main response data object containing window information. #### + Show 2 properties **`liveViewUrl`** `string` The URL that can be used to view the browser window in real-time. --- **`windowId`** `string` The unique identifier for the browser window. --- --- **`meta`** `object` Metadata about the request. #### + Show 1 property **`requestId`** `string` A unique identifier for this request. --- --- **`errors`** `array` An array of error objects if any errors occurred during the request. #### + Show 4 properties **`message`** `string` A human-readable error message describing what went wrong. --- **`code`** `string` A machine-readable error code identifying the type of error. --- **`details`** `object` Additional details about the error in key-value format. --- **`reason`** `string` Additional context about why the error occurred. --- --- **`warnings`** `array` An array of warning objects for non-critical issues. #### + Show 4 properties **`message`** `string` A human-readable warning message. --- **`code`** `string` A machine-readable warning code. --- **`details`** `object` Additional details about the warning in key-value format. --- **`reason`** `string` Additional context about why the warning was generated. --- --- **`Typescript`** ```javascript title="Typescript" import { AirtopClient } from '@airtop/sdk'; import puppeteer, { type Browser } from 'puppeteer'; client = new AirtopClient({ apiKey: AIRTOP_API_KEY }); const { data: session } = await client.sessions.create(); browser = await puppeteer.connect({ browserWSEndpoint: session.cdpWsUrl, headers: { Authorization: `Bearer ${AIRTOP_API_KEY}` || '', }, }); const page = await browser.newPage(); await page.setViewport({ width: 1280, height: 720 }); await page.goto('https://www.airtop.ai'); const windowInfo = await client.windows.getWindowInfoForPuppeteerPage(session, page); ```