Skip to main content

Overview

Cursor is an AI-powered code editor built on VS Code. It supports Model Context Protocol (MCP), allowing you to integrate WebHelp MCP Server directly into your coding workflow for instant documentation access.

Prerequisites

  • Cursor IDE installed (download here)
  • WebHelp MCP Server deployed and accessible
  • Node.js installed (for local MCP servers)

Configuration

1

Open Cursor Settings

Access Cursor’s configuration:
  1. Open Cursor IDE
  2. Press Cmd/Ctrl + Shift + P to open command palette
  3. Type “Preferences: Open User Settings (JSON)”
  4. Or navigate to File > Preferences > Settings and search for “MCP”
2

Configure MCP Servers

Add WebHelp MCP Server configuration to your Cursor settings:
{
  "mcp.servers": {
    "webhelp-oxygen": {
      "transport": {
        "type": "http",
        "url": "https://webhelp-mcp.example.com/www.oxygenxml.com/doc/versions/27.1/ug-editor"
      },
      "description": "Oxygen XML Editor documentation"
    }
  }
}
Replace webhelp-mcp.example.com with your actual WebHelp MCP Server domain.Endpoint formats:
  • Single site: /{domain}/{path}
  • Federated: /federated/{base64-encoded-urls}
3

Reload Cursor

Restart Cursor or reload the window:
  • Press Cmd/Ctrl + Shift + P
  • Type “Developer: Reload Window”
  • Press Enter
4

Verify Integration

Test the MCP connection:
  1. Open Cursor’s AI chat panel (Cmd/Ctrl + L)
  2. Type a query like:
    @webhelp-oxygen Search for WSDL validation
    
  3. The AI should use the WebHelp search tool to find relevant documentation

Usage in Cursor

Chat Panel

Use the @ mention syntax to query specific MCP servers:
@webhelp-oxygen Search for XML Schema validation

Inline AI

Access documentation while coding:
  1. Highlight code that needs documentation
  2. Press Cmd/Ctrl + K
  3. Ask about related concepts:
    Explain how this XSLT transform relates to Oxygen's XSLT debugging features
    
Cursor will automatically search the WebHelp documentation for relevant information.

Code Comments

Generate documentation-aware comments:
<!-- Ask Cursor: "Add comments explaining this DITA map structure based on Oxygen docs" -->
<map>
  <title>User Guide</title>
  <topicref href="introduction.dita"/>
</map>

Available Tools

Cursor has access to these WebHelp MCP Server tools: Description: Search documentation for relevant content Parameters:
  • query (string): Search query with boolean operator support (AND, OR)
Example:
@webhelp-oxygen search for "XSLT AND debugging"
Returns:
[
  {
    "title": "XSLT Debugger",
    "id": "topics/xslt-debugger.html",
    "url": "https://www.oxygenxml.com/doc/versions/27.1/ug-editor/topics/xslt-debugger.html"
  }
]

fetch

Description: Retrieve complete document content by ID Parameters:
  • id (string): Document ID from search results
Example:
@webhelp-oxygen fetch document "topics/xslt-debugger.html"
Returns:
{
  "title": "XSLT Debugger",
  "url": "https://www.oxygenxml.com/doc/versions/27.1/ug-editor/topics/xslt-debugger.html",
  "text": "# XSLT Debugger\n\nThe XSLT Debugger allows you to..."
}

Workflow Examples

Example 1: API Documentation Lookup

1

Write Code

// Need to parse DITA content
const parser = new DITAParser();
2

Ask Cursor

Press Cmd/Ctrl + K and ask:
@webhelp-dita-ot How should I structure DITA topic files?
3

Get Documentation

Cursor searches the DITA-OT documentation and provides context-aware suggestions.

Example 2: Error Resolution

1

Encounter Error

<!-- XSLT transformation error: Unknown function -->
<xsl:value-of select="unknown:function()"/>
2

Query Documentation

In chat: @webhelp-oxygen Search for custom XSLT functions
3

Apply Solution

Use the documentation to fix the error with proper function declarations.

Example 3: Code Generation

User: @webhelp-oxygen Generate a DITA map structure for a user guide

Cursor: [Searches documentation for DITA map examples]

Based on the Oxygen documentation, here's a recommended structure:

```xml
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE map PUBLIC "-//OASIS//DTD DITA Map//EN" "map.dtd">
<map>
  <title>Product User Guide</title>
  <topichead navtitle="Getting Started">
    <topicref href="introduction.dita"/>
    <topicref href="installation.dita"/>
  </topichead>
  <!-- More structure -->
</map>

Advanced Configuration

Workspace-Specific Settings

Create .cursor/settings.json in your project root:
.cursor/settings.json
{
  "mcp.servers": {
    "project-docs": {
      "transport": {
        "type": "http",
        "url": "https://webhelp-mcp.example.com/docs.myproject.com/api"
      },
      "description": "Project-specific documentation"
    }
  }
}

Environment Variables

Use environment variables for dynamic configuration:
settings.json
{
  "mcp.servers": {
    "webhelp-dynamic": {
      "transport": {
        "type": "http",
        "url": "${WEBHELP_MCP_URL}/www.oxygenxml.com/doc/versions/27.1/ug-editor"
      },
      "description": "Dynamic WebHelp server"
    }
  }
}
Set the environment variable:
export WEBHELP_MCP_URL="https://webhelp-mcp.example.com"

Custom Keybindings

Add keybindings for quick documentation access:
keybindings.json
[
  {
    "key": "cmd+shift+d",
    "command": "cursor.chat.mention",
    "args": { "serverId": "webhelp-oxygen" },
    "when": "editorTextFocus"
  }
]

Troubleshooting

Solution:
  1. Verify JSON syntax in settings file
  2. Check that the URL is correct and accessible
  3. Reload Cursor window (Cmd/Ctrl + Shift + P → “Developer: Reload Window”)
  4. Check Cursor’s developer console for errors (Help > Toggle Developer Tools)
Solution:
  1. Test the endpoint with curl:
    curl https://webhelp-mcp.example.com/www.oxygenxml.com/doc/versions/27.1/ug-editor
    
  2. Verify firewall and network settings
  3. Check if the server requires authentication
  4. Try with a local server first to isolate network issues
Solution:
  1. Ensure you’re using the exact server ID from settings
  2. Wait a few seconds after typing @ for autocomplete
  3. Check that MCP servers are enabled in Cursor settings
  4. Verify the server is connected (check status indicator)
Solution:
  1. Verify the documentation site URL is correct
  2. Try a simpler, broader search query
  3. Check that the WebHelp site has search enabled
  4. Test the search directly on the documentation website
Local HTTP servers (localhost) should only be used for development. Production environments should use HTTPS endpoints.
Use descriptive server IDs in your configuration to make it easier to reference them with @ mentions in the chat panel.

Performance Optimization

Caching Strategies

Implement caching for frequently accessed documentation:
settings.json
{
  "mcp.servers": {
    "webhelp-oxygen": {
      "transport": {
        "type": "http",
        "url": "https://webhelp-mcp.example.com/www.oxygenxml.com/doc/versions/27.1/ug-editor"
      },
      "cache": {
        "enabled": true,
        "ttl": 3600
      }
    }
  }
}

Request Throttling

Limit the number of concurrent requests:
settings.json
{
  "mcp.maxConcurrentRequests": 5,
  "mcp.requestTimeout": 30000
}

Integration with Cursor Features

Composer Mode

Use WebHelp MCP Server in Cursor’s Composer mode for multi-file edits:
  1. Press Cmd/Ctrl + Shift + I to open Composer
  2. Reference documentation:
    @webhelp-oxygen Create a DITA publishing transformation that follows Oxygen's recommended practices
    
  3. Cursor will generate code across multiple files based on the documentation

Tab Autocomplete

Cursor’s tab autocomplete will use documentation context when available:
<xsl:template match="topic">
  <!-- Cursor suggests based on Oxygen XSLT best practices -->
  <xsl:[TAB]

Next Steps

Build docs developers (and LLMs) love