/*
 * Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.
 */
import * as z from "zod";
import { remap as remap$ } from "../../lib/primitives.js";
import { safeParse } from "../../lib/schemas.js";
/** @internal */
export const Security$inboundSchema = z.object({
    api_key: z.string().optional(),
    api_secret: z.string().optional(),
}).transform((v) => {
    return remap$(v, {
        "api_key": "apiKey",
        "api_secret": "apiSecret",
    });
});
/** @internal */
export const Security$outboundSchema = z.object({
    apiKey: z.string().optional(),
    apiSecret: z.string().optional(),
}).transform((v) => {
    return remap$(v, {
        apiKey: "api_key",
        apiSecret: "api_secret",
    });
});
/**
 * @internal
 * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
 */
export var Security$;
(function (Security$) {
    /** @deprecated use `Security$inboundSchema` instead. */
    Security$.inboundSchema = Security$inboundSchema;
    /** @deprecated use `Security$outboundSchema` instead. */
    Security$.outboundSchema = Security$outboundSchema;
})(Security$ || (Security$ = {}));
export function securityToJSON(security) {
    return JSON.stringify(Security$outboundSchema.parse(security));
}
export function securityFromJSON(jsonString) {
    return safeParse(jsonString, (x) => Security$inboundSchema.parse(JSON.parse(x)), `Failed to parse 'Security' from JSON`);
}
//# sourceMappingURL=security.js.map