/* * Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT. * @generated-id: 36d23c68493b */ import * as z from "zod"; import { triggersDeleteTrigger } from "../../funcs/triggersDeleteTrigger.js"; import { formatResult, ToolDefinition } from "../tools.js"; const args = { id: z.string().describe("The ID of the trigger."), }; export const tool$triggersDeleteTrigger: ToolDefinition = { name: "delete-trigger", description: `Deletes a notification trigger Deletes a trigger.`, scopes: ["admin"], annotations: { "title": "Delete Trigger", "destructiveHint": true, "idempotentHint": true, "openWorldHint": false, "readOnlyHint": false, }, args, tool: async (client, args, ctx) => { const [result] = await triggersDeleteTrigger( client, args.id, { fetchOptions: { signal: ctx.signal } }, ).$inspect(); if (!result.ok) { return { content: [{ type: "text", text: result.error.message }], isError: true, }; } return formatResult(result.value); }, };