How to Connect Cursor to Slack MCP Server Seamlessly

How to Connect Cursor to Slack MCP Server Seamlessly

Learn how to securely connect Cursor to a Slack MCP Server using Lunar.dev’s MCPX Gateway. This step-by-step guide explains setup, authentication, and governance for seamless AI tool integration, ensuring full visibility, auditability, and policy control across your MCP environment.

Eyal Solomon, Co-Founder & CEO

Eyal Solomon, Co-Founder & CEO

MCP

Introduction

Integrating Cursor with a Slack MCP Server through Lunar.dev’s MCPX Gateway provides a robust and secure way to manage how AI tools and copilots interact with Slack. The Lunar MCPX Gateway acts as the governance and connectivity layer between local or remote MCP servers (like Slack) and client tools such as Cursor.
This setup allows developers to work with Slack’s capabilities directly inside Cursor while maintaining full visibility and control over requests, authentication, and environment configurations.

This guide walks you through how to connect Cursor to Slack MCP Server using the Lunar MCPX Gateway, covering prerequisites, setup steps, and troubleshooting.

Understanding the Slack MCP Server

What is an MCP Server?

An MCP (Model Context Protocol) Server exposes a set of tools or APIs that agents or copilots can connect to. In the case of Slack, the Slack MCP Server lets you integrate Slack’s messaging, channels, and user APIs into agentic workflows through the MCP protocol.

Why Use the Slack MCP Server with Lunar.dev?

When combined with Lunar’s MCPX Gateway, the Slack MCP Server can be connected securely and managed within your enterprise governance setup. Lunar MCPX gives teams:

  • Centralized Management: Define which MCP servers are available and under what conditions they can be accessed.

  • Secure Connectivity: All communication passes through the gateway with key-based authentication and optional IP allowlists.

  • Profile-Based Governance: Each user or workspace can operate under its own Profile, defining which tools and servers are available.

Overview of Cursor

Cursor is a collaborative development environment built to support AI-assisted coding and integration with MCP-compatible tools. By connecting to Lunar MCPX, Cursor can communicate with approved MCP servers—like Slack—within your governed workspace.

Connecting Slack MCP Server to Cursor via Lunar MCPX Gateway

Prerequisites

Before connecting, ensure the following:

  1. You have an operational Lunar MCPX Gateway instance (local or remote).

  2. You have access to a Slack MCP Server, either self-hosted or registered under your organization.

  3. You have a Cursor workspace set up with MCP connectivity enabled.

  4. Your Lunar environment variables for authentication are configured.

Refer to Lunar’s documentation for setting up environment variables:
👉 Environment Variables Configuration for Auth Key

Step-by-Step Connection Guide

Step 1: Connect Cursor to Lunar MCPX Gateway

Follow the guide: Connect Cursor to Lunar MCPX Gateway

  1. Launch Cursor and open your workspace settings.

  2. Under MCP Connections, select Add Gateway Connection.

  3. Provide your Lunar MCPX Gateway URL, such as http://localhost:3001 or your enterprise instance URL.

  4. Add your authentication key as defined in your .env file (MCP_GATEWAY_AUTH_KEY).

  5. Save and test the connection; Cursor should detect the active Lunar MCPX Gateway instance.

Step 2: Add the Slack MCP Server to Lunar MCPX

Follow the setup guide: Add Remote Slack MCP Server

  1. Access your Lunar MCPX dashboard or CLI.

  2. Add a new remote MCP server with:
    lunar mcpx add-server slack --url https://slack-mcp-server.yourdomain.com


  3. Confirm that the Slack MCP Server appears under your connected servers list.
  4. Optionally, assign it to a specific Profile if you are segmenting access by department or user.

Step 3: Link Slack MCP Server through Lunar Gateway in Cursor

  1. Return to Cursor and select Add MCP Server via Gateway.

  2. Choose the Slack MCP Server from your connected list.

  3. Test connectivity and validate successful authentication.

  4. Once connected, you can use Slack tools (e.g., send messages, query channels, trigger workflows) directly within Cursor.

Troubleshooting Common Issues

If the connection fails:

  • Verify the MCP Gateway endpoint and token in your .env.

  • Ensure your Slack MCP Server is reachable from the same network.

  • Check your Lunar MCPX logs (lunar logs --follow) for request errors.

  • Review Lunar’s connection guides for environment setup and OAuth configuration.

Use Cases

1. Team Notifications via Slack

You can configure a Cursor workflow to automatically send a message to a Slack channel when a code review completes, using the Slack MCP tool available via the Lunar Gateway.

2. Secure Audit and Visibility

Every Slack interaction via Cursor is logged by Lunar MCPX, allowing administrators to audit who accessed which MCP tools and when.

3. Scoped Profiles for Teams

Assign separate Slack MCP configurations for engineering, support, or marketing teams, each with its own authentication keys and visibility rules.

Conclusion

Connecting Cursor to the Slack MCP Server through Lunar.dev’s MCPX Gateway offers the best combination of developer experience and enterprise governance. You gain seamless interoperability across tools like Cursor and Slack, while Lunar ensures each connection is secure, authenticated, and fully observable.

Ready to Start your journey?

Manage a single service and unlock API management at scale