UNPKG

@launchdarkly/mcp-server

Version:

The local [Model Context Protocol (MCP)](https://modelcontextprotocol.io/) server for [LaunchDarkly](https://launchdarkly.com/) federal and European Union (EU) environments.

37 lines (31 loc) • 1.06 kB
/* * Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT. */ import { featureFlagsDelete } from "../../funcs/featureFlagsDelete.js"; import * as operations from "../../models/operations/index.js"; import { formatResult, ToolDefinition } from "../tools.js"; const args = { request: operations.DeleteFeatureFlagRequest$inboundSchema, }; export const tool$featureFlagsDelete: ToolDefinition<typeof args> = { name: "delete-feature-flag", description: `Removes a feature flag from the project. Used by AI agents to clean up deprecated toggles that are no longer in use, improving system hygiene and maintainability. `, scopes: ["write"], args, tool: async (client, args, ctx) => { const [result, apiCall] = await featureFlagsDelete( client, args.request, { fetchOptions: { signal: ctx.signal } }, ).$inspect(); if (!result.ok) { return { content: [{ type: "text", text: result.error.message }], isError: true, }; } return formatResult(void 0, apiCall); }, };