Type Text
Type Text
Section titled “Type Text”Type: page-type · Package: Browser v1.0.9
Writes text character by character, simulating real key presses. It’s slower than Fill Field, but it generates an event for each key — needed when the page reacts to typing: autocomplete that shows suggestions, masked fields, search boxes that filter live.
How it works
Section titled “How it works”It waits for the field given by the selector to exist on the page, focuses it and types the text letter by letter, with a pause (delay) between keys. Unlike Fill Field, it doesn’t clear the content first: it types from wherever the cursor is. If you need the field empty, use Fill Field with value = "" first.
- Approximate duration: number of characters ×
delay(with the default value, 20 characters take 1 s). - Accepts a credential in
text: it types it without it appearing in the playbook or the log.
Required parameters
Section titled “Required parameters”| Parameter | Type | Default | Description |
|---|---|---|---|
selector | selector | — | The field to type into. |
text | string | credential | — | The text to type. Supports expressions and credentials. |
Optional parameters
Section titled “Optional parameters”| Parameter | Type | Default | Description |
|---|---|---|---|
page | ZoanPageSession | — | The page session. Omit it inside a body; outside, pass the session variable (e.g. page = page). |
delay | number | 50 | Pause between keys in ms. Higher = more “human” and more reliable on sensitive pages; 0 types with no pause. |
timeout | number | 30000 | Maximum time in ms to wait for the element. Empty, 0 or negative: the project settings value or, if none, 30000. |
Output
Section titled “Output”This activity does not return a value.
Example
Section titled “Example”Type into a search box with autocomplete and then choose the suggestion:
Page Type selector = (#busquedaCiudad) text = "Bogotá" delay = 80Page Wait For selector = (.sugerencia) state = visiblePage Click selector = (.sugerencia)Common errors
Section titled “Common errors”| Message | Cause and fix |
|---|---|
Type failed: Timeout 30000ms exceeded. … | matches: 0 (…) | It didn’t find the field. Check the selector or wait first with Wait For. |
Type failed: … | matches: 2 (the selector is ambiguous: …) | The selector matches several elements. Make it more specific or add an index. |
'page' must be a ZoanPageSession. | page is empty outside a body. |
Related activities
Section titled “Related activities”- Fill Field — write quickly, all at once.
- Key Press — send special keys (Enter, Tab, shortcuts).