question-mcp
v1.0.0
Published
MCP server that relays Copilot questions to you via WhatsApp, SMS, or Slack when you're away from the console
Maintainers
Readme
QuestionMCP
An MCP server that relays questions from GitHub Copilot to you via WhatsApp, SMS, or Slack — and returns your reply. Use it when you're away from the console but Copilot needs your input.
How It Works
- Copilot calls the
ask_user_remotetool with a question. - The server sends the question to your configured messaging channel.
- It polls the channel's API for your reply (no webhooks or exposed ports needed).
- Your reply is returned to Copilot.
Installation
Option 1: npx (Recommended)
No installation needed — just add to your MCP client config:
GitHub Copilot CLI (~/.config/github-copilot/mcp.json):
{
"servers": {
"question-mcp": {
"type": "stdio",
"command": "npx",
"args": ["-y", "question-mcp"]
}
}
}Per-repository (.github/copilot/mcp.json):
{
"servers": {
"question-mcp": {
"type": "stdio",
"command": "npx",
"args": ["-y", "question-mcp"]
}
}
}Option 2: Global install
npm install -g question-mcpThen use in your MCP config:
{
"servers": {
"question-mcp": {
"type": "stdio",
"command": "question-mcp"
}
}
}Option 3: From source
git clone https://github.com/YOUR_USER/question-mcp.git
cd question-mcp
npm install
npm run buildThen use in your MCP config:
{
"servers": {
"question-mcp": {
"type": "stdio",
"command": "node",
"args": ["<path-to-question-mcp>/dist/index.js"]
}
}
}Configuration
The server works out of the box with no config — it defaults to console fallback (Copilot will use its built-in ask_user instead). Configure channels when you're ready.
Quick Setup (with Copilot)
The easiest way to configure channels is to let Copilot guide you:
- Add the server to your MCP config (see Installation above).
- Ask Copilot to use the
setup-guideprompt — it walks you through signing up and getting credentials for each channel. - Copilot will use the
configure_channeltool to save your credentials automatically. - Copilot will use the
test_connectiontool to verify everything works.
Manual Setup
Copy the example config and fill in your credentials:
cp config.example.json config.jsonYou can override the config file path with the QUESTION_MCP_CONFIG environment variable.
Edit config.json — you only need to configure the channels you want to use:
WhatsApp (via Twilio)
- Set
accountSidandauthTokenfrom your Twilio Console. from: Your Twilio WhatsApp-enabled number (e.g.,whatsapp:+14155238886).to: Your personal WhatsApp number (e.g.,whatsapp:+1XXXXXXXXXX).- You must have the Twilio Sandbox for WhatsApp set up, or a production WhatsApp sender.
SMS (via Twilio)
- Same Twilio credentials as WhatsApp.
from: Your Twilio phone number.to: Your personal phone number.
Slack
- Create a Slack App with the following scopes:
chat:write,channels:history(orgroups:historyfor private channels),im:history(for DMs). botToken: Thexoxb-bot token from your Slack app.channelId: The channel or DM conversation ID where questions will be posted.- Invite the bot to the channel.
Configuration Options
| Field | Description | Default |
|-------|-------------|---------|
| defaultChannel | Channel to use when none is specified (whatsapp, sms, slack, console) | console |
| timeoutSeconds | How long to wait for a reply before timing out | 300 |
| pollIntervalSeconds | How often to poll for replies (in seconds) | 5 |
| throttle.maxPerHour | Max outbound messages per hour (0 = unlimited) | 100 |
| throttle.maxPerDay | Max outbound messages per day (0 = unlimited) | 500 |
| workingHours.enabled | Whether to enforce working hours | false |
| workingHours.startHour | Start of working hours (24h format) | 9 |
| workingHours.endHour | End of working hours (24h format) | 18 |
| workingHours.workDays | Working days (0=Sun, 6=Sat) | [1,2,3,4,5] |
| workingHours.timezone | IANA timezone (e.g., America/New_York) | System tz |
Safeguards
- Throttling: Prevents unexpected bills from paid services. Configurable per-hour and per-day limits.
- Working Hours: Optionally restrict notifications to specific hours and days.
- Console Fallback: When no channels are configured, Copilot is told to use its built-in
ask_usertool instead.
MCP Tools & Prompts
Prompt: setup-guide
Interactive setup guide that walks you through configuring each channel with step-by-step instructions and links.
Parameters:
| Name | Type | Required | Description |
|------|------|----------|-------------|
| channel | string | No | Get guide for a specific channel (whatsapp, sms, or slack). Omit for the full guide. |
Tool: configure_channel
Configure a messaging channel by providing credentials. Saves to config.json automatically.
Parameters:
| Name | Type | Required | Description |
|------|------|----------|-------------|
| channel | string | Yes | whatsapp, sms, or slack |
| setAsDefault | boolean | No | Set this channel as the default |
| accountSid | string | For Twilio | Twilio Account SID |
| authToken | string | For Twilio | Twilio Auth Token |
| from | string | For Twilio | Sender number |
| to | string | For Twilio | Recipient number |
| botToken | string | For Slack | Bot User OAuth Token |
| channelId | string | For Slack | Slack channel/DM ID |
Tool: test_connection
Send a test message and wait for a reply to verify the channel is working.
Parameters:
| Name | Type | Required | Description |
|------|------|----------|-------------|
| channel | string | No | Channel to test (uses default if omitted) |
Tool: ask_user_remote
Send a question to the user via a messaging channel and wait for their reply.
Parameters:
| Name | Type | Required | Description |
|------|------|----------|-------------|
| question | string | Yes | The question to ask the user |
| channel | string | No | Override the default channel (whatsapp, sms, or slack) |
Returns: The user's reply text, or a timeout message if no reply is received.
Development
# Run in development mode (no build step)
npm run dev
# Type-check
npx tsc --noEmit
# Run tests
npm test