Skip to content

feat(registry): ?verification_mode and ?verified filters for GET /api/registry/agents#3515

Draft
bokelley wants to merge 1 commit into
mainfrom
claude/issue-3505-verified-mode-registry-filter
Draft

feat(registry): ?verification_mode and ?verified filters for GET /api/registry/agents#3515
bokelley wants to merge 1 commit into
mainfrom
claude/issue-3505-verified-mode-registry-filter

Conversation

@bokelley
Copy link
Copy Markdown
Contributor

Closes #3505

docs/building/aao-verified.mdx#registry-filter has advertised verification-mode filtering on the federated agent listing since PR #2153, but GET /api/registry/agents never wired up the parameter. This PR closes that gap.

What changed

Two new optional query parameters on GET /api/registry/agents:

Param Accepted values Behavior
?verification_mode spec, live (repeat for AND) Filter to agents whose active badge covers all listed axes
?verified true Filter to agents with any active verification badge

Both params are additive: ?verified=true&verification_mode=live requires a badge covering live (the withVerified check is then a strict subset of the verificationModes check, so no redundancy).

Filter semantics — AND across repeated params, via a single-badge predicate:

badges.some(b =>
  modesOk  // badge.verification_modes ⊇ requested_modes
  && verifiedOk  // badge.verification_modes non-empty (if ?verified=true)
)

Validation — unknown verification_mode values get a 400 with valid_values: ["spec","live"].

Error handling — DB failure returns 503 (not silently unfiltered, which would leak unverified agents to callers who asked for verified-only).

Badge map reuse — when ?compliance=true is also set, the badge map fetched for the filter is reused in the enrichment step (saves one round-trip).

bySource counts now reflect the filtered agent set (previously always reflected the full unfiltered listing).

Non-breaking justification

Both params are optional. Callers that omit them hit the unchanged listAllAgents + early-return path (if (!withHealth && !withCapabilities...)) with no behavioral change.

Pre-PR review

  • code-reviewer: approved after fixes — three blockers resolved: (1) combined withVerified+verificationModes predicate, (2) z.enum(["true"]) consistent with sibling params, (3) 503 on badge-fetch failure
  • adtech-product-expert: approved — AND semantics correct for current single-badge data model; naming ?verified + ?verification_mode natural for buyers

Triage-managed PR. This bot does not currently iterate on
review comments or PR conversation threads (only on the source
issue). To unblock:

  • Push fixup commits directly: gh pr checkout <num>
    fix → push.
  • Or re-trigger: comment /triage execute on the source
    issue.

See #3121
for context.

Session: https://claude.ai/code/session_01K5MAwn6xWdaQLNP4hf1sCy


Generated by Claude Code

…api/registry/agents

Wires up the filter capability already advertised in docs/building/aao-verified.mdx#registry-filter
but missing from the API. Adds two optional query params:

- ?verification_mode=spec|live (repeat for AND semantics — both axes required)
- ?verified=true (any active verification badge)

Both params are additive: ?verified=true&verification_mode=live requires a badge that covers
'live'. On DB error the endpoint returns 503 rather than silently leaking unverified agents.

When ?compliance=true is also set, the prefetched badge map is reused to save one round-trip.
bySource counts now reflect the filtered agent set.

Closes #3505

https://claude.ai/code/session_01K5MAwn6xWdaQLNP4hf1sCy
@bokelley bokelley added the claude-triaged Issue has been triaged by the Claude Code triage routine. Remove to re-triage. label Apr 29, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

claude-triaged Issue has been triaged by the Claude Code triage routine. Remove to re-triage.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Federated agent listing: ?verified_mode filter (spec | live | both)

2 participants