Huarp API Documentation

Browser RPA Execution Platform

Recommended: Install Community Node

The easiest and most powerful way to use Huarp with n8n is by installing our official Community Node.

📦 Package Name: n8n-nodes-huarp

Installation Steps:

  1. In your n8n instance, go to Settings > Community Nodes.
  2. Click the Install button.
  3. Enter n8n-nodes-huarp in the npm Package Name field.
  4. Check the box "I understand the risks of installing unverified code from a public source".
  5. Click Install.

Once installed, simply search for Huarp in the n8n nodes panel to start building automations visually.

Overview

Huarp is a Browser RPA (Robotic Process Automation) platform that allows you to automate browser interactions through a simple REST API.

You can build automations visually using the drag-and-drop interface, or execute them directly via API from tools like n8n.

Authentication

🔐 Authentication Required
All API endpoints require authentication. You can use API Tokens (Recommended for automation) or Supabase JWTs.

API Tokens

API Tokens are long-lived keys designed for automation, scripts, and n8n workflows. They never expire unless you revoke them.

How to generate a token:

  1. Dashboard: Go to the menu → API Tokens → Click New Token.
  2. Workflow Builder: When you use "Copy CURL" or "Copy n8n Module", the builder can automatically generate a token for you.

Usage: Include the token in the Authorization header:

Authorization: Bearer huarp_123456789...

Note: You can also send the token without the "Bearer" prefix.

API Endpoints

POST/api/rpa/run

Execute browser automation from raw steps or a saved workflow.

Request Body (Option A - Raw Steps)

{
  "steps": [
    { "action": "goto", "url": "https://example.com" },
    { "action": "type", "selector": "#email", "text": "user@example.com" },
    { "action": "click", "selector": "button[type=submit]" },
    { "action": "wait_for", "selector": ".dashboard" },
    { "action": "extract_text", "selector": ".balance", "var": "balance" }
  ],
  "return_vars": ["balance"],
  "timeout_seconds": 60
}

Request Body (Option B - Saved Workflow)

{
  "workflow_id": "uuid-of-saved-workflow",
  "timeout_seconds": 60
}

Response (Success)

{
  "job_id": "550e8400-e29b-41d4-a716-446655440000",
  "status": "success",
  "data": {
    "balance": "$1,234.56"
  },
  "error": null
}

Response (Error)

{
  "job_id": "550e8400-e29b-41d4-a716-446655440000",
  "status": "error",
  "data": {},
  "error": "Element not found: .balance"
}

POST/api/workflows

Save a new workflow.

{
  "name": "Login and Extract Balance",
  "description": "Logs into banking portal and extracts account balance",
  "steps": [...]
}

GET/api/workflows

List all saved workflows.

GET/api/workflows/:id

Get a specific workflow by ID.

PUT/api/workflows/:id

Update an existing workflow.

DELETE/api/workflows/:id

Delete a workflow.

Supported Actions

Action Description Required Parameters
goto Navigate to a URL url
click Click an element selector
type Type text into an input field selector, text
wait_for Wait for an element to appear selector
extract_text Extract text content from an element selector, var
extract_attribute Extract an attribute value from an element selector, attribute, var
screenshot Capture a screenshot (base64) None
get_html Get the full page HTML None

Security

Huarp implements the following security restrictions:

Using with n8n (HTTP Request)

⚠️ Important: Increase Timeout
RPA tasks can take several minutes to complete. The default timeout in n8n (often 2 minutes) is usually insufficient.
Please increase the "Timeout" option in your HTTP Request node to at least 600000 ms (10 minutes).
Failure to do this may cause the connection to drop and the job to be executed multiple times due to automatic retries.

To call Huarp from n8n:

  1. Add an HTTP Request node
  2. Set method to POST
  3. Set URL to
  4. Add authentication:
  5. Value: Bearer huarp_your_token
  6. Set body to JSON with your steps or workflow_id
{
  "steps": [
    { "action": "goto", "url": "https://example.com" },
    { "action": "extract_text", "selector": "h1", "var": "title" }
  ],
  "return_vars": ["title"]
}

Tip: You can copy the complete n8n node JSON (with authentication included!) directly from the Workflow Editor.

Rate Limits

Concurrent browser executions are limited (default: 2-3 simultaneous jobs).

Jobs exceeding the timeout will be terminated and marked as timeout.