/*
 * Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.
 * @generated-id: f3cdc62104da
 */
import * as z from "zod/v4";
import { remap as remap$ } from "../../lib/primitives.js";
import { safeParse } from "../../lib/schemas.js";
import { MCPServerIcon$inboundSchema } from "./mcpservericon.js";
import { ToolAnnotations$inboundSchema, } from "./toolannotations.js";
import { ToolExecution$inboundSchema } from "./toolexecution.js";
/** @internal */
export const MCPToolMeta$inboundSchema = z
    .object({
    name: z.string(),
    title: z.nullable(z.string()).optional(),
    description: z.nullable(z.string()).optional(),
    inputSchema: z.record(z.string(), z.any()),
    outputSchema: z.nullable(z.record(z.string(), z.any())).optional(),
    icons: z.nullable(z.array(MCPServerIcon$inboundSchema)).optional(),
    annotations: z.nullable(ToolAnnotations$inboundSchema).optional(),
    _meta: z.nullable(z.lazy(() => MCPToolMeta$inboundSchema)).optional(),
    execution: z.nullable(ToolExecution$inboundSchema).optional(),
}).catchall(z.any()).transform((v) => {
    return remap$(v, {
        "_meta": "meta",
    });
});
export function mcpToolMetaFromJSON(jsonString) {
    return safeParse(jsonString, (x) => MCPToolMeta$inboundSchema.parse(JSON.parse(x)), `Failed to parse 'MCPToolMeta' from JSON`);
}
//# sourceMappingURL=mcptoolmeta.js.map