Audit Harness FME feature flags across a project. Read-only; never writes. Four modes: inventory (list flags with metadata), rollout-report (per-env rollout state with stalled-promotion detection across a confirmed env sequence), stale-audit (find flags with no impressions via lastImpressionAt), pattern-search (find flags whose rule conditions structurally match an attribute name, matcher type, literal value, segment reference, or flag dependency — not a text grep). Use when asked to "show me all flags", "which flags are stale", "what flags are rolled out", "flag inventory", "flag health", "cleanup candidates", "find flags targeting segment X", "which flags depend on flag Y", or "find flags with rule matching attribute Z". Do not use for single-flag deep dive (explain-flag), creating flags (create-feature-flag), updating targeting (update-flag-targeting), archiving/deleting (manage-flag-lifecycle), pipeline rollouts (fme-pipeline), or code removal (cleanup-feature-flags).
99%
Does it follow best practices?
Run evals on this skill
Adds up to 20 points to the overall score
Passed
No findings from the security scan
Audit Harness FME feature flags across a project: list all flags with metadata, show rollout status per environment, find stale flags, or search rule conditions structurally. Read-only. Never writes. Related: explain-flag (single flag), cleanup-feature-flags (code removal), manage-flag-lifecycle (archive).
Works through the Harness MCP server or the Harness CLI; names are from tool-map.md.
| Operation | MCP | CLI |
|---|---|---|
| List environments | harness_list · fme_environment · filters: { offset: 0, limit: 100 } · compact: false | harness list fme_environment --json |
| List rollout statuses | harness_list · fme_rollout_status · filters: { offset: 0, limit: 100 } · compact: false | harness list rollout_status --json |
| List flags | harness_list · fme_feature_flag · size: 50 · filters: { name?, tags?, rollout_status_id?, offset? } · compact: false | harness list feature_flag [--search <name>] [--status <ACTIVE|ARCHIVED>] --limit 50 --json |
| Get flag | harness_get · fme_feature_flag · params.feature_flag_name | harness get feature_flag <name> --json |
| List definitions | harness_list · fme_feature_flag_definition · params.feature_flag_name · filters: { offset: 0, limit: 100 } · compact: false | harness list feature_flag:definition <name> --json |
| List segments | harness_list · fme_segment · filters: { segment_type, status?, offset: 0, limit: 100 } · compact: false | harness list segment --segment-type <STANDARD|LARGE|RULE_BASED> --json; cover ACTIVE and ARCHIVED with declared status filters |
| List experiments | harness_list · fme_experiment · filters: { parent_type: "FEATURE_FLAG", parent_name, status: ["ACTIVE", "PAUSED"], offset: 0, limit: 100 } · compact: false | harness list experiment --parent-type FEATURE_FLAG --parent-name <name> --status ACTIVE --json, then again with --status PAUSED |
For each filter: apply it server-side if declared by the installed transport (verify via --help); otherwise fetch the complete inventory and filter client-side. Paginate every list to completion per tool-map.md.
Fixed shape per mode:
Inventory: | Flag | Traffic type | Status | Rollout status | Tags | Owners | Created | Updated |
Rollout report: | Flag | <Env 1>* | <Env 2>* | … | Promotion | Notes | (production envs *; cells use actual treatment names/percentages, killed→<fallback>, targeted, limited, missing, unknown or archived). Promotion: stalled?, ahead, ok, behind (no alert), divergence, both killed, missing, unknown, intended ✓, not comparable, archived, or — for neutral-only. Label each hop in multi-env chains; see promotion-check.md.
Stale audit: | Flag | Bucket | Last Impression Per Env | Config | Next Step | (buckets: stale / active / unknown / never evaluated; verdicts: ready / caution / blocked)
Pattern search: | Flag | Env | Rule # | Combiner | Negated | Matcher type | Predicate match | Status | Notes | (coverage footer: matched N / no-match M / unparsed P / unchecked U; see rule-patterns.md)
Summary: counts per class, truncation line if paginated, hand-offs to sibling skills.
Follow scope-establishment.md. Restate: Working in org=..., project=....
Ask only for missing items relevant to the user's goal:
List environments through every page: ID → { name, isProduction }. Default display order: non-production first, production last. The environment sequence for promotion checks must be confirmed explicitly by the user — do not derive order from isProduction alone. List rollout statuses through every page: name → ID. Apply pagination completeness checks from tool-map.md.
Apply declared server-side filters (name, tags, rollout_status_id); handle remaining filters client-side on the complete inventory. Page through every offset to a short page. Inventory mode stops here. Skip to Phase 6.
Cost guard (rollout-report / stale-audit / pattern-search): If >50 flags after filtering, STOP: "This will fetch N paginated definition inventories. Narrow by tag, name, rollout status, or status, or confirm to proceed." See tool-map.md.
For each flag, list definitions (all pages, filters.limit: 100, advance offset). Failed or skipped pages → incomplete; never label unseen definitions missing.
Rollout-report: Classify each (flag, env) cell per concepts.md: killed → no definition → allocation < 100 → rules/targets present → defaultRule shape. For the confirmed promotion sequence, apply promotion-check.md to produce the Promotion column. Archived flags (global status: ARCHIVED): include in table as archived row; exclude from stalled/divergence alerts.
Stale-audit: Buckets per concepts.md §Staleness. impressions.lastImpressionAt: ISO-8601 (null = never evaluated; absent = unknown). For ready/caution candidates, run the experiment check (ACTIVE and PAUSED) per write-safety.md. Next Step: hand off to cleanup-feature-flags (code) or manage-flag-lifecycle (archive).
Pattern-search: Apply structural rule matching per rule-patterns.md. To resolve a segment name to its type, list that segment type's metadata via List segments (one complete paginated inventory per type; reuse across all flags). Killed flag definitions: scan rules but annotate matches inactive (killed). Archived flags included by the requested status filter: retain structural matches and annotate inactive (archived); do not imply live exposure.
Present the fixed table for the mode. Summary counts per class or bucket. Pagination alone is not truncation: report truncation/incomplete coverage only if the inventory was not finished.
Hand-offs: Single-flag → explain-flag. Cleanup candidate → cleanup-feature-flags. Archive → manage-flag-lifecycle. Update targeting → update-flag-targeting. Pipeline rollout → fme-pipeline.
new-checkout-flow rolled out?" — Route to explain-flag for one flag.payments" — Inventory mode, filter by tag.stale + fully rolled out.beta-users (STANDARD)" — Pattern-search, segment reference predicate.flag-A?" — Pattern-search, flag dependency predicate (IN_SPLIT).| Issue | Fix |
|---|---|
impressions.lastImpressionAt absent | Treat as unknown bucket; never infer "unused" |
| Definitions call fails with 404 | Re-list flags; confirm exact name (case-sensitive) |
| "Too many requests" or timeout | Narrow by tag, rollout status, or name; or process in batches |
| Pattern-search returns unparsed rows | See rule-patterns.md §Unparsed Shapes |
| Promotion check cannot compare | Confirm env IDs, sequence, and intended treatment per promotion-check.md |
See tool-map.md for generic errors.
harness/harness-ai
ca2ab81
If you maintain this skill, you can claim it as your own. Once claimed, you can manage eval scenarios, bundle related skills, attach documentation or rules, and ensure cross-agent compatibility.