<?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: Contextum </title>
    <description>The latest articles on DEV Community by Contextum  (@contextumai).</description>
    <link>https://dev.to/contextumai</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%2F3174465%2Fc9152959-39b8-461e-b824-eec47e245e74.jpeg</url>
      <title>DEV Community: Contextum </title>
      <link>https://dev.to/contextumai</link>
    </image>
    <atom:link rel="self" type="application/rss+xml" href="https://dev.to/feed/contextumai"/>
    <language>en</language>
    <item>
      <title>Building a Remote MCP Server on Contextum (Without Auth)</title>
      <dc:creator>Contextum </dc:creator>
      <pubDate>Tue, 20 May 2025 06:18:40 +0000</pubDate>
      <link>https://dev.to/contextumai/building-a-remote-mcp-server-on-contextum-without-auth-4mdm</link>
      <guid>https://dev.to/contextumai/building-a-remote-mcp-server-on-contextum-without-auth-4mdm</guid>
      <description>&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fubqc4d5nv3b6yvcwl542.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fubqc4d5nv3b6yvcwl542.png" alt="app.contextum.org" width="800" height="533"&gt;&lt;/a&gt;As AI and Web3 ecosystems continue to evolve, developers face the challenge of building scalable, flexible, and secure infrastructure for their applications. One such solution is deploying &lt;strong&gt;Model Context Protocol (MCP)&lt;/strong&gt; servers that can manage context data for AI models or agents. &lt;strong&gt;Contextum&lt;/strong&gt; offers a simple, serverless way to deploy remote MCP servers without the hassle of authentication, so you can focus on building and testing your AI and Web3 applications quickly.&lt;/p&gt;

&lt;p&gt;This article will guide you through the process of setting up a &lt;strong&gt;remote MCP server&lt;/strong&gt; on &lt;strong&gt;Contextum&lt;/strong&gt;, why it’s a great tool for rapid development, and how to easily connect it to the &lt;strong&gt;Contextum Playground&lt;/strong&gt; or local clients.&lt;/p&gt;

&lt;h3&gt;
  
  
  Why You Should Build a Remote MCP Server on Contextum
&lt;/h3&gt;

&lt;p&gt;When building AI systems, managing context data and enabling easy interaction with various tools is crucial. However, setting up traditional servers or managing complex authentication mechanisms often adds unnecessary overhead. Here’s why using &lt;strong&gt;Contextum&lt;/strong&gt; for deploying a remote MCP server without authentication is a compelling choice:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;&lt;p&gt;&lt;strong&gt;Zero Authentication Overhead&lt;/strong&gt;: Authentication systems can significantly complicate development workflows, especially in early stages or prototypes. Contextum removes this complexity by allowing you to deploy an MCP server that doesn’t require managing user identities or tokens.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;&lt;strong&gt;Frictionless Integration&lt;/strong&gt;: With &lt;strong&gt;Contextum&lt;/strong&gt;, you can deploy your MCP server and connect it to the &lt;strong&gt;Contextum Playground&lt;/strong&gt; or local clients in minutes, giving you a quick feedback loop for testing and iterating on your AI models.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;&lt;strong&gt;Highly Extendable&lt;/strong&gt;: Contextum is designed to be flexible. You can easily add custom tools to the MCP server, integrate your own models, and extend the server's functionality as your project grows.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;&lt;strong&gt;Web3 Compatibility&lt;/strong&gt;: Contextum is ideal for decentralized AI projects. The serverless nature of the platform combined with decentralized tools makes it perfect for Web3 applications that need to manage AI context data in a distributed, scalable manner.&lt;/p&gt;&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Now, let’s dive into how to set up and deploy a &lt;strong&gt;remote MCP server&lt;/strong&gt; on &lt;strong&gt;Contextum&lt;/strong&gt;.&lt;/p&gt;

&lt;h3&gt;
  
  
  Step-by-Step Guide to Building Your Remote MCP Server on Contextum
&lt;/h3&gt;

&lt;h4&gt;
  
  
  Step 1: Initialize Your Project
&lt;/h4&gt;

&lt;p&gt;Start by creating a new &lt;strong&gt;Contextum&lt;/strong&gt; project that includes a template for a remote MCP server without authentication. This template comes pre-configured with basic tools that you can modify and extend based on your needs.&lt;/p&gt;

&lt;p&gt;Run the following command to create a new &lt;strong&gt;Contextum&lt;/strong&gt; project:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;npm create contextum@latest &lt;span class="nt"&gt;--&lt;/span&gt; my-mcp-server &lt;span class="nt"&gt;--template&lt;/span&gt;&lt;span class="o"&gt;=&lt;/span&gt;contextum/ai/demos/remote-mcp-authless
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;This command will scaffold a new project for you in the &lt;code&gt;my-mcp-server&lt;/code&gt; directory. Once the project is created, navigate into the project directory and install the dependencies:&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="nb"&gt;cd &lt;/span&gt;my-mcp-server
npm &lt;span class="nb"&gt;install&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;h4&gt;
  
  
  Step 2: Customize Your MCP Server
&lt;/h4&gt;

&lt;p&gt;In the &lt;code&gt;src/index.ts&lt;/code&gt; file, you can define and customize the tools that your server will provide. Here is an example of adding two tools: a simple &lt;code&gt;calculator&lt;/code&gt; and a &lt;code&gt;multiplier&lt;/code&gt;.&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight typescript"&gt;&lt;code&gt;&lt;span class="k"&gt;import&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt; &lt;span class="nx"&gt;MCPServer&lt;/span&gt; &lt;span class="p"&gt;}&lt;/span&gt; &lt;span class="k"&gt;from&lt;/span&gt; &lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;contextum-server&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;

&lt;span class="kd"&gt;class&lt;/span&gt; &lt;span class="nc"&gt;MyMCPServer&lt;/span&gt; &lt;span class="kd"&gt;extends&lt;/span&gt; &lt;span class="nc"&gt;MCPServer&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
  &lt;span class="nf"&gt;init&lt;/span&gt;&lt;span class="p"&gt;()&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
    &lt;span class="c1"&gt;// Tool to add two numbers&lt;/span&gt;
    &lt;span class="k"&gt;this&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nx"&gt;server&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;tool&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;calculator&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="nx"&gt;input&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt; &lt;span class="o"&gt;=&amp;gt;&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
      &lt;span class="k"&gt;return&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
        &lt;span class="na"&gt;result&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="nx"&gt;input&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nx"&gt;number1&lt;/span&gt; &lt;span class="o"&gt;+&lt;/span&gt; &lt;span class="nx"&gt;input&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nx"&gt;number2&lt;/span&gt;
      &lt;span class="p"&gt;};&lt;/span&gt;
    &lt;span class="p"&gt;});&lt;/span&gt;

    &lt;span class="c1"&gt;// Tool to multiply two numbers&lt;/span&gt;
    &lt;span class="k"&gt;this&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nx"&gt;server&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;tool&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;multiplier&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="nx"&gt;input&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt; &lt;span class="o"&gt;=&amp;gt;&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
      &lt;span class="k"&gt;return&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
        &lt;span class="na"&gt;result&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="nx"&gt;input&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nx"&gt;number1&lt;/span&gt; &lt;span class="o"&gt;*&lt;/span&gt; &lt;span class="nx"&gt;input&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nx"&gt;number2&lt;/span&gt;
      &lt;span class="p"&gt;};&lt;/span&gt;
    &lt;span class="p"&gt;});&lt;/span&gt;

    &lt;span class="c1"&gt;// Tool to divide two numbers&lt;/span&gt;
    &lt;span class="k"&gt;this&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nx"&gt;server&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;tool&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;divider&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="nx"&gt;input&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt; &lt;span class="o"&gt;=&amp;gt;&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
      &lt;span class="k"&gt;if &lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="nx"&gt;input&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nx"&gt;number2&lt;/span&gt; &lt;span class="o"&gt;===&lt;/span&gt; &lt;span class="mi"&gt;0&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
        &lt;span class="k"&gt;return&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt; &lt;span class="na"&gt;error&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;Cannot divide by zero!&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt; &lt;span class="p"&gt;};&lt;/span&gt;
      &lt;span class="p"&gt;}&lt;/span&gt;
      &lt;span class="k"&gt;return&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt; &lt;span class="na"&gt;result&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="nx"&gt;input&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nx"&gt;number1&lt;/span&gt; &lt;span class="o"&gt;/&lt;/span&gt; &lt;span class="nx"&gt;input&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nx"&gt;number2&lt;/span&gt; &lt;span class="p"&gt;};&lt;/span&gt;
    &lt;span class="p"&gt;});&lt;/span&gt;
  &lt;span class="p"&gt;}&lt;/span&gt;
&lt;span class="p"&gt;}&lt;/span&gt;

&lt;span class="k"&gt;export&lt;/span&gt; &lt;span class="k"&gt;default&lt;/span&gt; &lt;span class="k"&gt;new&lt;/span&gt; &lt;span class="nc"&gt;MyMCPServer&lt;/span&gt;&lt;span class="p"&gt;();&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;In this example, we define three tools:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;code&gt;calculator&lt;/code&gt;: Adds &lt;code&gt;number1&lt;/code&gt; and &lt;code&gt;number2&lt;/code&gt; from the input.&lt;/li&gt;
&lt;li&gt;
&lt;code&gt;multiplier&lt;/code&gt;: Multiplies &lt;code&gt;number1&lt;/code&gt; and &lt;code&gt;number2&lt;/code&gt;.&lt;/li&gt;
&lt;li&gt;
&lt;code&gt;divider&lt;/code&gt;: Divides &lt;code&gt;number1&lt;/code&gt; by &lt;code&gt;number2&lt;/code&gt;, with an error check for division by zero.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;These tools are defined using &lt;code&gt;this.server.tool(...)&lt;/code&gt; and can be accessed via the MCP server once it’s deployed.&lt;/p&gt;

&lt;h4&gt;
  
  
  Step 3: Deploy Your MCP Server to Contextum
&lt;/h4&gt;

&lt;p&gt;After configuring your server, deploy it to &lt;strong&gt;Contextum&lt;/strong&gt;. The deployment process is straightforward, and the &lt;strong&gt;Contextum CLI&lt;/strong&gt; handles all the infrastructure management for you.&lt;/p&gt;

&lt;p&gt;To deploy your server, simply run:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;npm run deploy
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;After deployment, your server will be available at a URL like:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;https://&amp;lt;your-project-name&amp;gt;.app.contextum.org/sse
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;This is the endpoint you’ll use to interact with your server, either from the &lt;strong&gt;Contextum Playground&lt;/strong&gt; or local clients.&lt;/p&gt;

&lt;h4&gt;
  
  
  Step 4: Connect Your MCP Server to the Contextum Playground
&lt;/h4&gt;

&lt;p&gt;The &lt;strong&gt;Contextum Playground&lt;/strong&gt; is an interactive, web-based environment for testing and experimenting with your MCP server. To connect to your deployed server, follow these steps:&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;Visit the &lt;strong&gt;Contextum AI Playground&lt;/strong&gt; at &lt;a href="https://playground.contextum.org/" rel="noopener noreferrer"&gt;https://playground.contextum.org/&lt;/a&gt;.&lt;/li&gt;
&lt;li&gt;Enter the URL of your deployed server: &lt;code&gt;https://&amp;lt;your-project-name&amp;gt;.app.contextum.org/sse&lt;/code&gt;.&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;Once connected, you can interact with the tools you’ve defined (like &lt;code&gt;calculator&lt;/code&gt;, &lt;code&gt;multiplier&lt;/code&gt;, and &lt;code&gt;divider&lt;/code&gt;) directly in the Playground. This makes it easy to test the server's behavior in real time.&lt;/p&gt;

&lt;h4&gt;
  
  
  Step 5: Connect Your MCP Server to Local Clients
&lt;/h4&gt;

&lt;p&gt;You can also connect your remote MCP server to local clients using the &lt;strong&gt;mcp-remote&lt;/strong&gt; proxy. This allows you to send requests to your remote server from tools like &lt;strong&gt;Claude Desktop&lt;/strong&gt;.&lt;/p&gt;

&lt;p&gt;To connect &lt;strong&gt;Claude Desktop&lt;/strong&gt; to your MCP server, follow these steps:&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;Open &lt;strong&gt;Claude Desktop&lt;/strong&gt;.&lt;/li&gt;
&lt;li&gt;Go to &lt;strong&gt;Settings&lt;/strong&gt; &amp;gt; &lt;strong&gt;Developer&lt;/strong&gt; &amp;gt; &lt;strong&gt;Edit Config&lt;/strong&gt;.&lt;/li&gt;
&lt;li&gt;Add the following configuration for your MCP server:
&lt;/li&gt;
&lt;/ol&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight json"&gt;&lt;code&gt;&lt;span class="p"&gt;{&lt;/span&gt;&lt;span class="w"&gt;
  &lt;/span&gt;&lt;span class="nl"&gt;"mcpServers"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="p"&gt;{&lt;/span&gt;&lt;span class="w"&gt;
    &lt;/span&gt;&lt;span class="nl"&gt;"calculator"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="p"&gt;{&lt;/span&gt;&lt;span class="w"&gt;
      &lt;/span&gt;&lt;span class="nl"&gt;"command"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="s2"&gt;"npx"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;&lt;span class="w"&gt;
      &lt;/span&gt;&lt;span class="nl"&gt;"args"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="p"&gt;[&lt;/span&gt;&lt;span class="w"&gt;
        &lt;/span&gt;&lt;span class="s2"&gt;"mcp-remote"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;&lt;span class="w"&gt;
        &lt;/span&gt;&lt;span class="s2"&gt;"https://&amp;lt;your-project-name&amp;gt;.app.contextum.org/sse"&lt;/span&gt;&lt;span class="w"&gt;
      &lt;/span&gt;&lt;span class="p"&gt;]&lt;/span&gt;&lt;span class="w"&gt;
    &lt;/span&gt;&lt;span class="p"&gt;}&lt;/span&gt;&lt;span class="w"&gt;
  &lt;/span&gt;&lt;span class="p"&gt;}&lt;/span&gt;&lt;span class="w"&gt;
&lt;/span&gt;&lt;span class="p"&gt;}&lt;/span&gt;&lt;span class="w"&gt;
&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;This configuration tells &lt;strong&gt;Claude Desktop&lt;/strong&gt; to route its MCP requests through your remote server. Once you restart the application, you should see your defined tools available for use.&lt;/p&gt;

&lt;h3&gt;
  
  
  Advantages of Using Contextum for Remote MCP Servers
&lt;/h3&gt;

&lt;ul&gt;
&lt;li&gt;&lt;p&gt;&lt;strong&gt;No Authentication Hassles&lt;/strong&gt;: Traditional authentication systems can be time-consuming to set up and manage. By using &lt;strong&gt;Contextum&lt;/strong&gt;’s authentication-free server, you can bypass all the extra work and focus on building your application.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;&lt;strong&gt;Rapid Deployment&lt;/strong&gt;: With &lt;strong&gt;Contextum&lt;/strong&gt;, deploying your server is as simple as running a single command. You don’t have to manage infrastructure, allowing you to focus on the tools and functionality you want to offer.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;&lt;strong&gt;Seamless Integration&lt;/strong&gt;: Whether you’re using the &lt;strong&gt;Contextum Playground&lt;/strong&gt; for interactive testing or connecting to local tools like &lt;strong&gt;Claude Desktop&lt;/strong&gt;, &lt;strong&gt;Contextum&lt;/strong&gt; makes integration smooth and effortless.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;&lt;strong&gt;Extendable and Scalable&lt;/strong&gt;: Add any custom tools you need to extend the functionality of your MCP server. Whether it’s building new AI models or integrating third-party tools, &lt;strong&gt;Contextum&lt;/strong&gt; supports all your needs as your project grows.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;&lt;strong&gt;Ideal for Web3&lt;/strong&gt;: The serverless, decentralized nature of &lt;strong&gt;Contextum&lt;/strong&gt; makes it a perfect fit for Web3 applications where decentralized context management is a key component.&lt;/p&gt;&lt;/li&gt;
&lt;/ul&gt;




&lt;p&gt;&lt;strong&gt;Official Links for Contextum&lt;/strong&gt;:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;&lt;a href="https://contextum.org" rel="noopener noreferrer"&gt;Website&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;a href="https://app.contextum.org" rel="noopener noreferrer"&gt;App&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;a href="https://x.com/contextumai" rel="noopener noreferrer"&gt;X (formerly Twitter)&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;a href="https://github.com/contextumai" rel="noopener noreferrer"&gt;GitHub&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;a href="https://t.me/contextum" rel="noopener noreferrer"&gt;Telegram&lt;/a&gt;&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;This setup empowers developers to build and deploy remote MCP servers quickly, test them interactively, and integrate them with various AI tools without having to deal with complex authentication systems or infrastructure management.&lt;/p&gt;




&lt;p&gt;This version should be ready for &lt;strong&gt;dev.to&lt;/strong&gt; with added &lt;strong&gt;Contextum&lt;/strong&gt; links for further engagement!&lt;/p&gt;

</description>
    </item>
    <item>
      <title>Streamlining Decentralized Infrastructure with the Contextum CLI</title>
      <dc:creator>Contextum </dc:creator>
      <pubDate>Sun, 18 May 2025 21:49:52 +0000</pubDate>
      <link>https://dev.to/contextumai/streamlining-decentralized-infrastructure-with-the-contextum-cli-33o8</link>
      <guid>https://dev.to/contextumai/streamlining-decentralized-infrastructure-with-the-contextum-cli-33o8</guid>
      <description>&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fa4ef4ku6jwisdhn17z2a.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fa4ef4ku6jwisdhn17z2a.png" alt="Contextum ctxctl" width="800" height="533"&gt;&lt;/a&gt;&lt;br&gt;
Contextum's Modular Compute Protocol (MCP) introduces a new paradigm for decentralized, modular compute infrastructure. While its core architecture is powerful on its own, the &lt;strong&gt;Contextum CLI&lt;/strong&gt; is the tool that brings it all together for developers and operators. In this article, we explore the technical details of how this CLI empowers professionals to deploy, manage, and monitor MCP deployments efficiently.&lt;/p&gt;
&lt;h2&gt;
  
  
  What is Contextum CLI?
&lt;/h2&gt;

&lt;p&gt;The Contextum CLI (&lt;code&gt;ctxctl&lt;/code&gt;) is a command-line tool designed to interact with the MCP stack. It provides fine-grained control over deployment lifecycle operations including cluster initialization, node provisioning, configuration updates, monitoring, and teardown.&lt;/p&gt;
&lt;h3&gt;
  
  
  1. Deployment Management
&lt;/h3&gt;

&lt;p&gt;The CLI abstracts low-level orchestration complexity. Under the hood, it wraps tools like Terraform and Ansible (or native equivalents) to provision infrastructure and bootstrap MCP nodes across global regions.&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;ctxctl init &lt;span class="nt"&gt;--name&lt;/span&gt; dev-cluster &lt;span class="nt"&gt;--region&lt;/span&gt; us-east &lt;span class="nt"&gt;--nodes&lt;/span&gt; 3
ctxctl deploy &lt;span class="nt"&gt;--config&lt;/span&gt; config.yaml
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;

&lt;p&gt;&lt;br&gt;
`&lt;/p&gt;

&lt;p&gt;Supports:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Cloud and bare-metal provisioning&lt;/li&gt;
&lt;li&gt;Multi-region deployment strategies&lt;/li&gt;
&lt;li&gt;AI module pinning per node&lt;/li&gt;
&lt;/ul&gt;

&lt;h3&gt;
  
  
  2. Configuration as Code
&lt;/h3&gt;

&lt;p&gt;&lt;code&gt;ctxctl&lt;/code&gt; supports declarative configurations via YAML. This makes infrastructure reproducible and auditable.&lt;/p&gt;

&lt;p&gt;&lt;code&gt;&lt;/code&gt;`yaml&lt;/p&gt;

&lt;h1&gt;
  
  
  config.yaml
&lt;/h1&gt;

&lt;p&gt;nodes:&lt;br&gt;
  count: 5&lt;br&gt;
  type: edge&lt;br&gt;
region: eu-central&lt;br&gt;
ai_modules:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;name: langchain-agent
version: latest
`&lt;code&gt;&lt;/code&gt;
&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;This configuration is parsed by the CLI and translated into infrastructure provisioning steps.&lt;/p&gt;

&lt;h3&gt;
  
  
  3. Versioned Upgrades
&lt;/h3&gt;

&lt;p&gt;Keeping nodes and modules in sync is critical in modular compute environments. The CLI supports rolling updates, zero-downtime deployments, and module pinning.&lt;/p&gt;

&lt;p&gt;&lt;code&gt;&lt;/code&gt;&lt;code&gt;bash&lt;br&gt;
ctxctl update --deployment dev-cluster --version 2.1.4&lt;br&gt;
&lt;/code&gt;&lt;code&gt;&lt;/code&gt;&lt;/p&gt;

&lt;h3&gt;
  
  
  4. Observability and Debugging
&lt;/h3&gt;

&lt;p&gt;Integrated observability features:&lt;/p&gt;

&lt;p&gt;&lt;code&gt;&lt;/code&gt;&lt;code&gt;bash&lt;br&gt;
ctxctl status --deployment dev-cluster&lt;br&gt;
ctxctl logs --node node-1 --follow&lt;br&gt;
&lt;/code&gt;&lt;code&gt;&lt;/code&gt;&lt;/p&gt;

&lt;p&gt;Data is pulled from MCP internal APIs and logs via gRPC endpoints, allowing efficient real-time monitoring.&lt;/p&gt;

&lt;h3&gt;
  
  
  5. Secure Identity and Access
&lt;/h3&gt;

&lt;p&gt;Supports identity primitives like ed25519 and PQC keys. Credential management can be integrated with vault systems.&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;TLS mutual auth&lt;/li&gt;
&lt;li&gt;Role-based permissions&lt;/li&gt;
&lt;li&gt;Encrypted deployment configs&lt;/li&gt;
&lt;/ul&gt;

&lt;h2&gt;
  
  
  Internals
&lt;/h2&gt;

&lt;p&gt;The CLI is built in Rust for performance and safety. It uses:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;code&gt;clap&lt;/code&gt; for argument parsing&lt;/li&gt;
&lt;li&gt;
&lt;code&gt;serde&lt;/code&gt; for configuration parsing&lt;/li&gt;
&lt;li&gt;
&lt;code&gt;reqwest&lt;/code&gt; and &lt;code&gt;tonic&lt;/code&gt; for HTTP/gRPC communication&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;It interfaces with the MCP Control Plane over authenticated channels and caches metadata in local state directories (&lt;code&gt;~/.contextum/&lt;/code&gt;).&lt;/p&gt;

&lt;p&gt;For developers building on Contextum MCP, the CLI is more than just a tool — it's the operational backbone. By abstracting complexity while exposing fine-grained control, it enables rapid and reliable infrastructure deployment and management. If you're looking to scale decentralized compute or deploy AI at the edge, &lt;code&gt;ctxctl&lt;/code&gt; is a core part of the workflow.&lt;/p&gt;

&lt;blockquote&gt;
&lt;p&gt;Try it: &lt;code&gt;curl -s https://install.contextum.sh | bash&lt;/code&gt;&lt;/p&gt;
&lt;/blockquote&gt;




&lt;h2&gt;
  
  
  🔗 Contextum Links
&lt;/h2&gt;

&lt;ul&gt;
&lt;li&gt;🌐 Website: &lt;a href="https://contextum.org" rel="noopener noreferrer"&gt;https://contextum.org&lt;/a&gt;
&lt;/li&gt;
&lt;li&gt;🧠 GitHub: &lt;a href="https://github.com/ContextumAI" rel="noopener noreferrer"&gt;ContextumAI&lt;/a&gt;
&lt;/li&gt;
&lt;li&gt;🐦 Twitter/X: &lt;a href="https://x.com/contextumai" rel="noopener noreferrer"&gt;@contextumai&lt;/a&gt;
&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;em&gt;Follow for more deep dives into Contextum tooling and architecture.&lt;/em&gt;&lt;/p&gt;

</description>
      <category>devops</category>
      <category>cli</category>
      <category>infrastructureascode</category>
      <category>mcp</category>
    </item>
    <item>
      <title>ContextumAI: Secure, On-Chain MCP Server Deployment for Decentralized AI</title>
      <dc:creator>Contextum </dc:creator>
      <pubDate>Sat, 17 May 2025 20:34:22 +0000</pubDate>
      <link>https://dev.to/contextumai/contextumai-secure-on-chain-mcp-server-deployment-for-decentralized-ai-18ha</link>
      <guid>https://dev.to/contextumai/contextumai-secure-on-chain-mcp-server-deployment-for-decentralized-ai-18ha</guid>
      <description>&lt;p&gt;As AI systems move toward agentic architectures and autonomous collaboration, the demand for &lt;strong&gt;context-aware inference&lt;/strong&gt; in decentralized settings is growing. But today, deploying and governing Model Context Protocol (MCP) servers across EVM networks is still too fragile, insecure, and manual.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;ContextumAI&lt;/strong&gt; provides a decentralized, cryptographically verifiable platform to securely deploy and manage MCP servers with on-chain permissioning and tokenized governance.&lt;/p&gt;

&lt;p&gt;This post goes deep into the architecture, tooling, and smart contract mechanics of Contextum.&lt;/p&gt;




&lt;h2&gt;
  
  
  Problem Landscape: Why MCP Servers Need Better Infrastructure
&lt;/h2&gt;

&lt;p&gt;Model Context Protocol (MCP) servers are designed to serve real-time contextual data to AI agents—embeddings, metadata, model prompts, inference state—across trustless environments. However, current approaches have critical flaws:&lt;/p&gt;

&lt;h3&gt;
  
  
  1. Lack of Deployment Standardization
&lt;/h3&gt;

&lt;p&gt;MCP server deployments are typically hand-crafted or glued together with ad hoc scripts. These environments differ widely, introducing inconsistencies and misconfigurations.&lt;/p&gt;

&lt;h3&gt;
  
  
  2. No On-Chain Verifiability
&lt;/h3&gt;

&lt;p&gt;There’s no way for an agent to verify that a specific context server is running a particular container image or was deployed by a trusted identity.&lt;/p&gt;

&lt;h3&gt;
  
  
  3. No Governance or Access Control
&lt;/h3&gt;

&lt;p&gt;Permissions to deploy, upgrade, or terminate context servers are often centralized and untraceable.&lt;/p&gt;




&lt;h2&gt;
  
  
  Contextum’s Architecture: Layered Security Meets Developer Usability
&lt;/h2&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2F60ymkx6vfwq6nfwp0exx.jpg" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2F60ymkx6vfwq6nfwp0exx.jpg" alt="Contextum enables secure, decentralized MCP server deployment on EVM chains" width="800" height="533"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h3&gt;
  
  
  Core Design Goals:
&lt;/h3&gt;

&lt;ul&gt;
&lt;li&gt;Immutable + verifiable deployment&lt;/li&gt;
&lt;li&gt;On-chain governance for upgrades and access&lt;/li&gt;
&lt;li&gt;Portable CLI tooling&lt;/li&gt;
&lt;li&gt;Modular server runtimes&lt;/li&gt;
&lt;/ul&gt;




&lt;h2&gt;
  
  
  1. Containerized MCP Runtimes
&lt;/h2&gt;

&lt;p&gt;Our MCP server is a stateless containerized application written in &lt;strong&gt;TypeScript&lt;/strong&gt; and powered by &lt;strong&gt;Bun&lt;/strong&gt;, selected for fast startup, native TS support, and small binary footprint.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Example stack:&lt;/strong&gt;&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Runtime: Bun 1.x&lt;/li&gt;
&lt;li&gt;Container: Alpine Linux + Docker BuildKit&lt;/li&gt;
&lt;li&gt;Security: seccomp, no root, read-only FS, AppArmor&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;strong&gt;Sample Dockerfile:&lt;/strong&gt;&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight docker"&gt;&lt;code&gt;&lt;span class="k"&gt;FROM&lt;/span&gt;&lt;span class="s"&gt; oven/bun:alpine&lt;/span&gt;

&lt;span class="k"&gt;WORKDIR&lt;/span&gt;&lt;span class="s"&gt; /app&lt;/span&gt;
&lt;span class="k"&gt;COPY&lt;/span&gt;&lt;span class="s"&gt; . .&lt;/span&gt;

&lt;span class="k"&gt;RUN &lt;/span&gt;bun &lt;span class="nb"&gt;install&lt;/span&gt; &lt;span class="nt"&gt;--production&lt;/span&gt;

&lt;span class="k"&gt;CMD&lt;/span&gt;&lt;span class="s"&gt; ["bun", "start"]&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;

&lt;p&gt;&lt;br&gt;
`&lt;/p&gt;

&lt;p&gt;We restrict permissions aggressively—disabling shell access, limiting filesystem writes, and isolating secrets via environment variables passed only at runtime.&lt;/p&gt;




&lt;h2&gt;
  
  
  2. CLI Tooling (&lt;code&gt;contextum-cli&lt;/code&gt;)
&lt;/h2&gt;

&lt;p&gt;To reduce friction and error-proneness, we’ve built a CLI tool that abstracts complex steps into verifiable workflows:&lt;/p&gt;

&lt;p&gt;&lt;code&gt;&lt;/code&gt;&lt;code&gt;bash&lt;br&gt;
npx contextum-cli init&lt;br&gt;
npx contextum-cli build&lt;br&gt;
npx contextum-cli deploy --network sepolia --image-hash Qm123... --sign&lt;br&gt;
&lt;/code&gt;&lt;code&gt;&lt;/code&gt;&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;CLI Features:&lt;/strong&gt;&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Local container test &amp;amp; sign&lt;/li&gt;
&lt;li&gt;Push to decentralized registry (Phase 2)&lt;/li&gt;
&lt;li&gt;Deploy via smart contracts&lt;/li&gt;
&lt;li&gt;Track deployments by wallet address&lt;/li&gt;
&lt;li&gt;Typed config schema (&lt;code&gt;contextum.config.ts&lt;/code&gt;)&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Internally, we use &lt;code&gt;dockerode&lt;/code&gt; for container handling and &lt;code&gt;ethers.js&lt;/code&gt; for chain interaction.&lt;/p&gt;




&lt;h2&gt;
  
  
  3. Smart Contracts
&lt;/h2&gt;

&lt;p&gt;We’ve deployed minimal, auditable contracts to Ethereum testnet (currently Sepolia).&lt;/p&gt;

&lt;h3&gt;
  
  
  &lt;code&gt;ImageRegistry.sol&lt;/code&gt;
&lt;/h3&gt;

&lt;p&gt;Stores SHA-256 hashes of verified container images:&lt;/p&gt;

&lt;p&gt;&lt;code&gt;&lt;/code&gt;&lt;code&gt;solidity&lt;br&gt;
function registerImage(bytes32 hash) external onlyStaker {&lt;br&gt;
    require(!registered[hash], "Already registered");&lt;br&gt;
    registered[hash] = true;&lt;br&gt;
    emit ImageRegistered(hash, msg.sender);&lt;br&gt;
}&lt;br&gt;
&lt;/code&gt;&lt;code&gt;&lt;/code&gt;&lt;/p&gt;

&lt;h3&gt;
  
  
  &lt;code&gt;MCPDeploymentManager.sol&lt;/code&gt;
&lt;/h3&gt;

&lt;p&gt;Tracks deployment metadata:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Deployer address&lt;/li&gt;
&lt;li&gt;Image hash&lt;/li&gt;
&lt;li&gt;Deployment timestamp&lt;/li&gt;
&lt;li&gt;Linked governance settings&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Deployments are signed client-side and validated on-chain.&lt;/p&gt;




&lt;h2&gt;
  
  
  4. Governance Layer (CTXM Token)
&lt;/h2&gt;

&lt;p&gt;&lt;strong&gt;CTXM&lt;/strong&gt; is our native ERC-20 token that governs protocol-level permissions.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;CTXM Utility:&lt;/strong&gt;&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Stake to deploy servers (anti-spam)&lt;/li&gt;
&lt;li&gt;Vote on protocol upgrades&lt;/li&gt;
&lt;li&gt;Access premium server templates&lt;/li&gt;
&lt;li&gt;Fee discounts for enterprise deployments&lt;/li&gt;
&lt;/ul&gt;

&lt;h2&gt;
  
  
  Deployment Pipeline (Under the Hood)
&lt;/h2&gt;

&lt;p&gt;&lt;strong&gt;Sample flow:&lt;/strong&gt;&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;Developer signs container image (SHA-256)&lt;/li&gt;
&lt;li&gt;CLI uploads hash to &lt;code&gt;ImageRegistry&lt;/code&gt;
&lt;/li&gt;
&lt;li&gt;CLI deploys MCP server&lt;/li&gt;
&lt;li&gt;Metadata committed to &lt;code&gt;MCPDeploymentManager&lt;/code&gt;
&lt;/li&gt;
&lt;li&gt;Smart contract emits &lt;code&gt;DeploymentRegistered&lt;/code&gt;
&lt;/li&gt;
&lt;li&gt;Agents verify the deployment via chain&lt;/li&gt;
&lt;/ol&gt;




&lt;h2&gt;
  
  
  Roadmap
&lt;/h2&gt;

&lt;div class="table-wrapper-paragraph"&gt;&lt;table&gt;
&lt;thead&gt;
&lt;tr&gt;
&lt;th&gt;Phase&lt;/th&gt;
&lt;th&gt;Goal&lt;/th&gt;
&lt;/tr&gt;
&lt;/thead&gt;
&lt;tbody&gt;
&lt;tr&gt;
&lt;td&gt;✅ Phase 1&lt;/td&gt;
&lt;td&gt;MVP CLI, secure runtime, Sepolia testnet&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;⏳ Phase 2&lt;/td&gt;
&lt;td&gt;Decentralized image registry, encrypted secrets&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;🔜 Phase 3&lt;/td&gt;
&lt;td&gt;DAO governance launch, Snapshot voting, staking UI&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;⏭ Phase 4&lt;/td&gt;
&lt;td&gt;IPFS log persistence, zk proof-of-context, enterprise integrations&lt;/td&gt;
&lt;/tr&gt;
&lt;/tbody&gt;
&lt;/table&gt;&lt;/div&gt;




&lt;h2&gt;
  
  
  Dev Resources
&lt;/h2&gt;

&lt;ul&gt;
&lt;li&gt;Playground: &lt;a href="https://app.contextum.org" rel="noopener noreferrer"&gt;https://app.contextum.org&lt;/a&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;p&gt;GitHub: &lt;a href="https://github.com/ContextumAI" rel="noopener noreferrer"&gt;https://github.com/ContextumAI&lt;/a&gt;&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;&lt;code&gt;contextum-cli&lt;/code&gt;&lt;/li&gt;
&lt;li&gt;&lt;code&gt;mcp-runtime&lt;/code&gt;&lt;/li&gt;
&lt;li&gt;&lt;code&gt;smart-contracts&lt;/code&gt;&lt;/li&gt;
&lt;/ul&gt;


&lt;/li&gt;

&lt;/ul&gt;




&lt;h2&gt;
  
  
  Final Thoughts
&lt;/h2&gt;

&lt;p&gt;We believe the future of AI is decentralized—and &lt;strong&gt;context is the missing layer&lt;/strong&gt;. Contextum bridges Web3 infrastructure with verifiable AI serving for autonomous agents.&lt;/p&gt;

&lt;p&gt;If you’re interested in:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Running an MCP node&lt;/li&gt;
&lt;li&gt;Contributing to contracts&lt;/li&gt;
&lt;li&gt;Integrating decentralized governance&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;We’d love to hear from you.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Contact:&lt;/strong&gt; &lt;a href="//mailto:founders@contextum.org"&gt;founders@contextum.org&lt;/a&gt;&lt;br&gt;
&lt;strong&gt;Website:&lt;/strong&gt; &lt;a href="https://contextum.org" rel="noopener noreferrer"&gt;https://contextum.org&lt;/a&gt;&lt;/p&gt;

</description>
      <category>blockchain</category>
      <category>ai</category>
      <category>devops</category>
      <category>web3</category>
    </item>
  </channel>
</rss>
