Skip to content

args

Arguments passed to the script.

Arguments are passed to the script when the script is executed from a share sheet. You can specify the types of arguments a script supports from the script settings.

length

Number of arguments supplied by a share sheet.

Deprecated in version 1.3. Instead of relying on this property, take the length of the array containing the data type you are interested in.

The number of arguments passed to the script from the share seeht.

length: number

all

All arguments supplied by a share sheet.

Deprecated in version 1.3. Instead of relying on this property, access the array containing the data type you are interested in.

All arguments supplied by the share sheet.

all: [any]

plainTexts

Plain text arguments supplied by a share sheet.

All plain texts passed to the script from a share sheet.

If you have enabled "Text" as a share sheet input from the script settings, the script can be run from any share sheet throughout the system that shares plain text.

plainTexts: [string]

urls

URL arguments supplied by a share sheet.

All URLs passed to the script from a share sheet.

If you have enabled "URLs" as a share sheet input from the script settings, the script can be run from any share sheet throughout the system that shares URLs.

urls: [string]

fileURLs

File URL arguments supplied by a share sheet.

All file URLs passed to the script from a share sheet.

If you have enabled "File URLs" as a share sheet input from the script settings, the script can be run from any share sheet throughout the system that shares URLs pointing to a file.

fileURLs: [string]

images

Image arguments.

All images passed to the script from a share sheet.

If you have enabled "Images" as a share sheet input from the script settings, the script can be run from any share sheet throughout the system that shares images.

images: [Image]

queryParameters

Query parameters from a URL scheme.

Query parameters are supplied to a script when running it from a URL scheme. See the documentation on Scriptables URL schems for more information.

queryParameters: {string: string}

siriShortcutArguments

Arguments passed from a Siri Shortcut.

When creating a Siri Shortcut in Scriptable, you can define arguments that are passed to the script when the shortcut is run. This lets you differentiate the behaviour of a script based on some predefiend arguments.

For example, a script that checks the wather may expect an argument with the key "city". When creating a Siri Shortcut for the script, the argument should be passed with the value containing the name of the city to to check the weather for.

siriShortcutArguments: {string: string}

notification

Notification being handled by the script.

The notification that a script is being run in or the application was opened from.

The notification contains all information that was set when the notification was originally scheduled, including the userInfo property which can be used to contain custom data that might be relevant when running the script.

notification: Notification