@runhuman/mcp-server 2.0.0 → 2.0.1
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 +33 -12
- package/dist/index.js +136 -142
- package/dist/index.js.map +1 -1
- package/package.json +1 -1
package/README.md
CHANGED
|
@@ -54,22 +54,36 @@ Create a new QA job with human testers.
|
|
|
54
54
|
- `url` (string): The URL to test
|
|
55
55
|
- `description` (string): Instructions for the human tester describing what to test
|
|
56
56
|
- `schema` (object): Expected result schema that the tester response will be extracted into
|
|
57
|
+
- `targetDurationMinutes` (number, optional): Time limit for tester (default: 5, range: 1-60)
|
|
57
58
|
|
|
58
|
-
#### `
|
|
59
|
-
|
|
59
|
+
#### `wait_for_result`
|
|
60
|
+
Check status, wait, and retrieve results for a QA job in a single convenient call.
|
|
60
61
|
|
|
61
62
|
**Parameters:**
|
|
62
63
|
- `jobId` (string): The ID of the job to check
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
-
|
|
64
|
+
- `waitSeconds` (number, optional): How long to wait before checking again (default: 30, range: 1-300)
|
|
65
|
+
|
|
66
|
+
**Behavior:**
|
|
67
|
+
- Checks status BEFORE waiting (returns immediately if already complete)
|
|
68
|
+
- Waits for the specified duration
|
|
69
|
+
- Checks status AFTER waiting
|
|
70
|
+
- Returns results if complete, otherwise suggests calling again with longer wait time
|
|
71
|
+
|
|
72
|
+
**Usage Pattern:**
|
|
73
|
+
```javascript
|
|
74
|
+
// After creating a job, call repeatedly with increasing wait times:
|
|
75
|
+
let result = await wait_for_result(jobId, { waitSeconds: 30 });
|
|
76
|
+
if (result.status !== 'completed') {
|
|
77
|
+
result = await wait_for_result(jobId, { waitSeconds: 45 });
|
|
78
|
+
}
|
|
79
|
+
if (result.status !== 'completed') {
|
|
80
|
+
result = await wait_for_result(jobId, { waitSeconds: 60 });
|
|
81
|
+
}
|
|
82
|
+
```
|
|
69
83
|
|
|
70
84
|
**Returns:**
|
|
71
85
|
- `result`: Structured test results extracted from tester's response
|
|
72
|
-
- `status`: Job status (completed, failed,
|
|
86
|
+
- `status`: Job status (completed, failed, timeout, pending, claimed, in_progress)
|
|
73
87
|
- `costUsd`: Exact cost in USD with full precision (e.g., 0.396)
|
|
74
88
|
- `testDurationSeconds`: Time spent by tester in seconds (rounded up)
|
|
75
89
|
- Additional metadata (timestamps, tester info, etc.)
|
|
@@ -145,14 +159,14 @@ npm run test:inspector --workspace=@runhuman/mcp-server
|
|
|
145
159
|
|
|
146
160
|
The test script will:
|
|
147
161
|
1. ✅ Initialize a connection to the MCP server
|
|
148
|
-
2. ✅ List all available tools (create_job,
|
|
162
|
+
2. ✅ List all available tools (create_job, wait_for_result)
|
|
149
163
|
3. ✅ Test calling the create_job tool
|
|
150
164
|
|
|
151
165
|
### Expected Test Output
|
|
152
166
|
|
|
153
167
|
```
|
|
154
168
|
✅ Server initialized successfully
|
|
155
|
-
✅ Tools listed: create_job,
|
|
169
|
+
✅ Tools listed: create_job, wait_for_result
|
|
156
170
|
✅ create_job tool called successfully
|
|
157
171
|
```
|
|
158
172
|
|
|
@@ -198,7 +212,14 @@ Status: pending
|
|
|
198
212
|
...
|
|
199
213
|
```
|
|
200
214
|
|
|
201
|
-
**Agent
|
|
215
|
+
**Agent calls wait_for_result repeatedly until complete:**
|
|
216
|
+
```
|
|
217
|
+
⏳ Job Status: in_progress
|
|
218
|
+
Waited 30s, job not complete yet.
|
|
219
|
+
💡 Suggestion: Call wait_for_result again with waitSeconds: 45
|
|
220
|
+
```
|
|
221
|
+
|
|
222
|
+
**Finally:**
|
|
202
223
|
```
|
|
203
224
|
✅ Test completed!
|
|
204
225
|
Results Summary:
|
package/dist/index.js
CHANGED
|
@@ -75,7 +75,7 @@ server.setRequestHandler(ListToolsRequestSchema, async () => {
|
|
|
75
75
|
tools: [
|
|
76
76
|
{
|
|
77
77
|
name: 'create_job',
|
|
78
|
-
description: `⚠️ IMPORTANT: This ONLY creates and queues a job. It does NOT perform the test or return results. You MUST follow up with
|
|
78
|
+
description: `⚠️ IMPORTANT: This ONLY creates and queues a job. It does NOT perform the test or return results. You MUST follow up with wait_for_result.
|
|
79
79
|
|
|
80
80
|
Creates a QA job that will be performed by a REAL HUMAN tester (not AI). The human will manually test your application, describe findings in natural language, and GPT-4o will extract structured data from their response.
|
|
81
81
|
|
|
@@ -88,8 +88,8 @@ Use this when you need human verification of:
|
|
|
88
88
|
|
|
89
89
|
⚠️ REQUIRED WORKFLOW (do NOT skip steps):
|
|
90
90
|
1. create_job → Returns jobId (job is now QUEUED, not complete!)
|
|
91
|
-
2.
|
|
92
|
-
3.
|
|
91
|
+
2. wait_for_result → Checks status, waits, and retrieves results (takes 2-10 min total)
|
|
92
|
+
3. If not complete, call wait_for_result again with longer wait time
|
|
93
93
|
|
|
94
94
|
DO NOT treat job creation as completion. You MUST wait for and retrieve results.`,
|
|
95
95
|
inputSchema: {
|
|
@@ -116,36 +116,36 @@ DO NOT treat job creation as completion. You MUST wait for and retrieve results.
|
|
|
116
116
|
},
|
|
117
117
|
},
|
|
118
118
|
{
|
|
119
|
-
name: '
|
|
120
|
-
description: `Check
|
|
119
|
+
name: 'wait_for_result',
|
|
120
|
+
description: `Check status, wait, and retrieve results for a QA job in a single call.
|
|
121
121
|
|
|
122
|
-
|
|
122
|
+
This tool combines status checking, waiting, and result retrieval into one convenient function:
|
|
123
|
+
- Checks status BEFORE waiting (returns immediately if already complete)
|
|
124
|
+
- Waits for the specified duration (default 30s, configurable 1-300s)
|
|
125
|
+
- Checks status AFTER waiting
|
|
126
|
+
- Returns results if complete, otherwise suggests calling again with longer wait
|
|
123
127
|
|
|
124
|
-
|
|
125
|
-
|
|
126
|
-
type: 'object',
|
|
127
|
-
properties: {
|
|
128
|
-
jobId: {
|
|
129
|
-
type: 'string',
|
|
130
|
-
description: 'The job ID returned from create_job. Example: "550e8400-e29b-41d4-a716-446655440000"',
|
|
131
|
-
},
|
|
132
|
-
},
|
|
133
|
-
required: ['jobId'],
|
|
134
|
-
},
|
|
135
|
-
},
|
|
136
|
-
{
|
|
137
|
-
name: 'get_job_result',
|
|
138
|
-
description: `Get the structured results of a completed QA job. Only call this after get_job_status shows status="completed".
|
|
128
|
+
Jobs progress through states: pending → claimed → in_progress → completed (or failed/timeout)
|
|
129
|
+
Typical completion time: 2-10 minutes total
|
|
139
130
|
|
|
140
|
-
|
|
131
|
+
Use this tool repeatedly with increasing wait times until you get results:
|
|
132
|
+
- First call: wait_for_result(jobId, { waitSeconds: 30 })
|
|
133
|
+
- If not complete: wait_for_result(jobId, { waitSeconds: 45 })
|
|
134
|
+
- If still not complete: wait_for_result(jobId, { waitSeconds: 60 })
|
|
141
135
|
|
|
142
|
-
|
|
136
|
+
Returns immediately if job is already complete (no waiting needed).`,
|
|
143
137
|
inputSchema: {
|
|
144
138
|
type: 'object',
|
|
145
139
|
properties: {
|
|
146
140
|
jobId: {
|
|
147
141
|
type: 'string',
|
|
148
|
-
description: 'The job ID
|
|
142
|
+
description: 'The job ID returned from create_job. Example: "550e8400-e29b-41d4-a716-446655440000"',
|
|
143
|
+
},
|
|
144
|
+
waitSeconds: {
|
|
145
|
+
type: 'number',
|
|
146
|
+
description: 'How long to wait (in seconds) before checking status again. Default: 30. Range: 1-300. Increase this on subsequent calls (30 → 45 → 60) for better efficiency.',
|
|
147
|
+
minimum: 1,
|
|
148
|
+
maximum: 300,
|
|
149
149
|
},
|
|
150
150
|
},
|
|
151
151
|
required: ['jobId'],
|
|
@@ -213,10 +213,11 @@ Time limit: ${duration} minutes
|
|
|
213
213
|
The test has been queued for a HUMAN tester. It is NOT complete yet.
|
|
214
214
|
|
|
215
215
|
⚠️ REQUIRED NEXT STEPS:
|
|
216
|
-
1.
|
|
217
|
-
2.
|
|
218
|
-
3.
|
|
219
|
-
|
|
216
|
+
1. Call wait_for_result(jobId: "${data.jobId}", waitSeconds: 30)
|
|
217
|
+
2. If not complete, call wait_for_result again with waitSeconds: 45
|
|
218
|
+
3. Continue with increasing wait times (60, 90, etc.) until complete
|
|
219
|
+
|
|
220
|
+
Typical completion time: 2-10 minutes total.
|
|
220
221
|
|
|
221
222
|
DO NOT consider this task done until you have retrieved the results!`,
|
|
222
223
|
},
|
|
@@ -239,163 +240,156 @@ Please check:
|
|
|
239
240
|
isError: true
|
|
240
241
|
};
|
|
241
242
|
}
|
|
242
|
-
case '
|
|
243
|
+
case 'wait_for_result':
|
|
243
244
|
try {
|
|
244
|
-
const
|
|
245
|
-
|
|
246
|
-
|
|
245
|
+
const waitSeconds = Math.min(Math.max(args.waitSeconds || 30, 1), 300);
|
|
246
|
+
// Helper function to check job status
|
|
247
|
+
const checkJobStatus = async () => {
|
|
248
|
+
const response = await fetch(`${API_URL}/api/job/${args.jobId}`, {
|
|
249
|
+
headers: {
|
|
250
|
+
'Authorization': `Bearer ${API_KEY}`
|
|
251
|
+
}
|
|
252
|
+
});
|
|
253
|
+
if (!response.ok) {
|
|
254
|
+
if (response.status === 404) {
|
|
255
|
+
throw new Error(`Job not found: ${args.jobId}`);
|
|
256
|
+
}
|
|
257
|
+
throw new Error(`Failed to get job status: ${response.status} ${response.statusText}`);
|
|
247
258
|
}
|
|
248
|
-
|
|
249
|
-
|
|
250
|
-
|
|
259
|
+
return await response.json();
|
|
260
|
+
};
|
|
261
|
+
// Check status BEFORE waiting
|
|
262
|
+
console.error(`[wait_for_result] Checking initial status for job ${args.jobId}...`);
|
|
263
|
+
let job = await checkJobStatus();
|
|
264
|
+
// If already complete, return immediately
|
|
265
|
+
if (job.status === 'completed' || job.status === 'failed' || job.status === 'timeout') {
|
|
266
|
+
console.error(`[wait_for_result] Job already in terminal state: ${job.status}`);
|
|
267
|
+
if (job.status === 'completed') {
|
|
251
268
|
return {
|
|
252
|
-
content: [
|
|
269
|
+
content: [
|
|
270
|
+
{
|
|
253
271
|
type: 'text',
|
|
254
|
-
text:
|
|
272
|
+
text: `✅ Test completed!
|
|
255
273
|
|
|
256
|
-
Job ID: ${
|
|
274
|
+
Job ID: ${job.id}
|
|
257
275
|
|
|
258
|
-
|
|
276
|
+
**Test Results:**`
|
|
277
|
+
},
|
|
278
|
+
{
|
|
279
|
+
type: 'text',
|
|
280
|
+
text: JSON.stringify(job.result || {}, null, 2)
|
|
281
|
+
}
|
|
282
|
+
]
|
|
283
|
+
};
|
|
284
|
+
}
|
|
285
|
+
else if (job.status === 'failed') {
|
|
286
|
+
return {
|
|
287
|
+
content: [{
|
|
288
|
+
type: 'text',
|
|
289
|
+
text: `❌ Job failed
|
|
290
|
+
|
|
291
|
+
Job ID: ${job.id}
|
|
292
|
+
Error: ${job.error || 'Unknown error'}`
|
|
259
293
|
}],
|
|
260
294
|
isError: true
|
|
261
295
|
};
|
|
262
296
|
}
|
|
263
|
-
|
|
264
|
-
|
|
265
|
-
|
|
266
|
-
|
|
297
|
+
else { // timeout
|
|
298
|
+
return {
|
|
299
|
+
content: [{
|
|
300
|
+
type: 'text',
|
|
301
|
+
text: `⏰ Job timed out
|
|
267
302
|
|
|
268
|
-
|
|
269
|
-
|
|
270
|
-
|
|
271
|
-
|
|
272
|
-
|
|
303
|
+
Job ID: ${job.id}
|
|
304
|
+
|
|
305
|
+
The tester did not complete the test in time.`
|
|
306
|
+
}],
|
|
307
|
+
isError: true
|
|
308
|
+
};
|
|
309
|
+
}
|
|
273
310
|
}
|
|
274
|
-
|
|
311
|
+
// Job not complete yet, wait and check again
|
|
312
|
+
console.error(`[wait_for_result] Job status: ${job.status}. Waiting ${waitSeconds} seconds...`);
|
|
275
313
|
const statusEmoji = {
|
|
276
314
|
pending: '⏳',
|
|
277
315
|
claimed: '👤',
|
|
278
|
-
in_progress: '🔄'
|
|
279
|
-
completed: '✅',
|
|
280
|
-
failed: '❌',
|
|
281
|
-
timeout: '⏰'
|
|
316
|
+
in_progress: '🔄'
|
|
282
317
|
};
|
|
283
318
|
const emoji = statusEmoji[job.status] || '📊';
|
|
284
|
-
|
|
319
|
+
await new Promise(resolve => setTimeout(resolve, waitSeconds * 1000));
|
|
320
|
+
// Check status AFTER waiting
|
|
321
|
+
console.error(`[wait_for_result] Checking status after ${waitSeconds}s wait...`);
|
|
322
|
+
job = await checkJobStatus();
|
|
323
|
+
// Check if complete now
|
|
324
|
+
if (job.status === 'completed') {
|
|
325
|
+
return {
|
|
326
|
+
content: [
|
|
327
|
+
{
|
|
328
|
+
type: 'text',
|
|
329
|
+
text: `✅ Test completed!
|
|
285
330
|
|
|
286
|
-
Job ID: ${job.id}
|
|
287
|
-
|
|
288
|
-
|
|
289
|
-
|
|
290
|
-
|
|
291
|
-
|
|
292
|
-
|
|
293
|
-
|
|
294
|
-
|
|
331
|
+
Job ID: ${job.id}
|
|
332
|
+
|
|
333
|
+
**Test Results:**`
|
|
334
|
+
},
|
|
335
|
+
{
|
|
336
|
+
type: 'text',
|
|
337
|
+
text: JSON.stringify(job.result || {}, null, 2)
|
|
338
|
+
}
|
|
339
|
+
]
|
|
340
|
+
};
|
|
295
341
|
}
|
|
296
342
|
else if (job.status === 'failed') {
|
|
297
|
-
message += '\n\n❌ Job failed.' + (job.error ? ` Error: ${job.error}` : ' Check the error with get_job_result.');
|
|
298
|
-
}
|
|
299
|
-
else if (job.status === 'timeout') {
|
|
300
|
-
message += '\n\n⏰ Job timed out. The tester did not complete in time.';
|
|
301
|
-
}
|
|
302
|
-
return {
|
|
303
|
-
content: [{
|
|
304
|
-
type: 'text',
|
|
305
|
-
text: message
|
|
306
|
-
}]
|
|
307
|
-
};
|
|
308
|
-
}
|
|
309
|
-
catch (error) {
|
|
310
|
-
return {
|
|
311
|
-
content: [{
|
|
312
|
-
type: 'text',
|
|
313
|
-
text: `❌ Error checking job status
|
|
314
|
-
|
|
315
|
-
${error instanceof Error ? error.message : 'Unknown error'}`
|
|
316
|
-
}],
|
|
317
|
-
isError: true
|
|
318
|
-
};
|
|
319
|
-
}
|
|
320
|
-
case 'get_job_result':
|
|
321
|
-
try {
|
|
322
|
-
const response = await fetch(`${API_URL}/api/job/${args.jobId}`, {
|
|
323
|
-
headers: {
|
|
324
|
-
'Authorization': `Bearer ${API_KEY}`
|
|
325
|
-
}
|
|
326
|
-
});
|
|
327
|
-
if (!response.ok) {
|
|
328
|
-
if (response.status === 404) {
|
|
329
|
-
return {
|
|
330
|
-
content: [{
|
|
331
|
-
type: 'text',
|
|
332
|
-
text: `❌ Job not found
|
|
333
|
-
|
|
334
|
-
Job ID: ${args.jobId}
|
|
335
|
-
|
|
336
|
-
The job does not exist or you don't have permission to access it.`
|
|
337
|
-
}],
|
|
338
|
-
isError: true
|
|
339
|
-
};
|
|
340
|
-
}
|
|
341
343
|
return {
|
|
342
344
|
content: [{
|
|
343
345
|
type: 'text',
|
|
344
|
-
text: `❌
|
|
346
|
+
text: `❌ Job failed
|
|
345
347
|
|
|
346
|
-
|
|
347
|
-
Error: ${
|
|
348
|
+
Job ID: ${job.id}
|
|
349
|
+
Error: ${job.error || 'Unknown error'}`
|
|
348
350
|
}],
|
|
349
351
|
isError: true
|
|
350
352
|
};
|
|
351
353
|
}
|
|
352
|
-
|
|
353
|
-
if (job.status !== 'completed') {
|
|
354
|
+
else if (job.status === 'timeout') {
|
|
354
355
|
return {
|
|
355
356
|
content: [{
|
|
356
357
|
type: 'text',
|
|
357
|
-
text:
|
|
358
|
+
text: `⏰ Job timed out
|
|
358
359
|
|
|
359
360
|
Job ID: ${job.id}
|
|
360
|
-
|
|
361
|
-
|
|
362
|
-
|
|
363
|
-
|
|
364
|
-
job.status === 'failed' ? '❌ Job failed. Error: ' + (job.error || 'Unknown error') :
|
|
365
|
-
job.status === 'timeout' ? '⏰ Job timed out.' :
|
|
366
|
-
'Use get_job_status to check current status.'}`
|
|
367
|
-
}]
|
|
361
|
+
|
|
362
|
+
The tester did not complete the test in time.`
|
|
363
|
+
}],
|
|
364
|
+
isError: true
|
|
368
365
|
};
|
|
369
366
|
}
|
|
370
|
-
//
|
|
371
|
-
const
|
|
367
|
+
// Still not complete, suggest calling again with longer wait
|
|
368
|
+
const nextWait = Math.min(waitSeconds + 15, 120);
|
|
369
|
+
const statusMessage = job.status === 'pending' ?
|
|
370
|
+
'Waiting for a tester to claim this job...' :
|
|
371
|
+
'The tester is working on your test...';
|
|
372
|
+
return {
|
|
373
|
+
content: [{
|
|
374
|
+
type: 'text',
|
|
375
|
+
text: `${emoji} Job Status: ${job.status}
|
|
372
376
|
|
|
373
377
|
Job ID: ${job.id}
|
|
374
378
|
|
|
375
|
-
|
|
376
|
-
|
|
377
|
-
|
|
378
|
-
|
|
379
|
-
|
|
380
|
-
|
|
381
|
-
|
|
382
|
-
|
|
383
|
-
text: JSON.stringify(job.result || {}, null, 2)
|
|
384
|
-
}
|
|
385
|
-
];
|
|
386
|
-
if (job.error) {
|
|
387
|
-
contents.push({
|
|
388
|
-
type: 'text',
|
|
389
|
-
text: `\n⚠️ Note: ${job.error}`
|
|
390
|
-
});
|
|
391
|
-
}
|
|
392
|
-
return { content: contents };
|
|
379
|
+
${statusMessage}
|
|
380
|
+
|
|
381
|
+
⏰ Waited ${waitSeconds}s, job not complete yet.
|
|
382
|
+
|
|
383
|
+
💡 Suggestion: Call wait_for_result again with waitSeconds: ${nextWait}
|
|
384
|
+
Typical completion time: 2-10 minutes total.`
|
|
385
|
+
}]
|
|
386
|
+
};
|
|
393
387
|
}
|
|
394
388
|
catch (error) {
|
|
395
389
|
return {
|
|
396
390
|
content: [{
|
|
397
391
|
type: 'text',
|
|
398
|
-
text: `❌ Error
|
|
392
|
+
text: `❌ Error waiting for result
|
|
399
393
|
|
|
400
394
|
${error instanceof Error ? error.message : 'Unknown error'}`
|
|
401
395
|
}],
|
package/dist/index.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":";AAEA;;;;;;;;;;GAUG;AAEH,OAAO,EAAE,MAAM,EAAE,MAAM,2CAA2C,CAAC;AACnE,OAAO,EAAE,oBAAoB,EAAE,MAAM,2CAA2C,CAAC;AACjF,OAAO,EACL,q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