@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) • 976 B
text/typescript
/*
* Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.
*/
import { aiConfigsDelete } from "../../funcs/aiConfigsDelete.js";
import * as operations from "../../models/operations/index.js";
import { formatResult, ToolDefinition } from "../tools.js";
const args = {
request: operations.DeleteAIConfigRequest$inboundSchema,
};
export const tool$aiConfigsDelete: ToolDefinition<typeof args> = {
name: "delete-ai-config",
description:
`Deletes an AI Config and its associated variations. Intended for cleanup or deprecation workflows.
`,
scopes: ["write"],
args,
tool: async (client, args, ctx) => {
const [result, apiCall] = await aiConfigsDelete(
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);
},
};