# MCP setup and tools

Source: https://docs.myhub.host/mcp

Connect your coding agent to deploy GitHub projects and manage apps. For local project files, use the [CLI](https://docs.myhub.host/quick-start).

## Connect

```text title="Server URL"
https://cloud.myhub.host/mcp
```

**Claude Code**

```sh
claude mcp add --transport http --scope user hub https://cloud.myhub.host/mcp
claude mcp login hub
```

**Codex**

```sh
codex mcp add hub --url https://cloud.myhub.host/mcp
codex mcp login hub --scopes hub:read,hub:write
```

**Cursor**

[Add Hub to Cursor](https://cursor.com/link/mcp/install?name=hub\&config=eyJ1cmwiOiJodHRwczovL2Nsb3VkLm15aHViLmhvc3QvbWNwIn0%3D) and confirm installation.

**Claude app**

In [connector settings](https://claude.ai/customize/connectors), choose **Add custom connector**, name it **Hub**, paste the server URL, and select **Connect**.

**Other clients**

Add a remote server named **Hub** with the URL above. Choose **Streamable HTTP** and browser OAuth.

Approve your organization and **Read and write** access in the browser. Your Hub account needs the member role or higher to deploy.

## Deploy a project

Ask your agent:

```md title="Agent prompt"
Deploy owner/repository on Hub. Verify the deployment and give me its URL.
```

Public repositories clone anonymously. Private repositories require a GitHub grant to read the code; approve access using the returned installation link if prompted. Open the returned URL once your agent confirms the release is running.

New GitHub sources deploy once, with watching off. The agent can call `hub_deploy` with:

```json title="hub_deploy arguments"
{ "name": "my-app", "git": "owner/repository" }
```

For automatic deployments on push, ask your agent to enable watching:

```json title="hub_deploy with watching"
{ "name": "my-app", "git": "owner/repository", "watch": true }
```

`watch: true` requires a GitHub grant for webhooks, even for public repositories. Omit `watch` to preserve the setting for the same repository; a new or replacement repository defaults to off. Use `watch: false` to turn watching off explicitly. A `github_auth_required` result explains whether the grant is needed for webhooks or because the repository is private or does not exist. Open its installation link, approve access, then retry; hosted MCP does not wait for approval. See [Deploy from GitHub](https://docs.myhub.host/deploy/github) for the push workflow.

## Manage the connection

Review or revoke access in [MCP connections](https://cloud.myhub.host/mcp/connections). Reconnect to change the organization or permissions.

## Tools

The [MCP explorer](https://docs.myhub.host/mcp/explorer) lists all 20 tools with their arguments, examples, and response schemas. Use [the deployment Skill](https://docs.myhub.host/skills) for the agent's deployment and verification workflow.

`hub_app_runtime` inspects runtime or polls an operation with `hub:read`. Changing sleep policy uses `hub_app_runtime_set` and requires `hub:write`. See [runtime and sleep](https://docs.myhub.host/deploy/runtime#use-mcp) for examples.

`hub_validate` takes the text of a `hub.yaml` as `manifest`. See the [hub.yaml reference](https://docs.myhub.host/hub-yaml) for accepted fields and validation rules.