web_applyCookies¶
Injects a set of cookies into the current browser context. Pass [cookiesJson] as a JSON string in Playwright’s storage-state cookie array shape, e.g.:
[{“name”:”sid”,”value”:”abc”,”domain”:”.example.com”,”path”:”/”,”httpOnly”:true,”secure”:true,”sameSite”:”Lax”}]
Typically used to replay a previously-saved authenticated session so a trail can skip a full UI login. Pair with web_getStorageState (for capture) and web_navigate (to drive to the authenticated landing page after applying).
Source¶
- Kind: class-backed
- Class:
xyz.block.trailblaze.playwright.tools.PlaywrightNativeApplyCookiesTool
Contract¶
- Visible to LLM: yes (
surface_to_llm: true) - Recordable: yes (
is_recordable: true) - Host-only: no (
requires_host: false)
Input schema¶
Optional parameters¶
cookiesJson—StringJSON array of cookies in Playwright’s storage-state cookie shape. May be the full storageState JSON object (in which case thecookiesfield is read), or the bare cookies array.
Output¶
Returns: string (opaque text content)
Typed result schemas (kind: query | action, MCP structuredContent) are not yet carried by the resolved manifest — this section will gain detail when that lands.