Skip to main content

Prerequisites

Before you can configure and use Replit with Connect AI, you must first do the following:

Connect Replit to the Connect AI MCP

1
Open the official Replit MCP learning template available here. This template includes a preconfigured MCP runtime environment and sample configuration.
2
In Replit, click Remix. Replit does the following:
  • Creates a editable copy of the project.
  • Installs MCP dependencies.
  • Initializes the environment.
Wait for the environment to fully load before continuing.
3
Inside the project is a file named mcp-server-config.json. Copy and paste the following into this file. Replace the authorization header with the credentials obtained in the prerequisites.
{
  "systemPrompt": "You are a helpful AI assistant.

Today's date is {today_datetime}.",
  "llm": {
    "provider": "openai",
    "model": "gpt-4o-mini"
  },
  "mcpServers": {
    "cdata-mcp": {
      "command": "npx",
      "args": [
        "mcp-remote",
        "https://mcp.cloud.cdata.com/mcp",
        "--header",
        "Authorization": "Basic Bearer OAUTH_JWT_TOKEN" //OAuth JWT Token
      ]
    }
  }
}
4
Replit requires an LLM key to run MCP workflows. In the Replit Chat, when asked for an LLM key, provide your OpenAI API key. Replit stores this key securely in the Secrets Manager.
5
You can now open the Replit Chat panel and issue MCP commands.For example, enter the prompt "List all MCP tools." The output looks like the following:
Replit Test Output
6
To test whether Replit can communicate with the CData MCP successfully, enter the prompt: "Show me all available catalogs." Replit should return a list of catalogs from Connect AI.
7
You can now query your connected data source(s) in Connect AI using the Replit’s LLM.