auq-mcp-server 0.1.1 → 0.1.3

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/README.md CHANGED
@@ -12,7 +12,7 @@
12
12
 
13
13
  ## What does it do?
14
14
 
15
- Through the MCP server, your LLM can generate question sets consisting of multiple-choice, single-choice, and free-text questions (with an "Other" option for custom input) while coding or working, and wait for your answers.
15
+ Through this MCP server, your LLM can generate question sets consisting of multiple-choice, single-choice, and free-text questions (with an "Other" option for custom input) while coding or working, and wait for your answers.
16
16
 
17
17
  You can keep the `auq` CLI running in advance, or start it when questions are pending. With simple arrow key navigation, you can select answers and send them back to the AI—all within a clean terminal interface.
18
18
 
@@ -61,14 +61,27 @@ npx auq
61
61
 
62
62
  ## 🔌 MCP Server Configuration
63
63
 
64
- ### Claude Desktop
64
+ ### Cursor
65
65
 
66
- Add to `~/Library/Application Support/Claude/claude_desktop_config.json` (macOS) or `%APPDATA%\Claude\claude_desktop_config.json` (Windows):
66
+ [![Install MCP Server](https://cursor.com/deeplink/mcp-install-dark.svg)](https://cursor.com/en-US/install-mcp?name=ask-user-questions&config=eyJlbnYiOnt9LCJjb21tYW5kIjoibnB4IC15IGF1cS1tY3Atc2VydmVyIHNlcnZlciJ9)
67
+
68
+ ### Claude Code (CLI)
69
+
70
+ **Method 1: Using CLI** (Recommended)
71
+
72
+ ```bash
73
+ claude mcp add --transport stdio ask-user-questions -- npx -y auq-mcp-server server
74
+ ```
75
+
76
+ **Method 2: Manual Configuration**
77
+
78
+ Add to `.mcp.json` in your project root (for team-wide sharing):
67
79
 
68
80
  ```json
69
81
  {
70
82
  "mcpServers": {
71
- "auq": {
83
+ "ask-user-questions": {
84
+ "type": "stdio",
72
85
  "command": "npx",
73
86
  "args": ["-y", "auq-mcp-server", "server"]
74
87
  }
@@ -76,25 +89,79 @@ Add to `~/Library/Application Support/Claude/claude_desktop_config.json` (macOS)
76
89
  }
77
90
  ```
78
91
 
79
- **Restart Claude Desktop** after saving.
80
-
81
- ### Cursor / Other MCP Clients
92
+ Or add to `~/.claude.json` for global access across all projects.
82
93
 
83
- Add to `.mcp.json` in your project root:
94
+ **With environment variables:**
84
95
 
85
96
  ```json
86
97
  {
87
98
  "mcpServers": {
88
- "auq": {
99
+ "ask-user-questions": {
100
+ "type": "stdio",
89
101
  "command": "npx",
90
102
  "args": ["-y", "auq-mcp-server", "server"],
91
- "env": {}
103
+ "env": {
104
+ "AUQ_SESSION_DIR": "${AUQ_SESSION_DIR}"
105
+ }
92
106
  }
93
107
  }
94
108
  }
95
109
  ```
96
110
 
97
- Restart your client after configuration.
111
+ **Manage servers:**
112
+ ```bash
113
+ claude mcp list # View all servers
114
+ claude mcp get ask-user-questions # Server details
115
+ claude mcp remove ask-user-questions # Remove server
116
+ ```
117
+
118
+ **Verify setup:** Type `/mcp` in Claude Code to check server status.
119
+
120
+ ### Codex CLI
121
+
122
+ Add to `~/.codex/config.toml`:
123
+
124
+ ```toml
125
+ [mcp_servers.ask-user-questions]
126
+ command = "npx"
127
+ args = ["-y", "auq-mcp-server", "server"]
128
+ ```
129
+
130
+ **Full configuration example** (with optional settings):
131
+
132
+ ```toml
133
+ [mcp_servers.ask-user-questions]
134
+ command = "npx"
135
+ args = ["-y", "auq-mcp-server", "server"]
136
+
137
+ # Optional: Additional environment variables
138
+ # env = { "AUQ_SESSION_DIR" = "/custom/path" }
139
+
140
+ # Optional: Whitelist additional env vars
141
+ # env_vars = ["AUQ_SESSION_DIR"]
142
+
143
+ # Optional: Working directory
144
+ # cwd = "/Users/<user>/projects"
145
+ ```
146
+
147
+ Restart Codex CLI after saving the configuration.
148
+
149
+ ### Claude Desktop
150
+
151
+ Add to `~/Library/Application Support/Claude/claude_desktop_config.json` (macOS) or `%APPDATA%\Claude\claude_desktop_config.json` (Windows):
152
+
153
+ ```json
154
+ {
155
+ "mcpServers": {
156
+ "ask-user-questions": {
157
+ "command": "npx",
158
+ "args": ["-y", "auq-mcp-server", "server"]
159
+ }
160
+ }
161
+ }
162
+ ```
163
+
164
+ **Restart Claude Desktop** after saving.
98
165
 
99
166
  ---
100
167
 
package/dist/bin/auq.js CHANGED
@@ -1,5 +1,4 @@
1
1
  #!/usr/bin/env node
2
- import { exec } from "child_process";
3
2
  import { readFileSync } from "fs";
4
3
  import { dirname, join } from "path";
5
4
  import { fileURLToPath } from "url";
@@ -54,26 +53,10 @@ if (command === "--version" || command === "-v") {
54
53
  }
55
54
  // Handle 'server' command
56
55
  if (command === "server") {
57
- console.log("Starting MCP server...");
58
- const serverProcess = exec("node dist/src/server.js", (error, stdout, stderr) => {
59
- if (error) {
60
- console.error(`Error starting server: ${error.message}`);
61
- process.exit(1);
62
- }
63
- if (stderr) {
64
- console.error(stderr);
65
- }
66
- console.log(stdout);
67
- });
68
- // Forward signals
69
- process.on("SIGINT", () => {
70
- serverProcess.kill("SIGINT");
71
- process.exit(0);
72
- });
73
- process.on("SIGTERM", () => {
74
- serverProcess.kill("SIGTERM");
75
- process.exit(0);
76
- });
56
+ // Import and start the MCP server directly
57
+ // This avoids spawning a subprocess and outputting non-JSON to stdout
58
+ await import("../src/server.js");
59
+ // The server will start and handle stdio communication
77
60
  // Keep process alive
78
61
  await new Promise(() => { });
79
62
  }
@@ -1,6 +1,7 @@
1
1
  import { Box, Text, useApp, useInput } from "ink";
2
2
  import React, { useEffect, useRef, useState } from "react";
3
3
  import { SessionManager } from "../../session/SessionManager.js";
4
+ import { getSessionDirectory } from "../../session/utils.js";
4
5
  import { theme } from "../theme.js";
5
6
  import { ConfirmationDialog } from "./ConfirmationDialog.js";
6
7
  import { QuestionDisplay } from "./QuestionDisplay.js";
@@ -77,7 +78,7 @@ export const StepperView = ({ onComplete, sessionId, sessionRequest, }) => {
77
78
  const handleConfirm = async (userAnswers) => {
78
79
  setSubmitting(true);
79
80
  try {
80
- const sessionManager = new SessionManager();
81
+ const sessionManager = new SessionManager({ baseDir: getSessionDirectory() });
81
82
  await sessionManager.saveSessionAnswers(sessionId, {
82
83
  answers: userAnswers,
83
84
  sessionId,
@@ -114,7 +115,7 @@ export const StepperView = ({ onComplete, sessionId, sessionRequest, }) => {
114
115
  // Handle session rejection
115
116
  const handleRejectSession = async (reason) => {
116
117
  try {
117
- const sessionManager = new SessionManager();
118
+ const sessionManager = new SessionManager({ baseDir: getSessionDirectory() });
118
119
  await sessionManager.rejectSession(sessionId, reason);
119
120
  // Call onComplete with rejection flag
120
121
  if (onComplete) {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "auq-mcp-server",
3
- "version": "0.1.1",
3
+ "version": "0.1.3",
4
4
  "main": "dist/index.js",
5
5
  "bin": {
6
6
  "auq": "dist/bin/auq.js"