MCP Catalogs
Home

mcp-sdk-client-ssejs

by mybigday·0·Score 30

A React Native-compatible client transport for MCP using SSE.js to support llm.rn integration.

developer-toolsai-llmother
0
Forks
0
Open issues
8 mo ago
Last commit
2d ago
Indexed

Overview

This is a specialized client transport implementation for Model Context Protocol (MCP) designed specifically for React Native environments. It provides alternative transport implementations (SSEJSStreamableHTTPClientTransport and SSEJSClientTransport) based on sse.js, enabling MCP functionality in React Native apps when used with llama.rn. The package addresses specific challenges in React Native environments like missing CustomEvent implementations and module resolution issues.

Try asking AI

After installing, here are 6 things you can ask your AI assistant:

you:Building React Native applications that need to integrate with MCP servers
you:Implementing AI-powered features in mobile apps using llama.rn
you:Creating custom MCP client transports for specific environments
you:What is the difference between SSEJSStreamableHTTPClientTransport and SSEJSClientTransport?
you:Does this package support STDIO transport?
you:Can I use this with MCP servers other than llama.rn?

When to choose this

Choose this when building React Native applications that need to connect to MCP servers and you're using llama.rn for LLM integration.

When NOT to choose this

Don't choose this if you're not working in React Native or don't need SSE-based transport for your MCP client implementation.

Tools this server exposes

5 tools extracted from the README
  • listPrompts

    List available prompts

  • getPrompt

    Retrieve a specific prompt by name

  • listResources

    List available resources

  • readResource

    Read a resource by its URI

  • callTool

    Call a tool with specified name and arguments

Comparable tools

mcp-sdkmcp-server-ragmcp-sse

Installation

npm install @modelcontextprotocol/sdk
npm install mcp-sdk-client-ssejs

For React Native, you may need to configure your metro config:

module.exports = {
  presets: [/* ... */],
  plugins: [
    [
      'module-resolver',
      {
        alias: {
          '@modelcontextprotocol/sdk': '@modelcontextprotocol/sdk/dist/esm',
        },
      },
    ],
  ],
}

If CustomEvent is missing in React Native, add this polyfill:

import NativeCustomEvent from 'react-native/Libraries/Events/CustomEvent'

window.CustomEvent = class CustomEvent extends NativeCustomEvent {
  constructor(type, eventInitDict = {}) {
    super(type, eventInitDict)
  }
}

FAQ

What is the difference between SSEJSStreamableHTTPClientTransport and SSEJSClientTransport?
SSEJSStreamableHTTPClientTransport supports streaming HTTP responses, while SSEJSClientTransport uses standard Server-Sent Events without streaming capabilities. Both are designed for React Native environments.
Does this package support STDIO transport?
No, this package only provides HTTP and SSE transports. STDIO transport is not supported in this implementation.
Can I use this with MCP servers other than llama.rn?
Yes, this client transport is compatible with any MCP server that provides HTTP or SSE endpoints, not just llama.rn.

Compare mcp-sdk-client-ssejs with

GitHub →

Last updated · Auto-generated from public README + GitHub signals.