Skip to content

Commit bec92b8

Browse files
authored
Update the docs with info for remote MCP servers (#444)
<!-- Provide a brief summary of your changes --> ## Motivation and Context <!-- Why is this change needed? What problem does it solve? --> The following PR updates the publishing docs with information about remote MCP servers. Motivated by #438 ## How Has This Been Tested? <!-- Have you tested this in a real application? Which scenarios were tested? --> ## Breaking Changes <!-- Will users need to update their code or configurations? --> No ## Types of changes <!-- What types of changes does your code introduce? Put an `x` in all the boxes that apply: --> - [ ] Bug fix (non-breaking change which fixes an issue) - [ ] New feature (non-breaking change which adds functionality) - [ ] Breaking change (fix or feature that would cause existing functionality to change) - [x] Documentation update ## Checklist <!-- Go over all the following points, and put an `x` in all the boxes that apply. --> - [ ] I have read the [MCP Documentation](https://modelcontextprotocol.io) - [ ] My code follows the repository's style guidelines - [ ] New and existing tests pass locally - [ ] I have added appropriate error handling - [ ] I have added or updated documentation as needed ## Additional context <!-- Add any other context, implementation notes, or design decisions --> --------- Signed-off-by: Radoslav Dimitrov <[email protected]>
1 parent ba86c6b commit bec92b8

File tree

1 file changed

+96
-3
lines changed

1 file changed

+96
-3
lines changed

docs/guides/publishing/publish-server.md

Lines changed: 96 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,16 @@ By the end of this tutorial, you'll have:
1919
## Prerequisites
2020
2121
- An MCP server you've already built ([follow this guide if you don't have one already](https://modelcontextprotocol.io/quickstart/server))
22-
- Your server published to a package registry (npm, PyPI, Docker Hub, etc.)
22+
23+
## Deployment Options
24+
25+
You can make your MCP server available in multiple ways:
26+
27+
- **📦 Package deployment**: Published to registries (npm, PyPI, Docker Hub, etc.) and run locally by clients
28+
- **🌐 Remote deployment**: Hosted as a web service that clients connect to directly
29+
- **🔄 Hybrid deployment**: Offer both package and remote options for maximum flexibility
30+
31+
Learn more about [MCP server architecture](https://modelcontextprotocol.io/docs/concepts/servers) in the official docs.
2332
2433
## Step 1: Install the Publisher CLI
2534
@@ -108,9 +117,13 @@ The `name` field determines authentication requirements:
108117
- **`io.github.yourname/*`** - Requires GitHub authentication
109118
- **`com.yourcompany/*`** - Requires DNS or HTTP domain verification
110119

111-
### Add Package Validation
120+
### Configure Deployment Methods
112121

113-
Your package must include validation metadata to prove ownership.
122+
Configure your server to support packages, remotes, or both:
123+
124+
#### Package Deployment
125+
126+
Add package validation metadata to prove ownership of your packages.
114127

115128

116129
<details>
@@ -289,6 +302,85 @@ The official MCP registry currently only supports artifacts hosted on GitHub or
289302

290303
</details>
291304

305+
#### Remote Deployment
306+
307+
Add the `remotes` field to your `server.json` (can coexist with `packages`):
308+
309+
<details>
310+
<summary><strong>🌐 Remote Server Configuration</strong></summary>
311+
312+
### Requirements
313+
314+
- **Service endpoint**: Your MCP server must be accessible at the specified URL
315+
- **Transport protocol**: Choose from `sse` (Server-Sent Events) or `streamable-http`
316+
- **URL validation**: For domain namespaces only (see URL requirements below)
317+
318+
### Example server.json
319+
320+
```json
321+
{
322+
"$schema": "https://static.modelcontextprotocol.io/schemas/2025-07-09/server.schema.json",
323+
"name": "com.yourcompany/api-server",
324+
"description": "Cloud-hosted MCP server for API operations",
325+
"version": "2.0.0",
326+
"remotes": [
327+
{
328+
"type": "sse",
329+
"url": "https://mcp.yourcompany.com/sse"
330+
}
331+
]
332+
}
333+
```
334+
335+
### Multiple Transport Options
336+
337+
You can offer multiple connection methods:
338+
339+
```json
340+
{
341+
"remotes": [
342+
{
343+
"type": "sse",
344+
"url": "https://mcp.yourcompany.com/sse"
345+
},
346+
{
347+
"type": "streamable-http",
348+
"url": "https://mcp.yourcompany.com/http"
349+
}
350+
]
351+
}
352+
```
353+
354+
### URL Validation Requirements
355+
356+
- For `com.yourcompany/*` namespaces: URLs must be on `yourcompany.com` or its subdomains
357+
- For `io.github.username/*` namespaces: No URL restrictions (but you must authenticate via GitHub)
358+
359+
### Authentication Headers (Optional)
360+
361+
Configure headers that clients should send when connecting:
362+
363+
```json
364+
{
365+
"remotes": [
366+
{
367+
"type": "sse",
368+
"url": "https://mcp.yourcompany.com/sse",
369+
"headers": [
370+
{
371+
"name": "X-API-Key",
372+
"description": "API key for authentication",
373+
"is_required": true,
374+
"is_secret": true
375+
}
376+
]
377+
}
378+
]
379+
}
380+
```
381+
382+
</details>
383+
292384
## Step 4: Authenticate
293385

294386
Choose your authentication method based on your namespace:
@@ -357,6 +449,7 @@ See these real-world examples of published servers:
357449
- **Update your server**: Publish new versions with updated server.json files
358450
- **Set up CI/CD**: Automate publishing with [GitHub Actions](github-actions.md)
359451
- **Learn more**: Understand [server.json format](../../reference/server-json/generic-server-json.md) in depth
452+
- **More examples**: See [remote server configurations](../../reference/server-json/generic-server-json.md#remote-server-example) and [hybrid deployments](../../reference/server-json/generic-server-json.md#server-with-remote-and-package-options) in the schema documentation
360453

361454
## What You've Accomplished
362455

0 commit comments

Comments
 (0)