# uip agenthub mcp-tools and remote-a2a-agent

> Syntax and options for `uip agenthub mcp-tools`, which manages the tools attached to an AgentHub MCP server, and `uip agenthub remote-a2a-agent`, which manages remote agent-to-agent registrations.

Part of the [`uip agenthub`](./uip-agenthub.md) command family. This page covers `mcp-tools` (the tools attached to a `uipath`- or `platform`-type MCP server) and `remote-a2a-agent` (agent-to-agent registrations, unrelated to MCP servers). See [`uip agenthub`](./uip-agenthub.md#concepts) for shared concepts — server types, folder scoping, input modes.

## Synopsis

```text
uip agenthub mcp-tools list --mcp <slug> [--name <substr>] [--limit <n>] [--offset <n>]
uip agenthub mcp-tools get --mcp <slug> [<id>] [--name <name>] [--allow-multiple]
uip agenthub mcp-tools create-resource --mcp <slug> --category <category> (--target-name <name> | --target-identifier <guid>) [options...]
uip agenthub mcp-tools create-raw --mcp <slug> --file <path> | --body <json> [options...]
uip agenthub mcp-tools update [<id>] --mcp <slug> [--name <substr>] [--rename <name>] [options...]
uip agenthub mcp-tools delete [<ids...>] --mcp <slug> [--name <substr>] -y
uip agenthub mcp-tools template <resource|raw>
uip agenthub mcp-tools candidates --category <category> [--name <substr>] [--limit <n>] [--offset <n>]
uip agenthub mcp-tools enable --mcp <slug> [--name <name>]...
uip agenthub mcp-tools disable --mcp <slug> [--name <name>]...

uip agenthub remote-a2a-agent list [--name <substr>] [--limit <n>] [--offset <n>]
uip agenthub remote-a2a-agent get <slug>
uip agenthub remote-a2a-agent create --name <name> --slug <slug> [options...]
uip agenthub remote-a2a-agent update <slug> [options...]
uip agenthub remote-a2a-agent delete <slug> -y
uip agenthub remote-a2a-agent refresh-card <slug>
```

## uip agenthub mcp-tools

Manage tools attached to AgentHub MCP servers. Every verb requires `--mcp <slug>` to identify the parent server. Two tool-authoring paths exist: `create-resource` (resolve an existing Orchestrator process/agent/API-workflow into a tool via the Resource Catalog Service) and `create-raw` (a hand-written JSON payload) — both only work against a `uipath`-type parent server. `enable`/`disable` are a separate mechanism specific to `platform`-type servers, toggling membership in that server's `selectedToolNames` list rather than creating a distinct tool resource.

### uip agenthub mcp-tools list

#### Options

| Long | Value | Description |
|---|---|---|
| `--mcp <slug>` | string | **Required.** Parent MCP server slug. |
| `--name <substr>` | string | Filter by name substring. |
| `--limit <number>` / `--offset <number>` | integer | Paging. |

#### Example

```bash
uip agenthub mcp-tools list --mcp invoice-mcp
```

#### Data shape (--output json)

```json
{ "Code": "AgentHubMcpToolsList", "Data": { "items": [], "total": 0, "count": 0 } }
```

### uip agenthub mcp-tools get

Get one tool by id or by `--name` lookup.

#### Arguments

| Name | Required | Purpose |
|---|---|---|
| `[id]` | no | Tool id. Omit when using `--name`. |

#### Options

| Long | Value | Description |
|---|---|---|
| `--mcp <slug>` | string | **Required.** Parent MCP server slug. |
| `--name <name>` | string | Lookup by name substring. Fails if it matches other than exactly one tool, unless `--allow-multiple` is passed. |
| `--allow-multiple` | flag | Return every name match instead of failing on ambiguity. |

Passing neither `<id>` nor `--name` fails with a `NextCommand` hint pointing at `mcp-tools list`.

#### Example

```bash
uip agenthub mcp-tools get --mcp invoice-mcp tool-1
```

#### Data shape (--output json)

```json
{ "Code": "AgentHubMcpToolsGet", "Data": { "id": "tool-1", "name": "CreateInvoice" } }
```

### uip agenthub mcp-tools create-resource / create-raw

Add a tool to a `uipath`-type MCP server. Requires the parent to actually be `uipath`-typed — fails with a `NextCommand` hint (pointing at `refresh-tools` or `mcp-tools enable`, depending on the real type) otherwise.

#### Options

| Long | Value | Applies to | Description |
|---|---|---|---|
| `--mcp <slug>` | string | both | **Required.** Parent MCP server slug (must resolve to a `uipath`-type server). |
| `--name <name>` | string | both | Tool name. |
| `--description <text>` | string | both | Tool description. |
| `--target-name <name>` | string | `create-resource` | Resolve the target by display name via the Resource Catalog Service. Requires `--category`. Fails as `AmbiguousName` (with a `candidates` list) if more than one match, `UnknownTarget` if none. |
| `--target-identifier <guid>` | GUID | `create-resource` | Explicit target identifier — skips RCS name resolution. Wins over `--target-name` if both are given. |
| `--category <category>` | `automation`\|`agent`\|`agentic-process`\|`api-workflow` | `create-resource` | Maps to an RCS entity-type/sub-type filter pair (`automation`→Process, `agent`→Agent, `agentic-process`→ProcessOrchestration, `api-workflow`→Api). Required with `--target-name`. |
| `--target-folder-key <key>` / `--target-folder-path <path>` | GUID / string | both | Folder of the target resource, when it differs from the MCP server's own folder. An explicit value here always wins over one resolved from an RCS candidate or a payload field. |
| `--input-schema <json>` / `--output-schema <json>` / `--metadata <json>` | JSON | both | Tool schema/metadata. Validated as parseable JSON strings before the call. |
| `--continue-on-error` (default) / `--fail-fast` | flag | both | Batch-failure behavior (registered but not exercised by a single-tool create). |
| `--file <path>` / `--body <json>` | path / JSON | `create-raw` (required — no scalar mode) | Raw tool payload. `create-raw` has no equivalent scalar-flag input mode; `--file`/`--body` is the only way to supply content. |
| `--dry-run` | flag | both | Print the mutation plan without calling the API. |

#### Examples

```bash
uip agenthub mcp-tools create-resource --mcp invoice-mcp --category automation \
  --target-name InvoiceProcess --folder-key f1f2f3f4-0000-0000-0000-000000000001

uip agenthub mcp-tools create-raw --mcp invoice-mcp --file ./tool.json \
  --folder-key f1f2f3f4-0000-0000-0000-000000000001
```

#### Data shape (--output json)

```json
{ "Code": "AgentHubMcpToolsCreate", "Data": { "id": "tool-1", "name": "InvoiceProcess" } }
```

### uip agenthub mcp-tools update

Update one or more tools (via `--allow-multiple` with a `--name` match) on a `uipath`-type server.

#### Arguments

| Name | Required | Purpose |
|---|---|---|
| `[id]` | no | Tool id. Omit when using `--name`. |

#### Options

| Long | Value | Description |
|---|---|---|
| `--mcp <slug>` | string | **Required.** Parent MCP server slug. |
| `--name <substr>` | string | Lookup flag (selects which tool to update) — **not** a rename. Use `--rename` for that. |
| `--allow-multiple` | flag | Apply the update to every `--name` match instead of failing on ambiguity. |
| `--rename <name>` | string | New tool name. |
| `--description <text>` / `--target-identifier <guid>` / `--target-folder-key <key>` / `--target-folder-path <path>` / `--input-schema <json>` / `--output-schema <json>` / `--metadata <json>` | — | Same semantics as the `create-resource`/`create-raw` fields above. |

#### Examples

```bash
uip agenthub mcp-tools update tool-1 --mcp invoice-mcp --rename CreateInvoice
uip agenthub mcp-tools update --mcp invoice-mcp --name LegacyTool --rename NewTool
```

#### Data shape (--output json)

```json
{ "Code": "AgentHubMcpToolsUpdate", "Data": { "id": "tool-1", "name": "NewTool" } }
```

A single-id update returns one object; an `--allow-multiple` update returns an array.

### uip agenthub mcp-tools delete

#### Arguments

| Name | Required | Purpose |
|---|---|---|
| `[ids...]` | no | Tool id(s). Omit when using `--name`. |

#### Options

| Long | Description |
|---|---|
| `--mcp <slug>` | **Required.** Parent MCP server slug. |
| `--name <substr>` | Lookup by name substring instead of id(s). |
| `--allow-multiple` | Delete every name match instead of failing on ambiguity. |
| `-y, --yes` | Required to confirm. The CLI never prompts. |
| `--dry-run` | Print the mutation plan without deleting. |

#### Example

```bash
uip agenthub mcp-tools delete --mcp invoice-mcp tool-1 -y
```

#### Data shape (--output json)

```json
{ "Code": "AgentHubMcpToolsDelete", "Data": { "ids": ["tool-1"], "deleted": true } }
```

### uip agenthub mcp-tools template

Emit a resource-tool JSON skeleton. No folder options.

#### Arguments

| Name | Required | Purpose |
|---|---|---|
| `<kind>` | yes | `resource` or `raw`. |

#### Example

```bash
uip agenthub mcp-tools template resource
```

#### Data shape (--output json)

```json
{ "Code": "AgentHubMcpToolsTemplate", "Data": { "type": 0, "name": "resource-tool", "processType": "automation", "targetIdentifier": "resource-id", "targetFolderKey": "folder-guid" } }
```

### uip agenthub mcp-tools candidates

List Resource Catalog Service entities eligible for `create-resource --target-name`/`--target-identifier` resolution, for one category.

#### Options

| Long | Value | Required | Description |
|---|---|---|---|
| `--category <category>` | `automation`\|`agent`\|`agentic-process`\|`api-workflow` | **yes** | Candidate source category. Missing/invalid values fail client-side listing the allowed set. |
| `--name <substr>` | string | no | Filter candidate name. |
| `--limit <number>` / `--offset <number>` | integer | no | Paging. |

Requires the `RCS.Search` scope — a 401/invalid-scope error includes an instruction to re-run `uip login` and retry.

#### Example

```bash
uip agenthub mcp-tools candidates --category automation
```

#### Data shape (--output json)

```json
{ "Code": "AgentHubMcpToolsCandidates", "Data": { "items": [], "total": 0, "count": 0, "category": "automation" } }
```

### uip agenthub mcp-tools enable / disable

Toggle tool membership on a `platform`-type MCP server's `selectedToolNames` list. Fails if the parent server is not `platform`-typed.

#### Options

| Long | Value | Description |
|---|---|---|
| `--mcp <slug>` | string | **Required.** Parent MCP server slug (must be `platform`-typed). |
| `--name <name>` | string, repeatable | Tool name(s) to enable/disable. Alternatively pass `--file`/`--body` with a JSON array or single name. |
| `--dry-run` | flag | Print the mutation plan without calling the API. |

#### Examples

```bash
uip agenthub mcp-tools enable --mcp orch-mcp --name CreateAsset
uip agenthub mcp-tools disable --mcp orch-mcp --name CreateAsset
```

#### Data shape (--output json)

```json
{ "Code": "AgentHubMcpToolsEnable", "Data": { "slug": "orch-mcp", "selectedToolNames": ["CreateAsset"] } }
```

`disable`'s equivalent `Code` is `AgentHubMcpToolsDisable`; the response reflects `selectedToolNames` after removal.

## uip agenthub remote-a2a-agent

Manage remote agent-to-agent (A2A) registrations — described in source as "Advanced - not exposed in Orchestrator UI." Unrelated to MCP servers; carries its own agent-card metadata (name, description, a card URL or raw card JSON), optional static headers, an Integration Service connection id, and an activation flag. Folder-scoped like the rest of AgentHub.

### uip agenthub remote-a2a-agent list

#### Options

| Long | Value | Description |
|---|---|---|
| `--name <substr>` | string | Filter by name substring (server-side `search` param). |
| `--limit <number>` / `--offset <number>` | integer | Paging (`top`/`skip` on the wire). |

#### Example

```bash
uip agenthub remote-a2a-agent list
```

#### Data shape (--output json)

```json
{ "Code": "AgentHubRemoteA2aAgentList", "Data": { "items": [] } }
```

### uip agenthub remote-a2a-agent get

#### Arguments

| Name | Required | Purpose |
|---|---|---|
| `<slug>` | yes | Agent slug. |

#### Example

```bash
uip agenthub remote-a2a-agent get remote-agent
```

#### Data shape (--output json)

```json
{ "Code": "AgentHubRemoteA2aAgentGet", "Data": { "slug": "remote-agent" } }
```

### uip agenthub remote-a2a-agent create

#### Options

| Long | Value | Description |
|---|---|---|
| `--slug <slug>` / `--name <name>` / `--description <text>` | string | Agent identity fields. |
| `--agent-card-url <url>` | url | Agent card URL. |
| `--agent-card-json <json>` | JSON | Raw agent card JSON, as an alternative to a URL. |
| `--header <key=value>` | string, repeatable | Static request header. JSON-stringified into `headers` on the payload. |
| `--connection-id <id>` | string | Integration Service connection id. |
| `--use-relay` | flag | Route requests through UiPath Relay. |
| `--file <path>` / `--body <json>` | path / JSON | Alternative to scalar flags — same mutually-exclusive input-mode rule as `mcp create`. |
| `--dry-run` | flag | Print the mutation plan without calling the API. |

#### Example

```bash
uip agenthub remote-a2a-agent create --name RemoteAgent --slug remote-agent
```

#### Data shape (--output json)

```json
{ "Code": "AgentHubRemoteA2aAgentCreate", "Data": { "slug": "remote-agent" } }
```

### uip agenthub remote-a2a-agent update

Same fields as `create` (minus `--slug`, which is the positional argument), plus:

| Long | Value | Description |
|---|---|---|
| `--is-active <boolean>` | `true`\|`false` | Activation state. Rejects any other literal value with an argument-parsing error. |

#### Arguments

| Name | Required | Purpose |
|---|---|---|
| `<slug>` | yes | Agent slug. |

#### Example

```bash
uip agenthub remote-a2a-agent update remote-agent --name RemoteAgent
```

#### Data shape (--output json)

```json
{ "Code": "AgentHubRemoteA2aAgentUpdate", "Data": { "slug": "remote-agent" } }
```

### uip agenthub remote-a2a-agent delete

#### Arguments

| Name | Required | Purpose |
|---|---|---|
| `<slug>` | yes | Agent slug. |

#### Options

| Long | Description |
|---|---|
| `-y, --yes` | Required to confirm. The CLI never prompts. |
| `--dry-run` | Print the mutation plan without deleting. |

#### Example

```bash
uip agenthub remote-a2a-agent delete remote-agent -y
```

#### Data shape (--output json)

```json
{ "Code": "AgentHubRemoteA2aAgentDelete", "Data": { "slug": "remote-agent", "deleted": true } }
```

### uip agenthub remote-a2a-agent refresh-card

Re-fetch and refresh a remote agent's card metadata.

#### Arguments

| Name | Required | Purpose |
|---|---|---|
| `<slug>` | yes | Agent slug. |

#### Options

| Long | Description |
|---|---|
| `--dry-run` | Print the mutation plan without refreshing. |

#### Example

```bash
uip agenthub remote-a2a-agent refresh-card remote-agent
```

#### Data shape (--output json)

```json
{ "Code": "AgentHubRemoteA2aAgentRefreshCard", "Data": { "slug": "remote-agent" } }
```

## Related

- [`uip agenthub`](./uip-agenthub.md) — concepts and `mcp` (server registrations).

## See also

- [Global options](./global-options.md)
- [Exit codes](./exit-codes.md)
