Team and Workspace Settings

You can store plain key/value configuration at the team and workspace level so your Playwright tests can read shared values - timeouts, base URLs, feature flags, environment names - without hardcoding them into test code.

Unlike Team Secrets, settings are not encrypted and their values are shown in plain text. Use settings for non-sensitive configuration, and secrets for passwords, API keys, tokens, and PINs.

What this feature does

  • Store named key/value settings at the team level and at the workspace level

  • Edit and delete existing settings

  • Read settings in Playwright test steps using leapwork.team.settings.get() and leapwork.workspace.settings.get()

  • New workspaces are pre-populated with two defaults: timeoutMs = 5000 and enableSelfHeal = true. Team settings start empty and override the workspace value for that team when set.

Team vs. workspace settings

  • Team settings apply to a single team and are edited on the team page. Use them for values that differ per team.

  • Workspace settings apply to the whole workspace and act as a shared fallback. Use them for values that should be the same across every team in the workspace.

A common pattern is to read the team setting first and fall back to the workspace setting (and finally a hardcoded default) - see Using settings in Playwright tests.

How to add team settings

  1. Open the team you want to manage by double-clicking the team name in the Explorer.

  2. Scroll down to the Settings section on the team page.

  3. Click + Add setting to add a new setting.

  4. Enter a Setting key and a Value.

  5. Press Enter or click Save.

To edit a setting, double-click the row (or open the ⋮ menu and select Edit setting), change the value, and save.

To delete a setting, open the ⋮ menu on the row and select Delete setting, then confirm in the dialog.

Anyone with edit access to the team can manage its settings. Read-only members see the values but cannot change them.

How to add workspace settings

  1. Open the account menu from the top bar and click Workspace settings.

  2. The Settings section opens with Workspace settings selected in the left nav.

  3. Click + Add setting, enter a Setting key and a Value, and save.

  4. Edit and delete work the same way as team settings - double-click or use the ⋮ menu.

Only the subscription admin can add, edit, or delete workspace settings. Other members see the values in read-only mode.

Using settings in Playwright tests

Once a setting is saved, read it in any Playwright test step:

TypeScript
const baseUrl = leapwork.team.settings.get("baseUrl");
const timeoutMs = leapwork.workspace.settings.get("timeoutMs");

get() returns the value as a string, or undefined when the key is not set. Convert as needed (for example with Number(...) for numeric values).

To read the team setting first and fall back to the workspace setting, then a default, use the nullish-coalescing operator ?? so that a valid "false" or "0" value is respected:

TypeScript
const timeoutMs =
    leapwork.team.settings.get("timeoutMs")
    ?? leapwork.workspace.settings.get("timeoutMs")
    ?? "5000";

Default configuration in new test cases

Every new test case starts with a configuration block that resolves timeoutMs and enableSelfHeal from the team setting, then the workspace setting, then a built-in default:

TypeScript
leapwork.configuration({
    timeoutMs: Number(
        leapwork.team.settings.get("timeoutMs")
        ?? leapwork.workspace.settings.get("timeoutMs")
    ) || 5000,
    enableSelfHeal:
        (leapwork.team.settings.get("enableSelfHeal")
            ?? leapwork.workspace.settings.get("enableSelfHeal")) !== "false",
});

Resolution order is team setting → workspace setting → built-in default. timeoutMs falls back to 5000 when neither is set (or the value is not a valid number); enableSelfHeal is on unless a setting explicitly holds "false".

This means changing timeoutMs or enableSelfHeal in your team (or workspace) settings updates the default behavior for every new test case, without editing each test.

Tips

  • Keys are case-sensitive and are matched exactly as you type them, so get("timeoutMs") and get("timeoutms") are different keys.

  • Put values that vary per team in team settings, and shared defaults in workspace settings.

  • Settings values are always strings - remember to convert numbers and booleans in your test code.

  • Use settings for configuration and Team Secrets for anything sensitive.