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.

feat(devex): filter stamphog routing runs by outcome, reason, sha, time (#130139)

Julian Bez46a988b2329e
diff --git a/products/stamphog/README.md b/products/stamphog/README.md
index d5d7c5fadc49..f8fa071bd334 100644
--- a/products/stamphog/README.md
+++ b/products/stamphog/README.md
@@ -206,7 +206,8 @@ Routing never writes `payload_updated_at` or the descriptive fields of the row,
Each run that makes its requests is also recorded, append-only, in `RoutingRun` with one `RoutingRunOwner` row per owner: what the run did with the owner (`outcome`), why (`reason`), the model's one-line reason when it proposed a cut, also when a guard kept the owner, and every changed file the owner owns, without patches.
owners.yaml and the pull request both change after the run, so the run keeps its own copy of the file list, and `owners_sha` names the default-branch commit whose owners.yaml files decided the owners.
The plan decides each owner's outcome and reason. The rows are written after the `requested` record is saved, so a failed log write only logs and never makes the task request again.
-Read them with `GET routing_runs/` (filters `repository`, `pr_number`, `owner`) or the `stamphog-routing-runs-list` MCP tool.
+Read them with `GET routing_runs/` (filters `repository`, `pr_number`, `owner`, `outcome`, `reason`, `head_sha`, `created_after`, `created_before`) or the `stamphog-routing-runs-list` MCP tool.
+`outcome` and `reason` match the same owner as `owner`, so `owner=team-devex&outcome=cut` lists the runs that cut team-devex.
The list leaves out the file lists, because a large pull request gives every owner a long one. `GET routing_runs/{id}/` and `stamphog-routing-runs-get` return them. The model call carries `stamphog_routing_run_id`, `stamphog_repo` and `stamphog_pr_number`, which link a run to its LLM trace.
Every routing run (event, verdict or safety net) takes the same steps:
diff --git a/products/stamphog/backend/facade/api.py b/products/stamphog/backend/facade/api.py
index 9942948ce46e..bc324c2a980c 100644
--- a/products/stamphog/backend/facade/api.py
+++ b/products/stamphog/backend/facade/api.py
@@ -9,6 +9,7 @@ dataclasses. Never return ORM instances or import DRF.
from __future__ import annotations
from collections.abc import Callable, Iterator, Sequence
+from datetime import datetime
from typing import Any, TypeVar, overload
from uuid import UUID
@@ -694,10 +695,16 @@ def list_routing_runs(
repository: str | None = None,
pr_number: int | None = None,
owner: str | None = None,
+ outcome: RoutingOwnerOutcome | None = None,
+ reason: RoutingOwnerReason | None = None,
+ head_sha: str | None = None,
+ created_after: datetime | None = None,
+ created_before: datetime | None = None,
) -> LazyDTOList[contracts.RoutingRunDTO]:
"""The team's reviewer routing runs, newest first, each with its decision for every owner but no file lists.
`owner` keeps the runs that decided about that owner, as owners.yaml spells it (`team-devex`, `@alice`).
+ `outcome` and `reason` keep the runs where one owner row has them, the same row as `owner` when it is set.
`team_id` must be canonical, as every view passes it, so the reads skip the team lookup.
"""
# Run ids are uuid7, so the id breaks a created_at tie in time order and a page boundary never splits a tie.
@@ -706,9 +713,22 @@ def list_routing_runs(
qs = qs.filter(pull_request__repo_config__repository=repository)
if pr_number is not None:
qs = qs.filter(pull_request__pr_number=pr_number)
- if owner:
- # A subquery on the owners table, so the (team_id, owner) index answers it.
- owners = RoutingRunOwner.objects.for_team(team_id, canonical=True).filter(owner=owner)
+ if head_sha:
+ qs = qs.filter(head_sha=head_sha)
+ if created_after is not None:
+ qs = qs.filter(created_at__gte=created_after)
+ if created_before is not None:
+ qs = qs.filter(created_at__lt=created_before)
+ if owner or outcome or reason:
+ # One subquery on the owners table, so a run that cut one owner and requested another never
+ # matches `owner` plus `outcome` across two rows. The (team_id, owner) index answers `owner`.
+ owners = RoutingRunOwner.objects.for_team(team_id, canonical=True)
+ if owner:
+ owners = owners.filter(owner=owner)
+ if outcome:
+ owners = owners.filter(outcome=outcome)
+ if reason:
+ owners = owners.filter(reason=reason)
qs = qs.filter(id__in=owners.values("run_id"))
return LazyDTOList(qs, _routing_run_to_dto)
diff --git a/products/stamphog/backend/presentation/serializers.py b/products/stamphog/backend/presentation/serializers.py
index c76a6fc9e87f..0321f277ff43 100644
--- a/products/stamphog/backend/presentation/serializers.py
+++ b/products/stamphog/backend/presentation/serializers.py
@@ -848,6 +848,30 @@ class StamphogRoutingRunsQuerySerializer(serializers.Serializer):
"'team-devex', or a GitHub login such as '@octocat'."
),
)
+ outcome = serializers.ChoiceField(
+ choices=RoutingOwnerOutcome.choices,
+ required=False,
+ help_text=(
+ "Keep only runs where an owner got this outcome. With `owner`, that owner must have it, so "
+ "`owner=team-devex&outcome=cut` lists the runs that cut team-devex."
+ ),
+ )
+ reason = serializers.ChoiceField(
+ choices=RoutingOwnerReason.choices,
+ required=False,
+ help_text="Keep only runs where an owner was kept or cut for this reason. With `owner`, that owner must have it.",
+ )
+ head_sha = serializers.CharField(
+ required=False,
+ max_length=64,
+ help_text="Keep only runs on this head commit. Pass the full 40-character SHA.",
+ )
+ created_after = serializers.DateTimeField(
+ required=False, help_text="Keep only runs created at or after this time (ISO 8601)."
+ )
+ created_before = serializers.DateTimeField(
+ required=False, help_text="Keep only runs created before this time (ISO 8601)."
+ )
@extend_schema_serializer(component_name="StamphogRoutingPin")
diff --git a/products/stamphog/backend/tests/test_api.py b/products/stamphog/backend/tests/test_api.py
index 835fd5f314ba..a5e1d742f15f 100644
--- a/products/stamphog/backend/tests/test_api.py
+++ b/products/stamphog/backend/tests/test_api.py
@@ -1,4 +1,5 @@
import json
+from datetime import timedelta
from typing import Any
import pytest
@@ -1311,7 +1312,7 @@ class TestRoutingRunAPI(StamphogTeamScopedTestMixin, APIBaseTest):
run = RoutingRun.objects.unscoped().create(
team_id=team_id,
pull_request=pull_request,
- head_sha="head-1",
+ head_sha=f"head-{pr_number}",
mode=RoutingMode.ALWAYS,
trigger="opened",
scope="full",
@@ -1327,6 +1328,10 @@ class TestRoutingRunAPI(StamphogTeamScopedTestMixin, APIBaseTest):
("everything_in_the_team", {}, [2, 1]),
("by_owner", {"owner": "team-beta"}, [1]),
("by_pull_request", {"pr_number": 2}, [2]),
+ ("by_head_sha", {"head_sha": "head-2"}, [2]),
+ ("by_outcome", {"outcome": "cut"}, [1]),
+ ("by_reason", {"reason": "model_kept"}, [2]),
+ ("by_owner_and_outcome_on_one_owner", {"owner": "team-alpha", "outcome": "cut"}, []),
]
)
def test_list_filters_the_teams_runs(self, _name: str, query: dict, expected_pr_numbers: list[int]) -> None:
@@ -1335,6 +1340,18 @@ class TestRoutingRunAPI(StamphogTeamScopedTestMixin, APIBaseTest):
assert response.status_code == status.HTTP_200_OK, response.content
assert [run["pr_number"] for run in response.json()["results"]] == expected_pr_numbers
+ @parameterized.expand([("created_after", [2]), ("created_before", [1])])
+ def test_list_keeps_the_runs_inside_the_time_window(self, param: str, expected_pr_numbers: list[int]) -> None:
+ now = timezone.now()
+ runs = RoutingRun.objects.unscoped().filter(team_id=self.team.id)
+ runs.filter(pull_request__pr_number=1).update(created_at=now - timedelta(days=3))
+ runs.filter(pull_request__pr_number=2).update(created_at=now - timedelta(days=1))
+
+ response = self.client.get(self.url, {param: (now - timedelta(days=2)).isoformat()})
+
+ assert response.status_code == status.HTTP_200_OK, response.content
+ assert [run["pr_number"] for run in response.json()["results"]] == expected_pr_numbers
+
def test_a_run_says_why_each_owner_was_or_was_not_asked(self) -> None:
response = self.client.get(self.url, {"pr_number": 1})
diff --git a/products/stamphog/frontend/generated/api.schemas.ts b/products/stamphog/frontend/generated/api.schemas.ts
index 37d098560c3b..de0dcd195f72 100644
--- a/products/stamphog/frontend/generated/api.schemas.ts
+++ b/products/stamphog/frontend/generated/api.schemas.ts
@@ -1019,6 +1019,20 @@ export const StamphogReviewRunsListTrigger = {
} as const
export type StamphogRoutingRunsListParams = {
+ /**
+ * Keep only runs created at or after this time (ISO 8601).
+ */
+ created_after?: string
+ /**
+ * Keep only runs created before this time (ISO 8601).
+ */
+ created_before?: string
+ /**
+ * Keep only runs on this head commit. Pass the full 40-character SHA.
+ * @minLength 1
+ * @maxLength 64
+ */
+ head_sha?: string
/**
* Number of results to return per page.
*/
@@ -1027,6 +1041,18 @@ export type StamphogRoutingRunsListParams = {
* The initial index from which to return the results.
*/
offset?: number
+ /**
+ * Keep only runs where an owner got this outcome. With `owner`, that owner must have it, so `owner=team-devex&outcome=cut` lists the runs that cut team-devex.
+ *
+ * * `requested` - Requested
+ * * `labeled` - Labeled
+ * * `refused` - Refused by GitHub
+ * * `cut` - Cut
+ * * `not_requested` - Not requested
+ * * `already_requested` - Already requested
+ * @minLength 1
+ */
+ outcome?: StamphogRoutingRunsListOutcome
/**
* Keep only runs that decided about this owner, spelled as in owners.yaml: a team slug such as 'team-devex', or a GitHub login such as '@octocat'.
* @minLength 1
@@ -1036,9 +1062,49 @@ export type StamphogRoutingRunsListParams = {
* Filter by pull request number.
*/
pr_number?: number
+ /**
+ * Keep only runs where an owner was kept or cut for this reason. With `owner`, that owner must have it.
+ *
+ * * `sensitive` - Owns a sensitive path
+ * * `new_path` - Owns a new path
+ * * `largest_owner` - Has the largest part
+ * * `diff_not_seen` - Diff not shown to the model
+ * * `cut_skipped` - Cut step skipped
+ * * `model_kept` - Kept by the model
+ * * `model_cut` - Cut by the model
+ * * `stamphog_approved` - Stamphog approved
+ * @minLength 1
+ */
+ reason?: StamphogRoutingRunsListReason
/**
* Filter by repository full name, e.g. 'PostHog/posthog'.
* @minLength 1
*/
repository?: string
}
+
+export type StamphogRoutingRunsListOutcome =
+ (typeof StamphogRoutingRunsListOutcome)[keyof typeof StamphogRoutingRunsListOutcome]
+
+export const StamphogRoutingRunsListOutcome = {
+ Requested: 'requested',
+ Labeled: 'labeled',
+ Refused: 'refused',
+ Cut: 'cut',
+ NotRequested: 'not_requested',
+ AlreadyRequested: 'already_requested',
+} as const
+
+export type StamphogRoutingRunsListReason =
+ (typeof StamphogRoutingRunsListReason)[keyof typeof StamphogRoutingRunsListReason]
+
+export const StamphogRoutingRunsListReason = {
+ Sensitive: 'sensitive',
+ NewPath: 'new_path',
+ LargestOwner: 'largest_owner',
+ DiffNotSeen: 'diff_not_seen',
+ CutSkipped: 'cut_skipped',
+ ModelKept: 'model_kept',
+ ModelCut: 'model_cut',
+ StamphogApproved: 'stamphog_approved',
+} as const
diff --git a/products/stamphog/mcp/tools.yaml b/products/stamphog/mcp/tools.yaml
index ce4c378f702f..ac922304a813 100644
--- a/products/stamphog/mcp/tools.yaml
+++ b/products/stamphog/mcp/tools.yaml
@@ -206,11 +206,13 @@ tools:
request, with the run's decision for every owner of the changed code from owners.yaml: an `outcome` and the
`reason` behind it, and the model's one-line `model_reason` when it proposed a cut. To answer "why was my
team not asked to review", filter by `owner` (a team slug such as `team-devex`, or a GitHub login such as
- `@octocat`), optionally with `repository` and `pr_number`. An owner missing from a run was not a candidate:
- it owns none of the changed files that routing reads (generated, vendored and lock files are skipped), or
- GitHub listed fewer files than the pull request changes (`files_truncated`). No runs for a pull request
- means no run was recorded: routing is off for the repository, it still waits for stamphog's verdict, or the
- log write failed. Use `stamphog-routing-runs-get` for the files each owner owns.
+ `@octocat`), optionally with `repository` and `pr_number`. Add `outcome` (for example `cut`) or `reason` to
+ keep only the runs where that owner got it, and `created_after` or `created_before` to set a time window.
+ `head_sha` finds the run for one commit. An owner missing from a run was not a candidate: it owns none of
+ the changed files that routing reads (generated, vendored and lock files are skipped), or GitHub listed
+ fewer files than the pull request changes (`files_truncated`). No runs for a pull request means no run was
+ recorded: routing is off for the repository, it still waits for stamphog's verdict, or the log write failed.
+ Use `stamphog-routing-runs-get` for the files each owner owns.
feature_flag: stamphog
response:
informational_wrapper:
diff --git a/services/mcp/schema/generated-tool-definitions.json b/services/mcp/schema/generated-tool-definitions.json
index 3c674e16982e..3eb7dba86288 100644
--- a/services/mcp/schema/generated-tool-definitions.json
+++ b/services/mcp/schema/generated-tool-definitions.json
@@ -14181,7 +14181,7 @@
"feature_flag": "stamphog"
},
"stamphog-routing-runs-list": {
- "description": "List stamphog's reviewer routing runs, newest first. Each run is one round of review requests on a pull request, with the run's decision for every owner of the changed code from owners.yaml: an `outcome` and the `reason` behind it, and the model's one-line `model_reason` when it proposed a cut. To answer \"why was my team not asked to review\", filter by `owner` (a team slug such as `team-devex`, or a GitHub login such as `@octocat`), optionally with `repository` and `pr_number`. An owner missing from a run was not a candidate: it owns none of the changed files that routing reads (generated, vendored and lock files are skipped), or GitHub listed fewer files than the pull request changes (`files_truncated`). No runs for a pull request means no run was recorded: routing is off for the repository, it still waits for stamphog's verdict, or the log write failed. Use `stamphog-routing-runs-get` for the files each owner owns.",
+ "description": "List stamphog's reviewer routing runs, newest first. Each run is one round of review requests on a pull request, with the run's decision for every owner of the changed code from owners.yaml: an `outcome` and the `reason` behind it, and the model's one-line `model_reason` when it proposed a cut. To answer \"why was my team not asked to review\", filter by `owner` (a team slug such as `team-devex`, or a GitHub login such as `@octocat`), optionally with `repository` and `pr_number`. Add `outcome` (for example `cut`) or `reason` to keep only the runs where that owner got it, and `created_after` or `created_before` to set a time window. `head_sha` finds the run for one commit. An owner missing from a run was not a candidate: it owns none of the changed files that routing reads (generated, vendored and lock files are skipped), or GitHub listed fewer files than the pull request changes (`files_truncated`). No runs for a pull request means no run was recorded: routing is off for the repository, it still waits for stamphog's verdict, or the log write failed. Use `stamphog-routing-runs-get` for the files each owner owns.",
"category": "Stamphog",
"feature": "stamphog",
"summary": "List stamphog reviewer routing runs",
diff --git a/services/mcp/schema/tool-definitions-all.json b/services/mcp/schema/tool-definitions-all.json
index 9faf96414fb5..bfd0e41def4a 100644
--- a/services/mcp/schema/tool-definitions-all.json
+++ b/services/mcp/schema/tool-definitions-all.json
@@ -14882,7 +14882,7 @@
"feature_flag": "stamphog"
},
"stamphog-routing-runs-list": {
- "description": "List stamphog's reviewer routing runs, newest first. Each run is one round of review requests on a pull request, with the run's decision for every owner of the changed code from owners.yaml: an `outcome` and the `reason` behind it, and the model's one-line `model_reason` when it proposed a cut. To answer \"why was my team not asked to review\", filter by `owner` (a team slug such as `team-devex`, or a GitHub login such as `@octocat`), optionally with `repository` and `pr_number`. An owner missing from a run was not a candidate: it owns none of the changed files that routing reads (generated, vendored and lock files are skipped), or GitHub listed fewer files than the pull request changes (`files_truncated`). No runs for a pull request means no run was recorded: routing is off for the repository, it still waits for stamphog's verdict, or the log write failed. Use `stamphog-routing-runs-get` for the files each owner owns.",
+ "description": "List stamphog's reviewer routing runs, newest first. Each run is one round of review requests on a pull request, with the run's decision for every owner of the changed code from owners.yaml: an `outcome` and the `reason` behind it, and the model's one-line `model_reason` when it proposed a cut. To answer \"why was my team not asked to review\", filter by `owner` (a team slug such as `team-devex`, or a GitHub login such as `@octocat`), optionally with `repository` and `pr_number`. Add `outcome` (for example `cut`) or `reason` to keep only the runs where that owner got it, and `created_after` or `created_before` to set a time window. `head_sha` finds the run for one commit. An owner missing from a run was not a candidate: it owns none of the changed files that routing reads (generated, vendored and lock files are skipped), or GitHub listed fewer files than the pull request changes (`files_truncated`). No runs for a pull request means no run was recorded: routing is off for the repository, it still waits for stamphog's verdict, or the log write failed. Use `stamphog-routing-runs-get` for the files each owner owns.",
"category": "Stamphog",
"feature": "stamphog",
"summary": "List stamphog reviewer routing runs",
diff --git a/services/mcp/src/api/generated.ts b/services/mcp/src/api/generated.ts
index b5b16cf93e4e..a279b2222506 100644
--- a/services/mcp/src/api/generated.ts
+++ b/services/mcp/src/api/generated.ts
@@ -134138,6 +134138,20 @@ export namespace Schemas {
} as const;
export type StamphogRoutingRunsListParams = {
+ /**
+ * Keep only runs created at or after this time (ISO 8601).
+ */
+ created_after?: string;
+ /**
+ * Keep only runs created before this time (ISO 8601).
+ */
+ created_before?: string;
+ /**
+ * Keep only runs on this head commit. Pass the full 40-character SHA.
+ * @minLength 1
+ * @maxLength 64
+ */
+ head_sha?: string;
/**
* Number of results to return per page.
*/
@@ -134146,6 +134160,18 @@ export namespace Schemas {
* The initial index from which to return the results.
*/
offset?: number;
+ /**
+ * Keep only runs where an owner got this outcome. With `owner`, that owner must have it, so `owner=team-devex&outcome=cut` lists the runs that cut team-devex.
+ *
+ * * `requested` - Requested
+ * * `labeled` - Labeled
+ * * `refused` - Refused by GitHub
+ * * `cut` - Cut
+ * * `not_requested` - Not requested
+ * * `already_requested` - Already requested
+ * @minLength 1
+ */
+ outcome?: StamphogRoutingRunsListOutcome;
/**
* Keep only runs that decided about this owner, spelled as in owners.yaml: a team slug such as 'team-devex', or a GitHub login such as '@octocat'.
* @minLength 1
@@ -134155,6 +134181,20 @@ export namespace Schemas {
* Filter by pull request number.
*/
pr_number?: number;
+ /**
+ * Keep only runs where an owner was kept or cut for this reason. With `owner`, that owner must have it.
+ *
+ * * `sensitive` - Owns a sensitive path
+ * * `new_path` - Owns a new path
+ * * `largest_owner` - Has the largest part
+ * * `diff_not_seen` - Diff not shown to the model
+ * * `cut_skipped` - Cut step skipped
+ * * `model_kept` - Kept by the model
+ * * `model_cut` - Cut by the model
+ * * `stamphog_approved` - Stamphog approved
+ * @minLength 1
+ */
+ reason?: StamphogRoutingRunsListReason;
/**
* Filter by repository full name, e.g. 'PostHog/posthog'.
* @minLength 1
@@ -134162,6 +134202,32 @@ export namespace Schemas {
repository?: string;
};
+ export type StamphogRoutingRunsListOutcome = typeof StamphogRoutingRunsListOutcome[keyof typeof StamphogRoutingRunsListOutcome];
+
+
+ export const StamphogRoutingRunsListOutcome = {
+ Requested: 'requested',
+ Labeled: 'labeled',
+ Refused: 'refused',
+ Cut: 'cut',
+ NotRequested: 'not_requested',
+ AlreadyRequested: 'already_requested',
+ } as const;
+
+ export type StamphogRoutingRunsListReason = typeof StamphogRoutingRunsListReason[keyof typeof StamphogRoutingRunsListReason];
+
+
+ export const StamphogRoutingRunsListReason = {
+ Sensitive: 'sensitive',
+ NewPath: 'new_path',
+ LargestOwner: 'largest_owner',
+ DiffNotSeen: 'diff_not_seen',
+ CutSkipped: 'cut_skipped',
+ ModelKept: 'model_kept',
+ ModelCut: 'model_cut',
+ StamphogApproved: 'stamphog_approved',
+ } as const;
+
export type StreamlitAppsListParams = {
/**
* Number of results to return per page.
diff --git a/services/mcp/src/generated/stamphog/api.ts b/services/mcp/src/generated/stamphog/api.ts
index 6a54d5ba65e6..77594048deca 100644
--- a/services/mcp/src/generated/stamphog/api.ts
+++ b/services/mcp/src/generated/stamphog/api.ts
@@ -171,9 +171,31 @@ export const StamphogRoutingRunsListParams = () => zod.object({
),
})
+export const stamphogRoutingRunsListQueryHeadShaMax = 64
+
export const StamphogRoutingRunsListQueryParams = () => zod.object({
+ created_after: zod.iso
+ .datetime({ offset: true })
+ .optional()
+ .describe('Keep only runs created at or after this time (ISO 8601).'),
+ created_before: zod.iso
+ .datetime({ offset: true })
+ .optional()
+ .describe('Keep only runs created before this time (ISO 8601).'),
+ head_sha: zod
+ .string()
+ .min(1)
+ .max(stamphogRoutingRunsListQueryHeadShaMax)
+ .optional()
+ .describe('Keep only runs on this head commit. Pass the full 40-character SHA.'),
limit: zod.number().optional().describe('Number of results to return per page.'),
offset: zod.number().optional().describe('The initial index from which to return the results.'),
+ outcome: zod
+ .enum(['requested', 'labeled', 'refused', 'cut', 'not_requested', 'already_requested'])
+ .optional()
+ .describe(
+ 'Keep only runs where an owner got this outcome. With `owner`, that owner must have it, so `owner=team-devex&outcome=cut` lists the runs that cut team-devex.\n\n\* `requested` - Requested\n\* `labeled` - Labeled\n\* `refused` - Refused by GitHub\n\* `cut` - Cut\n\* `not_requested` - Not requested\n\* `already_requested` - Already requested'
+ ),
owner: zod
.string()
.min(1)
@@ -182,6 +204,21 @@ export const StamphogRoutingRunsListQueryParams = () => zod.object({
"Keep only runs that decided about this owner, spelled as in owners.yaml: a team slug such as 'team-devex', or a GitHub login such as '@octocat'."
),
pr_number: zod.number().optional().describe('Filter by pull request number.'),
+ reason: zod
+ .enum([
+ 'sensitive',
+ 'new_path',
+ 'largest_owner',
+ 'diff_not_seen',
+ 'cut_skipped',
+ 'model_kept',
+ 'model_cut',
+ 'stamphog_approved',
+ ])
+ .optional()
+ .describe(
+ 'Keep only runs where an owner was kept or cut for this reason. With `owner`, that owner must have it.\n\n\* `sensitive` - Owns a sensitive path\n\* `new_path` - Owns a new path\n\* `largest_owner` - Has the largest part\n\* `diff_not_seen` - Diff not shown to the model\n\* `cut_skipped` - Cut step skipped\n\* `model_kept` - Kept by the model\n\* `model_cut` - Cut by the model\n\* `stamphog_approved` - Stamphog approved'
+ ),
repository: zod.string().min(1).optional().describe("Filter by repository full name, e.g. 'PostHog\/posthog'."),
})
diff --git a/services/mcp/src/tools/generated/stamphog.ts b/services/mcp/src/tools/generated/stamphog.ts
index d707fc3185bd..b3814764711e 100644
--- a/services/mcp/src/tools/generated/stamphog.ts
+++ b/services/mcp/src/tools/generated/stamphog.ts
@@ -272,10 +272,15 @@ const stamphogRoutingRunsList = (): ToolBase<
method: 'GET',
path: `/api/projects/${encodeURIComponent(String(projectId))}/stamphog/routing_runs/`,
query: {
+ created_after: params.created_after,
+ created_before: params.created_before,
+ head_sha: params.head_sha,
limit: params.limit,
offset: params.offset,
+ outcome: params.outcome,
owner: params.owner,
pr_number: params.pr_number,
+ reason: params.reason,
repository: params.repository,
},
})