Menu
Introduction
Getting Started
Developer guide
Release
Architecture
CLI
Technical documentations
Version
Publication date

Mar 9, 2022

Confidentiality
Public
Reactions
1
Share

Download a scenario

TASK
6 times
50 %
58 seconds
Typing name :  TASK.gws_core.ScenarioDownloaderShareLink Brick :  gws_core

Download a scenario from another lab using a share link

Download a scenario from another lab using a share link.

This task retrieves a scenario (its protocol structure, tasks, and optionally its resources) from another lab using a public or space-scoped share link. It is commonly used to transfer scenarios between a development and a production environment.

After a successful download, the task notifies the origin lab that the scenario has been received.

Parameters

  • link: The share link URL of the scenario to download. Must be a valid lab share scenario link.
  • resource_mode: Controls which resources are downloaded along with the scenario:
    • Auto: Automatically selects the best mode based on the scenario status (e.g. inputs for draft scenarios, outputs for finished ones, inputs of draft tasks for partially run scenarios).
    • Inputs and outputs: Downloads both input and output resources.
    • Inputs only: Downloads only the input resources.
    • Outputs only: Downloads only the output resources.
    • All: Downloads all resources (inputs, outputs, and intermediate results).
    • Inputs of draft tasks: Downloads only the input resources of tasks that have not been run yet (DRAFT status). Useful for partially run scenarios where only the remaining tasks need their inputs.
    • None: Downloads only the scenario structure without any resource content.
  • create_option: Determines how to handle an existing scenario with the same ID:
    • Update if exists: Updates the existing scenario in place.
    • Skip if exists: Raises an error if the scenario already exists.
    • Force new scenario: Creates a new scenario with a new ID, even if one already exists.
  • auto_run: If enabled, the scenario is automatically queued for execution after download. Requires the resource mode to include input resources.
  • skip_scenario_tags: If enabled, scenario-level tags from the source are not applied.
  • skip_resource_tags: If enabled, resource-level tags from the source are not applied.

Output

  • scenario: A ScenarioResource referencing the downloaded scenario.

Output

Scenario
Scenario resource

Configuration

link

Link to download the scenario

Type : string

resource_mode

Optional

Mode for downloading resource of the scenario

Type : stringAllowed values : 
Auto
Inputs and outputs
Inputs only
Outputs only
Inputs of draft tasks
All
None
Default value : Auto

create_option

Optional

This applies for the scenario and the resources

Type : stringAllowed values : 
Update if exists
Skip if exists
Force new scenario
Default value : Update if exists

auto_run

Optional

If true, the scenario will be automatically run after download

Type : bool

skip_scenario_tags

Optional

If true, the scenario tags will not be set in the destination

Type : bool

skip_resource_tags

Optional

If true, the resource tags will not be set in the destination

Type : bool
Shine Logo
Technical bricks to reuse or customize

Have you developed a brick?

Share it to accelerate projects for the entire community.