Skip to content

feat: add fme_change_request resource - #1049

Open
MatiasCasaliSplit wants to merge 2 commits into
harness:mainfrom
MatiasCasaliSplit:FME-18670-change-requests-mcp
Open

MatiasCasaliSplit wants to merge 2 commits into
harness:mainfrom
MatiasCasaliSplit:FME-18670-change-requests-mcp

Conversation

@MatiasCasaliSplit

@MatiasCasaliSplit MatiasCasaliSplit commented Oct 2, 2026 •

Copy link
Copy Markdown
Contributor

WHAT

Adds the read-only fme_change_request resource (list only), backed by GET /fme/api/v4/change-requests. It is Harness-native only. Scope is project by default (org_id + project_id). Pass resource_scope='account' to list across the whole account.

WHY

Agents can list pending change requests (FME approval workflow items) for feature flags and segments without knowing the flag or segment name first. For example, they can answer "what's waiting on my approval?" with filter=APPROVALS.

Changes

  • src/registry/toolsets/feature-flags.ts: adds the fme_change_request resource (supportedScopes: ["account", "project"], FME_HARNESS_NATIVE_SCOPE_PARAMS).
    • Filters:
      • status (repeatable, defaults server-side to [REQUESTED])
      • filter (ALL default / APPROVALS / SUBMISSIONS)
      • environment_id (repeatable)
      • resource_type (FEATURE_FLAG / SEGMENT)
      • segment_type (STANDARD / LARGE / RULE_BASED)
      • offset / limit (harness_list size maps to limit, as on the other FME v4 lists)
    • Arrays and comma-separated strings for status / environment_id are sent as repeated query params. Enum values are canonicalized case-insensitively.
    • Invalid enums are rejected before any HTTP call. So are segment_type without resource_type=SEGMENT (and the reverse), and a missing org_id / project_id without resource_scope='account'.
    • skipCompact: the generic whitelist would drop resourceName, resourceType, environment, createdBy and approvalConfig.
  • tests/registry/feature-flags.test.ts: 12 tests covering routing, account scope, filter mapping, CSV splitting and case canonicalization, validation errors, the extractor, and resource metadata.
  • README.md: resource table row, a notes bullet, the toolset list, and the regenerated counts (260 resource types).

Testing

  • pnpm build, pnpm typecheck, pnpm standards:check (79 passed), pnpm docs:check all pass.
  • pnpm test: 171 files, 3937 tests, all passing.
  • I ran the resource through the built registry and HarnessClient.buildUrl against a local service-web-admin, and every request returned 200 with the expected filtering. The calls covered:
    • project scope and account scope
    • multiple status values with filter=SUBMISSIONS and limit=5
    • filter=APPROVALS
    • resource_type=FEATURE_FLAG
    • resource_type=SEGMENT&segment_type=STANDARD
    • one and two environment_id values

MatiasCasaliSplit and others added 2 commits October 2, 2026 18:02
Read-only list of FME change requests via GET /fme/api/v4/change-requests.
Project-scoped by default, account-wide with resource_scope='account'.
Filters: status, filter, environment_id, resource_type, segment_type, offset/limit.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>

AI-Session-Id: 5a5ac74a-f1b4-4630-a714-f0bb6efc222b
AI-Tool: claude-code
AI-Model: unknown
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant