Skip to content

Scripting API / core/LocationApi

core/LocationApi

Classes

LocationApi

Methods

closeTab()

closeTab(): Promise<void>

Closes the current browser tab or window.

If the tab wasn’t script-opened, it will fall back to going back one step in the user’s browsing history.

Returns

Promise<void>

goToDashboard()

goToDashboard(dashboardId, openInNewTab?): Promise<void>

Navigates to the given dashboard.

Parameters
Parameter Type Description
dashboardId number The ID of the dashboard to open.
openInNewTab? boolean Whether to open the dashboard in a new browser tab. Defaults to false.
Returns

Promise<void>

goToInspection()

goToInspection(inspectionId, revision?, openInNewTab?): Promise<void>

Navigates to the given inspection.

Parameters
Parameter Type Description
inspectionId number The ID of the inspection to open.
revision? number | "latest" The ID of the inspection revision to open. Defaults to latest.
openInNewTab? boolean Whether to open the inspection in a new browser tab. Defaults to false.
Returns

Promise<void>