/*
 * Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.
 * @generated-id: 4b4aede044ad
 */
import * as z from "zod/v4";
import { remap as remap$ } from "../../lib/primitives.js";
import { safeParse } from "../../lib/schemas.js";
import { ConsumerType$inboundSchema } from "./consumertype.js";
import { ToolExecutionConfiguration$inboundSchema, } from "./toolexecutionconfiguration.js";
/** @internal */
export const ConnectionPreference$inboundSchema = z.object({
    name: z.string(),
    tool_configuration: ToolExecutionConfiguration$inboundSchema,
    is_default: z.nullable(z.boolean()).optional(),
    consumer_type: z.nullable(ConsumerType$inboundSchema).optional(),
}).transform((v) => {
    return remap$(v, {
        "tool_configuration": "toolConfiguration",
        "is_default": "isDefault",
        "consumer_type": "consumerType",
    });
});
export function connectionPreferenceFromJSON(jsonString) {
    return safeParse(jsonString, (x) => ConnectionPreference$inboundSchema.parse(JSON.parse(x)), `Failed to parse 'ConnectionPreference' from JSON`);
}
//# sourceMappingURL=connectionpreference.js.map