AGENT SKILL

manage-feature-flags

Manage Harness Feature Flags (FME / Split.io) via MCP. List flags by workspace, get flag details, create flags, kill or restore flags per environment, archive or unarchive flags, and delete flags. Use when asked to create a feature flag, kill/restore a flag, list flags, check flag status, enable or disable a feature, or manage feature rollouts. Trigger phrases: feature flag, kill switch, restore flag, create flag, feature rollout, archive flag, FME flag.

License 许可
Apache-2.0
最近更新
2026-06-06
Stars
★ 0
Forks
0

01 前言 Front Matter

name
manage-feature-flags
license
Apache-2.0
metadata
{ "author": "Harness", "version": "2.0.0", "mcp-server": "harness-mcp-v2" }
description
Manage Harness Feature Flags (FME / Split.io) via MCP. List flags by workspace, get flag details, create flags, kill or restore flags per environment, archive or unarchive flags, and delete flags. Use when asked to create a feature flag, kill/restore a flag, list flags, check flag status, enable or disable a feature, or manage feature rollouts. Trigger phrases: feature flag, kill switch, restore flag, create flag, feature rollout, archive flag, FME flag.
compatibility
Requires Harness MCP v2 server (harness-mcp-v2). Feature Flags are served by the FME (Split.io) backend — operations use the `fme_feature_flag` resource type and require a `workspace_id`.

03 SKILL.md 正文

Manage Feature Flags

Create, list, kill/restore, and delete Harness FME (Split.io-backed) Feature Flags via MCP.

Prerequisites

FME flags are workspace-scoped (not project-scoped). You must discover the workspace_id and environment_id before most operations.

Step 0a: List workspaces

Call MCP tool: harness_list
Parameters:
  resource_type: "fme_workspace"

Step 0b: List environments (per workspace)

Call MCP tool: harness_list
Parameters:
  resource_type: "fme_environment"
  workspace_id: "<workspace_id>"

Instructions

Step 1: List Existing Flags

Call MCP tool: harness_list
Parameters:
  resource_type: "fme_feature_flag"
  workspace_id: "<workspace_id>"

Filter by name, tags, or rollout status:

Call MCP tool: harness_list
Parameters:
  resource_type: "fme_feature_flag"
  workspace_id: "<workspace_id>"
  name: "dark_mode"
  tags: "ui"
  rollout_status_id: "<uuid>"   # discover via fme_rollout_status

Step 2: Get Flag Details

Call MCP tool: harness_get
Parameters:
  resource_type: "fme_feature_flag"
  workspace_id: "<workspace_id>"
  feature_flag_name: "<flag_name>"

For per-environment targeting/state, use fme_feature_flag_definition and pass environment_id.

Step 3: Create a Flag

Call MCP tool: harness_create
Parameters:
  resource_type: "fme_feature_flag"
  workspace_id: "<workspace_id>"
  traffic_type_id: "<traffic_type_id>"   # required by FME
  body:
    name: "dark_mode"
    description: "Enable dark mode UI theme"
    tags: ["ui", "rollout"]

Step 4: Kill or Restore a Flag (per environment)

Kill (turn the flag OFF in one environment):

Call MCP tool: harness_execute
Parameters:
  resource_type: "fme_feature_flag"
  action: "kill"
  workspace_id: "<workspace_id>"
  feature_flag_name: "<flag_name>"
  environment_id: "<environment_id>"

Restore (re-enable after a kill):

Call MCP tool: harness_execute
Parameters:
  resource_type: "fme_feature_flag"
  action: "restore"
  workspace_id: "<workspace_id>"
  feature_flag_name: "<flag_name>"
  environment_id: "<environment_id>"

Step 5: Archive / Unarchive a Flag

Call MCP tool: harness_execute
Parameters:
  resource_type: "fme_feature_flag"
  action: "archive"      # or "unarchive"
  workspace_id: "<workspace_id>"
  feature_flag_name: "<flag_name>"

Archiving is subject to OPA policy checks (returns 409 on violation). Unarchive returns 409 if dependent objects exist.

Step 6: Update Flag Metadata

Call MCP tool: harness_update
Parameters:
  resource_type: "fme_feature_flag"
  workspace_id: "<workspace_id>"
  feature_flag_name: "<flag_name>"
  body:
    description: "Updated description"
    tags: ["ui", "ga"]

Step 7: Delete a Flag

Call MCP tool: harness_delete
Parameters:
  resource_type: "fme_feature_flag"
  workspace_id: "<workspace_id>"
  feature_flag_name: "<flag_name>"

FME Resource Types Reference

Resource Type Operations Description
fme_workspace list List FME workspaces
fme_environment list List FME environments (per workspace)
fme_feature_flag list, get, create, update, delete, execute(kill/restore/archive/unarchive) Flag metadata at workspace scope
fme_feature_flag_definition list, get Per-environment rollout targeting and state
fme_rollout_status list Discover valid rollout_status_id values
fme_rule_based_segment list, get Rule-based segments
fme_rule_based_segment_definition list, get, execute(enable/disable/change_request) Segment definition per environment

Examples

  • "Create a feature flag for dark mode" — Create fme_feature_flag with body: { name: "dark_mode", ... }
  • "Kill the experimental-search flag in production" — Execute kill with production environment_id
  • "Restore the new-checkout flag in staging" — Execute restore with staging environment_id
  • "List all feature flags in my workspace" — List fme_feature_flag for workspace
  • "Archive the stale beta_banner flag" — Execute archive

Performance Notes

  • Always discover workspace_id and environment_id before kill/restore — wrong environment can affect production.
  • List existing flags before creating to avoid duplicates.
  • FME does not expose a single "toggle" action — use kill (off) and restore (on) per environment.

Troubleshooting

Flag won't kill/restore

  • environment_id is required — kills are per-environment
  • Confirm feature_flag_name is exact (case-sensitive)
  • Verify the flag lives in the specified workspace_id

Flag Not Found

  • FME flags are workspace-scoped — confirm the correct workspace_id
  • Use harness_list with resource_type: "fme_feature_flag" and no filters to see all flags in the workspace

Archive fails with 409

  • An OPA policy may block archival — review governance policies
  • For unarchive, remove dependent segments/targeting before retrying

04 同仓库更多 Skills

AdmiralGallade
AdmiralGallade/harness-repository

verify-sign

Add an Artifact Verification (SscaArtifactVerification) step to an existing Harness pipeline to verify Cosign signatures on container or local-stage artifacts. Supports CI, Security, and CD Deploy (containerized step group). Supports Third-Party registries (Docker, ECR, GCR, GAR, ACR), Harness Artifact Registry (HAR), and Harness Local Stage artifacts. Only works with existing pipelines. Use when asked to verify signed artifacts, verify artifact signature, verify-sign, validate Cosign signature, or configure SscaArtifactVerification. Trigger phrases: verify sign, verify artifact, artifact verification, verify signature, verify-sign, SscaArtifactVerification, verify signed image, verify Cosign, HAR verification.

★ 0
AdmiralGallade
AdmiralGallade/harness-repository

template-usage

Track Harness template dependencies, usage, and adoption via MCP v2 tools. Find which pipelines or other templates reference a given template, analyze update impact, identify unused templates, and compare version adoption. Use when asked about template usage, template references, template dependencies, impact analysis before updating a template, finding unused templates, or tracking template adoption across projects. Trigger phrases: template usage, who uses template, template references, template dependencies, template impact, unused templates, template adoption. Do NOT use for creating or updating templates (use create-template instead).

★ 0
AdmiralGallade
AdmiralGallade/harness-repository

sign-artifact

Add an Artifact Signing (SscaArtifactSigning) step to an existing Harness pipeline to Cosign-sign container or local-stage artifacts with keyless, key-based, or Vault signing. Supports Third-Party registries (Docker, ECR, GCR, GAR, ACR), Harness Artifact Registry (HAR), and Harness Local Stage artifacts. Place after image build/push; optionally upload .sig to the registry. Only works with existing pipelines. Use when asked to sign artifacts, add artifact signing, Cosign sign image, attach signature to registry, or configure SscaArtifactSigning. Trigger phrases: sign artifact, artifact signing, sign image, Cosign sign, add signing step, SscaArtifactSigning, attach signature, sign container image, HAR signing.

★ 0
AdmiralGallade
AdmiralGallade/harness-repository

sei-analytics

Advanced engineering analytics via Harness Software Engineering Insights (SEI) MCP. Configure sprint velocity and estimation accuracy tracking, engineering investment allocation breakdowns, sprint planning with capacity forecasts, and release readiness assessments. Use when asked about sprint analytics, investment allocation, sprint planning, capacity forecasting, or release readiness. Do NOT use for DORA metrics (use dora-metrics instead). Trigger phrases: sprint velocity, sprint analytics, investment allocation, capacity planning, sprint forecast, release readiness, engineering productivity, estimation accuracy, sprint planning, scope creep, code quality trends.

★ 0
AdmiralGallade
AdmiralGallade/harness-repository

security-report

Generate security compliance reports using Harness SCS and STO via MCP. Analyze vulnerabilities, SBOMs, and manage exemptions. Use when user says "security report", "vulnerabilities", "SBOM", "security scan", "compliance check", or asks about application security.

★ 0
AdmiralGallade
AdmiralGallade/harness-repository

scorecard-review

Review service maturity scorecards and compliance using Harness IDP via MCP. Check production readiness, security, and documentation scores. Use when user says "scorecard", "service maturity", "production readiness", "compliance score", or asks about service health scores.

★ 0