<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom" xmlns:dc="http://purl.org/dc/elements/1.1/">
  <channel>
    <title>DEV Community: Muhammad Amir Ejaz</title>
    <description>The latest articles on DEV Community by Muhammad Amir Ejaz (@amirejaz).</description>
    <link>https://dev.to/amirejaz</link>
    <image>
      <url>https://media2.dev.to/dynamic/image/width=90,height=90,fit=cover,gravity=auto,format=auto/https:%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Fuser%2Fprofile_image%2F2880652%2F2507ad5a-2ebe-4f4e-9d2a-b264f75bfe04.png</url>
      <title>DEV Community: Muhammad Amir Ejaz</title>
      <link>https://dev.to/amirejaz</link>
    </image>
    <atom:link rel="self" type="application/rss+xml" href="https://dev.to/feed/amirejaz"/>
    <language>en</language>
    <item>
      <title>Seamless Remote MCP Server Support with ToolHive</title>
      <dc:creator>Muhammad Amir Ejaz</dc:creator>
      <pubDate>Mon, 06 Oct 2025 16:13:39 +0000</pubDate>
      <link>https://dev.to/stacklok/seamless-remote-mcp-server-support-with-toolhive-4jk7</link>
      <guid>https://dev.to/stacklok/seamless-remote-mcp-server-support-with-toolhive-4jk7</guid>
      <description>&lt;p&gt;The Model Context Protocol (MCP) is transforming how AI assistants connect to tools and data. Local MCP servers have powered individual workflows, but developers have long wanted the ability to scale those workflows across teams and environments. Until now, running MCP remotely has been complex and limited.&lt;br&gt;
With ToolHive’s new remote server support, that changes. Everything you rely on in local MCP workflows—simplicity, reliability, and integration—is now available for remote servers too. Teams can connect, manage, and scale MCP across the cloud with the same streamlined experience they already know from local development.&lt;/p&gt;
&lt;h2&gt;
  
  
  Introducing ToolHive’s Remote MCP Server Support
&lt;/h2&gt;

&lt;p&gt;&lt;em&gt;Everything you love about local MCP workflows, now extended to remote servers.&lt;/em&gt;  &lt;/p&gt;

&lt;p&gt;ToolHive brings &lt;strong&gt;native, end-to-end support for remote MCP servers&lt;/strong&gt;, eliminating the gap between local and remote workflows. Teams can now connect, manage, and scale remote servers with the same simplicity and reliability they’ve come to expect from local development.  &lt;/p&gt;
&lt;h2&gt;
  
  
  What Remote Server Support Provides
&lt;/h2&gt;

&lt;p&gt;ToolHive’s remote server support brings a complete set of capabilities for managing remote MCP servers, organized around three key pillars:  &lt;/p&gt;
&lt;h3&gt;
  
  
  Workflow Integration
&lt;/h3&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;Native integration&lt;/strong&gt;: Remote servers work seamlessly with ToolHive’s core workflow management.
&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Unified commands&lt;/strong&gt;: Use &lt;code&gt;thv run&lt;/code&gt; for both local and remote servers.
&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Lifecycle management&lt;/strong&gt;: Remote servers appear in &lt;code&gt;thv list&lt;/code&gt; and can be controlled with &lt;code&gt;thv stop&lt;/code&gt;, &lt;code&gt;thv restart&lt;/code&gt;, and &lt;code&gt;thv rm&lt;/code&gt;.
&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Studio support&lt;/strong&gt;: Manage remote servers alongside local workloads in ToolHive Studio.
&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Group organization&lt;/strong&gt;: Organize servers into groups for easier project management.
&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Persistent state&lt;/strong&gt;: Configurations are stored in ToolHive’s unified state management system.
&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Registry integration&lt;/strong&gt;: Store and run remote server configurations from the ToolHive registry.
&lt;/li&gt;
&lt;/ul&gt;
&lt;h3&gt;
  
  
  Authentication &amp;amp; Security
&lt;/h3&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;Advanced authentication&lt;/strong&gt;: Full OAuth and OIDC support with dynamic client registration (RFC 7591).
&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Automatic token management&lt;/strong&gt;: Tokens are refreshed and managed securely without manual intervention.
&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Secure credential handling&lt;/strong&gt;: Supports file-based secret storage and environment variables for sensitive data.
&lt;/li&gt;
&lt;/ul&gt;
&lt;h3&gt;
  
  
  Convenience &amp;amp; Automation
&lt;/h3&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;Automatic naming&lt;/strong&gt;: Server names are derived from URLs (e.g., &lt;code&gt;https://api.example.com/mcp&lt;/code&gt; → &lt;code&gt;example&lt;/code&gt;).
&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Integrated experience&lt;/strong&gt;: Remote servers behave just like local ones—no extra setup required.
&lt;/li&gt;
&lt;/ul&gt;
&lt;h2&gt;
  
  
  Authentication Features
&lt;/h2&gt;

&lt;p&gt;Authentication is central to working with remote MCP servers, and ToolHive provides full support out of the box. It handles OAuth 2.0, OIDC, and Dynamic Client Registration automatically, so you can connect securely without wrestling with manual setup.  &lt;/p&gt;
&lt;h3&gt;
  
  
  Supported Authentication Methods
&lt;/h3&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;OIDC Authentication&lt;/strong&gt;
For identity-provider–based authentication (e.g., Azure AD), ToolHive supports OIDC with automatic token management.
&lt;/li&gt;
&lt;/ul&gt;
&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;  thv run https://azure-mcp.example.com/mcp &lt;span class="se"&gt;\&lt;/span&gt;
    &lt;span class="nt"&gt;--name&lt;/span&gt; azure-mcp-server &lt;span class="se"&gt;\&lt;/span&gt;
    &lt;span class="nt"&gt;--remote-auth-issuer&lt;/span&gt; https://login.microsoftonline.com/your-tenant-id/v2.0 &lt;span class="se"&gt;\&lt;/span&gt;
    &lt;span class="nt"&gt;--remote-auth-client-id&lt;/span&gt; your-client-id &lt;span class="se"&gt;\&lt;/span&gt;
    &lt;span class="nt"&gt;--remote-auth-client-secret&lt;/span&gt; your-client-secret&lt;span class="se"&gt;\&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;


&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;OAuth 2.0 Authentication&lt;/strong&gt;
For services that expose custom authorization and token endpoints, ToolHive lets you configure them directly:
&lt;/li&gt;
&lt;/ul&gt;
&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;  thv run https://oauth-mcp.example.com/mcp &lt;span class="se"&gt;\&lt;/span&gt;
    &lt;span class="nt"&gt;--name&lt;/span&gt; oauth-mcp-server &lt;span class="se"&gt;\&lt;/span&gt;
    &lt;span class="nt"&gt;--remote-auth-authorize-url&lt;/span&gt; https://oauth.example.com/oauth/authorize &lt;span class="se"&gt;\&lt;/span&gt;
    &lt;span class="nt"&gt;--remote-auth-token-url&lt;/span&gt; https://oauth.example.com/oauth/token &lt;span class="se"&gt;\&lt;/span&gt;
    &lt;span class="nt"&gt;--remote-auth-client-id&lt;/span&gt; your-client-id &lt;span class="se"&gt;\&lt;/span&gt;
    &lt;span class="nt"&gt;--remote-auth-client-secret&lt;/span&gt; your-client-secret
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;


&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;Dynamic Client Registration (RFC 7591)&lt;/strong&gt;
When no client credentials are provided, ToolHive can automatically register an OAuth client with the authorization server:
&lt;/li&gt;
&lt;/ul&gt;
&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;  thv run https://dynamic-mcp.example.com/mcp &lt;span class="se"&gt;\&lt;/span&gt;
    &lt;span class="nt"&gt;--name&lt;/span&gt; dynamic-mcp-server
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;


&lt;p&gt;ToolHive will:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Discover OAuth/OIDC endpoints.&lt;/li&gt;
&lt;li&gt;Register a new OAuth client.&lt;/li&gt;
&lt;li&gt;Obtain and manage client credentials.&lt;/li&gt;
&lt;li&gt;Handle token lifecycle automatically.&lt;/li&gt;
&lt;/ul&gt;
&lt;h3&gt;
  
  
  Advanced Options
&lt;/h3&gt;

&lt;p&gt;For more complex scenarios, ToolHive also supports:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;Custom scopes and timeouts&lt;/strong&gt;
&lt;/li&gt;
&lt;/ul&gt;
&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;  thv run https://api.example.com/mcp &lt;span class="se"&gt;\&lt;/span&gt;
    &lt;span class="nt"&gt;--name&lt;/span&gt; custom-mcp-server &lt;span class="se"&gt;\&lt;/span&gt;
    &lt;span class="nt"&gt;--remote-auth-issuer&lt;/span&gt; https://auth.example.com &lt;span class="se"&gt;\&lt;/span&gt;
    &lt;span class="nt"&gt;--remote-auth-client-id&lt;/span&gt; your-client-id &lt;span class="se"&gt;\&lt;/span&gt;
    &lt;span class="nt"&gt;--remote-auth-scopes&lt;/span&gt; openid,profile,email,api:read &lt;span class="se"&gt;\&lt;/span&gt;
    &lt;span class="nt"&gt;--remote-auth-timeout&lt;/span&gt; 2m
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;


&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;Secure credential handling&lt;/strong&gt; (e.g., file-based secrets)
&lt;/li&gt;
&lt;/ul&gt;
&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;  thv run https://secure-mcp.example.com/mcp &lt;span class="se"&gt;\&lt;/span&gt;
    &lt;span class="nt"&gt;--name&lt;/span&gt; secure-mcp-server &lt;span class="se"&gt;\&lt;/span&gt;
    &lt;span class="nt"&gt;--remote-auth-issuer&lt;/span&gt; https://auth.example.com &lt;span class="se"&gt;\&lt;/span&gt;
    &lt;span class="nt"&gt;--remote-auth-client-id&lt;/span&gt; your-client-id &lt;span class="se"&gt;\&lt;/span&gt;
    &lt;span class="nt"&gt;--remote-auth-client-secret-file&lt;/span&gt; /path/to/client-secret.txt
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;h2&gt;
  
  
  Getting Started with Remote Servers
&lt;/h2&gt;

&lt;p&gt;ToolHive makes it simple to launch and manage remote MCP servers. Just pass a URL to the &lt;code&gt;thv run&lt;/code&gt; command—ToolHive automatically detects authentication requirements and applies dynamic client registration if needed.&lt;/p&gt;
&lt;h3&gt;
  
  
  Basic Usage
&lt;/h3&gt;


&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;&lt;span class="c"&gt;# Run a remote MCP server directly (automatic naming if not provided)&lt;/span&gt;
thv run https://remote-server.com/mcp &lt;span class="nt"&gt;--name&lt;/span&gt; my-remote-server

&lt;span class="c"&gt;# List all servers (local and remote)&lt;/span&gt;
thv list

&lt;span class="c"&gt;# Stop a remote server&lt;/span&gt;
thv stop my-remote-server

&lt;span class="c"&gt;# Restart a remote server&lt;/span&gt;
thv restart my-remote-server

&lt;span class="c"&gt;# Remove a remote server&lt;/span&gt;
thv &lt;span class="nb"&gt;rm &lt;/span&gt;my-remote-server
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;

&lt;h3&gt;
  
  
  Running from the Registry
&lt;/h3&gt;

&lt;p&gt;ToolHive’s registry also supports remote servers, so you can store and reuse configurations with consistent naming and authentication settings.&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;&lt;span class="c"&gt;# Run a remote server from the registry&lt;/span&gt;
thv run my-remote-server-from-registry

&lt;span class="c"&gt;# Run with OAuth/OIDC authentication from registry&lt;/span&gt;
thv run my-oauth-server &lt;span class="se"&gt;\&lt;/span&gt;
  &lt;span class="nt"&gt;--remote-auth-client-id&lt;/span&gt; your-client-id &lt;span class="se"&gt;\&lt;/span&gt;
  &lt;span class="nt"&gt;--remote-auth-client-secret&lt;/span&gt; your-client-secret
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;






&lt;h2&gt;
  
  
  Conclusion
&lt;/h2&gt;

&lt;p&gt;The addition of &lt;strong&gt;remote MCP server support&lt;/strong&gt; makes ToolHive a truly comprehensive platform for managing both local and distributed MCP workflows. By removing the complexity of configuration, authentication, and lifecycle management, ToolHive lets developers focus on what really matters: building and scaling great applications.&lt;/p&gt;

&lt;p&gt;Whether you’re a backend developer integrating external services, a DevOps engineer orchestrating distributed systems, or a security engineer ensuring robust authentication across your infrastructure, ToolHive brings &lt;strong&gt;simplicity, security, and reliability&lt;/strong&gt; to every step of the process.&lt;/p&gt;

&lt;p&gt;👉 Get started with &lt;a href="https://docs.stacklok.com/toolhive" rel="noopener noreferrer"&gt;ToolHive Docs&lt;/a&gt;, or explore the details on &lt;a href="https://github.com/stacklok/toolhive/issues/1172" rel="noopener noreferrer"&gt;GitHub&lt;/a&gt;.&lt;/p&gt;

</description>
      <category>ai</category>
      <category>mcp</category>
      <category>tooling</category>
      <category>toolhive</category>
    </item>
  </channel>
</rss>
