Personal experiment demonstrating how Amazon Q can act as an MCP client to fetch GitHub info from a local MCP server
- Clone the repo:
cd mcp-github-server - Install dependencies:
npm install - Create a .env file with your GitHub token:
GITHUB_TOKEN=your_personal_token_here
Note: Make sure the token has at least repo scope for private repos or read:public_repo for public repos.
npm install
npm startConsole should show: GitHub MCP server running via stdio and waiting for requests...
- Open Amazon Q Chat panel → Configure MCP Servers → Add new
- Fill in:
| Field | Value |
|---|---|
| Name | github-connector |
| Transport | stdio |
| Command | /usr/local/bin/npm |
| Arguments | start |
| Timeout | 60 |
| Environment Variables | GITHUB_TOKEN={your_personal_token} |
Confirm that Q is started in the project root where package.json lives.
- In Q chat or Q CLI, type:
/mcp list-tools
- You should see your
list_repostool listed.
- To fetch GitHub repos:
/mcp call-tool github-connector:list_repos
- Q will call the MCP server via stdio and return the formatted GitHub repo list.