rf-mcp
v0.36.0Robot Framework MCP Server - Natural Language Test Automation Bridge
These tools were reported by the server itself during our smoke test (tools/list), not copied from the README.
manage_library_plugins Manage Library Plugins
Inspect or reload library plugins.
| Parameter | Type | Description |
|---|---|---|
action | string | One of "list", "reload", or "diagnose". |
plugin_name | Plugin name when action="diagnose". |
recommend_libraries Recommend Libraries
Recommend libraries for a scenario or generate/merge sampling prompts. WHEN TO USE THIS TOOL: - IMMEDIATELY after analyze_scenario, before execute_step - When you encounter "No keyword with name" errors - To discover which libraries provide needed functionality This tool analyzes scenario text and suggests relevant libraries, saving you from guessing which libraries to import.
| Parameter | Type | Description |
|---|---|---|
scenario * | string | Natural-language description of the task to automate. |
apply_search_order | boolean | When True, applies recommended order to the session. |
available_libraries | Optional pre-fetched library metadata to use instead of registry defaults. | |
check_availability | boolean | When True, checks installability/presence of suggested libs. |
context | string | Context such as "web", "mobile", or "api". Defaults to "web". |
include_keywords | boolean | When True, include a compact keyword list (names only) for the top recommendation. |
k | Number of samples to request when mode="sampling_prompt" (defaults to 4). | |
max_recommendations | integer | Maximum libraries to return (direct mode). |
mode | string | "direct", "sampling_prompt", or "merge_samples". |
samples | Sampled recommendations to merge when mode="merge_samples". | |
session_id | Optional session id to align recommendations with an existing session. | |
use_llm_refinement | boolean | When True, uses LLM via ctx.sample() to refine recommendations. |
analyze_scenario Analyze Scenario
Analyze a natural-language scenario into structured intent and create a session. WORKFLOW: This is the single front door — your FIRST tool call for any test scenario. It CREATES the session, so do NOT also call manage_session(action="init") for the same scenario (that causes redundant session churn). Reuse the returned session_id in every later call. What this tool does: 1. Creates a new session with unique session_id (or reuses provided one) 2. Analyzes scenario to detect context (web/api/mobile/desktop) 3. Auto-configures libraries based on scenario text 4. Returns session_id for use in…
| Parameter | Type | Description |
|---|---|---|
scenario * | string | Human-language description of the task to automate. |
context | string | Application context (e.g., "web", "mobile", "api", "desktop"); defaults to "web". An explicit context="desktop" DETERMINISTICALLY forces a native desktop (PlatynUI) session regardless of scenario word… |
session_id | string | Optional existing session id to reuse; if omitted, a new one is created. |
find_keywords Find Keywords
Discover Robot Framework keywords using multiple strategies. WHEN TO USE THIS TOOL: - ALWAYS before calling execute_step with an unfamiliar keyword - When you're unsure of exact keyword name or spelling - To discover what keywords are available in imported libraries - When error says "No keyword with name 'X' found"
| Parameter | Type | Description |
|---|---|---|
query * | string | Search text or intent description. Examples: "click a button", "validate json", "get*request" |
context | string | Scenario context (e.g., "web", "mobile", "api") used by semantic discovery. |
current_state | Optional state payload to improve semantic matching. | |
library_name | Optional library filter applied to ALL strategies. When set, restricts results to the named library and its compatible siblings (e.g., library_name="Browser" excludes Sel… | |
limit | Optional maximum number of results to return. | |
session_id | Required for strategy="session" to search the live RF namespace. | |
strategy | string | Discovery approach: - "semantic": Hybrid keyword search combining name/doc pattern matching, tag/action-class classification, and (when installed) sentence-transformers embedding… |
strict_library | boolean | OBS-33 — when True AND a library preference is set (via ``library_name`` or session ``explicit_library_preference``), exclude EVERY library that isn't the preferr… |
manage_session Manage Session
Manage session lifecycle: initialize, configure libraries/variables, and organize tests. For a NEW scenario, prefer analyze_scenario — it is the front door that CREATES the session (and auto-configures libraries). Use manage_session for explicit session ops on an existing session (importing extra libraries/resources/variables, multi-test structure). Do NOT call action="init" right after analyze_scenario — the session already exists; that only causes redundant churn.
| Parameter | Type | Description |
|---|---|---|
action * | string | |
alias | ||
args | ||
keyword | ||
libraries | ||
library_name | ||
model_name | ||
model_tier | ||
profile | ||
resource_path | ||
scenario | ||
scope | string | |
session_id | string | |
template | ||
test_documentation | string | |
test_message | string | |
test_name | ||
test_setup | ||
test_status | string | |
test_tags | ||
test_teardown | ||
tool_profile | ||
variable_file_path | ||
variables |
execute_flow Execute Flow
Execute structured flow (if/for/try) within a session.
| Parameter | Type | Description |
|---|---|---|
session_id * | string | Session id to run the flow in. |
structure * | string | Flow type ("if", "for", "try"). |
condition | Expression for if/conditional flows. | |
else_steps | Steps for the else branch (if). | |
except_patterns | Error patterns to match for except handling. | |
except_steps | Steps for the except block. | |
finally_steps | Steps for the finally block. | |
item_var | string | Variable name to bind each item in for-each loops. |
items | Items to iterate when structure="for". | |
max_iterations | integer | Maximum iterations for for-each loops. |
rethrow | boolean | Whether to rethrow after except/finally. |
stop_on_failure | boolean | Whether to stop loop/branch execution on first failure. |
then_steps | Steps for the main branch (if/loop body/try block). | |
try_steps | Steps for the try block (when structure="try"). |
get_session_state Get Session State
Retrieve aggregated session state for debugging and visibility.
| Parameter | Type | Description |
|---|---|---|
session_id * | string | Active session identifier to inspect. |
dom_chunk_size | integer | Maximum size of each DOM chunk when streaming is enabled (minimum 1024 bytes). |
elements_of_interest | Targeted element identifiers passed to application state collectors. | |
include_dom_stream | boolean | Chunk large page_source payloads into page_source_stream entries for easier transport. |
include_reduced_dom | boolean | Whether to include lightweight semantic DOM (ARIA snapshots) for quick inspection. |
mode | string | |
page_source_filtered | boolean | When True, returns sanitized/filtered DOM text instead of the full source. |
page_source_filtering_level | string | Filtering aggressiveness for DOM output (standard|aggressive). |
sections | Specific data blocks to include (e.g., summary, page_source, variables, application_state, ui_tree). ui_tree (desktop/PlatynUI sessions only): accessibility-tree snapshot. Lists applications; pass app… | |
since_version | ||
state_type | string | Type of application state to fetch when requesting application_state (dom|api|database|all). |
execute_step Execute Step
Execute a single Robot Framework keyword (or Evaluate) within a session.
| Parameter | Type | Description |
|---|---|---|
keyword * | string | Keyword name (Library.Keyword supported). Use find_keywords to discover correct keyword names before calling. |
arguments | array | Keyword arguments; positional and named (`name=value`) supported. |
assign_to | Variable name(s) to assign the result to (string or list). CRITICAL: Use this to capture results for later steps. Example: assign_to="response" captures ${response} variable | |
bdd_group | string | Optional group name for BDD keyword generation. Steps with the same bdd_group are clustered into a single behavioral keyword when build_test_suite(bdd_style=True) is called. Examp… |
bdd_intent | string | BDD intent prefix for the group: "given", "when", "then", "and", "but". Used with bdd_group to assign Given/When/Then prefixes in the generated BDD test suite. |
detail_level | string | Response verbosity: "minimal" | "standard" | "full". |
expression | Expression for mode="evaluate"; falls back to keyword/first argument. | |
mode | string | "keyword" (default) or "evaluate" (runs BuiltIn.Evaluate). |
pre_validate_timeout_ms | Override the pre-validation gate's timeout for this single call. Pre-validation is the fast ~500ms-default check that verifies an element is visible / enabled before the keyword runs; it a… | |
raise_on_failure | boolean | If True, raise on failure; otherwise return error in payload. |
record | Override the record gate that decides whether a successful step is appended to session.steps for build_test_suite output. - None (default): auto-classify. Read-only inspection keywords (… | |
scenario_hint | string | Optional scenario text to auto-configure libraries on first call. |
session_id | string | Session to execute in; resolves default if omitted. |
timeout_ms | Optional timeout in milliseconds for keyword execution. If not provided, uses smart defaults based on keyword type: - Element actions (Click, Fill): 5000ms - Navigation (Go To,… | |
use_context | Whether to run inside RF native context; defaults via config/attach. |
build_test_suite Build Test Suite
Generate a Robot Framework test suite from previously executed steps.
| Parameter | Type | Description |
|---|---|---|
test_name * | string | Name for the generated test case. |
bdd_style | boolean | Generate BDD-style suite with a Keywords section. When True, steps are grouped into behavioral keywords (Given/When/Then) and a ``*** Keywords ***`` section is appended to the generated .robot content… |
data_driven_mode | string | How to render data-driven (template) test cases. "auto" (default) — auto-detect: named rows → suite_template, else per_test. "per_test" — [Template] per test case with data rows (current behavio… |
documentation | string | Optional test case documentation. |
include_pre_start | boolean | Whether to adopt exploratory steps executed BEFORE start_test into the generated test body. Default False excludes them (the response reports ``excluded_pre_start_count`` + a summary) so the suite ref… |
output_path | string | Optional absolute path to persist the generated .robot suite to disk directly (UTF-8; parent directories created). ALWAYS use this to save a suite — do NOT write ``rf_text`` via the ``Create File``… |
remove_library_prefixes | boolean | Whether to strip library prefixes from keywords. |
session_id | string | Session containing executed steps; auto-resolves if empty/invalid. |
tags | Optional test tags. |
check_library_availability Check Library Availability
Verify that specified Robot Framework libraries can be imported/installed. Recommended as step 3 after analyze_scenario and recommend_libraries; use the recommended names to avoid unnecessary checks.
| Parameter | Type | Description |
|---|---|---|
libraries * | array | Library names to verify (preferably from recommend_libraries output). |
execute_batch Execute Batch
Execute multiple RF keywords in one call with recovery and variable chaining. Reduces N MCP round-trips to 1. Steps run sequentially; each step's return value is available to later steps via ${STEP_N} references in arguments. Both 0-based (${STEP_0} = first step) and 1-based (${STEP_1} = first step) indexing are accepted. When ambiguous, 1-based is preferred.
| Parameter | Type | Description |
|---|---|---|
session_id * | string | Session to execute within (must exist or be auto-created). |
steps * | array | List of step dicts, each with: - keyword (str, required): RF keyword name - arguments (list[str], optional): Positional arguments, may contain ${STEP_N} (both 0-based and 1-based indexing supported)… |
max_recovery_attempts | integer | Max recovery retries per failed step (1-10, default 2). |
on_failure | string | Policy on step failure: - "stop": abort immediately - "retry": retry without recovery logic - "recover" (default): attempt tiered recovery before giving up On DESKTOP (PlatynUI) sessions, retries are… |
timeout_ms | integer | Total batch time budget in milliseconds (1000-600000, default 120000). |
resume_batch Resume Batch
Resume a failed batch from its failure point, optionally inserting fix steps. After execute_batch returns status=FAIL with a batch_id, call this to: 1. Re-run the failed step (with optional fix_steps injected before it) 2. Continue executing remaining steps from the original batch
| Parameter | Type | Description |
|---|---|---|
batch_id * | string | The batch_id from a failed execute_batch response. |
fix_steps | Optional steps to execute before retrying the failed step. Same format as execute_batch steps. | |
timeout_ms | Override remaining timeout budget (uses original if omitted). |
get_keyword_info Get Keyword Info
Get keyword/library docs or parse a signature. Call this before execute_step when you know the keyword name but not its arguments. Modes: "keyword" (default — document one keyword), "library" (list a library's keywords), "session" (resolve against the live session namespace), "parse" (parse a signature string). Pass session_id to scope the lookup to that session's libraries.
| Parameter | Type | Description |
|---|---|---|
arguments | Optional arguments to parse when mode="parse". | |
keyword_name | Keyword to document (required for modes "keyword"/"session"/"parse"). | |
library_name | Library to document (required for mode "library"; optional for keyword mode — explicit per-call scope that takes precedence over session-derived scope). | |
mode | string | One of "keyword" (default), "library", "session", or "parse". |
session_id | Optional session id. - mode="keyword" / "global" (OBS-19): when provided without ``library_name``, restricts the keyword lookup to libraries imported in that session… |
set_library_search_order Set Library Search Order
Set explicit library search order for keyword resolution.
| Parameter | Type | Description |
|---|---|---|
libraries * | array | Library names in priority order (highest first). |
session_id | string | Session to apply the search order to. |
get_locator_guidance Get Locator Guidance
Provide locator/selector guidance for Browser, SeleniumLibrary, AppiumLibrary, PlatynUI.BareMetal, or RequestsLibrary. For API testing, call with library="requests" (or "api") to get a RequestsLibrary request/response cookbook — session setup, response-field access (${resp.json()["field"]}), the $resp-in-Evaluate rule, Status Should Be, JSON body/headers, the Cookie token header, and expected_status= for non-2xx — BEFORE writing Evaluate-based assertions. For VISUAL validation, call with library="visual" (or "screenshot") to learn WHEN a screenshot beats the DOM/ARIA tree (canvas/image t…
| Parameter | Type | Description |
|---|---|---|
error_message | Optional error text to tailor guidance (e.g., from a failed keyword). | |
keyword_name | Optional keyword name for context-specific hints. | |
library | string | Target library ("Browser", "SeleniumLibrary", "AppiumLibrary", "PlatynUI.BareMetal", or "RequestsLibrary"/"api"). Case-insensitive. |
visual_check Visual Check
Capture a screenshot of the current UI for VISUAL validation (change: visual-inspection-guidance). Token-cheap by DEFAULT: saves the screenshot to disk and returns the PATH as text — a multimodal agent WITH file access reads that file on demand for checks the DOM/ARIA can't do (canvas/image text, layout/overlap, obscured elements, color, charts). Call get_locator_guidance(library="visual") for when to use it. Set return_image=true ONLY if your model is multimodal AND cannot read the saved file (e.g. a hosted/remote MCP): the response then includes an image content block. This requires ROBO…
| Parameter | Type | Description |
|---|---|---|
session_id * | string | |
filename | ||
return_image | boolean |
run_test_suite Run Test Suite
Validate or execute a Robot Framework suite.
| Parameter | Type | Description |
|---|---|---|
capture_screenshots | boolean | Enable screenshot capture on failures (if supported). |
execution_options | object | RF execution options (variables, tags, loglevel, etc.). For ``suite_file_path`` with dry/validate mode, these are forwarded to Robot (e.g. ``variables``, ``include_tags``, ``exclude_tags``, ``test`` /… |
include_warnings | boolean | Whether to include warnings in validation output. |
mode | string | "dry"/"validate" for dry run; "full" to execute. Defaults to "full". |
output_level | string | Response verbosity ("minimal", "standard", "detailed"). |
session_id | string | Session containing steps to build/execute; optional if suite_file_path is given. |
suite_file_path | string | Path to an existing .robot file to validate/execute. |
validation_level | string | Dry-run validation depth ("minimal", "standard", "strict"). Default "standard". |
manage_attach Manage Attach
Inspect or control attach bridge configuration.
| Parameter | Type | Description |
|---|---|---|
action | string | One of: - "status" (default): Check bridge configuration and health - "stop": Send stop command to bridge (sets stop flag) - "cleanup"/"clean": Clean expired sessions and check bridge health - "reset"… |
intent_action Intent Action
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 ``extract`` with ``mode="text"``. The ``extract`` verb is the canonical mode-aware getter (text / attribute / count / value / url / title) and additionally surfaces ``extracted_value`` at the top level of the response. ``extract_text`` will be removed in a future release; prefer ``intent="extract"`` for new code. The intent is resolved based on the sessio…
| Parameter | Type | Description |
|---|---|---|
intent * | string | Action verb (e.g. "click", "navigate", "fill", "extract") |
assign_to | Variable name to capture result (esp. useful for extract: the extracted text/count/attribute is assigned to this var). | |
attribute_name | Required when ``intent="extract"`` and ``mode="attribute"``; the HTML attribute name to read (e.g. ``"href"``, ``"data-testid"``, ``"value"``). Ignored for other modes. | |
commit | boolean | 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 i… |
detail_level | string | Response detail level |
force | boolean | 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 int… |
match | string | 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=… |
mode | string | 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… |
nth | 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 a… | |
options | Additional options (e.g. {"timeout": "10s"}) | |
session_id | Session to execute against. Pass the session_id returned by analyze_scenario or manage_session(action="init") — the session that has your libraries loaded. If omitted, it is inferred ONLY when exact… | |
target | Locator or URL (e.g. "#submit", "text=Login", "https://example.com"). REQUIRED for navigate/click/fill/hover/select/assert_visible/wait_for. Only optional for extract with mode="url" or mode="title".… | |
value | Value for fill/select intents |