Expand description
Actions and events related to the inspected page belong to the page domain.
Types, command parameters and event payloads for the Page
domain. The method-name constants for the same domain are in
crate::methods.
Structs§
- AdFrame
Status - Indicates whether a frame has been identified as an ad and why.
- AddCompilation
Cache Params - Seeds compilation cache for given url. Compilation cache does not survive cross-process navigation.
- AddScript
ToEvaluate OnLoad Params - Deprecated, please use addScriptToEvaluateOnNewDocument instead.
- AddScript
ToEvaluate OnLoad Returns - What
Page.addScriptToEvaluateOnLoadanswers with. - AddScript
ToEvaluate OnNew Document Params - Evaluates given script in every frame upon creation (before loading frame’s scripts).
- AddScript
ToEvaluate OnNew Document Returns - What
Page.addScriptToEvaluateOnNewDocumentanswers with. - AppManifest
Error - Error while paring app manifest.
- AppManifest
Parsed Properties - Parsed app manifest properties.
- Back
Forward Cache Blocking Details - Experimental: may change without notice.
- Back
Forward Cache NotRestored Explanation - Experimental: may change without notice.
- Back
Forward Cache NotRestored Explanation Tree - Experimental: may change without notice.
- Back
Forward Cache NotUsed Event - Fired for failed bfcache history navigations if BackForwardCache feature is enabled. Do not assume any ordering with the Page.frameNavigated event. This event is fired only for main-frame history navigation where the document changes (non-same-document navigations), when bfcache navigation fails.
- Bring
ToFront Params - Brings page to front (activates tab).
- Capture
Screenshot Params - Capture page screenshot.
- Capture
Screenshot Returns - What
Page.captureScreenshotanswers with. - Capture
Snapshot Params - Returns a snapshot of the page as a string. For MHTML format, the serialization includes iframes, shadow DOM, external resources, and element-inline styles.
- Capture
Snapshot Returns - What
Page.captureSnapshotanswers with. - Clear
Compilation Cache Params - Clears seeded compilation cache.
- Clear
Device Metrics Override Params - Clears the overridden device metrics.
- Clear
Device Orientation Override Params - Clears the overridden Device Orientation.
- Clear
Geolocation Override Params - Clears the overridden Geolocation Position and Error.
- Close
Params - Tries to close page, running its beforeunload hooks, if any.
- Compilation
Cache Params - Per-script compilation cache parameters for
Page.produceCompilationCache - Compilation
Cache Produced Event - Issued for every compilation cache generated.
- Crash
Params - Crashes renderer on the IO thread, generates minidumps.
- Create
Isolated World Params - Creates an isolated world for the given frame.
- Create
Isolated World Returns - What
Page.createIsolatedWorldanswers with. - Delete
Cookie Params - Deletes browser cookie with given name, domain and path.
- Disable
Params - Disables page domain notifications.
- Document
Opened Event - Fired when opening document to write to.
- DomContent
Event Fired Event - Payload of the
Page.domContentEventFiredevent. - Download
Progress Event - Fired when download makes progress. Last call has |done| == true. Deprecated. Use Browser.downloadProgress instead.
- Download
Will Begin Event - Fired when page is about to start a download. Deprecated. Use Browser.downloadWillBegin instead.
- Enable
Params - Enables page domain notifications.
- File
Chooser Opened Event - Emitted only when
page.interceptFileChooseris enabled. - File
Filter - Experimental: may change without notice.
- File
Handler - Experimental: may change without notice.
- Font
Families - Generic font families collection.
- Font
Sizes - Default font sizes.
- Frame
- Information about the Frame on the page.
- Frame
Attached Event - Fired when frame has been attached to its parent.
- Frame
Cleared Scheduled Navigation Event - Fired when frame no longer has a scheduled navigation.
- Frame
Detached Event - Fired when frame has been detached from its parent.
- Frame
Navigated Event - Fired once navigation of the frame has completed. Frame is now associated with the new loader.
- Frame
Requested Navigation Event - Fired when a renderer-initiated navigation is requested. Navigation may still be cancelled after the event is issued.
- Frame
Resized Event - Experimental: may change without notice.
- Frame
Resource - Information about the Resource on the page.
- Frame
Resource Tree - Information about the Frame hierarchy along with their cached resources.
- Frame
Scheduled Navigation Event - Fired when frame schedules a potential navigation.
- Frame
Started Loading Event - Fired when frame has started loading.
- Frame
Started Navigating Event - Fired when a navigation starts. This event is fired for both
renderer-initiated and browser-initiated navigations. For
renderer-initiated navigations, the event is fired after
frameRequestedNavigation. Navigation may still be cancelled after the event is issued. Multiple events can be fired for a single navigation, for example, when a same-document navigation becomes a cross-document navigation (such as in the case of a frameset). - Frame
Stopped Loading Event - Fired when frame has stopped loading.
- Frame
Subtree Will BeDetached Event - Fired before frame subtree is detached. Emitted before any frame of the subtree is actually detached.
- Frame
Tree - Information about the Frame hierarchy.
- Generate
Test Report Params - Generates a report for testing.
- GetAd
Script Ancestry Params - Experimental: may change without notice.
- GetAd
Script Ancestry Returns - What
Page.getAdScriptAncestryanswers with. - GetAnnotated
Page Content Params - Get the annotated page content for the main frame. This is an experimental command that is subject to change.
- GetAnnotated
Page Content Returns - What
Page.getAnnotatedPageContentanswers with. - GetApp
IdParams - Returns the unique (PWA) app id, along with IWA bundle ID and parent app info. Only returns values if the feature flag ‘WebAppEnableManifestId’ is enabled
- GetApp
IdReturns - What
Page.getAppIdanswers with. - GetApp
Manifest Params - Gets the processed manifest for this current document. This API always waits for the manifest to be loaded. If manifestId is provided, and it does not match the manifest of the current document, this API errors out. If there is not a loaded page, this API errors out immediately.
- GetApp
Manifest Returns - What
Page.getAppManifestanswers with. - GetFrame
Tree Params - Returns present frame tree structure.
- GetFrame
Tree Returns - What
Page.getFrameTreeanswers with. - GetInstallability
Errors Params - Experimental: may change without notice.
- GetInstallability
Errors Returns - What
Page.getInstallabilityErrorsanswers with. - GetLayout
Metrics Params - Returns metrics relating to the layouting of the page, such as viewport bounds/scale.
- GetLayout
Metrics Returns - What
Page.getLayoutMetricsanswers with. - GetManifest
Icons Params - Deprecated because it’s not guaranteed that the returned icon is in fact the one used for PWA installation.
- GetManifest
Icons Returns - What
Page.getManifestIconsanswers with. - GetNavigation
History Params - Returns navigation history for the current page.
- GetNavigation
History Returns - What
Page.getNavigationHistoryanswers with. - GetOrigin
Trials Params - Get Origin Trials on given frame.
- GetOrigin
Trials Returns - What
Page.getOriginTrialsanswers with. - GetPermissions
Policy State Params - Get Permissions Policy state on given frame.
- GetPermissions
Policy State Returns - What
Page.getPermissionsPolicyStateanswers with. - GetResource
Content Params - Returns content of the given resource.
- GetResource
Content Returns - What
Page.getResourceContentanswers with. - GetResource
Tree Params - Returns present frame / resource tree structure.
- GetResource
Tree Returns - What
Page.getResourceTreeanswers with. - GetSibling
SubApps Params - Returns the list of sibling Sub-Apps sharing the same parent app if the inspected context is a Sub-App.
- GetSibling
SubApps Returns - What
Page.getSiblingSubAppsanswers with. - GetSpell
Check Custom Dictionary Params - Returns the words that the frame’s document added to its spell check
custom dictionary with
document.spellCheckCustomDictionary.addWords(), sorted. Page script cannot read the dictionary back; this lets developers inspect it. - GetSpell
Check Custom Dictionary Returns - What
Page.getSpellCheckCustomDictionaryanswers with. - GetSub
Apps Params - Returns the list of installed child Sub-Apps for the inspected parent app.
- GetSub
Apps Returns - What
Page.getSubAppsanswers with. - Handle
Java Script Dialog Params - Accepts or dismisses a JavaScript initiated dialog (alert, confirm, prompt, or onbeforeunload).
- Image
Resource - The image definition used in both icon and screenshot.
- Installability
Error - The installability error
- Installability
Error Argument - Experimental: may change without notice.
- Interstitial
Hidden Event - Fired when interstitial page was hidden
- Interstitial
Shown Event - Fired when interstitial page was shown
- Javascript
Dialog Closed Event - Fired when a JavaScript initiated dialog (alert, confirm, prompt, or onbeforeunload) has been closed.
- Javascript
Dialog Opening Event - Fired when a JavaScript initiated dialog (alert, confirm, prompt, or onbeforeunload) is about to open.
- Launch
Handler - Experimental: may change without notice.
- Layout
Viewport - Layout viewport position and dimensions.
- Lifecycle
Event Event - Fired for lifecycle events (navigation, load, paint, etc) in the current target (including local frames).
- Load
Event Fired Event - Payload of the
Page.loadEventFiredevent. - Navigate
Params - Navigates current page to the given URL.
- Navigate
Returns - What
Page.navigateanswers with. - Navigate
ToHistory Entry Params - Navigates current page to the given history entry.
- Navigated
Within Document Event - Fired when same-document navigation happens, e.g. due to history API usage or anchor navigation.
- Navigation
Entry - Navigation history entry.
- Origin
Trial - Experimental: may change without notice.
- Origin
Trial Token - Experimental: may change without notice.
- Origin
Trial Token With Status - Experimental: may change without notice.
- Permissions
Policy Block Locator - Experimental: may change without notice.
- Permissions
Policy Feature State - Experimental: may change without notice.
- Print
ToPdf Params - Print page as PDF.
- Print
ToPdf Returns - What
Page.printToPDFanswers with. - Produce
Compilation Cache Params - Requests backend to produce compilation cache for the specified scripts.
scriptsare appended to the list of scripts for which the cache would be produced. The list may be reset during page navigation. When script with a matching URL is encountered, the cache is optionally produced upon backend discretion, based on internal heuristics. See also:Page.compilationCacheProduced. - Protocol
Handler - Experimental: may change without notice.
- Related
Application - Experimental: may change without notice.
- Reload
Params - Reloads given page optionally ignoring the cache.
- Remove
Script ToEvaluate OnLoad Params - Deprecated, please use removeScriptToEvaluateOnNewDocument instead.
- Remove
Script ToEvaluate OnNew Document Params - Removes given script from the list.
- Reset
Navigation History Params - Resets navigation history for the current page.
- Scope
Extension - Experimental: may change without notice.
- Screencast
Frame AckParams - Acknowledges that a screencast frame has been received by the frontend.
- Screencast
Frame Event - Compressed image data requested by the
startScreencast. - Screencast
Frame Metadata - Screencast frame metadata.
- Screencast
Visibility Changed Event - Fired when the page with currently enabled screencast was shown or hidden `.
- Screenshot
- Experimental: may change without notice.
- Script
Font Families - Font families collection for a script.
- Search
InResource Params - Searches for given string in resource content.
- Search
InResource Returns - What
Page.searchInResourceanswers with. - Security
Origin Details - Additional information about the frame document’s security origin.
- SetAd
Blocking Enabled Params - Enable Chrome’s experimental ad filter on all sites.
- SetBypass
CspParams - Enable page Content Security Policy by-passing.
- SetDevice
Metrics Override Params - Overrides the values of device screen dimensions (window.screen.width, window.screen.height, window.innerWidth, window.innerHeight, and “device-width”/“device-height”-related CSS media query results).
- SetDevice
Orientation Override Params - Overrides the Device Orientation.
- SetDocument
Content Params - Sets given markup as the document’s HTML.
- SetDownload
Behavior Params - Set the behavior when downloading a file.
- SetFont
Families Params - Set generic font families.
- SetFont
Sizes Params - Set default font sizes.
- SetGeolocation
Override Params - Overrides the Geolocation Position or Error. Omitting any of the parameters emulates position unavailable.
- SetInput
Visualization Params - Configures input visualization on the page.
- SetIntercept
File Chooser Dialog Params - Intercept file chooser requests and transfer control to protocol clients.
When file chooser interception is enabled, native file chooser dialog is
not shown. Instead, a protocol event
Page.fileChooserOpenedis emitted. - SetLifecycle
Events Enabled Params - Controls whether page will emit lifecycle events.
- SetPrerendering
Allowed Params - Enable/disable prerendering manually. This command is a short-term solution for https://crbug.com/1440085. See https://docs.google.com/document/d/12HVmFxYj5Jc-eJr5OmWsa2bqTJsbgGLKI6ZIyx0_wpA for more details. TODO(https://crbug.com/1440085): Remove this once Puppeteer supports tab targets.
- SetRph
Registration Mode Params - Extensions for Custom Handlers API: https://html.spec.whatwg.org/multipage/system-state.html#rph-automation
- SetSpc
Transaction Mode Params - Sets the Secure Payment Confirmation transaction mode. https://w3c.github.io/secure-payment-confirmation/#sctn-automation-set-spc-transaction-mode
- SetTouch
Emulation Enabled Params - Toggles mouse event-based touch event emulation.
- SetWeb
Lifecycle State Params - Tries to update the web lifecycle state of the page. It will transition the page to the given state according to: https://github.com/WICG/web-lifecycle/
- Share
Target - Experimental: may change without notice.
- Shortcut
- Experimental: may change without notice.
- Start
Screen Recording Params - Starts screencast video recording.
- Start
Screen Recording Returns - What
Page.startScreenRecordinganswers with. - Start
Screencast Params - Starts sending each frame using the
screencastFrameevent. - Stop
Loading Params - Force the page stop all navigations and pending resource fetches.
- Stop
Screen Recording Params - Stops screencast video recording.
- Stop
Screen Recording Returns - What
Page.stopScreenRecordinganswers with. - Stop
Screencast Params - Stops sending each frame in the
screencastFrame. - SubApp
- Viewport
- Viewport for capturing screenshot.
- Visual
Viewport - Visual viewport position, dimensions, and scale.
- Wait
ForDebugger Params - Pauses page execution. Can be resumed using generic Runtime.runIfWaitingForDebugger.
- WebApp
Manifest - Experimental: may change without notice.
- Window
Open Event - Fired when a new window is going to be opened, via window.open(), link click, form submission, etc.
Enums§
- AdFrame
Explanation - Experimental: may change without notice.
- AdFrame
Type - Indicates whether a frame has been identified as an ad.
- Back
Forward Cache NotRestored Reason - List of not restored reasons for back-forward cache.
- Back
Forward Cache NotRestored Reason Type - Types of not restored reasons for back-forward cache.
- Capture
Screenshot Format - The values
formataccepts oncaptureScreenshot. - Capture
Snapshot Format - The values
formataccepts oncaptureSnapshot. - Client
Navigation Disposition - Experimental: may change without notice.
- Client
Navigation Reason - Experimental: may change without notice.
- Cross
Origin Isolated Context Type - Indicates whether the frame is cross-origin isolated and why it is the case.
- Dialog
Type - Javascript dialog type.
- Download
Progress State - The values
stateaccepts ondownloadProgress. - File
Chooser Opened Mode - The values
modeaccepts onfileChooserOpened. - Frame
Detached Reason - The values
reasonaccepts onframeDetached. - Frame
Started Navigating Navigation Type - The values
navigationTypeaccepts onframeStartedNavigating. - Gated
ApiFeatures - Experimental: may change without notice.
- Navigated
Within Document Navigation Type - The values
navigationTypeaccepts onnavigatedWithinDocument. - Navigation
Type - The type of a frameNavigated event.
- Origin
Trial Status - Status for an Origin Trial.
- Origin
Trial Token Status - Origin Trial(https://www.chromium.org/blink/origin-trials) support. Status for an Origin Trial token.
- Origin
Trial Usage Restriction - Experimental: may change without notice.
- Permissions
Policy Block Reason - Reason for a permissions policy feature to be disabled.
- Permissions
Policy Feature - All Permissions Policy features. This enum should match the one defined in services/network/public/cpp/permissions_policy/permissions_policy_features.json5. LINT.IfChange(PermissionsPolicyFeature)
- Print
ToPdf Transfer Mode - The values
transferModeaccepts onprintToPDF. - Referrer
Policy - The referring-policy used for the navigation.
- Secure
Context Type - Indicates whether the frame is a secure context and why it is the case.
- SetDownload
Behavior Behavior - The values
behavioraccepts onsetDownloadBehavior. - SetRph
Registration Mode Mode - The values
modeaccepts onsetRPHRegistrationMode. - SetSpc
Transaction Mode Mode - The values
modeaccepts onsetSPCTransactionMode. - SetTouch
Emulation Enabled Configuration - The values
configurationaccepts onsetTouchEmulationEnabled. - SetWeb
Lifecycle State State - The values
stateaccepts onsetWebLifecycleState. - Start
Screen Recording Capture Area - The values
captureAreaaccepts onstartScreenRecording. - Start
Screencast Format - The values
formataccepts onstartScreencast. - Transition
Type - Transition type.
Type Aliases§
- FrameId
- Unique frame identifier.
- Script
Identifier - Unique script identifier.