intent_action
Automates web interactions by executing high-level intents (click, fill, navigate) that automatically resolve to the appropriate Robot Framework library keyword.
Instructions
Execute a high-level intent that auto-resolves to the correct library keyword.
Valid intents: navigate, click, fill, hover, select, assert_visible, extract, wait_for.
Also accepted but DEPRECATED:
extract_text — equivalent to
extractwithmode="text". Theextractverb is the canonical mode-aware getter (text / attribute / count / value / url / title) and additionally surfacesextracted_valueat the top level of the response.extract_textwill be removed in a future release; preferintent="extract"for new code.
The intent is resolved based on the session's active library (Browser/SeleniumLibrary/AppiumLibrary).
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| nth | No | Zero-based nth-match index. Disambiguates when multiple elements match the same locator (e.g., an id duplicated across mobile vs desktop nav). Browser library appends ``>> nth=<n>``; SeleniumLibrary appends ``:nth-of-type(<n+1>)`` for CSS locators only (other locator types are unaffected and log a debug-level warning). | |
| mode | No | For ``intent="extract"`` only. Selects what to read from the page; ignored for other intents. "text" — element text content (default) "attribute" — element attribute value (requires attribute_name) "count" — number of matching elements (multi-match OK) "value" — DOM property "value" (input values) "url" — current page URL (no target needed) "title" — current page title (no target needed) The extracted value is surfaced as ``result["extracted_value"]`` and assigned to ``assign_to`` if provided. mode="count" additionally skips pre-validation for this call — counting is the only mode where matching zero/multiple elements is the expected outcome rather than a failure. | text |
| force | No | Use when: the element is visible but Playwright reports it "blocked by another element" — overlay, sticky header, cookie-consent banner, modal backdrop, animation still running. Symptom: ``Click intercepted`` or ``element is not stable`` / ``outside of the viewport`` errors despite the element appearing correct in the ARIA snapshot. Example: a "Submit" button covered by a sticky consent banner the user can't dismiss programmatically. What it does: for a Browser-library click intent, swaps ``Click`` for ``Click With Options force=True``, which skips Playwright's actionability checks. For other libraries / intents whose mapping declares no ``force_keyword``, the flag is silently ignored. Caveat: do NOT use ``force=True`` to drive elements that are genuinely hidden (display:none, visibility:hidden) — that's an anti-pattern; the resulting click won't behave like a real user click. Prefer natural locators first; fall through to ``force=True`` only when an overlay is the genuine cause. | |
| match | No | Select-match strategy for the ``select`` intent. ``"label"`` (default) - match by visible option text. Mirrors RF semantics for ``Select Options By label``. ``"value"`` - match by ``<option value="X">`` attribute. ``"index"`` - match by zero-based integer index. ``"text"`` - synonym for ``"label"`` (most libraries). ``"auto"`` - OPT-IN heuristic. Numeric value -> ``"value"``, otherwise ``"label"``. Use with care: numeric visible labels (years, amounts) mis-route. For SeleniumLibrary, this also picks the dispatched keyword (``Select From List By Label`` / ``Value`` / ``Index``). Ignored for non-select intents. | label |
| value | No | Value for fill/select intents | |
| commit | No | Use when: the page uses Vue, React, Angular reactive forms, jQuery validate, idealForms, formvalidation.io, or any framework that gates validation on the DOM ``change`` event. Symptom: a form submit is rejected with a "required" or validation error despite every visible field appearing correctly filled; the framework's internal model still thinks the inputs are empty because Playwright's ``fill`` didn't fire a real ``change``. What it does: after a successful Browser-library FILL, dispatches a real DOM ``change`` event on the target via Browser's ``Dispatch Event`` keyword. Off by default — the follow-up is best-effort and any failure is logged and ignored (it never escalates a successful fill into a failed step). No effect for non-FILL intents, non-Browser libraries, or failed fills. | |
| intent | Yes | Action verb (e.g. "click", "navigate", "fill", "extract") | |
| target | No | Locator or URL (e.g. "#submit", "text=Login", "https://example.com"). Optional for extract mode="url"/mode="title". | |
| options | No | Additional options (e.g. {"timeout": "10s"}) | |
| assign_to | No | Variable name to capture result (esp. useful for extract: the extracted text/count/attribute is assigned to this var). | |
| session_id | No | Session to execute against (uses default if not provided) | |
| detail_level | No | Response detail level | standard |
| attribute_name | No | Required when ``intent="extract"`` and ``mode="attribute"``; the HTML attribute name to read (e.g. ``"href"``, ``"data-testid"``, ``"value"``). Ignored for other modes. |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
No arguments | |||