This document describes the grammar and available options for writing Symphony E2E workflow files in YAML.
Each Symphony workflow YAML file must follow this structure:
name: <string> # Required. Name of your workflow.
url: <string> # Required. Target website URL (must be valid URI).
colorMode: <light|dark> # Optional. UI color mode. Defaults to "light".
flow: # Required. Ordered list of workflow steps.
- <action>
- <action>Each item in flow is an action. Supported actions:
Enter a value into an input field.
- input:
selector: <selector>
value: <string>You can use several locator strategies for selector:
label:<label text>— by visible label or aria-labeltestID:<test id>— bydata-testidattributeplaceholder:<placeholder text>— by placeholderrole:<role> name="<name>"— by ARIA role and accessible name- CSS selector — e.g.,
#username,.form-input,input[name="email"]
Examples:
- input:
selector: 'label:Email'
value: 'user@example.com'
- input:
selector: 'testID:login-input'
value: 'alice'
- input:
selector: 'role:textbox name="username"'
value: 'bob'
- input:
selector: '#search'
value: 'Symphony'Click an element by visible text or CSS selector.
- clickOn: <text>or
- clickOn:
selector: <css selector>Examples:
- clickOn: "Login"
- clickOn:
selector: "#submit-btn"Pause execution for a specified duration (milliseconds).
- waitFor:
duration: <number>Example:
- waitFor:
duration: 2000Simulate key presses or shortcuts.
- keyboard:
key: <key or combination>Supported keys:
- Single keys:
Enter,Escape,KeyA,ArrowUp, etc. - Combinations:
Control+KeyA,Shift+Alt+KeyS,ControlOrMeta+KeyC
Examples:
- keyboard:
key: Enter
- keyboard:
key: Control+KeyAScroll the page by direction or to a position.
By direction:
- scroll:
direction: down # or "up"
speed: 100 # (optional, pixels/sec, default: 300)By position:
- scroll:
position:
x: 0
y: 500name(string, required): Display name for the workflow.url(string, required): Target website URL. Must be a valid URI.colorMode(string, optional): "light" or "dark". Defaults to "light".flow(array, required): List of actions (see above).
label:<text>— by label or aria-labeltestID:<id>— by data-testidplaceholder:<text>— by placeholderrole:<role> name="<name>"— by ARIA role and name- CSS selector — e.g.,
#id,.class,input[name="foo"]
Supported keys include:
- Modifier keys:
Shift,Control,Alt,Meta,ControlOrMeta - Alphabetic:
KeyA...KeyZ - Digits:
Digit0...Digit9 - Function:
F1...F12 - Arrow:
ArrowUp,ArrowDown,ArrowLeft,ArrowRight - Editing:
Backspace,Tab,Enter,Delete,Escape,Space,Insert - Page navigation:
Home,End,PageUp,PageDown - Symbol:
Minus,Equal,BracketLeft,BracketRight,Backslash,Semicolon,Quote,Backquote,Comma,Period,Slash - Lock:
CapsLock,ScrollLock - Misc:
ContextMenu,Pause,PrintScreen
Supported roles include (not exhaustive):
button,textbox,searchbox,link,checkbox,radio,tab,tabpanel,menuitem,listbox,option,dialog,form,grid,row,cell,table,navigation,main,banner,alert,tooltip, etc.
name: Demo Workflow
url: https://myapp.com/
colorMode: light
flow:
- input:
selector: 'label:Username'
value: 'alice'
- input:
selector: 'label:Password'
value: 'wonderland'
- clickOn: "Sign In"
- waitFor:
duration: 1500
- scroll:
direction: down
speed: 200
- keyboard:
key: Control+KeyK