Types

Link copied to clipboard
@Serializable
data class BackForwardCacheNotUsed(val loaderId: LoaderId, val frameId: FrameId, val notRestoredExplanations: List<BackForwardCacheNotRestoredExplanation>, val notRestoredExplanationsTree: BackForwardCacheNotRestoredExplanationTree? = null) : PageEvent

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.

Link copied to clipboard
@Serializable
data class CompilationCacheProduced(val url: String, val data: String) : PageEvent

Issued for every compilation cache generated. Is only available if Page.setGenerateCompilationCache is enabled.

Link copied to clipboard
@Serializable
data class DocumentOpened(val frame: Frame) : PageEvent

Fired when opening document to write to.

Link copied to clipboard
@Serializable
data class DomContentEventFired(val timestamp: MonotonicTime) : PageEvent

(undocumented in the protocol definition)

Link copied to clipboard
@Serializable
data class DownloadProgress(val guid: String, val totalBytes: Double, val receivedBytes: Double, val state: DownloadProgressState) : PageEvent

Fired when download makes progress. Last call has |done| == true. Deprecated. Use Browser.downloadProgress instead.

Link copied to clipboard
@Serializable
data class DownloadWillBegin(val frameId: FrameId, val guid: String, val url: String, val suggestedFilename: String) : PageEvent

Fired when page is about to start a download. Deprecated. Use Browser.downloadWillBegin instead.

Link copied to clipboard
@Serializable
data class FileChooserOpened(val frameId: FrameId? = null, val mode: FileChooserOpenedMode, val backendNodeId: BackendNodeId? = null) : PageEvent

Emitted only when page.interceptFileChooser is enabled.

Link copied to clipboard
@Serializable
data class FrameAttached(val frameId: FrameId, val parentFrameId: FrameId, val stack: StackTrace? = null) : PageEvent

Fired when frame has been attached to its parent.

Link copied to clipboard
@Serializable
data class FrameClearedScheduledNavigation(val frameId: FrameId) : PageEvent

Fired when frame no longer has a scheduled navigation.

Link copied to clipboard
@Serializable
data class FrameDetached(val frameId: FrameId, val reason: FrameDetachedReason? = null) : PageEvent

Fired when frame has been detached from its parent.

Link copied to clipboard
@Serializable
data class FrameNavigated(val frame: Frame, val type: NavigationType? = null) : PageEvent

Fired once navigation of the frame has completed. Frame is now associated with the new loader.

Link copied to clipboard
@Serializable
data class FrameRequestedNavigation(val frameId: FrameId, val reason: ClientNavigationReason, val url: String, val disposition: ClientNavigationDisposition) : PageEvent

Fired when a renderer-initiated navigation is requested. Navigation may still be cancelled after the event is issued.

Link copied to clipboard
@Serializable
object FrameResized : PageEvent

(undocumented in the protocol definition)

Link copied to clipboard
@Serializable
data class FrameScheduledNavigation(val frameId: FrameId, val delay: Double, val reason: ClientNavigationReason, val url: String) : PageEvent

Fired when frame schedules a potential navigation.

Link copied to clipboard
@Serializable
data class FrameStartedLoading(val frameId: FrameId) : PageEvent

Fired when frame has started loading.

Link copied to clipboard
@Serializable
data class FrameStoppedLoading(val frameId: FrameId) : PageEvent

Fired when frame has stopped loading.

Link copied to clipboard
@Serializable
object InterstitialHidden : PageEvent

Fired when interstitial page was hidden

Link copied to clipboard
@Serializable
object InterstitialShown : PageEvent

Fired when interstitial page was shown

Link copied to clipboard
@Serializable
data class JavascriptDialogClosed(val result: Boolean, val userInput: String) : PageEvent

Fired when a JavaScript initiated dialog (alert, confirm, prompt, or onbeforeunload) has been closed.

Link copied to clipboard
@Serializable
data class JavascriptDialogOpening(val url: String, val message: String, val type: DialogType, val hasBrowserHandler: Boolean, val defaultPrompt: String? = null) : PageEvent

Fired when a JavaScript initiated dialog (alert, confirm, prompt, or onbeforeunload) is about to open.

Link copied to clipboard
@Serializable
data class LifecycleEvent(val frameId: FrameId, val loaderId: LoaderId, val name: String, val timestamp: MonotonicTime) : PageEvent

Fired for top level page lifecycle events such as navigation, load, paint, etc.

Link copied to clipboard
@Serializable
data class LoadEventFired(val timestamp: MonotonicTime) : PageEvent

(undocumented in the protocol definition)

Link copied to clipboard
@Serializable
data class NavigatedWithinDocument(val frameId: FrameId, val url: String) : PageEvent

Fired when same-document navigation happens, e.g. due to history API usage or anchor navigation.

Link copied to clipboard
@Serializable
data class ScreencastFrame(val data: String, val metadata: ScreencastFrameMetadata, val sessionId: Int) : PageEvent

Compressed image data requested by the startScreencast.

Link copied to clipboard
@Serializable
data class ScreencastVisibilityChanged(val visible: Boolean) : PageEvent

Fired when the page with currently enabled screencast was shown or hidden `.

Link copied to clipboard
@Serializable
data class WindowOpen(val url: String, val windowName: String, val windowFeatures: List<String>, val userGesture: Boolean) : PageEvent

Fired when a new window is going to be opened, via window.open(), link click, form submission, etc.