REST Resource: processes

Resource: Process

Representation of a single script process execution that was started from the script editor, a trigger, an application, or using the Apps Script API. This is distinct from the Operation resource, which only represents executions started via the Apps Script API.

JSON representation
{"projectName": string,"functionName": string,"processType": enum (ProcessType),"processStatus": enum (ProcessStatus),"userAccessLevel": enum (UserAccessLevel),"startTime": string,"duration": string}
Fields
projectName

string

Name of the script being executed.

functionName

string

Name of the function the started the execution.

processType

enum (ProcessType)

The executions type.

processStatus

enum (ProcessStatus)

The executions status.

userAccessLevel

enum (UserAccessLevel)

The executing users access level to the script.

startTime

string (Timestamp format)

Time the execution started.

A timestamp in RFC3339 UTC "Zulu" format, with nanosecond resolution and up to nine fractional digits. Examples: "2014-10-02T15:01:23Z" and "2014-10-02T15:01:23.045123456Z".

duration

string (Duration format)

Duration the execution spent executing.

A duration in seconds with up to nine fractional digits, ending with 's'. Example: "3.5s".

ProcessType

The type of process, which defines how the process was started.

Enums
PROCESS_TYPE_UNSPECIFIEDUnspecified type.
ADD_ONThe process was started from an add-on entry point.
EXECUTION_APIThe process was started using the Apps Script API.
TIME_DRIVENThe process was started from a time-based trigger.
TRIGGERThe process was started from an event-based trigger.
WEBAPPThe process was started from a web app entry point.
EDITORThe process was started using the Apps Script IDE.
SIMPLE_TRIGGERThe process was started from a G Suite simple trigger.
MENUThe process was started from a G Suite menu item.
BATCH_TASKThe process was started as a task in a batch job.

ProcessStatus

The process status.

Enums
PROCESS_STATUS_UNSPECIFIEDUnspecified status.
RUNNINGThe process is currently running.
PAUSEDThe process has paused.
COMPLETEDThe process has completed.
CANCELEDThe process was cancelled.
FAILEDThe process failed.
TIMED_OUTThe process timed out.
UNKNOWNProcess status unknown.
DELAYEDThe process is delayed, waiting for quota.

UserAccessLevel

The various user access levels.

Enums
USER_ACCESS_LEVEL_UNSPECIFIEDUser access level unspecified
NONEThe user has no access.
READThe user has read-only access.
WRITEThe user has write access.
OWNERThe user is an owner.

Methods

list

List information about processes made by or on behalf of a user, such as process type and current status.

listScriptProcesses

List information about a script's executed processes, such as process type and current status.