---
id: "navegador-automacao-interacao"
titulo: "Automation: interacting with the page"
resumo: "Commands that click, fill, type, drag and read element state by snapshot reference."
idioma: "en"
tipo: "referencia"
categoria: "telas"
aplicavelDesde: "0.0.16"
capabilities: ["browser.element.interact", "browser.element.inspect", "browser.mouse.control", "browser.form.fill"]
estadoEditorial: "aprovado"
nivelEvidencia: "artefato-distribuido"
refFonte: "27574c339b58316408f6be2d62169d59041d07bf"
revisaoFonte: "2026-09-24"
revisor: "mantenedor (v1, 2026-10-03)"
rota: "/docs/en/ferramentas/navegador/automacao-referencia-interacao/"
fonte: "pt-br/ferramentas/navegador/automacao-referencia-interacao.md"
caminhoPublico: "docs/publica/en/ferramentas/navegador/automacao-referencia-interacao.md"
hashFonte: "sha256:3d101604495fd2ad64acfa3e19faeb79df51c9b0cc0ae215d69e1e735d0f5ddb"
hashDestaPagina: "sha256:c94d96e30ad1a4087b7afcb2349b6b579a0ba8db4488173ca8583b1a618547ab"
traducaoAssistidaPorIA: true
traducaoDesatualizada: false
corpoRetido: false
---
<!-- traducao-assistida-por-ia: idioma=EN fonte=pt-br/ferramentas/navegador/automacao-referencia-interacao.md fonteHash=sha256:3d101604495fd2ad64acfa3e19faeb79df51c9b0cc0ae215d69e1e735d0f5ddb estado=atual -->

Commands, flags and values are **literal** — they are not translated. All of them accept the target flags `--page`/`--node`/`--workspace` described in [Automation: navigation](/docs/en/ferramentas/navegador/automacao-referencia-navegacao/), and without a target they act on the active tab of the current workspace.

## The reference comes from the snapshot

The element commands use **`--element <ref>`**, and those `ref`s come from `elyra snapshot`.

- Take the snapshot, use the `ref`s on the same page.
- **After navigating or changing the page, the old `ref`s no longer apply** — take a new snapshot.
- The CLI recommends, after each action, taking a new snapshot to check what actually settled.

## Actions by reference

| Command | Use |
|---|---|
| `elyra click --element <ref>` | Click |
| `elyra dblclick --element <ref>` | Double click |
| `elyra hover --element <ref>` | Hover |
| `elyra focus --element <ref>` | Focus |
| `elyra fill --element <ref> --value <text>` | Clear and fill |
| `elyra type --input <text>` | Type at the current focus |
| `elyra select --element <ref> --value <value>` | Choose a dropdown option |
| `elyra check --element <ref>` / `elyra uncheck --element <ref>` | Check / uncheck a box or radio |
| `elyra clear --element <ref>` | Clear the field's content |
| `elyra select-all --element <ref>` | Select all text in the field |
| `elyra keypress --key <name>` | Press a key (`Enter`, `Tab`, `Escape`, `ArrowDown`…) |
| `elyra drag --from <ref> --to <ref>` | Drag from one element to another |
| `elyra upload --element <ref> --files <path,...>` | Send local files to a file input |

Requirements: `fill` and `select` require `--value`; `drag` requires `--from` and `--to`; `upload` requires `--files`; `keypress` requires `--key`. `check` and `uncheck` are the same parameterized handler.

> **`clear` erases without undo.** **`upload` sends files from your disk to the page** — check what is going and where.

## Fill several fields at once

```
elyra fill-form (--fields '<json>' | --fields-file <path>) [--page <id>] [--workspace <selector>] [--json]
```

- `--fields` is a JSON array in the form `[{"element":"<ref>","value":"<text>"}]`, with `ref`s from `snapshot`.
- `--fields` and `--fields-file` are **mutually exclusive**; providing both is an error.
- **Every field is reported**: the result says what landed and what failed. Use `elyra snapshot --json` to check.
- An invalid or empty file fails.

## Read state and property

| Command | What it returns |
|---|---|
| `elyra get --what text\|html\|value\|url\|title\|count\|box [--element <ref>]` | Element property — or the page's, when the property is the page's |
| `elyra is --what visible\|enabled\|checked --element <ref>` | Element state |
| `elyra find --locator <type> --value <text> --action <action>` | Finds by semantic locator and performs the action |
| `elyra highlight --selector <ref>` | Highlights the element |
| `elyra scrollintoview --element <ref>` | Scrolls to the element |
| `elyra inserttext --text <text>` | Inserts text **without key events** |

> **`inserttext` does not fire `keydown` or `keyup`.** Pages that react to key events do not behave as if you had typed — for those cases, use real typing.

## Low-level mouse

```
elyra mouse move --x <n> --y <n> [--page <id>] [--workspace <selector>] [--json]
elyra mouse down [--button <left|right|middle>] [--page <id>] [--workspace <selector>] [--json]
elyra mouse up [--button <left|right|middle>] [--page <id>] [--workspace <selector>] [--json]
elyra mouse wheel --dy <n> [--dx <n>] [--page <id>] [--workspace <selector>] [--json]
```

- `mouse move` requires `--x` and `--y`; `mouse wheel` requires `--dy`, with `--dx` optional.
- The coordinates are **absolute on the page** and depend on the current viewport. Without a recent snapshot, the target can miss — on pages with scrolling, the target moves without warning.
