nile-mcp-server

The Nile MCP Server is an implementation of the Model Context Protocol (MCP) for the Nile database platform. This server enables LLM applications to interact with the Nile platform through a standardized interface. It offers features such as database management, credential management, region management, and the ability to execute SQL queries directly on Nile databases.

GitHub Stars

16

User Rating

Not Rated

Favorites

0

Views

28

Forks

8

Issues

4

Installation
Difficulty
Intermediate
Estimated Time
10-20 minutes
Requirements
Node.js: 18.0.0以上
npm: 8.0.0以上

Installation

Installation

Prerequisites

Please specify required software and versions:
Node.js: 18.0.0 or higher
npm: 8.0.0 or higher

Installation Steps

1. Clone Repository

bash
git clone https://github.com/niledatabase/nile-mcp-server.git
cd nile-mcp-server

2. Install Dependencies

bash
npm install

3. Build the Project

bash
npm run build

4. Start Server

bash
npm start

Troubleshooting

Common Issues

Issue: Server won't start Solution: Check Node.js version and reinstall dependencies.

Configuration

Configuration

Basic Configuration

Claude Desktop Setup

Edit ~/.config/claude-desktop/claude_desktop_config.json (macOS/Linux) or %APPDATA%\Claude\claude_desktop_config.json (Windows):
json
{
  "mcpServers": {
    "nile-mcp-server": {
      "command": "node",
      "args": ["dist/index.js"],
      "env": {
        "API_KEY": "your-api-key"
      }
    }
  }
}

Environment Variables

Set the following environment variables as needed:
bash
export API_KEY="your-api-key"
export DEBUG="true"

Configuration Example

Basic Configuration

json
{
  "mcpServers": {
    "nile-mcp-server": {
      "command": "node",
      "args": ["dist/index.js"],
      "env": {
        "PORT": "3000"
      }
    }
  }
}

Examples

Examples

Basic Usage

Here are basic usage examples for the MCP server:

Programmatic Usage

javascript
// JavaScript example (Node.js)
const { MCPClient } = require('@modelcontextprotocol/client');

const client = new MCPClient();
await client.connect();

// Execute tool
const result = await client.callTool('toolName', {
  parameter1: 'value1',
  parameter2: 'value2'
});

console.log(result);

Advanced Examples

Automation Script

bash
#!/bin/bash

Batch processing example

for file in *.txt; do mcp-tool process "$file" done

Use Cases

Developing applications that create and manage databases and users
Building tools that automate queries to databases using LLMs
Implementing multi-tenant applications for managing multiple tenants
Creating dashboards that monitor database states and provide error messages to users

Additional Resources