/* * Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT. */ import * as z from "zod/v3"; import { destinationsGetAttempt } from "../../funcs/destinationsGetAttempt.js"; import * as operations from "../../models/operations/index.js"; import { formatResult, ToolDefinition } from "../tools.js"; const args = { tenantId: z.string(), destinationId: z.string(), attemptId: z.string(), include: operations.GetTenantDestinationAttemptInclude$inboundSchema .optional(), }; export const tool$destinationsGetAttempt: ToolDefinition = { name: "destinations-get-attempt", description: `Get Destination Attempt Retrieves details for a specific attempt scoped to a destination.`, args, tool: async (client, args, ctx) => { const [result, apiCall] = await destinationsGetAttempt( client, args.tenantId, args.destinationId, args.attemptId, args.include, { fetchOptions: { signal: ctx.signal } }, ).$inspect(); if (!result.ok) { return { content: [{ type: "text", text: result.error.message }], isError: true, }; } const value = result.value; return formatResult(value, apiCall); }, };