Introduction

Model Context Protocol (MCP) is an open-source standard to expose tools, data, or functionality to AI applications.

KeyLines MCP server enables AI agents in your code editor to access our APIs and documentation and provides more accurate and relevant help when developing with KeyLines.

All Cambridge Intelligence products have MCP servers. You can use them individually or together when integrating multiple products from our suite.

Adding MCP servers

MCP servers are compatible with different code editors thanks to the universal open-source standard.

Generally, code editors have an MCP configuration file, often named mcp.json. Every MCP server is added to this config file as a new entry:

{
  "servers": {
     "keylines": {
         "url": "https://mcp.cambridge-intelligence.com/keylines",   // our KeyLines MCP server
         "type": "http"
     },
     "mapweave": {
         "url": "https://mcp.cambridge-intelligence.com/mapweave",   // our MapWeave MCP server
         "type": "http"
     },
     / ... /
  }
}

This section shows how to add MCP servers to selected code editors. If your code editor isn't here, check the official documentation for the exact location of the MCP config file.

Claude Code

First, install Claude Code globally in your environment:

npm install -g @anthropic-ai/claude-code

Next, add a new MCP server to Claude and name it:

claude mcp add --transport http my-keylines-mcp-server https://mcp.cambridge-intelligence.com/keylines

Finally, verify that the server is running:

claude mcp list

For details and troubleshooting, see Connect Claude Code to tools via MCP.

Cursor

Create a config file named .cursor/mcp.json in your project's root folder. Then add the MCP server:

{
  "mcpServers": {
     "keylines": {
         "command": "npx",
         "args": ["-y", "mcp-remote@latest", "https://mcp.cambridge-intelligence.com/keylines"]
     }
  }
}
  • "npx": Runs the server using npx tool by Node.js
  • "-y": Confirms the installation
  • "mcp-remote@latest", "https://mcp.cambridge-intelligence.com/keylines": Downloads the package

This method downloads the MCP server as a package using mcp-remote because Cursor currently doesn't consistently support streamable http connections.

To verify the server is running, press Shift+Command+U (Mac) / Ctrl+Shift+U (Windows) to open the Output panel. Select MCP Logs from the drop-down menu to view logs confirming that the server is connected.

For details and troubleshooting, see the Model Context Protocol (MCP) docs by Cursor.

JetBrains IDEs

To add an MCP server to JetBrains IDEs such as IntelliJ IDEA or WebStorm, use the latest version of the IDE and install the JetBrains AI Assistant plugin.

  1. Go to Settings | Tools | AI Assistant | Model Context Protocol (MCP).
  2. Click the + button to add a new MCP server.
  3. Select As JSON in the top left corner of the edit window.
  4. Add the new server in the edit window:
  5. {
      "mcpServers": {
         "keylines": {
             "url": "https://mcp.cambridge-intelligence.com/keylines",
             "type": "http"
         }
      }
    }

To verify the server is running, go to Help | Show Log in Explorer/Finder/Nautilus (depending on OS). The directory contains an mcp folder with a separate log file for each MCP server.

For details and troubleshooting, see the Model Context Protocol (MCP) docs by JetBrains.

VS Code

Make sure you are on the latest version of VS Code and have access to GitHub Copilot.

  1. Press Shift+Command+P (Mac) / Ctrl+Shift+P (Windows) to open the Command Palette.
  2. Locate the MCP: Add Server command in the search bar and select it.
  3. Select the HTTP (HTTP or Server-Sent Events) option.
  4. Paste in the server URL and press Enter to confirm:
  5. https://mcp.cambridge-intelligence.com/keylines
  6. Create a unique server ID and press Enter to confirm:
  7. my-keylines-mcp-server
  8. Select the scope of work for this MCP server. The options are:
    • Global : Available in all workspaces and runs globally, recommended by us
    • Workspace : Available in this workspace only and runs locally

This creates an mcp.json file in the .vscode directory with the MCP server specified.

To verify the server is running, click the Extensions icon in the left navigation panel and find the MCP SERVERS - INSTALLED tab. Right-click on the server listed in this tab and select Show Output to view logs confirming that the server is connected.

For details and troubleshooting, see the Use MCP servers in VS Code docs by VS Code.

Example prompts

To help you get started, here are some example prompts to use for the MCP servers:

  • Create a new KeyLines project using pnpm as a package manager and Vite as a bundler that shows a simple chart with two nodes connected by a link.
  • Add a KronoGraph timeline into my KeyLines project and visualise my nodes on the timeline.
  • How to add more nodes to an existing chart in KeyLines?
  • What is the difference between organic and sequential layout?
  • How can I style my annotations to make them look better?

Data we collect

We collect a short list of key words from your prompts and the answers provided by the MCP server, and we analyse this data so we can continue improving our MCP server for a better developer experience. The format may look like this:

"query": "export chart to PNG image"