https://github.com/jeswr/solid-mcp
  
  
    Access data in a Solid Pod using the Model Context Protocol 
    https://github.com/jeswr/solid-mcp
  
        Last synced: 4 months ago 
        JSON representation
    
Access data in a Solid Pod using the Model Context Protocol
- Host: GitHub
 - URL: https://github.com/jeswr/solid-mcp
 - Owner: jeswr
 - License: mit
 - Created: 2025-03-13T11:16:25.000Z (8 months ago)
 - Default Branch: main
 - Last Pushed: 2025-07-10T22:35:23.000Z (4 months ago)
 - Last Synced: 2025-07-11T04:31:54.173Z (4 months ago)
 - Language: TypeScript
 - Size: 1.77 MB
 - Stars: 0
 - Watchers: 1
 - Forks: 0
 - Open Issues: 1
 - 
            Metadata Files:
            
- Readme: README.md
 - License: LICENSE
 - Security: SECURITY.md
 
 
Awesome Lists containing this project
- awesome-mcp-servers - **solid-mcp** - Access data in a Solid Pod using the Model Context Protocol `typescript` `npm install jeswr/solid-mcp` (π Web Development)
 
README
          # solid-mcp
[](https://github.com/jeswr/solid-mcp/blob/master/LICENSE)
[](https://www.npmjs.com/package/@jeswr/solid-mcp)
[](https://github.com/jeswr/solid-mcp/tree/main/)
[](https://dependabot.com/)
[](https://github.com/semantic-release/semantic-release)
> β οΈ **WARNING**: This entire project was created by generative AI and has not been reviewed or tested by a human yet. Use with caution in production environments.
Anthropic Model Context Protocol (MCP) integration for the Solid protocol.
This library enables AI models like Claude to access and manipulate data stored in Solid pods through the Model Context Protocol. It allows AI systems to read, write, search, and manage resources in Solid pods while respecting user privacy and control over their data.
## Features
- π Seamless integration between Anthropic's MCP and Solid pods
- π Read and write resources in Solid pods
- π Search for resources and contents
- π Create and manage containers
- π Authentication support for secure pod access
- π§° Tool-based API for integration with AI models
- π Structured data handling
## Installation
```bash
npm install @jeswr/solid-mcp
```
## Usage
### Basic Setup
```typescript
import { createSolidMCPServer, SolidPodConfig } from '@jeswr/solid-mcp';
// Configure access to a Solid Pod
const config: SolidPodConfig = {
  podUrl: 'https://example.solidcommunity.net/',
  auth: {
    type: 'bearer',
    token: 'your-solid-access-token',
  }
};
// Create the MCP server
const server = createSolidMCPServer(config);
```
### Reading a Resource
```typescript
// Example MCP request to read a resource
const request = {
  action: 'read_resource',
  parameters: {
    uri: '/profile/card',
    include_content: true,
  },
};
// Handle the request
const response = await server.handleRequest(request);
console.log('Response:', response);
```
### Writing a Resource
```typescript
// Example MCP request to write a resource
const request = {
  action: 'write_resource',
  parameters: {
    uri: '/examples/hello.txt',
    content: 'Hello, Solid World!',
    content_type: 'text/plain',
  },
};
// Handle the request
const response = await server.handleRequest(request);
console.log('Response:', response);
```
### Listing Container Contents
```typescript
// Example MCP request to list a container
const request = {
  action: 'list_container',
  parameters: {
    uri: '/examples/',
  },
};
// Handle the request
const response = await server.handleRequest(request);
console.log('Response:', response);
```
### Searching for Resources
```typescript
// Example MCP request to search for resources
const request = {
  action: 'search',
  parameters: {
    container_uri: '/',
    search_term: 'profile',
    recursive: true,
  },
};
// Handle the request
const response = await server.handleRequest(request);
console.log('Response:', response);
```
## API Reference
### `createSolidMCPServer(config: SolidPodConfig): SolidMCPServer`
Creates a new MCP server for a Solid Pod.
### `SolidClient`
Client for interacting with a Solid Pod.
- `readResource(uri: string, includeContent?: boolean): Promise`
- `writeResource(uri: string, content: any, contentType: string): Promise`
- `deleteResource(uri: string): Promise`
- `createContainer(uri: string): Promise`
### `SolidMCPServer`
MCP server for Solid Pod integration.
- `handleRequest(request: any): Promise`
- `getService(): SolidMCPService`
## Integration with Anthropic Claude
This library makes it easy to integrate Solid pods with Anthropic's Claude AI through the Model Context Protocol. Claude can access and manipulate data in Solid pods while respecting user privacy and control.
### Example Claude Integration
```typescript
// In your Claude MCP client implementation
const solidMCPServer = createSolidMCPServer({
  podUrl: 'https://example.solidcommunity.net/',
  auth: { type: 'bearer', token: 'your-solid-access-token' }
});
// When Claude needs to access data
const claudeRequest = {
  action: 'read_resource',
  parameters: { uri: '/notes/important.txt' }
};
const response = await solidMCPServer.handleRequest(claudeRequest);
// Provide the response to Claude for context
```
## Running Examples
The library includes example code showing how to use the various features:
```bash
npm run example
```
## License
Β©2025βpresent
[Jesse Wright](https://github.com/jeswr),
[MIT License](https://github.com/jeswr/solid-mcp/blob/master/LICENSE).