@vibescope/mcp-server 0.2.3 → 0.2.4

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.
Files changed (79) hide show
  1. package/CHANGELOG.md +84 -0
  2. package/README.md +45 -2
  3. package/dist/api-client.d.ts +276 -8
  4. package/dist/api-client.js +123 -8
  5. package/dist/handlers/blockers.d.ts +11 -0
  6. package/dist/handlers/blockers.js +37 -2
  7. package/dist/handlers/bodies-of-work.d.ts +2 -0
  8. package/dist/handlers/bodies-of-work.js +30 -1
  9. package/dist/handlers/connectors.js +2 -2
  10. package/dist/handlers/decisions.d.ts +11 -0
  11. package/dist/handlers/decisions.js +37 -2
  12. package/dist/handlers/deployment.d.ts +6 -0
  13. package/dist/handlers/deployment.js +33 -5
  14. package/dist/handlers/discovery.js +27 -11
  15. package/dist/handlers/fallback.js +12 -6
  16. package/dist/handlers/file-checkouts.d.ts +1 -0
  17. package/dist/handlers/file-checkouts.js +17 -2
  18. package/dist/handlers/findings.d.ts +5 -0
  19. package/dist/handlers/findings.js +19 -2
  20. package/dist/handlers/git-issues.js +4 -2
  21. package/dist/handlers/ideas.d.ts +5 -0
  22. package/dist/handlers/ideas.js +19 -2
  23. package/dist/handlers/progress.js +2 -2
  24. package/dist/handlers/project.d.ts +1 -0
  25. package/dist/handlers/project.js +35 -2
  26. package/dist/handlers/requests.js +6 -3
  27. package/dist/handlers/roles.js +13 -2
  28. package/dist/handlers/session.d.ts +12 -0
  29. package/dist/handlers/session.js +288 -25
  30. package/dist/handlers/sprints.d.ts +2 -0
  31. package/dist/handlers/sprints.js +30 -1
  32. package/dist/handlers/tasks.d.ts +25 -2
  33. package/dist/handlers/tasks.js +228 -35
  34. package/dist/handlers/tool-docs.js +72 -5
  35. package/dist/templates/agent-guidelines.d.ts +18 -0
  36. package/dist/templates/agent-guidelines.js +207 -0
  37. package/dist/tools.js +478 -125
  38. package/dist/utils.d.ts +5 -2
  39. package/dist/utils.js +90 -51
  40. package/package.json +51 -46
  41. package/scripts/version-bump.ts +203 -0
  42. package/src/api-client.ts +371 -12
  43. package/src/handlers/__test-setup__.ts +5 -0
  44. package/src/handlers/blockers.test.ts +76 -0
  45. package/src/handlers/blockers.ts +56 -2
  46. package/src/handlers/bodies-of-work.ts +59 -1
  47. package/src/handlers/connectors.ts +2 -2
  48. package/src/handlers/decisions.test.ts +71 -2
  49. package/src/handlers/decisions.ts +56 -2
  50. package/src/handlers/deployment.test.ts +81 -0
  51. package/src/handlers/deployment.ts +38 -5
  52. package/src/handlers/discovery.ts +27 -11
  53. package/src/handlers/fallback.test.ts +11 -10
  54. package/src/handlers/fallback.ts +14 -8
  55. package/src/handlers/file-checkouts.test.ts +83 -3
  56. package/src/handlers/file-checkouts.ts +22 -2
  57. package/src/handlers/findings.test.ts +2 -2
  58. package/src/handlers/findings.ts +38 -2
  59. package/src/handlers/git-issues.test.ts +2 -2
  60. package/src/handlers/git-issues.ts +4 -2
  61. package/src/handlers/ideas.test.ts +1 -1
  62. package/src/handlers/ideas.ts +34 -2
  63. package/src/handlers/progress.ts +2 -2
  64. package/src/handlers/project.ts +47 -2
  65. package/src/handlers/requests.test.ts +38 -7
  66. package/src/handlers/requests.ts +6 -3
  67. package/src/handlers/roles.test.ts +1 -1
  68. package/src/handlers/roles.ts +20 -2
  69. package/src/handlers/session.test.ts +303 -4
  70. package/src/handlers/session.ts +348 -35
  71. package/src/handlers/sprints.ts +61 -1
  72. package/src/handlers/tasks.test.ts +0 -73
  73. package/src/handlers/tasks.ts +269 -40
  74. package/src/handlers/tool-docs.ts +77 -5
  75. package/src/handlers/types.test.ts +259 -0
  76. package/src/templates/agent-guidelines.ts +210 -0
  77. package/src/tools.ts +479 -125
  78. package/src/utils.test.ts +7 -5
  79. package/src/utils.ts +95 -51
package/src/tools.ts CHANGED
@@ -37,9 +37,39 @@ Use mode:'full' for complete context, mode:'lite' (default) for minimal tokens.`
37
37
  enum: ['developer', 'validator', 'deployer', 'reviewer', 'maintainer'],
38
38
  description: 'Agent role: developer (general work, default), validator (task validation), deployer (deployments), reviewer (code review), maintainer (housekeeping)',
39
39
  },
40
+ hostname: {
41
+ type: 'string',
42
+ description: 'Machine hostname for worktree tracking. Pass os.hostname() to filter stale worktrees to only those created on this machine.',
43
+ },
44
+ agent_type: {
45
+ type: 'string',
46
+ enum: ['claude', 'gemini', 'cursor', 'windsurf', 'other'],
47
+ description: 'Agent type for onboarding. When a new agent type connects to an existing project, setup instructions are returned.',
48
+ },
40
49
  },
41
50
  },
42
51
  },
52
+ {
53
+ name: 'confirm_agent_setup',
54
+ description: `Confirm that agent setup is complete for this project. Call this after creating your agent's configuration file (e.g., .claude/CLAUDE.md, .gemini/GEMINI.md).
55
+
56
+ This marks your agent type as fully onboarded to the project, so you won't receive setup instructions again.`,
57
+ inputSchema: {
58
+ type: 'object',
59
+ properties: {
60
+ project_id: {
61
+ type: 'string',
62
+ description: 'Project UUID',
63
+ },
64
+ agent_type: {
65
+ type: 'string',
66
+ enum: ['claude', 'gemini', 'cursor', 'windsurf', 'other'],
67
+ description: 'Agent type that completed setup',
68
+ },
69
+ },
70
+ required: ['project_id', 'agent_type'],
71
+ },
72
+ },
43
73
  {
44
74
  name: 'get_help',
45
75
  description: 'Get guidance on a specific topic. Use when unsure about workflows.',
@@ -63,6 +93,33 @@ Use mode:'full' for complete context, mode:'lite' (default) for minimal tokens.`
63
93
  properties: {},
64
94
  },
65
95
  },
96
+ {
97
+ name: 'report_token_usage',
98
+ description: `Report actual Claude API token usage for accurate cost tracking.
99
+
100
+ IMPORTANT: MCP can only estimate tokens from tool I/O (~1-5% of actual usage). Call this tool after each API response to report actual usage from the Claude API response headers.
101
+
102
+ The Claude API response includes 'usage.input_tokens' and 'usage.output_tokens' - pass those values here for accurate cost attribution.`,
103
+ inputSchema: {
104
+ type: 'object',
105
+ properties: {
106
+ input_tokens: {
107
+ type: 'number',
108
+ description: 'Input tokens from Claude API response (usage.input_tokens)',
109
+ },
110
+ output_tokens: {
111
+ type: 'number',
112
+ description: 'Output tokens from Claude API response (usage.output_tokens)',
113
+ },
114
+ model: {
115
+ type: 'string',
116
+ enum: ['opus', 'sonnet', 'haiku'],
117
+ description: 'Model used for this API call (optional, uses session model if not provided)',
118
+ },
119
+ },
120
+ required: ['input_tokens', 'output_tokens'],
121
+ },
122
+ },
66
123
  // Cost monitoring tools
67
124
  {
68
125
  name: 'get_cost_summary',
@@ -87,19 +144,7 @@ Use mode:'full' for complete context, mode:'lite' (default) for minimal tokens.`
87
144
  required: ['project_id'],
88
145
  },
89
146
  },
90
- {
91
- name: 'get_cost_alerts',
92
- description: 'Get cost alerts for the current user.',
93
- inputSchema: {
94
- type: 'object',
95
- properties: {
96
- project_id: {
97
- type: 'string',
98
- description: 'Filter by project (optional)',
99
- },
100
- },
101
- },
102
- },
147
+ // REMOVED: get_cost_alerts - unbounded collection, use dashboard to view alerts
103
148
  {
104
149
  name: 'add_cost_alert',
105
150
  description: 'Add a cost alert threshold.',
@@ -174,58 +219,9 @@ Use mode:'full' for complete context, mode:'lite' (default) for minimal tokens.`
174
219
  required: ['alert_id'],
175
220
  },
176
221
  },
177
- {
178
- name: 'get_task_costs',
179
- description: 'Get cost breakdown by task for a project.',
180
- inputSchema: {
181
- type: 'object',
182
- properties: {
183
- project_id: {
184
- type: 'string',
185
- description: 'Project UUID',
186
- },
187
- limit: {
188
- type: 'number',
189
- description: 'Max tasks to return (default: 20)',
190
- },
191
- },
192
- required: ['project_id'],
193
- },
194
- },
195
- {
196
- name: 'get_body_of_work_costs',
197
- description: 'Get cost breakdown by body of work with phase-level details. Returns costs for pre/core/post phases and model breakdown.',
198
- inputSchema: {
199
- type: 'object',
200
- properties: {
201
- body_of_work_id: {
202
- type: 'string',
203
- description: 'Body of work UUID (optional if project_id provided)',
204
- },
205
- project_id: {
206
- type: 'string',
207
- description: 'Project UUID to get all body of work costs (optional if body_of_work_id provided)',
208
- },
209
- },
210
- },
211
- },
212
- {
213
- name: 'get_sprint_costs',
214
- description: 'Get cost breakdown by sprint with velocity metrics. Returns cost per story point and phase breakdown.',
215
- inputSchema: {
216
- type: 'object',
217
- properties: {
218
- sprint_id: {
219
- type: 'string',
220
- description: 'Sprint UUID (optional if project_id provided)',
221
- },
222
- project_id: {
223
- type: 'string',
224
- description: 'Project UUID to get all sprint costs (optional if sprint_id provided)',
225
- },
226
- },
227
- },
228
- },
222
+ // REMOVED: get_task_costs - unbounded collection, use get_cost_summary for aggregated data
223
+ // REMOVED: get_body_of_work_costs - unbounded collection, use get_cost_summary for aggregated data
224
+ // REMOVED: get_sprint_costs - unbounded collection, use get_cost_summary for aggregated data
229
225
  // Knowledge Base Query Tool
230
226
  {
231
227
  name: 'query_knowledge_base',
@@ -399,17 +395,47 @@ Use mode:'full' for complete context, mode:'lite' (default) for minimal tokens.`
399
395
  type: 'boolean',
400
396
  description: 'Automatically tag deployments on main branch',
401
397
  },
402
- git_auto_commit_on_complete: {
398
+ deployment_instructions: {
399
+ type: 'string',
400
+ description: 'Instructions for how to deploy (e.g., "Push to main for Vercel auto-deploy", "Run fly deploy")',
401
+ },
402
+ // Git and validation settings
403
+ git_delete_branch_on_merge: {
403
404
  type: 'boolean',
404
- description: 'Agents must commit changes after completing tasks',
405
+ description: 'Delete feature branch after PR merge (default: true)',
405
406
  },
406
- git_auto_pr_on_complete: {
407
+ require_pr_for_validation: {
407
408
  type: 'boolean',
408
- description: 'Agents must create PR after completing tasks',
409
+ description: 'Require PR exists before task validation can be approved (default: true for github-flow/git-flow)',
409
410
  },
410
- deployment_instructions: {
411
- type: 'string',
412
- description: 'Instructions for how to deploy (e.g., "Push to main for Vercel auto-deploy", "Run fly deploy")',
411
+ auto_merge_on_approval: {
412
+ type: 'boolean',
413
+ description: 'Automatically merge PR when validator approves (default: true)',
414
+ },
415
+ validation_required: {
416
+ type: 'boolean',
417
+ description: 'Completed tasks require validation before being considered done (default: true)',
418
+ },
419
+ // Task default settings
420
+ default_task_priority: {
421
+ type: 'integer',
422
+ minimum: 1,
423
+ maximum: 5,
424
+ description: 'Default priority for new tasks when not specified (1=highest, 5=lowest, default: 3)',
425
+ },
426
+ require_time_estimates: {
427
+ type: 'boolean',
428
+ description: 'Require estimated_minutes when creating tasks (default: false)',
429
+ },
430
+ // Agent behavior settings
431
+ fallback_activities_enabled: {
432
+ type: 'boolean',
433
+ description: 'Allow agents to perform background activities when no tasks available (default: true)',
434
+ },
435
+ preferred_fallback_activities: {
436
+ type: 'array',
437
+ items: { type: 'string' },
438
+ description: 'Array of preferred fallback activities (e.g., ["code_review", "security_review"]). Null means all allowed.',
413
439
  },
414
440
  },
415
441
  required: ['project_id'],
@@ -434,8 +460,76 @@ Use mode:'full' for complete context, mode:'lite' (default) for minimal tokens.`
434
460
  },
435
461
  },
436
462
  {
437
- name: 'get_tasks',
438
- description: 'Get tasks for a project, optionally filtered by status. By default returns only root tasks (not subtasks).',
463
+ name: 'get_project_summary',
464
+ description: 'Get a unified project overview with aggregated stats. Token-efficient way to get task counts, blockers, findings, active agents, and more in a single call.',
465
+ inputSchema: {
466
+ type: 'object',
467
+ properties: {
468
+ project_id: {
469
+ type: 'string',
470
+ description: 'Project UUID',
471
+ },
472
+ },
473
+ required: ['project_id'],
474
+ },
475
+ },
476
+ // Targeted task endpoints (token-efficient)
477
+ {
478
+ name: 'get_task',
479
+ description: `Get a single task by ID with optional subtasks and milestones.`,
480
+ inputSchema: {
481
+ type: 'object',
482
+ properties: {
483
+ task_id: {
484
+ type: 'string',
485
+ description: 'Task UUID',
486
+ },
487
+ include_subtasks: {
488
+ type: 'boolean',
489
+ description: 'Include subtasks array (default: false)',
490
+ },
491
+ include_milestones: {
492
+ type: 'boolean',
493
+ description: 'Include milestones array (default: false)',
494
+ },
495
+ },
496
+ required: ['task_id'],
497
+ },
498
+ },
499
+ {
500
+ name: 'search_tasks',
501
+ description: `Search tasks by text query. Supports pagination with offset. Use for finding specific tasks by title or description.`,
502
+ inputSchema: {
503
+ type: 'object',
504
+ properties: {
505
+ project_id: {
506
+ type: 'string',
507
+ description: 'Project UUID',
508
+ },
509
+ query: {
510
+ type: 'string',
511
+ description: 'Search query (min 2 chars). Searches title and description.',
512
+ },
513
+ status: {
514
+ type: 'array',
515
+ items: { type: 'string', enum: ['backlog', 'pending', 'in_progress', 'completed', 'cancelled'] },
516
+ description: 'Filter by status (optional, array)',
517
+ },
518
+ limit: {
519
+ type: 'number',
520
+ description: 'Max results per page (1-20, default: 10)',
521
+ },
522
+ offset: {
523
+ type: 'number',
524
+ description: 'Number of results to skip for pagination (default: 0)',
525
+ },
526
+ },
527
+ required: ['project_id', 'query'],
528
+ },
529
+ },
530
+ {
531
+ name: 'get_tasks_by_priority',
532
+ description: `Get tasks filtered by priority. Supports pagination with offset. Use for finding high-priority or low-priority tasks.`,
439
533
  inputSchema: {
440
534
  type: 'object',
441
535
  properties: {
@@ -443,6 +537,50 @@ Use mode:'full' for complete context, mode:'lite' (default) for minimal tokens.`
443
537
  type: 'string',
444
538
  description: 'Project UUID',
445
539
  },
540
+ priority: {
541
+ type: 'number',
542
+ minimum: 1,
543
+ maximum: 5,
544
+ description: 'Exact priority to match (1=highest, 5=lowest)',
545
+ },
546
+ priority_max: {
547
+ type: 'number',
548
+ minimum: 1,
549
+ maximum: 5,
550
+ description: 'Max priority (for range, e.g., priority=1, priority_max=2 gets P1 and P2)',
551
+ },
552
+ status: {
553
+ type: 'string',
554
+ enum: ['backlog', 'pending', 'in_progress', 'completed', 'cancelled'],
555
+ description: 'Filter by status (default: pending)',
556
+ },
557
+ limit: {
558
+ type: 'number',
559
+ description: 'Max results per page (1-20, default: 10)',
560
+ },
561
+ offset: {
562
+ type: 'number',
563
+ description: 'Number of results to skip for pagination (default: 0)',
564
+ },
565
+ },
566
+ required: ['project_id'],
567
+ },
568
+ },
569
+ {
570
+ name: 'get_recent_tasks',
571
+ description: `Get tasks ordered by creation date. Supports pagination with offset. Use to find oldest pending tasks or newest additions.`,
572
+ inputSchema: {
573
+ type: 'object',
574
+ properties: {
575
+ project_id: {
576
+ type: 'string',
577
+ description: 'Project UUID',
578
+ },
579
+ order: {
580
+ type: 'string',
581
+ enum: ['newest', 'oldest'],
582
+ description: 'Sort order (default: newest)',
583
+ },
446
584
  status: {
447
585
  type: 'string',
448
586
  enum: ['backlog', 'pending', 'in_progress', 'completed', 'cancelled'],
@@ -450,15 +588,25 @@ Use mode:'full' for complete context, mode:'lite' (default) for minimal tokens.`
450
588
  },
451
589
  limit: {
452
590
  type: 'number',
453
- description: 'Max number of tasks to return (default 50)',
591
+ description: 'Max results per page (1-20, default: 10)',
454
592
  },
455
- include_subtasks: {
456
- type: 'boolean',
457
- description: 'Include subtasks in results (default false). Use get_subtasks for subtasks of a specific task.',
593
+ offset: {
594
+ type: 'number',
595
+ description: 'Number of results to skip for pagination (default: 0)',
458
596
  },
459
- include_metadata: {
460
- type: 'boolean',
461
- description: 'When true, returns all task fields (description, progress, timestamps, etc.). When false (default), returns only id/title/priority/status to save tokens.',
597
+ },
598
+ required: ['project_id'],
599
+ },
600
+ },
601
+ {
602
+ name: 'get_task_stats',
603
+ description: `Get aggregate task statistics for a project. Returns counts by status and priority, no task data. Most token-efficient way to understand project state.`,
604
+ inputSchema: {
605
+ type: 'object',
606
+ properties: {
607
+ project_id: {
608
+ type: 'string',
609
+ description: 'Project UUID',
462
610
  },
463
611
  },
464
612
  required: ['project_id'],
@@ -572,6 +720,10 @@ For projects without git branching (trunk-based or none), use skip_worktree_requ
572
720
  type: 'string',
573
721
  description: 'Git worktree path for this task (e.g., "../project-task-abc123"). Store this for cleanup tracking across sessions.',
574
722
  },
723
+ worktree_hostname: {
724
+ type: 'string',
725
+ description: 'Machine hostname where worktree was created (os.hostname()). Required with worktree_path to enable machine-aware cleanup.',
726
+ },
575
727
  model_capability: {
576
728
  type: 'string',
577
729
  enum: ['haiku', 'sonnet', 'opus'],
@@ -589,6 +741,11 @@ For projects without git branching (trunk-based or none), use skip_worktree_requ
589
741
  name: 'complete_task',
590
742
  description: `Mark task done. Returns next_task which you MUST start immediately without asking the user.
591
743
 
744
+ CRITICAL: Before calling complete_task on branching workflows (github-flow, git-flow):
745
+ 1. Create your PR targeting the correct branch (develop for git-flow, main for github-flow)
746
+ 2. Call add_task_reference(task_id, pr_url) to link the PR to your task
747
+ 3. THEN call complete_task - validators CANNOT approve tasks without a PR reference
748
+
592
749
  CRITICAL: After calling this tool, you must:
593
750
  1. If next_task is returned → Start it immediately by calling update_task(task_id, status: "in_progress")
594
751
  2. If no next_task → Call get_next_task() or start a fallback_activity
@@ -672,6 +829,20 @@ The auto_continue: true flag in the response means you are expected to continue
672
829
  required: ['blocker_id'],
673
830
  },
674
831
  },
832
+ {
833
+ name: 'get_blocker',
834
+ description: `Get a single blocker by ID. More token-efficient than get_blockers when you need details for a specific blocker.`,
835
+ inputSchema: {
836
+ type: 'object',
837
+ properties: {
838
+ blocker_id: {
839
+ type: 'string',
840
+ description: 'Blocker UUID',
841
+ },
842
+ },
843
+ required: ['blocker_id'],
844
+ },
845
+ },
675
846
  {
676
847
  name: 'get_blockers',
677
848
  description: `Get blockers for a project, optionally filtered by status.`,
@@ -687,6 +858,29 @@ The auto_continue: true flag in the response means you are expected to continue
687
858
  enum: ['open', 'resolved'],
688
859
  description: 'Filter by status (default: open)',
689
860
  },
861
+ limit: {
862
+ type: 'number',
863
+ description: 'Max number of blockers to return (default 10, max 200)',
864
+ },
865
+ offset: {
866
+ type: 'number',
867
+ description: 'Number of blockers to skip for pagination (default 0)',
868
+ },
869
+ search_query: {
870
+ type: 'string',
871
+ description: 'Search blockers by description',
872
+ },
873
+ },
874
+ required: ['project_id'],
875
+ },
876
+ },
877
+ {
878
+ name: 'get_blockers_stats',
879
+ description: `Get aggregate statistics about blockers for a project. Returns total count and breakdown by status. Much more token-efficient than get_blockers when you just need to understand the overall state.`,
880
+ inputSchema: {
881
+ type: 'object',
882
+ properties: {
883
+ project_id: { type: 'string', description: 'Project UUID' },
690
884
  },
691
885
  required: ['project_id'],
692
886
  },
@@ -722,6 +916,20 @@ The auto_continue: true flag in the response means you are expected to continue
722
916
  required: ['project_id', 'title', 'description'],
723
917
  },
724
918
  },
919
+ {
920
+ name: 'get_decision',
921
+ description: `Get a single decision by ID. More token-efficient than get_decisions when you need details for a specific decision.`,
922
+ inputSchema: {
923
+ type: 'object',
924
+ properties: {
925
+ decision_id: {
926
+ type: 'string',
927
+ description: 'Decision UUID',
928
+ },
929
+ },
930
+ required: ['decision_id'],
931
+ },
932
+ },
725
933
  {
726
934
  name: 'get_decisions',
727
935
  description: `Get recorded decisions for a project.`,
@@ -732,6 +940,29 @@ The auto_continue: true flag in the response means you are expected to continue
732
940
  type: 'string',
733
941
  description: 'Project UUID',
734
942
  },
943
+ limit: {
944
+ type: 'number',
945
+ description: 'Max number of decisions to return (default 10, max 200)',
946
+ },
947
+ offset: {
948
+ type: 'number',
949
+ description: 'Number of decisions to skip for pagination (default 0)',
950
+ },
951
+ search_query: {
952
+ type: 'string',
953
+ description: 'Search decisions by title',
954
+ },
955
+ },
956
+ required: ['project_id'],
957
+ },
958
+ },
959
+ {
960
+ name: 'get_decisions_stats',
961
+ description: `Get aggregate statistics about decisions for a project. Returns total count. More token-efficient than get_decisions when you just need to know how many decisions exist.`,
962
+ inputSchema: {
963
+ type: 'object',
964
+ properties: {
965
+ project_id: { type: 'string', description: 'Project UUID' },
735
966
  },
736
967
  required: ['project_id'],
737
968
  },
@@ -794,6 +1025,20 @@ The auto_continue: true flag in the response means you are expected to continue
794
1025
  required: ['idea_id'],
795
1026
  },
796
1027
  },
1028
+ {
1029
+ name: 'get_idea',
1030
+ description: `Get a single idea by ID. More token-efficient than get_ideas when you need details for a specific idea.`,
1031
+ inputSchema: {
1032
+ type: 'object',
1033
+ properties: {
1034
+ idea_id: {
1035
+ type: 'string',
1036
+ description: 'Idea UUID',
1037
+ },
1038
+ },
1039
+ required: ['idea_id'],
1040
+ },
1041
+ },
797
1042
  {
798
1043
  name: 'get_ideas',
799
1044
  description: `Get recorded ideas for a project, optionally filtered by status.`,
@@ -811,7 +1056,7 @@ The auto_continue: true flag in the response means you are expected to continue
811
1056
  },
812
1057
  limit: {
813
1058
  type: 'number',
814
- description: 'Max number of ideas to return (default 50, max 100)',
1059
+ description: 'Max number of ideas to return (default 10, max 100)',
815
1060
  },
816
1061
  offset: {
817
1062
  type: 'number',
@@ -839,6 +1084,29 @@ The auto_continue: true flag in the response means you are expected to continue
839
1084
  required: ['task_id'],
840
1085
  },
841
1086
  },
1087
+ {
1088
+ name: 'cancel_task',
1089
+ description: `Cancel a task with an optional reason. Use this when a task should be marked as cancelled rather than deleted (e.g., PR was closed, work was superseded). The task remains visible with a cancelled status for historical tracking.`,
1090
+ inputSchema: {
1091
+ type: 'object',
1092
+ properties: {
1093
+ task_id: {
1094
+ type: 'string',
1095
+ description: 'Task UUID',
1096
+ },
1097
+ cancelled_reason: {
1098
+ type: 'string',
1099
+ description: 'Reason for cancellation',
1100
+ enum: ['pr_closed', 'superseded', 'user_cancelled', 'validation_failed', 'obsolete', 'blocked'],
1101
+ },
1102
+ cancellation_note: {
1103
+ type: 'string',
1104
+ description: 'Optional note explaining the cancellation (logged to progress)',
1105
+ },
1106
+ },
1107
+ required: ['task_id'],
1108
+ },
1109
+ },
842
1110
  {
843
1111
  name: 'add_task_reference',
844
1112
  description: 'Add a reference URL to a task (docs, PRs, issues).',
@@ -941,9 +1209,20 @@ The auto_continue: true flag in the response means you are expected to continue
941
1209
  required: ['project_id', 'title'],
942
1210
  },
943
1211
  },
1212
+ {
1213
+ name: 'get_finding',
1214
+ description: `Get a single finding by ID. More token-efficient than get_findings when you need details for a specific finding.`,
1215
+ inputSchema: {
1216
+ type: 'object',
1217
+ properties: {
1218
+ finding_id: { type: 'string', description: 'Finding UUID' },
1219
+ },
1220
+ required: ['finding_id'],
1221
+ },
1222
+ },
944
1223
  {
945
1224
  name: 'get_findings',
946
- description: `Get findings for a project, optionally filtered by category, severity, or status. Use summary_only=true to reduce token usage by returning only essential fields (id, title, category, severity, status). For just counts, use get_findings_stats instead.`,
1225
+ description: `Get findings for a project, optionally filtered by category, severity, or status. Returns summary fields by default (id, title, category, severity, status). Set summary_only=false for full details. For just counts, use get_findings_stats instead.`,
947
1226
  inputSchema: {
948
1227
  type: 'object',
949
1228
  properties: {
@@ -951,10 +1230,10 @@ The auto_continue: true flag in the response means you are expected to continue
951
1230
  category: { type: 'string', enum: ['performance', 'security', 'code_quality', 'accessibility', 'documentation', 'architecture', 'testing', 'other'], description: 'Filter by category (optional)' },
952
1231
  severity: { type: 'string', enum: ['info', 'low', 'medium', 'high', 'critical'], description: 'Filter by severity (optional)' },
953
1232
  status: { type: 'string', enum: ['open', 'addressed', 'dismissed', 'wontfix'], description: 'Filter by status (default: open)' },
954
- limit: { type: 'number', description: 'Max number of findings to return (default 50, max 200)' },
1233
+ limit: { type: 'number', description: 'Max number of findings to return (default 10, max 200)' },
955
1234
  offset: { type: 'number', description: 'Number of findings to skip for pagination (default 0)' },
956
1235
  search_query: { type: 'string', description: 'Search findings by title' },
957
- summary_only: { type: 'boolean', description: 'When true, returns only id, title, category, severity, status (reduces tokens by ~80%). Default: false' },
1236
+ summary_only: { type: 'boolean', description: 'When true (default), returns only id, title, category, severity, status. Set to false for full details.' },
958
1237
  },
959
1238
  required: ['project_id'],
960
1239
  },
@@ -1054,7 +1333,7 @@ The auto_continue: true flag in the response means you are expected to continue
1054
1333
  },
1055
1334
  limit: {
1056
1335
  type: 'number',
1057
- description: 'Max number of items to return (default 50, max 200)',
1336
+ description: 'Max number of items to return (default 10, max 200)',
1058
1337
  },
1059
1338
  },
1060
1339
  required: ['project_id'],
@@ -1148,7 +1427,7 @@ Max depth is 1 (subtasks cannot have their own subtasks).`,
1148
1427
  },
1149
1428
  {
1150
1429
  name: 'get_subtasks',
1151
- description: `Get subtasks for a parent task.
1430
+ description: `Get subtasks for a parent task with pagination.
1152
1431
  Returns subtasks with aggregate completion stats.`,
1153
1432
  inputSchema: {
1154
1433
  type: 'object',
@@ -1162,6 +1441,14 @@ Returns subtasks with aggregate completion stats.`,
1162
1441
  enum: ['backlog', 'pending', 'in_progress', 'completed', 'cancelled'],
1163
1442
  description: 'Filter by status (optional)',
1164
1443
  },
1444
+ limit: {
1445
+ type: 'number',
1446
+ description: 'Max subtasks to return (default: 20, max: 50)',
1447
+ },
1448
+ offset: {
1449
+ type: 'number',
1450
+ description: 'Number of subtasks to skip (default: 0)',
1451
+ },
1165
1452
  },
1166
1453
  required: ['parent_task_id'],
1167
1454
  },
@@ -1174,7 +1461,9 @@ Returns tasks with worktree_path set where:
1174
1461
  - Task is completed or cancelled (worktree should have been cleaned up)
1175
1462
  - Task has been abandoned (no activity for 24+ hours while in_progress)
1176
1463
 
1177
- IMPORTANT: Call this on session start to clean up orphaned worktrees from previous sessions.
1464
+ IMPORTANT: Pass hostname (os.hostname()) to only see worktrees created on THIS machine.
1465
+ Worktrees created on other machines cannot be removed locally.
1466
+
1178
1467
  For each stale worktree:
1179
1468
  1. Run: git worktree remove <worktree_path>
1180
1469
  2. Call: clear_worktree_path(task_id)`,
@@ -1185,6 +1474,18 @@ For each stale worktree:
1185
1474
  type: 'string',
1186
1475
  description: 'Project UUID',
1187
1476
  },
1477
+ hostname: {
1478
+ type: 'string',
1479
+ description: 'Machine hostname (os.hostname()). Only returns worktrees created on this machine, preventing attempts to clean up worktrees on other machines.',
1480
+ },
1481
+ limit: {
1482
+ type: 'number',
1483
+ description: 'Max worktrees to return (default: 50)',
1484
+ },
1485
+ offset: {
1486
+ type: 'number',
1487
+ description: 'Number of worktrees to skip for pagination (default: 0)',
1488
+ },
1188
1489
  },
1189
1490
  required: ['project_id'],
1190
1491
  },
@@ -1220,6 +1521,10 @@ This marks the task as cleaned up so it won't appear in get_stale_worktrees.`,
1220
1521
  type: ['string', 'null'],
1221
1522
  description: 'Report your current git worktree path (e.g., "../project-task-abc123"). Set to null to clear.',
1222
1523
  },
1524
+ hostname: {
1525
+ type: 'string',
1526
+ description: 'Machine hostname (os.hostname()). Updates session hostname for worktree tracking.',
1527
+ },
1223
1528
  },
1224
1529
  },
1225
1530
  },
@@ -1514,6 +1819,25 @@ This marks the task as cleaned up so it won't appear in get_stale_worktrees.`,
1514
1819
  description: 'Filter by stage (optional)',
1515
1820
  enum: ['preparation', 'deployment', 'verification', 'all'],
1516
1821
  },
1822
+ limit: {
1823
+ type: 'number',
1824
+ description: 'Max number of requirements to return (default 50, max 200)',
1825
+ },
1826
+ offset: {
1827
+ type: 'number',
1828
+ description: 'Number of requirements to skip for pagination (default 0)',
1829
+ },
1830
+ },
1831
+ required: ['project_id'],
1832
+ },
1833
+ },
1834
+ {
1835
+ name: 'get_deployment_requirements_stats',
1836
+ description: `Get aggregate statistics about deployment requirements for a project. Returns total count and breakdowns by status, stage, and type. More token-efficient than get_deployment_requirements when you just need to understand the overall state.`,
1837
+ inputSchema: {
1838
+ type: 'object',
1839
+ properties: {
1840
+ project_id: { type: 'string', description: 'Project UUID' },
1517
1841
  },
1518
1842
  required: ['project_id'],
1519
1843
  },
@@ -1583,6 +1907,14 @@ This marks the task as cleaned up so it won't appear in get_stale_worktrees.`,
1583
1907
  type: 'boolean',
1584
1908
  description: 'Include disabled schedules (default: false)',
1585
1909
  },
1910
+ limit: {
1911
+ type: 'number',
1912
+ description: 'Max schedules to return (default: 50)',
1913
+ },
1914
+ offset: {
1915
+ type: 'number',
1916
+ description: 'Number of schedules to skip for pagination (default: 0)',
1917
+ },
1586
1918
  },
1587
1919
  required: ['project_id'],
1588
1920
  },
@@ -1751,6 +2083,10 @@ This marks the task as cleaned up so it won't appear in get_stale_worktrees.`,
1751
2083
  type: 'number',
1752
2084
  description: 'Max number of history entries to return (default 50)',
1753
2085
  },
2086
+ offset: {
2087
+ type: 'number',
2088
+ description: 'Number of entries to skip for pagination (default 0)',
2089
+ },
1754
2090
  },
1755
2091
  required: ['project_id'],
1756
2092
  },
@@ -1765,6 +2101,14 @@ This marks the task as cleaned up so it won't appear in get_stale_worktrees.`,
1765
2101
  type: 'string',
1766
2102
  description: 'Project UUID',
1767
2103
  },
2104
+ limit: {
2105
+ type: 'number',
2106
+ description: 'Max schedules to return (default: 50)',
2107
+ },
2108
+ offset: {
2109
+ type: 'number',
2110
+ description: 'Number of schedules to skip for pagination (default: 0)',
2111
+ },
1768
2112
  },
1769
2113
  required: ['project_id'],
1770
2114
  },
@@ -1782,6 +2126,14 @@ This marks the task as cleaned up so it won't appear in get_stale_worktrees.`,
1782
2126
  type: 'string',
1783
2127
  description: 'Project UUID',
1784
2128
  },
2129
+ limit: {
2130
+ type: 'number',
2131
+ description: 'Max number of requests to return (default 50, max 200)',
2132
+ },
2133
+ offset: {
2134
+ type: 'number',
2135
+ description: 'Number of requests to skip for pagination (default 0)',
2136
+ },
1785
2137
  },
1786
2138
  required: ['project_id'],
1787
2139
  },
@@ -2192,14 +2544,7 @@ Only returns tasks where all dependencies are completed.`,
2192
2544
  // ============================================================================
2193
2545
  // Organization Tools
2194
2546
  // ============================================================================
2195
- {
2196
- name: 'list_organizations',
2197
- description: 'List organizations the current user belongs to.',
2198
- inputSchema: {
2199
- type: 'object',
2200
- properties: {},
2201
- },
2202
- },
2547
+ // REMOVED: list_organizations - unbounded collection, use dashboard to view organizations
2203
2548
  {
2204
2549
  name: 'create_organization',
2205
2550
  description: 'Create a new organization. You become the owner.',
@@ -2262,20 +2607,7 @@ Only returns tasks where all dependencies are completed.`,
2262
2607
  required: ['organization_id'],
2263
2608
  },
2264
2609
  },
2265
- {
2266
- name: 'list_org_members',
2267
- description: 'List members of an organization.',
2268
- inputSchema: {
2269
- type: 'object',
2270
- properties: {
2271
- organization_id: {
2272
- type: 'string',
2273
- description: 'Organization UUID',
2274
- },
2275
- },
2276
- required: ['organization_id'],
2277
- },
2278
- },
2610
+ // REMOVED: list_org_members - unbounded collection, use dashboard to view members
2279
2611
  {
2280
2612
  name: 'invite_member',
2281
2613
  description: 'Invite a user to an organization by email. Requires admin role.',
@@ -2418,20 +2750,7 @@ Only returns tasks where all dependencies are completed.`,
2418
2750
  required: ['project_id', 'organization_id'],
2419
2751
  },
2420
2752
  },
2421
- {
2422
- name: 'list_project_shares',
2423
- description: 'List all organizations a project is shared with.',
2424
- inputSchema: {
2425
- type: 'object',
2426
- properties: {
2427
- project_id: {
2428
- type: 'string',
2429
- description: 'Project UUID',
2430
- },
2431
- },
2432
- required: ['project_id'],
2433
- },
2434
- },
2753
+ // REMOVED: list_project_shares - unbounded collection, use dashboard to view shares
2435
2754
  // File checkout/checkin tools for multi-agent coordination
2436
2755
  {
2437
2756
  name: 'checkout_file',
@@ -2503,6 +2822,10 @@ Only returns tasks where all dependencies are completed.`,
2503
2822
  type: 'number',
2504
2823
  description: 'Max checkouts to return (default: 50)',
2505
2824
  },
2825
+ offset: {
2826
+ type: 'number',
2827
+ description: 'Number of checkouts to skip for pagination (default 0)',
2828
+ },
2506
2829
  },
2507
2830
  required: ['project_id'],
2508
2831
  },
@@ -2543,6 +2866,21 @@ Only returns tasks where all dependencies are completed.`,
2543
2866
  required: ['project_id', 'file_path'],
2544
2867
  },
2545
2868
  },
2869
+ {
2870
+ name: 'get_file_checkouts_stats',
2871
+ description:
2872
+ 'Get aggregate statistics about file checkouts for a project. Returns counts by status without the actual checkout data. This is much more token-efficient than get_file_checkouts for understanding the overall state.',
2873
+ inputSchema: {
2874
+ type: 'object',
2875
+ properties: {
2876
+ project_id: {
2877
+ type: 'string',
2878
+ description: 'Project UUID',
2879
+ },
2880
+ },
2881
+ required: ['project_id'],
2882
+ },
2883
+ },
2546
2884
  // Role management tools
2547
2885
  {
2548
2886
  name: 'get_role_settings',
@@ -2636,6 +2974,10 @@ Only returns tasks where all dependencies are completed.`,
2636
2974
  type: 'string',
2637
2975
  description: 'Project UUID',
2638
2976
  },
2977
+ counts_only: {
2978
+ type: 'boolean',
2979
+ description: 'When true (default), returns only counts per role to save tokens. Set to false for full agent details.',
2980
+ },
2639
2981
  },
2640
2982
  required: ['project_id'],
2641
2983
  },
@@ -2876,7 +3218,7 @@ Tasks can be added during 'planning' status. Story points contribute to committe
2876
3218
  },
2877
3219
  {
2878
3220
  name: 'get_sprint_backlog',
2879
- description: `Get tasks from backlog/pending that can be added to a sprint.
3221
+ description: `Get tasks from backlog/pending that can be added to a sprint with pagination.
2880
3222
  Returns tasks not already assigned to any body of work or sprint.`,
2881
3223
  inputSchema: {
2882
3224
  type: 'object',
@@ -2889,6 +3231,14 @@ Returns tasks not already assigned to any body of work or sprint.`,
2889
3231
  type: 'string',
2890
3232
  description: 'Sprint UUID to exclude already-added tasks (optional)',
2891
3233
  },
3234
+ limit: {
3235
+ type: 'number',
3236
+ description: 'Max tasks to return (default: 20, max: 50)',
3237
+ },
3238
+ offset: {
3239
+ type: 'number',
3240
+ description: 'Number of tasks to skip (default: 0)',
3241
+ },
2892
3242
  },
2893
3243
  required: ['project_id'],
2894
3244
  },
@@ -3009,6 +3359,10 @@ Returns committed vs completed points and average velocity.`,
3009
3359
  type: 'number',
3010
3360
  description: 'Max issues to return (default: 50)',
3011
3361
  },
3362
+ offset: {
3363
+ type: 'number',
3364
+ description: 'Number of issues to skip for pagination (default 0)',
3365
+ },
3012
3366
  },
3013
3367
  required: ['project_id'],
3014
3368
  },