Skip to main content

MCP Server Endpoints

myweave provides multiple endpoints for AI integration:

Available MCP Tools

When you connect to myweave’s MCP server, your AI can execute this tool:
These tools are defined in our OpenAPI specification and automatically exposed through the MCP server. Your AI can execute them directly when you ask questions or give commands.

Example Tool Usage

Ask your AI to execute tools:
The AI automatically maps your natural language requests to the appropriate MCP tool, constructs the correct API call, handles authentication, and returns the results.

Claude Desktop Setup

Step 1: Locate Configuration File

  • macOS: ~/Library/Application Support/Claude/claude_desktop_config.json
  • Windows: %APPDATA%\Claude\claude_desktop_config.json
  • Linux: ~/.config/Claude/claude_desktop_config.json

Step 2: Add myweave MCP Server

Edit the file and add:
When Claude executes a myweave API call, it will prompt you for a JWT (Bearer token) per our OpenAPI security. The AI agent handles attaching it.

Step 3: Restart Claude Desktop

Close and reopen Claude Desktop for changes to take effect.

Step 4: Test the Integration

Ask Claude:
Claude will query the MCP server and provide accurate, up-to-date answers from your documentation.

Example Prompts

Generate Integration Code:
Query API Details:
Execute MCP Tools (Requires API Key):
Claude’s Response:

Cursor IDE Setup

Step 1: Install MCP Extension

In Cursor, install the MCP extension for Model Context Protocol support.

Step 2: Configure MCP Server

Create or edit .cursor/mcp.json in your project:
When Cursor executes a myweave API call, it will prompt you for a JWT based on the OpenAPI security requirements. The AI handles authentication internally.

Step 3: Restart Cursor

Step 4: Use in Development

Now when coding, Cursor can:
  • Query myweave docs automatically
  • Generate integration code
  • Provide accurate API examples
  • Reference latest endpoint specifications

Example Usage in Cursor

While coding:
Ask in chat:

Custom MCP Client

Build Your Own MCP Client

Step 1: Install MCP SDK
Step 2: Create MCP Client
Your MCP client will automatically prompt for the required JWT (Authorization: Bearer) when executing API calls.
Step 3: Use in Your AI App
How Authentication Works:
  • MCP client reads that /chat requires Bearer auth (from OpenAPI spec)
  • Prompts user for a JWT (or uses cached credential)
  • Automatically includes Authorization: Bearer token in requests

Direct llms.txt Integration

For simpler integrations without full MCP protocol:

Load Documentation Index

Load Complete Documentation


Authentication

What You Need

myweave API requires authentication for all API requests:
  • API Key - Required header: X-API-Key
  • JWT Token - Optional header: Authorization: Bearer (for user-specific requests)
Get your API key: support@myweave.ai

How It Works

When your AI agent tries to execute a myweave API call through MCP:
  1. AI reads OpenAPI spec → Sees that X-API-Key header is required
  2. AI prompts you → “Please provide your myweave API key”
  3. You provide the key → AI stores it securely for the session
  4. AI executes API call → Includes X-API-Key: your_key header automatically
  5. Request goes to myweave → Your API authenticates and processes the request
The AI agent handles authentication internally based on the security requirements defined in our OpenAPI specification.
Your API key is handled by your AI tool (Claude, Cursor, etc.) and sent directly to myweave’s API. The MCP server just serves the documentation—authentication happens between the AI agent and myweave API.
For complete details on authentication methods, JWT tokens, login flows, and token refresh, see the Authentication Guide.

Verification

After configuring MCP, test that it’s working: Test 1: Documentation Query
Expected Response:
Test 2: Code Generation
Expected: AI generates accurate code using latest API structure and MCP tool. Test 3: MCP Tool Execution (Requires API Key)
Expected Flow:
Test 4: List Available Tools
Expected: AI lists the 4 MCP tools (chat, get-user-threads, threads, upload-knowledge)

Troubleshooting

Symptoms:
  • AI says it can’t access myweave documentation
  • No response when asking about myweave
Solutions:
  1. Check Configuration File Path
    • Ensure you edited the correct config file
    • Verify JSON syntax is valid (no trailing commas, proper quotes)
  2. Restart Your AI Application
    • Close and completely restart Claude Desktop or Cursor
    • Some changes require a full restart
  3. Test Manually
    Should return documentation index.
  4. Check Network Connection
    • Ensure you have internet access
    • Check if firewall is blocking the connection
Symptoms:
  • “401 Unauthorized” errors
  • “Missing or invalid API key”
  • API calls fail but doc queries work
Solutions:
  1. Provide API Key When Prompted
    • When your AI asks for API key, provide it
    • The AI will store it securely for the session
  2. Verify API Key is Valid Test your API key manually:
  3. Request New API Key If your key is invalid, request a new one from support@myweave.ai
  4. Check for Typos
    • Ensure you copied the full API key
    • No extra spaces or line breaks
    • API keys start with specific prefixes (check your key format)
Symptoms:
  • “Token expired” errors
  • User-specific requests failing
  • Works initially, then stops after ~1 hour
Solutions:
  1. Refresh Your JWT Token See the Authentication Guide for token refresh flow
  2. Provide New Token to AI When prompted, provide the refreshed JWT token
  3. For Long Sessions Implement automatic token refresh in your application. See Authentication Guide.
Symptoms:
  • AI says “I don’t have information about myweave”
  • Queries return generic responses instead of specific docs
Solutions:
  1. Use Explicit References Try: “Using the myweave MCP server, show me how to start a chat”
  2. Verify MCP Server Name
    • Check that server name in config matches what you reference
    • Try: “Using @myweave, show me the API endpoints”
  3. Check MCP is Actually Configured
    • Ensure config file has mcpServers section
    • Verify no JSON syntax errors
  4. Test with Simple Query Try: “List all available MCP servers” Should show “myweave” if configured correctly
Why This Happens:
  • Some MCP clients only support documentation queries
  • API execution requires additional permissions
  • API key may not be properly configured
Solutions:
  1. Verify API Execution is Supported
    • Claude Desktop: ✅ Supports API execution
    • Cursor: ⚠️ May be documentation-only (check version)
    • Custom clients: ✅ Depends on implementation
  2. Provide API Key When Prompted Ensure you provide the correct API key when the AI tool asks for it.
  3. Use Custom Client for Full Control Build your own MCP client for complete API execution support. See Examples for complete implementations.

Next Steps

Use Cases

See real-world examples of hybrid AI apps

Code Examples

Complete implementations for TypeScript, Python, React

Chat API

Explore all API endpoints

Authentication

Learn about API keys and JWT tokens

Get API Access

Ready to build AI apps that integrate human expertise?

Request API Key

Email support@myweave.ai to get your API key and start building