Skip to content

:hedgehog: PostHog is the leading platform for building self-driving products. Our developer tools – AI observability, analytics, session replay, flags, experiments, error tracking, logs, and more – capture all the context agents need to diagnose problems, uncover opportunities, and ship fixes. Steer it all from Slack, web, desktop, or the MCP.

chore(signals): fold self-driving-inbox-get into inbox-reports-list (#95362)

posthog[bot]c7d6f1359e9a
diff --git a/products/signals/mcp/tools.yaml b/products/signals/mcp/tools.yaml
index cbae2991e22c..4968b69ec127 100644
--- a/products/signals/mcp/tools.yaml
+++ b/products/signals/mcp/tools.yaml
@@ -176,10 +176,20 @@ tools:
are still moving through the pipeline, and `pending_input` reports are waiting on a human. Each report's
full work log, including signal findings, judgments, and log entries, is readable via
inbox-report-artefacts-list; read it before acting on a report. Results are paginated and ordered by
- '-is_suggested_reviewer,status,-updated_at' by default. To find the self-driving reports for one source
- record — e.g. what the inbox already investigated for a specific support ticket — pass that record's id as
- `source_id` together with exactly one `source_product` (for a support ticket: `source_product=conversations`
- and the ticket's UUID as `source_id`); add `include_all_statuses=true` to include dismissed ones.
+ '-is_suggested_reviewer,status,-updated_at' by default. To answer "what should I look at next", pass
+ `view=actionable` with `use_priority_preference=true`, `sort=priority`, and `limit=10`: that returns ready,
+ actionable reports that have no implementation PR yet, at or above the requesting user's personal
+ PR-generation threshold, falling back to the project threshold. `use_priority_preference` selects which
+ priorities to include, and does not order them, so pass `sort=priority` to put P0 first; the default
+ ordering can put a recently updated P4 above an older P0. Without `limit` a page holds up to 100 reports,
+ each with its summary. The other views are `needs_input` (waiting on a human), `monitoring` (an
+ implementation PR is open), `resolved`, `dismissed`, `not_actionable`, and `all`. Narrow by reviewer with
+ `scope=for_me`, or `scope=teammate` plus `teammate_uuid`; the default `scope=entire_project` searches every
+ report. `priority`, `source_product`, and `scout` each take a comma-separated list. To find the self-driving
+ reports for one source record — e.g. what the inbox already investigated for a specific support ticket —
+ pass that record's id as `source_id` together with exactly one `source_product` (for a support ticket:
+ `source_product=conversations` and the ticket's UUID as `source_id`); add `include_all_statuses=true` to
+ include dismissed ones.
agent_note: >
You may inspect reports without claiming them. A claim indicates active work that should not be duplicated.
Before claiming a report, read the report and its work log. If you decide to begin working to fix the issues
@@ -204,6 +214,7 @@ tools:
- signal_count
- total_weight
- source_products
+ - scout_name
- is_suggested_reviewer
- implementation_pr_url
- implementation_pr_state
@@ -898,46 +909,6 @@ tools:
`keys_only=true` to scan which memories exist without pulling their (potentially large) bodies, or
`content_max_chars` to cap each `content` to a preview — both keep a wide orientation/dedupe scan from
returning every entry's full prose. Results capped at 1000.
- self-driving-inbox-get:
- operation: signals_reports_list
- enabled: true
- scopes:
- - task:read
- annotations:
- readOnly: true
- destructive: false
- idempotent: true
- input_schema: ReportInboxInputSchema
- enrich_url: '{id}'
- list: true
- title: Get self-driving inbox
- description: >
- Get the top 10 prioritized, actionable self-driving reports for the current project, including their
- summaries. By default this uses the requesting user's personal PR-generation threshold, falling back to the
- project threshold. Choose another view for reports needing human input, implementation PRs being monitored,
- resolved or dismissed reports, or reports judged not actionable. Filter by reviewer scope, priority, source
- product, scout, or text search, and use offset to page through further results. Use
- inbox-report-artefacts-list to read a report's evidence and work log before acting on it.
- response:
- include:
- - id
- - title
- - summary
- - status
- - priority
- - actionability
- - already_addressed
- - dismissal_reason
- - dismissal_note
- - signal_count
- - total_weight
- - source_products
- - scout_name
- - is_suggested_reviewer
- - implementation_pr_url
- - implementation_pr_merged
- - created_at
- - updated_at
signals-report-artefacts-diff:
operation: signals_report_artefacts_diff
enabled: false
diff --git a/services/mcp/schema/generated-tool-definitions.json b/services/mcp/schema/generated-tool-definitions.json
index cf6c182ba27c..203ee2c6a938 100644
--- a/services/mcp/schema/generated-tool-definitions.json
+++ b/services/mcp/schema/generated-tool-definitions.json
@@ -5724,7 +5724,7 @@
}
},
"inbox-reports-list": {
- "description": "List signal reports for the current project. A signal report is a cluster of related observations (signals) that PostHog has aggregated into a single issue or trend. Reports surface in the Inbox. Supports filtering by status (potential, candidate, in_progress, pending_input, ready, resolved, failed, suppressed), free-text search across title and summary, source_product (e.g. error_tracking, session_replay), suggested_reviewers, `unclaimed`, and `assignee=me`. Claimed reports remain actionable and visible; use `unclaimed=true` to pick work that has no owner and no draft, open, or unknown PR. Some statuses are hidden by default (currently suppressed, i.e. human-dismissed); pass `include_all_statuses=true` to list reports in every status. Do this when deduplicating against the full inbox state, and read each row's `status` (plus `dismissal_reason` / `dismissal_note` on dismissed rows) before acting. For picking up work, filter to `ready` — earlier statuses are still moving through the pipeline, and `pending_input` reports are waiting on a human. Each report's full work log, including signal findings, judgments, and log entries, is readable via inbox-report-artefacts-list; read it before acting on a report. Results are paginated and ordered by '-is_suggested_reviewer,status,-updated_at' by default. To find the self-driving reports for one source record — e.g. what the inbox already investigated for a specific support ticket — pass that record's id as `source_id` together with exactly one `source_product` (for a support ticket: `source_product=conversations` and the ticket's UUID as `source_id`); add `include_all_statuses=true` to include dismissed ones.",
+ "description": "List signal reports for the current project. A signal report is a cluster of related observations (signals) that PostHog has aggregated into a single issue or trend. Reports surface in the Inbox. Supports filtering by status (potential, candidate, in_progress, pending_input, ready, resolved, failed, suppressed), free-text search across title and summary, source_product (e.g. error_tracking, session_replay), suggested_reviewers, `unclaimed`, and `assignee=me`. Claimed reports remain actionable and visible; use `unclaimed=true` to pick work that has no owner and no draft, open, or unknown PR. Some statuses are hidden by default (currently suppressed, i.e. human-dismissed); pass `include_all_statuses=true` to list reports in every status. Do this when deduplicating against the full inbox state, and read each row's `status` (plus `dismissal_reason` / `dismissal_note` on dismissed rows) before acting. For picking up work, filter to `ready` — earlier statuses are still moving through the pipeline, and `pending_input` reports are waiting on a human. Each report's full work log, including signal findings, judgments, and log entries, is readable via inbox-report-artefacts-list; read it before acting on a report. Results are paginated and ordered by '-is_suggested_reviewer,status,-updated_at' by default. To answer \"what should I look at next\", pass `view=actionable` with `use_priority_preference=true`, `sort=priority`, and `limit=10`: that returns ready, actionable reports that have no implementation PR yet, at or above the requesting user's personal PR-generation threshold, falling back to the project threshold. `use_priority_preference` selects which priorities to include, and does not order them, so pass `sort=priority` to put P0 first; the default ordering can put a recently updated P4 above an older P0. Without `limit` a page holds up to 100 reports, each with its summary. The other views are `needs_input` (waiting on a human), `monitoring` (an implementation PR is open), `resolved`, `dismissed`, `not_actionable`, and `all`. Narrow by reviewer with `scope=for_me`, or `scope=teammate` plus `teammate_uuid`; the default `scope=entire_project` searches every report. `priority`, `source_product`, and `scout` each take a comma-separated list. To find the self-driving reports for one source record — e.g. what the inbox already investigated for a specific support ticket — pass that record's id as `source_id` together with exactly one `source_product` (for a support ticket: `source_product=conversations` and the ticket's UUID as `source_id`); add `include_all_statuses=true` to include dismissed ones.",
"category": "Signals",
"feature": "signals",
"summary": "List signal reports",
@@ -9823,20 +9823,6 @@
"readOnlyHint": true
}
},
- "self-driving-inbox-get": {
- "description": "Get the top 10 prioritized, actionable self-driving reports for the current project, including their summaries. By default this uses the requesting user's personal PR-generation threshold, falling back to the project threshold. Choose another view for reports needing human input, implementation PRs being monitored, resolved or dismissed reports, or reports judged not actionable. Filter by reviewer scope, priority, source product, scout, or text search, and use offset to page through further results. Use inbox-report-artefacts-list to read a report's evidence and work log before acting on it.",
- "category": "Signals",
- "feature": "signals",
- "summary": "Get self-driving inbox",
- "title": "Get self-driving inbox",
- "required_scopes": ["task:read"],
- "annotations": {
- "destructiveHint": false,
- "idempotentHint": true,
- "openWorldHint": true,
- "readOnlyHint": true
- }
- },
"session-recording-bulk-delete": {
"description": "Delete a batch of session recordings by session ID, up to 100 per call. Deletion is permanent and cannot be undone — confirm with the user before deleting. Prefer this over `session-recording-delete` whenever more than one recording needs deleting: find the target IDs with `query-session-recordings-list`, then delete in batches. Pass `date_from` (e.g. '-30d') when the recordings' age is known — it makes the lookup much faster. IDs with no matching recording are skipped, so a `deleted_count` below `total_requested` is normal when some recordings were already deleted or never existed.",
"category": "Session replays",
diff --git a/services/mcp/schema/tool-definitions-all.json b/services/mcp/schema/tool-definitions-all.json
index 56c58347c8ee..bb73d8ddeec6 100644
--- a/services/mcp/schema/tool-definitions-all.json
+++ b/services/mcp/schema/tool-definitions-all.json
@@ -5921,7 +5921,7 @@
}
},
"inbox-reports-list": {
- "description": "List signal reports for the current project. A signal report is a cluster of related observations (signals) that PostHog has aggregated into a single issue or trend. Reports surface in the Inbox. Supports filtering by status (potential, candidate, in_progress, pending_input, ready, resolved, failed, suppressed), free-text search across title and summary, source_product (e.g. error_tracking, session_replay), suggested_reviewers, `unclaimed`, and `assignee=me`. Claimed reports remain actionable and visible; use `unclaimed=true` to pick work that has no owner and no draft, open, or unknown PR. Some statuses are hidden by default (currently suppressed, i.e. human-dismissed); pass `include_all_statuses=true` to list reports in every status. Do this when deduplicating against the full inbox state, and read each row's `status` (plus `dismissal_reason` / `dismissal_note` on dismissed rows) before acting. For picking up work, filter to `ready` — earlier statuses are still moving through the pipeline, and `pending_input` reports are waiting on a human. Each report's full work log, including signal findings, judgments, and log entries, is readable via inbox-report-artefacts-list; read it before acting on a report. Results are paginated and ordered by '-is_suggested_reviewer,status,-updated_at' by default. To find the self-driving reports for one source record — e.g. what the inbox already investigated for a specific support ticket — pass that record's id as `source_id` together with exactly one `source_product` (for a support ticket: `source_product=conversations` and the ticket's UUID as `source_id`); add `include_all_statuses=true` to include dismissed ones.",
+ "description": "List signal reports for the current project. A signal report is a cluster of related observations (signals) that PostHog has aggregated into a single issue or trend. Reports surface in the Inbox. Supports filtering by status (potential, candidate, in_progress, pending_input, ready, resolved, failed, suppressed), free-text search across title and summary, source_product (e.g. error_tracking, session_replay), suggested_reviewers, `unclaimed`, and `assignee=me`. Claimed reports remain actionable and visible; use `unclaimed=true` to pick work that has no owner and no draft, open, or unknown PR. Some statuses are hidden by default (currently suppressed, i.e. human-dismissed); pass `include_all_statuses=true` to list reports in every status. Do this when deduplicating against the full inbox state, and read each row's `status` (plus `dismissal_reason` / `dismissal_note` on dismissed rows) before acting. For picking up work, filter to `ready` — earlier statuses are still moving through the pipeline, and `pending_input` reports are waiting on a human. Each report's full work log, including signal findings, judgments, and log entries, is readable via inbox-report-artefacts-list; read it before acting on a report. Results are paginated and ordered by '-is_suggested_reviewer,status,-updated_at' by default. To answer \"what should I look at next\", pass `view=actionable` with `use_priority_preference=true`, `sort=priority`, and `limit=10`: that returns ready, actionable reports that have no implementation PR yet, at or above the requesting user's personal PR-generation threshold, falling back to the project threshold. `use_priority_preference` selects which priorities to include, and does not order them, so pass `sort=priority` to put P0 first; the default ordering can put a recently updated P4 above an older P0. Without `limit` a page holds up to 100 reports, each with its summary. The other views are `needs_input` (waiting on a human), `monitoring` (an implementation PR is open), `resolved`, `dismissed`, `not_actionable`, and `all`. Narrow by reviewer with `scope=for_me`, or `scope=teammate` plus `teammate_uuid`; the default `scope=entire_project` searches every report. `priority`, `source_product`, and `scout` each take a comma-separated list. To find the self-driving reports for one source record — e.g. what the inbox already investigated for a specific support ticket — pass that record's id as `source_id` together with exactly one `source_product` (for a support ticket: `source_product=conversations` and the ticket's UUID as `source_id`); add `include_all_statuses=true` to include dismissed ones.",
"category": "Signals",
"feature": "signals",
"summary": "List signal reports",
@@ -10395,20 +10395,6 @@
"readOnlyHint": true
}
},
- "self-driving-inbox-get": {
- "description": "Get the top 10 prioritized, actionable self-driving reports for the current project, including their summaries. By default this uses the requesting user's personal PR-generation threshold, falling back to the project threshold. Choose another view for reports needing human input, implementation PRs being monitored, resolved or dismissed reports, or reports judged not actionable. Filter by reviewer scope, priority, source product, scout, or text search, and use offset to page through further results. Use inbox-report-artefacts-list to read a report's evidence and work log before acting on it.",
- "category": "Signals",
- "feature": "signals",
- "summary": "Get self-driving inbox",
- "title": "Get self-driving inbox",
- "required_scopes": ["task:read"],
- "annotations": {
- "destructiveHint": false,
- "idempotentHint": true,
- "openWorldHint": true,
- "readOnlyHint": true
- }
- },
"session-recording-bulk-delete": {
"description": "Delete a batch of session recordings by session ID, up to 100 per call. Deletion is permanent and cannot be undone — confirm with the user before deleting. Prefer this over `session-recording-delete` whenever more than one recording needs deleting: find the target IDs with `query-session-recordings-list`, then delete in batches. Pass `date_from` (e.g. '-30d') when the recordings' age is known — it makes the lookup much faster. IDs with no matching recording are skipped, so a `deleted_count` below `total_requested` is normal when some recordings were already deleted or never existed.",
"category": "Session replays",
diff --git a/services/mcp/schema/tool-inputs.json b/services/mcp/schema/tool-inputs.json
index f2f57eecd1af..71d2c91e3350 100644
--- a/services/mcp/schema/tool-inputs.json
+++ b/services/mcp/schema/tool-inputs.json
@@ -1118,78 +1118,6 @@
},
"required": ["query"]
},
- "ReportInboxInputSchema": {
- "type": "object",
- "properties": {
- "view": {
- "default": "actionable",
- "description": "Inbox section to return. Defaults to actionable reports that are ready to pick up.",
- "type": "string",
- "enum": [
- "actionable",
- "needs_input",
- "monitoring",
- "resolved",
- "dismissed",
- "not_actionable",
- "all"
- ]
- },
- "scope": {
- "default": "entire_project",
- "description": "Limit results by suggested reviewer, or search the entire project.",
- "type": "string",
- "enum": ["for_me", "entire_project", "teammate"]
- },
- "teammate_uuid": {
- "description": "PostHog user UUID required when scope is teammate.",
- "type": "string",
- "format": "uuid",
- "pattern": "^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"
- },
- "priorities": {
- "description": "Priorities to include. When omitted, uses the requesting user's personal PR-generation threshold, falling back to the project threshold.",
- "type": "array",
- "items": {
- "type": "string",
- "enum": ["P0", "P1", "P2", "P3", "P4"]
- }
- },
- "source_products": {
- "type": "array",
- "items": {
- "type": "string"
- }
- },
- "scouts": {
- "description": "Scout skill_name slugs to include.",
- "type": "array",
- "items": {
- "type": "string"
- }
- },
- "search": {
- "description": "Case-insensitive substring match against report title and summary.",
- "type": "string"
- },
- "sort": {
- "default": "priority",
- "type": "string",
- "enum": ["priority", "last_updated", "newest", "oldest"]
- },
- "limit": {
- "default": 10,
- "type": "integer",
- "minimum": 1,
- "maximum": 10
- },
- "offset": {
- "type": "integer",
- "minimum": 0,
- "maximum": 9007199254740991
- }
- }
- },
"SavedMetricsAttachSchema": {
"type": "array",
"items": {
diff --git a/services/mcp/src/schema/tool-inputs.ts b/services/mcp/src/schema/tool-inputs.ts
index 78a5bcf21ce1..2390359655df 100644
--- a/services/mcp/src/schema/tool-inputs.ts
+++ b/services/mcp/src/schema/tool-inputs.ts
@@ -215,43 +215,6 @@ export const PromptListInputSchema = z.object({
),
})
-export const ReportInboxInputSchema = z
- .object({
- view: z
- .enum(['actionable', 'needs_input', 'monitoring', 'resolved', 'dismissed', 'not_actionable', 'all'])
- .default('actionable')
- .describe('Inbox section to return. Defaults to actionable reports that are ready to pick up.'),
- scope: z
- .enum(['for_me', 'entire_project', 'teammate'])
- .default('entire_project')
- .describe('Limit results by suggested reviewer, or search the entire project.'),
- teammate_uuid: z.string().uuid().optional().describe('PostHog user UUID required when scope is teammate.'),
- priorities: z
- .array(z.enum(['P0', 'P1', 'P2', 'P3', 'P4']))
- .optional()
- .describe(
- "Priorities to include. When omitted, uses the requesting user's personal PR-generation threshold, falling back to the project threshold."
- ),
- source_products: z.array(z.string()).optional(),
- scouts: z.array(z.string()).optional().describe('Scout skill_name slugs to include.'),
- search: z.string().optional().describe('Case-insensitive substring match against report title and summary.'),
- sort: z.enum(['priority', 'last_updated', 'newest', 'oldest']).default('priority'),
- limit: z.number().int().min(1).max(10).default(10),
- offset: z.number().int().min(0).optional(),
- })
- .superRefine((data, context) => {
- if (data.scope === 'teammate' && !data.teammate_uuid) {
- context.addIssue({ code: 'custom', path: ['teammate_uuid'], message: 'Required when scope is teammate.' })
- }
- })
- .transform(({ priorities, source_products, scouts, ...query }) => ({
- ...query,
- priority: priorities?.join(','),
- use_priority_preference: priorities === undefined ? true : undefined,
- source_product: source_products?.join(','),
- scout: scouts?.join(','),
- }))
-
export const FeedbackSubmitSchema = z
.object({
summary: z
diff --git a/services/mcp/src/tools/exec.ts b/services/mcp/src/tools/exec.ts
index bca486cafc96..f45adbd85eb3 100644
--- a/services/mcp/src/tools/exec.ts
+++ b/services/mcp/src/tools/exec.ts
@@ -460,6 +460,12 @@ const DEPRECATED_TOOL_REDIRECTS: Record<string, (allTools: Tool<ZodObjectAny>[])
.join('\n')
return `Tool "query-run" was removed. Pick the typed query tool that matches your intent, or use "execute-sql" for arbitrary HogQL. Available query-* tools:\n${queryTools}`
},
+ // Folded into "inbox-reports-list", which already served the same endpoint.
+ // Spell out the filter renames: the replacement declares no required
+ // parameters, so an old array filter sent to it is silently dropped and the
+ // caller gets an unfiltered list instead of an error.
+ 'self-driving-inbox-get': () =>
+ 'Tool "self-driving-inbox-get" was removed. Use "inbox-reports-list", which lists the same reports. For the old default, pass { "view": "actionable", "use_priority_preference": true, "sort": "priority", "limit": 10 }. The array filters became comma-separated strings: `priorities` is now `priority`, `source_products` is now `source_product`, and `scouts` is now `scout`. `view`, `scope`, `teammate_uuid`, `search`, and `offset` keep their names.',
}
/**
diff --git a/services/mcp/src/tools/generated/signals.ts b/services/mcp/src/tools/generated/signals.ts
index b9c1da1f2692..d8c4388cacc5 100644
--- a/services/mcp/src/tools/generated/signals.ts
+++ b/services/mcp/src/tools/generated/signals.ts
@@ -3,7 +3,6 @@ import { z } from 'zod'
import type { Schemas } from '@/api/generated'
import * as orvalSchemas from '@/generated/signals/api'
-import { ReportInboxInputSchema } from '@/schema/tool-inputs'
import { normalizeParamAliases } from '@/tools/cast-helpers'
import { getConfirmedActionRuntime } from '@/tools/confirmed-action-registry'
import {
@@ -282,6 +281,7 @@ const inboxReportsList = (): ToolBase<
'signal_count',
'total_weight',
'source_products',
+ 'scout_name',
'is_suggested_reviewer',
'implementation_pr_url',
'implementation_pr_state',
@@ -1382,60 +1382,6 @@ const scoutScratchpadSearch = (): ToolBase<
},
})
-const SelfDrivingInboxGetSchema = () => ReportInboxInputSchema
-
-const selfDrivingInboxGet = (): ToolBase<
- ReturnType<typeof SelfDrivingInboxGetSchema>,
- Schemas.PaginatedSignalReportList
-> => ({
- name: 'self-driving-inbox-get',
- schema: SelfDrivingInboxGetSchema(),
- handler: async (context: Context, params: z.infer<ReturnType<typeof SelfDrivingInboxGetSchema>>) => {
- const projectId = await context.stateManager.getProjectId()
- const parsedParams = SelfDrivingInboxGetSchema().parse(params)
- const result = await context.api.request<Schemas.PaginatedSignalReportList>({
- method: 'GET',
- path: `/api/projects/${encodeURIComponent(String(projectId))}/signals/reports/`,
- query: parsedParams,
- })
- const filtered = {
- ...result,
- results: (result.results ?? []).map((item: any) =>
- pickResponseFields(item, [
- 'id',
- 'title',
- 'summary',
- 'status',
- 'priority',
- 'actionability',
- 'already_addressed',
- 'dismissal_reason',
- 'dismissal_note',
- 'signal_count',
- 'total_weight',
- 'source_products',
- 'scout_name',
- 'is_suggested_reviewer',
- 'implementation_pr_url',
- 'implementation_pr_merged',
- 'created_at',
- 'updated_at',
- ])
- ),
- } as typeof result
- return await withPostHogUrl(
- context,
- {
- ...filtered,
- results: await Promise.all(
- (filtered.results ?? []).map((item) => withPostHogUrl(context, item, `/inbox/${item.id}`))
- ),
- },
- '/inbox'
- )
- },
-})
-
const SignalsScoutConfigCreateSchema = () => {
const SignalsScoutConfigCreateBody = orvalSchemas.SignalsScoutConfigCreateBody()
return SignalsScoutConfigCreateBody
@@ -2107,7 +2053,6 @@ export const GENERATED_TOOLS: Record<string, () => ToolBase<ZodObjectAny>> = {
'scout-scratchpad-forget': scoutScratchpadForget,
'scout-scratchpad-remember': scoutScratchpadRemember,
'scout-scratchpad-search': scoutScratchpadSearch,
- 'self-driving-inbox-get': selfDrivingInboxGet,
'signals-scout-config-create': signalsScoutConfigCreate,
'signals-scout-config-delete': signalsScoutConfigDelete,
'signals-scout-config-list': signalsScoutConfigList,
diff --git a/services/mcp/tests/unit/__snapshots__/tool-schemas/self-driving-inbox-get.json b/services/mcp/tests/unit/__snapshots__/tool-schemas/self-driving-inbox-get.json
deleted file mode 100644
index 8df63e7d058e..000000000000
--- a/services/mcp/tests/unit/__snapshots__/tool-schemas/self-driving-inbox-get.json
+++ /dev/null
@@ -1,65 +0,0 @@
-{
- "$schema": "https://json-schema.org/draft/2020-12/schema",
- "properties": {
- "limit": {
- "default": 10,
- "maximum": 10,
- "minimum": 1,
- "type": "integer"
- },
- "offset": {
- "maximum": 9007199254740991,
- "minimum": 0,
- "type": "integer"
- },
- "priorities": {
- "description": "Priorities to include. When omitted, uses the requesting user's personal PR-generation threshold, falling back to the project threshold.",
- "items": {
- "enum": ["P0", "P1", "P2", "P3", "P4"],
- "type": "string"
- },
- "type": "array"
- },
- "scope": {
- "default": "entire_project",
- "description": "Limit results by suggested reviewer, or search the entire project.",
- "enum": ["for_me", "entire_project", "teammate"],
- "type": "string"
- },
- "scouts": {
- "description": "Scout skill_name slugs to include.",
- "items": {
- "type": "string"
- },
- "type": "array"
- },
- "search": {
- "description": "Case-insensitive substring match against report title and summary.",
- "type": "string"
- },
- "sort": {
- "default": "priority",
- "enum": ["priority", "last_updated", "newest", "oldest"],
- "type": "string"
- },
- "source_products": {
- "items": {
- "type": "string"
- },
- "type": "array"
- },
- "teammate_uuid": {
- "description": "PostHog user UUID required when scope is teammate.",
- "format": "uuid",
- "pattern": "^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$",
- "type": "string"
- },
- "view": {
- "default": "actionable",
- "description": "Inbox section to return. Defaults to actionable reports that are ready to pick up.",
- "enum": ["actionable", "needs_input", "monitoring", "resolved", "dismissed", "not_actionable", "all"],
- "type": "string"
- }
- },
- "type": "object"
-}
diff --git a/services/mcp/tests/unit/exec.test.ts b/services/mcp/tests/unit/exec.test.ts
index 75bd62ca7505..ef3c0b74785c 100644
--- a/services/mcp/tests/unit/exec.test.ts
+++ b/services/mcp/tests/unit/exec.test.ts
@@ -1412,6 +1412,7 @@ describe('exec tool', () => {
['property-definitions', 'read-data-schema'],
['query-generate-hogql-from-question', 'execute-sql'],
['query-run', 'execute-sql'],
+ ['self-driving-inbox-get', 'inbox-reports-list'],
])('throws redirect when calling deprecated %s', async (deprecated, replacement) => {
const exec = createExec()
await expect(exec.handler(mockContext, { command: `call ${deprecated} {}` })).rejects.toThrow(
diff --git a/services/mcp/tests/unit/inbox-reports-list-single-surface.test.ts b/services/mcp/tests/unit/inbox-reports-list-single-surface.test.ts
new file mode 100644
index 000000000000..16c4a2a3865c
--- /dev/null
+++ b/services/mcp/tests/unit/inbox-reports-list-single-surface.test.ts
@@ -0,0 +1,41 @@
+import * as fs from 'node:fs'
+import * as path from 'node:path'
+
+import { describe, expect, it } from 'vitest'
+import { parse as parseYaml } from 'yaml'
+
+import { GENERATED_TOOLS } from '@/tools/generated/signals'
+
+// A second tool on the same operation gives each filter two spellings, so an
+// agent that reads one tool's description cannot call the other. Keep one tool
+// on the operation, and keep the parameters that description names.
+describe('inbox-reports-list owns the Inbox reports list operation', () => {
+ const config = parseYaml(
+ fs.readFileSync(path.resolve(__dirname, '../../../../products/signals/mcp/tools.yaml'), 'utf-8')
+ ) as { tools: Record<string, { operation?: string; enabled?: boolean }> }
+
+ it('has exactly one enabled tool for signals_reports_list', () => {
+ const owners = Object.entries(config.tools)
+ .filter(([, tool]) => tool.enabled && tool.operation === 'signals_reports_list')
+ .map(([name]) => name)
+ expect(owners).toEqual(['inbox-reports-list'])
+ })
+
+ it('keeps the parameters its description documents', () => {
+ // The schema strips unknown keys, so assert the parsed output, not just that parsing passed.
+ const call = {
+ view: 'actionable',
+ use_priority_preference: true,
+ sort: 'priority',
+ limit: 10,
+ scope: 'teammate',
+ teammate_uuid: '01a04d4c-9994-716b-8038-10627229a016',
+ priority: 'P0,P1',
+ source_product: 'error_tracking',
+ scout: 'signals-scout-error-tracking',
+ }
+ const result = GENERATED_TOOLS['inbox-reports-list']!().schema.safeParse(call)
+ expect(result.success).toBe(true)
+ expect(result.data).toMatchObject(call)
+ })
+})