feat(traces): route governance endpoints via llmops base [PLT-106297]#604
feat(traces): route governance endpoints via llmops base [PLT-106297]#604ashishupadhyay88 wants to merge 3 commits into
Conversation
getGovernanceDecisions/getGovernanceSummary now hit
llmopstenant_/api/Governance/agentic/{traces,summary} (was insightsrtm_).
The Traceview endpoints stay on insightsrtm_ — they 404 on llmops.
Scope for the two governance methods changes to Traces.Api OR.Folders.Read
(the llmops/Traces service scope), matching the SDK's other llmops
endpoints. E2E-verified against a provisioned tenant.
Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
Review findingsFile not in diff: Now that Per CLAUDE.md: Three things need updating before this PR is ready:
|
…s [PLT-106297] The llmops governance endpoint is a facade that forwards to InsightsRTM, so the token needs Traces.Api (llmops gateway) AND the InsightsRTM scopes (Insights.RealTimeData Insights OR.Folders.Read) for the internal forward. E2E-verified with an external-app OAuth token carrying all four. Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
Review findingsTwo open issues: 1. New — 2. Prior open — integration test (from previous review, still unresolved): |
…ment [PLT-106297] Governance endpoints moved to llmopstenant_; the skip stays because that facade forwards to InsightsRTM (PAT-rejecting), so PAT integration still cannot reach them. Comment updated to reflect both bases. Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
|
Thanks — both findings were based on the assumption that these are plain 1. Scope ( 2. Integration test skip — kept skipped, comment corrected in aaff672. The premise that these now "accept PAT with |
|
✅ No issues found. Checked for bugs and CLAUDE.md compliance. |
|
|
✅ No issues found. Checked for bugs and CLAUDE.md compliance. |



What
Routes the two governance AgentTraces endpoints from the
insightsrtm_base tollmopstenant_/api:getGovernanceDecisions()insightsrtm_/Governance/agentic/tracesllmopstenant_/api/Governance/agentic/tracesgetGovernanceSummary()insightsrtm_/Governance/agentic/summaryllmopstenant_/api/Governance/agentic/summaryScope change (breaking for these 2 methods)
The llmops governance endpoint is a facade that forwards the request to InsightsRTM internally. So the token must satisfy both hops:
Traces.Api— to pass the llmops gateway.Insights.RealTimeData Insights OR.Folders.Read— for the internal forward toinsightsrtm_(same scopes the directinsightsrtm_route always required).Documented scope for both methods:
Insights.RealTimeData Insights OR.Folders.Read→Traces.Api Insights.RealTimeData Insights OR.Folders.ReadThis is breaking: existing consumers must add
Traces.Apito their external app (the InsightsRTM scopes were already required).docs/oauth-scopes.mdupdated.E2E
Verified against a real external-app OAuth token in
governancedevs/DefaultTenant:Traces.Api→ passed the llmops gateway but 401 on the internal InsightsRTM forward (Failed to call insightsrtm_ … Unauthorized).Traces.Api Insights.RealTimeData Insights OR.Folders.Read→ both governance endpoints return 200 with data.Files
src/utils/constants/endpoints/agent-traces.ts(2 governance constants)docs/oauth-scopes.md(scope for the 2 governance methods)Note / open decision
llmops governance is a proxy to InsightsRTM — the migration adds a network hop and an extra required scope (
Traces.Api) with no functional change versus callinginsightsrtm_directly. Keeping it because llmops is the canonical route going forward; flag if the extra scope burden isn't worth it.TODO before ready-for-review
llmopstenant_/api/Governance/agentic/*(browser consumers / E2E proxy).🤖 Draft — pending Cloudflare whitelist + final sign-off.