Skip to main content

The Retool Context object

Properties

All properties for this object with supported data types or values. You can write JavaScript almost anywhere in Retool to manipulate or read property values.

appName

The name and path of the app.

Type string
Format Plain Text
Configurability Read-only
Defaultnull
Examples
false"/path/to/app"

appUuid

The unique ID of the app.

Type string
Format Plain Text
Configurability Read-only
Defaultnull
Examples
false"12345678-1234-1234-1234-123456789012"

currentPage

The currently selected page.

Type string
Format Plain Text
Configurability Read-only
Defaultnull
Examples
false"page1"

environment

The selected environment.

Type string
Format Plain Text
Configurability Read-only
Defaultnull
Examples
false"production"

inEditorMode

Whether the app is open in the App IDE.

Type boolean
Format True/False
Configurability Read-only
Defaultnull
Examples
falsetrue

pages

A list of app pages.

Type array
Array values object
Configurability Read-only
Defaultnull
Array Object Properties

id

The unique identifier (name).

Type string
Format Plain Text
Configurability Inspector
Default{placeholder}1
Examples
falsequery1
falsebutton1

title

The title of the page.

Type string
Format Plain Text
Configurability Inspector > Content > Browser title
Defaultnull
Examples
falsePage 1

url

The URL path of the page.

Type string
Format URL
Configurability Inspector > Content > Custom URL
Defaultnull
Examples
falsepage1

isCurrentPage

Whether the page is the current page.

Type boolean
Format True/False
Configurability Read-only
Defaultnull
Examples
falsetrue


pageTag

The release version of the app. Applies only to apps in 'preview' mode. Defaults to latest if using the working version.

Type string
Format Plain Text
Configurability Read-only
Defaultnull
Examples
falselatest
false1.0.0

runningQueries

A list of queries running.

Type array
Format Plain Text
Array values string
Configurability Read-only
Default[]
Examples
false["query1", "query2"]

translations

A list of translated text for localization.

Type object
Configurability Read-only
Defaultnull