From fec322b3e95e4fbf45e0c6997a1171558392fe47 Mon Sep 17 00:00:00 2001
From: "microsoft-playwright-automation[bot]"
<203992400+microsoft-playwright-automation[bot]@users.noreply.github.com>
Date: Wed, 21 Jan 2026 10:13:00 +0000
Subject: [PATCH] feat(roll): roll to ToT Playwright (21-01-26)
---
nodejs/docs/api/class-page.mdx | 4 ++++
nodejs/docs/api/class-pageagent.mdx | 6 +++---
2 files changed, 7 insertions(+), 3 deletions(-)
diff --git a/nodejs/docs/api/class-page.mdx b/nodejs/docs/api/class-page.mdx
index ad5637ee4a..10b8a3ac60 100644
--- a/nodejs/docs/api/class-page.mdx
+++ b/nodejs/docs/api/class-page.mdx
@@ -279,6 +279,10 @@ await page.agent(options);
- `cacheOutFile` [string] *(optional)*
When specified, generated entries are written into the `cacheOutFile` instead of updating the `cacheFile`.
+ - `expect` [Object] *(optional)*#
+ - `timeout` [number] *(optional)*
+
+ Default timeout for expect calls in milliseconds, defaults to 5000ms.
- `limits` [Object] *(optional)*#
- `maxTokens` [number] *(optional)*
diff --git a/nodejs/docs/api/class-pageagent.mdx b/nodejs/docs/api/class-pageagent.mdx
index f2820ede7d..e53b521f2f 100644
--- a/nodejs/docs/api/class-pageagent.mdx
+++ b/nodejs/docs/api/class-pageagent.mdx
@@ -60,7 +60,7 @@ await agent.expect('"0 items" to be reported');
Maximum number of tokens to consume. The agentic loop will stop after input + output tokens exceed this value. Defaults to context-wide value specified in `agent` property.
- `timeout` [number] *(optional)*#
- Request timeout in milliseconds. Defaults to action timeout. Pass `0` to disable timeout.
+ Expect timeout in milliseconds. Defaults to `5000`. The default value can be changed via `expect.timeout` option in the config, or by specifying the `expect` property of the [expect](/api/class-page.mdx#page-agent-option-expect) option. Pass `0` to disable timeout.
**Returns**
- [Promise]<[void]>#
@@ -102,7 +102,7 @@ await agent.extract('List of items in the cart', z.object({
Maximum number of tokens to consume. The agentic loop will stop after input + output tokens exceed this value. Defaults to context-wide value specified in `agent` property.
- `timeout` [number] *(optional)*#
- Request timeout in milliseconds. Defaults to action timeout. Pass `0` to disable timeout.
+ Extract timeout in milliseconds. Defaults to `5000`. The default value can be changed via `actionTimeout` option in the config, or by using the [browserContext.setDefaultTimeout()](/api/class-browsercontext.mdx#browser-context-set-default-timeout) or [page.setDefaultTimeout()](/api/class-page.mdx#page-set-default-timeout) methods. Pass `0` to disable timeout.
**Returns**
- [Promise]<[Object]>#
@@ -153,7 +153,7 @@ await agent.perform('Click submit button');
Maximum number of tokens to consume. The agentic loop will stop after input + output tokens exceed this value. Defaults to context-wide value specified in `agent` property.
- `timeout` [number] *(optional)*#
- Request timeout in milliseconds. Defaults to action timeout. Pass `0` to disable timeout.
+ Perform timeout in milliseconds. Defaults to `5000`. The default value can be changed via `actionTimeout` option in the config, or by using the [browserContext.setDefaultTimeout()](/api/class-browsercontext.mdx#browser-context-set-default-timeout) or [page.setDefaultTimeout()](/api/class-page.mdx#page-set-default-timeout) methods. Pass `0` to disable timeout.
**Returns**
- [Promise]<[Object]>#