Skip to main content

MCP servers: connect AI coding assistants to your tools

AI coding assistants like Cursor, Codex, and Claude are powerful on their own, but they become significantly more useful when they can interact with your actual services — querying data, creating resources, and running operations without you switching context. That is exactly what MCP servers enable.

What is MCP?

The Model Context Protocol (MCP) is an open standard that lets AI assistants call external tools over a structured interface. Instead of the assistant guessing or asking you to copy-paste, it can directly invoke a tool — like "list all apps" or "create a link" — and get a real response from your service.

An MCP server exposes a set of tools (think of them as typed API endpoints) that the assistant can discover and call. Each tool has a name, a description, an input schema, and returns structured output. The assistant sees the tool list, decides which one fits your request, fills in the parameters, and calls it.

How it works

  1. Discovery — the assistant connects to the MCP server and calls tools/list to learn what tools are available.
  2. Planning — when you ask a question or give an instruction, the assistant picks the right tool and fills in the arguments.
  3. Execution — the assistant calls tools/call with the tool name and arguments. The server processes the request and returns a result.
  4. Response — the assistant reads the result and presents it to you in natural language.

Configuring MCP servers in Cursor

Cursor uses a .cursor/mcp.json file at the root of your workspace (or in your home directory for global config).

{
"mcpServers": {
"my-service": {
"url": "https://example.com/mcp",
"headers": {
"Authorization": "Bearer YOUR_API_KEY"
}
}
}
}

The url field points to the MCP endpoint. The headers object is sent with every request — use it for authentication. After saving the file, reload Cursor (or restart it) so the MCP server is picked up.

Configuring MCP servers in Codex

Codex reads MCP server configuration from ~/.codex/config.toml.

[mcp_servers."my-service"]
type = "url"
url = "https://example.com/mcp"

[mcp_servers."my-service".headers]
Authorization = "Bearer YOUR_API_KEY"

Restart Codex after editing the config.

Configuring MCP servers in Claude

Claude Desktop reads MCP configuration from its settings file. On macOS this is ~/Library/Application Support/Claude/claude_desktop_config.json.

{
"mcpServers": {
"my-service": {
"url": "https://example.com/mcp",
"headers": {
"Authorization": "Bearer YOUR_API_KEY"
}
}
}
}

Restart Claude Desktop after saving changes. The server will appear in the tool list when you start a new conversation.

LinkMe MCP server

LinkMe provides a deployed MCP server at https://li-nk.me/mcp. It lets you manage your apps, links, and keys directly from your AI assistant — no local setup required.

Getting an MCP key

  1. Sign in to the LinkMe portal.
  2. Go to the Team page.
  3. In the MCP Keys section, generate a new key.

Keys can be personal (access your own apps) or team-scoped (access all apps in a team). MCP keys are available on the Indie plan and above.

Each key has can_read and can_write capabilities. Start with read-only and enable writes only when needed.

Cursor setup

Add this to .cursor/mcp.json in your project root:

{
"mcpServers": {
"linkme": {
"url": "https://li-nk.me/mcp",
"headers": {
"Authorization": "Bearer tk_YOUR_KEY"
}
}
}
}

Reload Cursor and the LinkMe tools will appear in the MCP panel.

Codex setup

Add this to ~/.codex/config.toml:

[mcp_servers."linkme"]
type = "url"
url = "https://li-nk.me/mcp"

[mcp_servers."linkme".headers]
Authorization = "Bearer tk_YOUR_KEY"

Restart Codex to pick up the new server.

Claude setup

Add to ~/Library/Application Support/Claude/claude_desktop_config.json:

{
"mcpServers": {
"linkme": {
"url": "https://li-nk.me/mcp",
"headers": {
"Authorization": "Bearer tk_YOUR_KEY"
}
}
}
}

Restart Claude Desktop to pick up the new server.

Available tools

Once connected, your assistant can use these tools:

Read tools (always available)

ToolWhat it does
health.getCheck if the LinkMe API is healthy.
apps.listList all apps you own or have access to (personal keys).
apps.listByTeamList all apps in your team (team-scoped keys — team ID is auto-filled).
teams.getGet details about your team (team-scoped keys — team ID is auto-filled).
apps.getGet details for a specific app by ID.
links.listByAppList all links for a specific app.
links.getInsightsGet click analytics and insights for a specific link.
links.getDetailsGet full details for a link including metadata and configuration.

Write tools (require can_write on the key)

ToolWhat it does
links.createCreate a new link in an app.
links.updateUpdate an existing link's configuration.

What you can ask

Here are examples of natural language requests your assistant will handle using LinkMe MCP:

Listing and exploring:

  • "What apps do I have?"
  • "Show me all links for app app_abc123"
  • "Get insights for link link_xyz789"
  • "Is the LinkMe API healthy?"

Creating and managing (write-enabled keys only):

Team context (team-scoped keys):

  • "What apps does my team have?"
  • "Show me the team details"
  • "List links for the team's marketing app"

The assistant automatically uses the right tool based on your key type — you do not need to specify team IDs or worry about which endpoint to call.

Security

LinkMe MCP enforces the same security boundaries as the REST API:

  • MCP can only call explicitly allowlisted endpoints.
  • Your key's can_read/can_write capabilities are enforced on every call.
  • App-key scoped requests must match the key's app ID.
  • Team membership is enforced by the REST layer — MCP cannot bypass it.
  • Write tools are disabled by default on the server.
  • Internal endpoints (/internal/*) are never accessible.

For the full security model, see the MCP Security & Access Model documentation.

caution

Do not commit real API keys to version control. Use placeholder values in checked-in config files and override locally, or add .cursor/mcp.json to .gitignore.