- Overview
- Get started
- Concepts
- Using UiPath CLI
- How-to guides
- CI/CD recipes
- Command reference
- Overview
- Exit codes
- Global options
- uip codedagent
- uip coder
- uip context-grounding
- uip docsai
- uip function
- uip guardrails
- uip llm-configuration
- uip llm-gateway
- uip maestro authoring
- uip maestro registry
- uip model-hub
- activities find
- activities get-default-xaml
- analyze
- analyzer-rules list
- build
- cleanup
- data-fabric-entities install
- data-fabric-entities list
- files diff
- get-library-object-repository
- get-object-repository
- init
- instances list
- pack
- packages inspect
- packages install
- packages versions
- publish
- remote
- restore
- run, debug & execution
- settings
- studio start
- templates search
- test-data add-entity
- test-data add-queue
- test-data add-variation
- tm
- uia
- validate
- workflow-examples get
- workflow-examples list
- uip tasks
- uip traces
- uip traces feedback
- Migration
- Reference & support
uip mcp
Syntax and options for `uip mcp`, which exposes UiPath CLI as a Model Context Protocol server for MCP-aware clients.
uip mcp exposes the CLI as a Model Context Protocol server, letting MCP-aware clients (Claude Desktop, Cursor, VS Code MCP hosts, etc.) invoke any uip subcommand as a tool.
Skills are the primary path for teaching AI coding agents to use the UiPath CLI — see uip skills and Skills. MCP is provided as an alternative for clients that do not support skills or that prefer MCP-style tool invocation. If your agent supports skills, prefer skills.
Synopsis
uip mcp serve
uip mcp serve
uip mcp serve honors the global options (--output, --output-filter, --log-level, --log-file) for the server process itself; the tools it exposes to clients run any CLI command and return its output. Exit codes follow the standard contract.
uip mcp serve
Starts the MCP server on stdio (newline-delimited JSON-RPC). There is no network listener, no HTTP transport, and no port configuration — stdio is the only supported transport in 1.x.
Arguments
None.
Options
None. The server runs until the stdio transport is closed by the client (usually when the host application quits).
Behavior
- The server advertises two tools:
run_command, for AI models, takes one argument:command(string) — The CLI command to run, without theuipprefix. Example:"login status --output json". The server splits the string on whitespace, keeping quoted runs together, and appends--output json.
run_argv, for programs that already hold the command as an argument list, takes one argument:args(array of strings) — The command's arguments, one per element, without theuipprefix. Example:["is", "connections", "list", "--output", "json"]. Each element is passed through as given, so values with spaces or quotes are safe. Nothing is appended, so pass your own--output.
- The server enumerates every installed
uipsubcommand at startup and includes a rendered command catalog in the MCP tool's description.mcpandhelpsubcommands are excluded from that catalog — the client cannot ask the server to start another MCP server. - Calls to both tools run one at a time.
- On each
run_commandcall, the CLI runs the requested command and returns the combined stdout/stderr. If the child exits non-zero, or if it wrote an error envelope to stderr with a zero exit code (a rare case where a command reports failure without changing the exit code), the result is flaggedisError: trueand prefixed withError (exit code N):.
Example (starting the server from a shell — normally your MCP client launches this for you):
uip mcp serve
uip mcp serve
Configuring an MCP client
All configurations use the same command/args. The server name (uipath below) is arbitrary.
Claude Desktop — edit claude_desktop_config.json:
- macOS:
~/Library/Application Support/Claude/claude_desktop_config.json - Windows:
%APPDATA%\Claude\claude_desktop_config.json
{
"mcpServers": {
"uipath": {
"command": "uip",
"args": ["mcp", "serve"]
}
}
}
{
"mcpServers": {
"uipath": {
"command": "uip",
"args": ["mcp", "serve"]
}
}
}
Restart Claude Desktop after saving.
Claude Code — add via its CLI:
claude mcp add uipath -- uip mcp serve
claude mcp add uipath -- uip mcp serve
Cursor — edit .cursor/mcp.json (project-local) or the Cursor global MCP config:
{
"mcpServers": {
"uipath": {
"command": "uip",
"args": ["mcp", "serve"]
}
}
}
{
"mcpServers": {
"uipath": {
"command": "uip",
"args": ["mcp", "serve"]
}
}
}
VS Code — edit .vscode/mcp.json:
{
"servers": {
"uipath": {
"command": "uip",
"args": ["mcp", "serve"]
}
}
}
{
"servers": {
"uipath": {
"command": "uip",
"args": ["mcp", "serve"]
}
}
}
Lifecycle
The MCP server has no standalone stop command. It lives as a child process of the MCP client and exits when:
- the client closes the stdio connection,
- the host application quits, or
- you remove the server entry from the client's config and reload.
Authentication and tenant context
uip mcp serve does not manage credentials. Every run_command and run_argv invocation reads the same stored session as an interactive shell would — so you must have run uip login separately before asking the agent to call commands that require auth. If no session exists, the tool result will contain the usual AuthenticationError payload. Refer to Exit codes.
Data shape
Tool results follow the MCP tool-call contract. On success:
{
"content": [
{ "type": "text", "text": "<combined stdout/stderr>" }
],
"isError": false
}
{
"content": [
{ "type": "text", "text": "<combined stdout/stderr>" }
],
"isError": false
}
On failure, isError is true and text is prefixed with Error (exit code N):. The inner text is the command's JSON output.
A run_argv result returns stdout, stderr, and the exit code as separate fields, both as structuredContent and as the same object serialized in text. A non-zero exit is reported in exitCode, and isError is never set:
{
"content": [
{ "type": "text", "text": "{\"stdout\":\"…\",\"stderr\":\"\",\"exitCode\":0}" }
],
"structuredContent": { "stdout": "…", "stderr": "", "exitCode": 0 }
}
{
"content": [
{ "type": "text", "text": "{\"stdout\":\"…\",\"stderr\":\"\",\"exitCode\":0}" }
],
"structuredContent": { "stdout": "…", "stderr": "", "exitCode": 0 }
}
Considerations
- Request JSON from
run_argvcalls.run_commandappends--output jsonto every command.run_argvappends nothing, so include--output jsoninargswhen the caller parses the output. - No filtering of destructive commands. The
run_commandandrun_argvtools can invoke anyuipsubcommand, includinglogout,tools uninstall, and tools that mutate Orchestrator state. Treat the MCP server as an authenticated shell and scope the agent accordingly. helpandmcpare hidden from the catalog but can still be invoked by the client. Nothing preventsmcp servefrom being called recursively through anotherrun_command; this is a no-op in practice because the outer server controls stdio.
Related
uip skills— primary AI integration path.- Skills — why skills are preferred over raw MCP access for agent ergonomics.
- Authentication — the session
run_commandinherits. - Global options —
--output jsoninside MCP calls.