$git clone https://github.com/executeautomation/mcp-database-serverThis MCP (Model Context Protocol) server provides database access capabilities to Claude, supporting SQLite, SQL Server, PostgreSQL, and MySQL databases.
| 1 | [](https://mseep.ai/app/executeautomation-mcp-database-server) |
| 2 | |
| 3 | # MCP Database Server |
| 4 | |
| 5 | This MCP (Model Context Protocol) server provides database access capabilities to Claude, supporting SQLite, SQL Server, PostgreSQL, and MySQL databases. |
| 6 | |
| 7 | ## Installation |
| 8 | |
| 9 | 1. Clone the repository: |
| 10 | ``` |
| 11 | git clone https://github.com/executeautomation/mcp-database-server.git |
| 12 | cd mcp-database-server |
| 13 | ``` |
| 14 | |
| 15 | 2. Install dependencies: |
| 16 | ``` |
| 17 | npm install |
| 18 | ``` |
| 19 | |
| 20 | 3. Build the project: |
| 21 | ``` |
| 22 | npm run build |
| 23 | ``` |
| 24 | |
| 25 | ## Usage Options |
| 26 | |
| 27 | There are two ways to use this MCP server with Claude: |
| 28 | |
| 29 | 1. **Direct usage**: Install the package globally and use it directly |
| 30 | 2. **Local development**: Run from your local development environment |
| 31 | |
| 32 | ### Direct Usage with NPM Package |
| 33 | |
| 34 | The easiest way to use this MCP server is by installing it globally: |
| 35 | |
| 36 | ```bash |
| 37 | npm install -g @executeautomation/database-server |
| 38 | ``` |
| 39 | |
| 40 | This allows you to use the server directly without building it locally. |
| 41 | |
| 42 | ### Local Development Setup |
| 43 | |
| 44 | If you want to modify the code or run from your local environment: |
| 45 | |
| 46 | 1. Clone and build the repository as shown in the Installation section |
| 47 | 2. Run the server using the commands in the Usage section below |
| 48 | |
| 49 | ## Usage |
| 50 | |
| 51 | ### SQLite Database |
| 52 | |
| 53 | To use with an SQLite database: |
| 54 | |
| 55 | ``` |
| 56 | node dist/src/index.js /path/to/your/database.db |
| 57 | ``` |
| 58 | |
| 59 | ### SQL Server Database |
| 60 | |
| 61 | To use with a SQL Server database: |
| 62 | |
| 63 | ``` |
| 64 | node dist/src/index.js --sqlserver --server <server-name> --database <database-name> [--user <username> --password <password>] |
| 65 | ``` |
| 66 | |
| 67 | Required parameters: |
| 68 | - `--server`: SQL Server host name or IP address |
| 69 | - `--database`: Name of the database |
| 70 | |
| 71 | Optional parameters: |
| 72 | - `--user`: Username for SQL Server authentication (if not provided, Windows Authentication will be used) |
| 73 | - `--password`: Password for SQL Server authentication |
| 74 | - `--port`: Port number (default: 1433) |
| 75 | |
| 76 | ### PostgreSQL Database |
| 77 | |
| 78 | To use with a PostgreSQL database: |
| 79 | |
| 80 | ``` |
| 81 | node dist/src/index.js --postgresql --host <host-name> --database <database-name> [--user <username> --password <password>] |
| 82 | ``` |
| 83 | |
| 84 | Required parameters: |
| 85 | - `--host`: PostgreSQL host name or IP address |
| 86 | - `--database`: Name of the database |
| 87 | |
| 88 | Optional parameters: |
| 89 | - `--user`: Username for PostgreSQL authentication |
| 90 | - `--password`: Password for PostgreSQL authentication |
| 91 | - `--port`: Port number (default: 5432) |
| 92 | - `--ssl`: Enable SSL connection (true/false) |
| 93 | - `--connection-timeout`: Connection timeout in milliseconds (default: 30000) |
| 94 | |
| 95 | ### MySQL Database |
| 96 | |
| 97 | #### Standard Authentication |
| 98 | |
| 99 | To use with a MySQL database: |
| 100 | |
| 101 | ``` |
| 102 | node dist/src/index.js --mysql --host <host-name> --database <database-name> --port <port> [--user <username> --password <password>] |
| 103 | ``` |
| 104 | |
| 105 | Required parameters: |
| 106 | - `--host`: MySQL host name or IP address |
| 107 | - `--database`: Name of the database |
| 108 | - `--port`: Port number (default: 3306) |
| 109 | |
| 110 | Optional parameters: |
| 111 | - `--user`: Username for MySQL authentication |
| 112 | - `--password`: Password for MySQL authentication |
| 113 | - `--ssl`: Enable SSL connection (true/false or object) |
| 114 | - `--connection-timeout`: Connection timeout in milliseconds (default: 30000) |
| 115 | |
| 116 | #### AWS IAM Authentication |
| 117 | |
| 118 | For Amazon RDS MySQL instances with IAM database authentication: |
| 119 | |
| 120 | **Prerequisites:** |
| 121 | - AWS credentials must be configured (the RDS Signer uses the default credential provider chain) |
| 122 | - Configure using one of these methods: |
| 123 | - `aws configure` (uses default profile) |
| 124 | - `AWS_PROFILE=myprofile` environment variable |
| 125 | - `AWS_ACCESS_KEY_ID` and `AWS_SECRET_ACCESS_KEY` environment variables |
| 126 | - IAM roles (if running on EC2) |
| 127 | |
| 128 | ``` |
| 129 | node dist/src/index.js --mysql --aws-iam-auth --host <rds-endpoint> --database <database-name> --user <aws-username> --aws-region <region> |
| 130 | ``` |
| 131 | |
| 132 | Required parameters: |
| 133 | - `--host`: RDS endpoint hostname |
| 134 | - `--database`: Name of the database |
| 135 | - `--aws-iam-auth`: Enable AWS IAM authentication |
| 136 | - `--user`: AWS IAM username (also the database user) |
| 137 | - `--aws-region`: AWS region where RDS instance is located |
| 138 | |
| 139 | Note: SSL is |