<?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>Forem: xabozhu</title>
    <description>The latest articles on Forem by xabozhu (@xabozhu).</description>
    <link>https://forem.com/xabozhu</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%2F2593450%2Faa78dfe2-070c-463f-b95f-1edcf7c216c1.jpeg</url>
      <title>Forem: xabozhu</title>
      <link>https://forem.com/xabozhu</link>
    </image>
    <atom:link rel="self" type="application/rss+xml" href="https://forem.com/feed/xabozhu"/>
    <language>en</language>
    <item>
      <title>A Step-by-Step Guide to Connecting sol-mcp with Your AI IDE</title>
      <dc:creator>xabozhu</dc:creator>
      <pubDate>Fri, 24 Oct 2025 07:21:32 +0000</pubDate>
      <link>https://forem.com/xabozhu/a-step-by-step-guide-to-connecting-sol-mcp-with-your-ai-ide-117l</link>
      <guid>https://forem.com/xabozhu/a-step-by-step-guide-to-connecting-sol-mcp-with-your-ai-ide-117l</guid>
      <description>&lt;p&gt;If you're a developer, analyst, or enthusiast working with the Solana blockchain, you know how complex transaction data can be. Manually parsing instructions and decoding on-chain data is time-consuming and difficult.&lt;/p&gt;

&lt;p&gt;This article will show you how to connect the &lt;strong&gt;sol-mcp (Model Context Protocol) server&lt;/strong&gt; directly to your AI assistant, such as &lt;strong&gt;Claude&lt;/strong&gt;, using its command-line tool. This server acts as a powerful "translator," giving your AI the ability to parse and analyze any Solana transaction in real-time.&lt;br&gt;
Best of all? No complex local installation is required.&lt;/p&gt;


&lt;h2&gt;
  
  
  Part 1: "Installation" (The 30-Second Setup)
&lt;/h2&gt;

&lt;p&gt;This is the best part: the &lt;code&gt;sol-mcp&lt;/code&gt; server is already hosted and available for you to use. You don't need to clone the repository, install dependencies, or run a local server.&lt;/p&gt;

&lt;p&gt;Your one and only setup step is to get the server endpoint URL.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;MCP Server Endpoint:&lt;/strong&gt;&lt;a href="https://solmcp.daog1.workers.dev/" rel="noopener noreferrer"&gt;&lt;code&gt;https://solmcp.daog1.workers.dev/&lt;/code&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;That's it. Keep this URL handy for the next step.&lt;/p&gt;


&lt;h2&gt;
  
  
  Part 2: Connecting sol-mcp to Your AI Model (like Claude)
&lt;/h2&gt;

&lt;p&gt;Connecting sol-mcp to Claude is a straightforward process that uses the Claude CLI (Command Line Interface). This method securely registers the server and your personal API key.&lt;/p&gt;
&lt;h3&gt;
  
  
  Step 1: Get Your Personal API Key
&lt;/h3&gt;

&lt;p&gt;Before you can add the server, you need to get your unique API key.&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;Go to the &lt;code&gt;sol-mcp&lt;/code&gt; server homepage: &lt;a href="https://solmcp.daog1.workers.dev/" rel="noopener noreferrer"&gt;&lt;strong&gt;&lt;code&gt;https://solmcp.daog1.workers.dev/&lt;/code&gt;&lt;/strong&gt;&lt;/a&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Log in with your GitHub account&lt;/strong&gt;.&lt;/li&gt;
&lt;li&gt;Once authenticated, the site will provide you with your &lt;strong&gt;personal API key&lt;/strong&gt; (it will look something like &lt;code&gt;sol-xxxxxxxx...&lt;/code&gt;).&lt;/li&gt;
&lt;li&gt;Copy this key and keep it handy for the next step.&lt;/li&gt;
&lt;/ol&gt;
&lt;h3&gt;
  
  
  Step 2: Add the MCP Server via Command Line
&lt;/h3&gt;

&lt;p&gt;Now, open your terminal and use the following command to add the sol-mcp server to your Claude configuration.&lt;br&gt;
Make sure to replace YOUR_PERSONAL_API_KEY with the actual key you just copied.&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;claude mcp add --transport http solana-mcp https://solmcp.daog1.workers.dev/mcp --header "x-api-key: YOUR_PERSONAL_API_KEY"
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Let's quickly break down that command:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;code&gt;claude mcp add&lt;/code&gt;: The standard command to add a new MCP server.&lt;/li&gt;
&lt;li&gt;
&lt;code&gt;solana-mcp&lt;/code&gt;: This is the local name you're giving the server (you can change this, but &lt;code&gt;solana-mcp&lt;/code&gt; is a good, clear name).&lt;/li&gt;
&lt;li&gt;
&lt;code&gt;https://.../mcp&lt;/code&gt;: This is the specific API endpoint for the server.&lt;/li&gt;
&lt;li&gt;
&lt;code&gt;--header "x-api-key: ..."&lt;/code&gt;: This is how you securely send your personal API key to authenticate your requests.&lt;/li&gt;
&lt;/ul&gt;

&lt;h3&gt;
  
  
  Step 3: Start Analyzing!
&lt;/h3&gt;

&lt;p&gt;That's it! Claude now has the sol-mcp server registered as a tool. You can immediately start asking it to analyze transactions, just as shown in Part 3.&lt;/p&gt;




&lt;h2&gt;
  
  
  Part 3: How to Use It (The Fun Part)
&lt;/h2&gt;

&lt;p&gt;Now that your AI is connected, you can use natural language to perform a deep-dive analysis of Solana transactions. The &lt;code&gt;sol-mcp&lt;/code&gt; server has equipped your AI with several new functions, including:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;code&gt;get_solana_transaction&lt;/code&gt;: Fetches and analyzes a full transaction, including all instructions and balance changes.&lt;/li&gt;
&lt;li&gt;
&lt;code&gt;analyze_solana_instruction&lt;/code&gt;: Dives into one specific instruction within a transaction.&lt;/li&gt;
&lt;li&gt;
&lt;code&gt;analyze_instruction_data&lt;/code&gt;: Decodes raw instruction data (hex or base64) using over 1,000 known program IDLs.&lt;/li&gt;
&lt;li&gt;
&lt;code&gt;get_account_data_with_parsing&lt;/code&gt;: Retrieves and parses account data based on its owner.&lt;/li&gt;
&lt;/ul&gt;




&lt;h2&gt;
  
  
  Example Queries:
&lt;/h2&gt;

&lt;p&gt;You can now ask your AI assistant (e.g., in the Claude chat) directly.&lt;/p&gt;

&lt;h3&gt;
  
  
  Analyze a Full Transaction:
&lt;/h3&gt;

&lt;blockquote&gt;
&lt;p&gt;&lt;em&gt;You&lt;/em&gt;: “do a comprehensive analysis on this TX  &lt;code&gt;4Aio58jGweCVUHxUAjGq5bzTCTkFJVSC7iP1yFoFA6Qh7GbbJsCV8Ef6RuYFaTwA5azhjR7eY22DXYVWV7Sv29BL&lt;/code&gt;with subcalls"&lt;/p&gt;
&lt;/blockquote&gt;

&lt;p&gt;Your AI will now call the multiple functions such as get_solana_transaction   get_program_subcalls  analyze_solana_instruction, process the JSON output, and give you a human-readable summary of the entire transaction, including what programs were called, what functions were executed, and what the parameters were:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;🔍 Comprehensive Transaction Analysis

  Basic Information

  - Signature: 4Aio58jGweCVUHxUAjGq5bzTCTkFJVSC7iP1yFoFA6Qh7GbbJsCV8Ef6RuYFaTwA5azhjR7eY22DXYVWV7Sv29BL
  - Status: ✅ Successfully executed
  - Block: 372374425 (2025-10-10T04:50:17.000Z)
  - Fee: 0.000005 SOL (5,000 lamports)
  - Total Compute Units: 160,715

  ---
  🔄 Transaction Flow Analysis

  Phase 1: Setup &amp;amp; Configuration

  1. Compute Budget Configuration - Set compute limit to 160,715 units
  2. Associated Token Account Creation - Created ATA for intermediate token handling
  3. Custom Program Initialization - Interaction with unknown program 2badCgdN...

  Phase 2: Multi-Hop Arbitrage Execution

  The transaction executed a sophisticated round-trip arbitrage through Jupiter's DEX aggregator:

  Leg 1: SOL → Intermediate Token (Raydium)
  - Input: 21,172,611 lamports (0.021172611 SOL)
  - Output: 32,446,774,528,742 units of intermediate token (7hWc...18Fy3)
  - Program: Raydium AMM (675kPX9MHTjS2zt1qfr1NYHuzeLXfQM9H24wFSUt1Mp8)

  Leg 2: Intermediate Token → SOL (Orca Whirlpool)
  - Input: 32,446,774,528,742 intermediate tokens
  - Output: 21,197,804 lamports (0.021197804 SOL)
  - Program: Orca Whirlpool (whirLbMiicVdio4qvUfM5KAg6Ct8VwpYzGff3uctyCc)

  Phase 3: Cleanup &amp;amp; Settlement

  1. Account Closure - Temporary token account closed
  2. Profit Distribution - Net profit transferred to beneficiary

  ---
  📊 Financial Analysis

  Balance Changes:
  - FkdDHrM8j8psKbxuwjV1jBKCM2JGPygkj7WCX8sSCzNm: -0.000010654 SOL (initiator)
  - H6YtZBn9wjEoZM96ZVPgNQVwzqBCn3QteviZXSzKkWb: +0.000025193 SOL (beneficiary)
  - 96gYZGLnJYVFmbjzopPSU6QiEV5fGqZNyN9nmNhvrZU5: +0.000005654 SOL (fee recipient)
  - Ftf9Xc2jTJ2CaX9YojviUeGPPdq1pkoqSgwdwD3h6hnt: +0.021172611 SOL (funding source)

  Arbitrage Result:
  - Investment: 0.021172611 SOL
  - Return: 0.021197804 SOL
  - Net Profit: 0.000025193 SOL (~0.12% gain)
  - Platform Fee: 0.000005654 SOL

● Inner Instructions &amp;amp; Subcalls Analysis

  Jupiter V6 Subcalls:
  - Raydium Swap: Executed through 675kPX9MHTjS2zt1qfr1NYHuzeLXfQM9H24wFSUt1Mp8
  - Orca Whirlpool Swap: Executed through whirLbMiicVdio4qvUfM5KAg6Ct8VwpYzGff3uctyCc
  - Token Program Calls: Multiple SPL token transfers and account operations

  Custom Program Activity:
  - Unknown Program: 2badCgdNVD1fa7saBy8qgtztARRgGG9Vhky1Bk4vwtSZ handled routing logic
  - Profit Logging: Program logged "Profit: 25193" (25,193 lamports)

  ---
  🔒 Security &amp;amp; Risk Analysis

  Positive Indicators:

  ✅ Proper Account Management - Temporary accounts correctly created and closed✅ Standard AMM Usage - Utilized
  established Raydium and Orca pools✅ Transparent Execution - All operations logged and traceable✅ Minimal
  Slippage - 0 slippage tolerance indicates precise execution

  Risk Considerations:

  ⚠️ Unknown Program Interaction - Custom program 2badCgdN... lacks public documentation⚠️ High-Frequency Trading
  Pattern - Suggests bot/algorithmic trading activity⚠️ Profit Concentration - Single beneficiary receives all
  profits

  Transaction Efficiency:

  - Compute Utilization: 160,715 units (moderate complexity)
  - Execution Speed: Single transaction execution
  - Cost Efficiency: Low fees relative to profit margin

● 🎯 Conclusion

  This transaction represents a sophisticated arbitrage strategy executed through Jupiter's DEX aggregation
  protocol. The key findings are:

  1. Multi-Hop Arbitrage: Successfully exploited price discrepancies between Raydium and Orca AMMs
  2. Profit Generation: Net gain of 0.000025193 SOL (~0.12% return)
  3. Technical Sophistication: Utilized custom routing logic and proper account management
  4. Security Profile: Generally safe execution with standard AMM interactions

  The transaction demonstrates advanced DeFi trading strategies on Solana, leveraging Jupiter's aggregation
  capabilities to capture arbitrage opportunities across multiple liquidity pools in a single atomic transaction.
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;You've successfully integrated a powerful blockchain analysis engine directly into your development workflow, turning your AI assistant into a true Solana expert.&lt;/p&gt;

</description>
      <category>ai</category>
      <category>mcp</category>
      <category>solana</category>
      <category>onchain</category>
    </item>
  </channel>
</rss>
