Flows API
  • Globus Flows
  • Overview
  • Getting Started
    • How to Run a Flow
    • How to Monitor a Flow Run
    • How to Create a Flow
  • Authoring Flows
    • Introduction
    • Actions
    • Expressions
    • Choice States
    • Wait States
    • Fail States
    • Pass States
    • Protecting Secrets
    • Handling Exceptions
    • Performing Actions as Different Users
    • Run Context
    • Validating Flow Definitions
  • Authoring Input Schemas
  • Authentication and Authorization
  • Consents and Resuming Runs
  • Permissions
  • Limits
  • Hosted Action Providers
    • Hello World
    • Globus Search - Ingest Task
    • Globus Search - Delete Task
    • Send Notification Email
    • Wait For User Selection
    • Expression Evaluation
    • DataCite Mint
    • Transfer APs
    • Compute AP
  • Example Flows
    • Simple Transfer
    • Move (copy and delete) files
    • Transfer and Share Files
    • Two Stage Globus Transfer
    • Transfer After Approval
    • Looping Batched Move
    • Tar and Transfer with Globus Compute
Skip to main content
Globus Docs
  • Getting Started
    Getting Started

    Getting Started and Tutorial docs cover how to perform some activity or provide an introduction to a feature. They are not comprehensive, but help you get started with Globus or with new Globus features.

    • Users
    • Admins
    • Developers
  • Reference
    Reference
    • Service
      • Auth
      • Groups
      • Transfer
      • Timers
      • Flows
      • Compute
      • Search
    • Agents
      • Globus Connect Server
      • GCS CLI
      • Globus Connect Personal
      • Globus Compute
    • SDK
      • Python
      • JS
    • Clients
      • CLI
    • Security and Compliance
      • Product Security
      • Privacy
      • Solutions for Sensitive Data
      • FAQs
  • Solutions & Guides
    Solutions & Guides

    Find practical approaches for leveraging Globus in research environments, integrating with platforms, and building science gateways. Access hands-on guides, integration instructions, and real-world scenarios for advanced usage.

    • Portals/Science Gateways
    • Guides
  • Support
    Support

    Find answers to frequently asked questions, connect with the community by joining our mailing lists, or reach out directly to Globus support.

    • FAQs
    • Mailing Lists
    • Contact Us
    • Check Support Tickets
  • Site Search
  1. Home
  2. Globus Services
  3. Globus Flows
  4. Authoring Flows
  5. Run Context

Run Context

Basic information about the run's state and the user invoking the flow is provided through a "virtual", read-only property available at the JSONPath $._context. This path may be used in a path for a Parameters value on an action or Pass state type, or in expressions which are evaluated when generating Parameters values as described above. This allows the flow to refer to these values as parameters to various states. As this is a read-only value, the _context cannot be overwritten by using the path in a ResultPath on any state. The _context value is itself an object containing the following properties:

Property name

Description

flow_id

The id of the flow that is being executed

flow_title

The title of the flow at execution start time

(This will not reflect changes made to the title after execution start time)

run_id

The unique id assigned to this run (execution) of the flow

run_label

The label assigned to this run (execution) of the flow

(This will not reflect changes made to the label after execution start time)

username

The Globus Auth username for the user invoking the flow

email

The email address for the user invoking the flow

user_id

The Globus Auth user id for the user invoking the flow (in URN format)

identities

A list of all identities associated with the user invoking the flow (in URN format)

token_info

A child object containing the fields exp, iat, and nbf (described below)

The token_info fields are defined as follows:

  • exp: Timestamp, measured in the number of seconds since UTC January 1, 1970, indicating when this token will expire.

  • iat: Timestamp, measured in the number of seconds since UTC January 1, 1970, indicating when this token was originally issued.

  • nbf: Timestamp, measured in the number of seconds since UTC January 1, 1970, indicating when this token is not to be used before.

Example Context Object

All values in this example are generated and do not reflect real data.

{
  "flow_id": "2eee349e-cc4d-41e9-8918-de77c951b50b",
  "flow_title": "My Cool Flow",
  "run_id": "4a5d602b-37f4-4ca8-9711-42d14b56be9f",
  "run_label": "My Cool Run",
  "email": "fake-user@globus.org",
  "username": "fake-user",
  "user_id": "urn:globus:auth:identity:5f949d68-ffb0-409b-ac9e-a3a8be22cd5d",
  "identities": [
    "urn:globus:auth:identity:5f949d68-ffb0-409b-ac9e-a3a8be22cd5d",
    "urn:globus:auth:identity:ed9b2fcb-3950-4927-b2aa-afb3cf95c89f"
  ],
  "token_info": {
    "exp": 1241724600,
    "iat": 1241710200,
    "nbf": 1241710200
  }
}
  • Globus Flows
  • Overview
  • Getting Started
    • How to Run a Flow
    • How to Monitor a Flow Run
    • How to Create a Flow
  • Authoring Flows
    • Introduction
    • Actions
    • Expressions
    • Choice States
    • Wait States
    • Fail States
    • Pass States
    • Protecting Secrets
    • Handling Exceptions
    • Performing Actions as Different Users
    • Run Context
    • Validating Flow Definitions
  • Authoring Input Schemas
  • Authentication and Authorization
  • Consents and Resuming Runs
  • Permissions
  • Limits
  • Hosted Action Providers
    • Hello World
    • Globus Search - Ingest Task
    • Globus Search - Delete Task
    • Send Notification Email
    • Wait For User Selection
    • Expression Evaluation
    • DataCite Mint
    • Transfer APs
    • Compute AP
  • Example Flows
    • Simple Transfer
    • Move (copy and delete) files
    • Transfer and Share Files
    • Two Stage Globus Transfer
    • Transfer After Approval
    • Looping Batched Move
    • Tar and Transfer with Globus Compute
© 2010- The University of Chicago Legal Privacy Accessibility