/* * Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT. * @generated-id: 1f372fe1b408 */ import * as z from "zod/v4"; import { remap as remap$ } from "../../lib/primitives.js"; import { ConnectorAuthenticationHeader, ConnectorAuthenticationHeader$Outbound, ConnectorAuthenticationHeader$outboundSchema, } from "./connectorauthenticationheader.js"; export type BearerAuthMethod = { methodType: "bearer"; /** * Optional additional headers sent with requests. */ headers?: Array | null | undefined; }; /** @internal */ export type BearerAuthMethod$Outbound = { method_type: "bearer"; headers?: Array | null | undefined; }; /** @internal */ export const BearerAuthMethod$outboundSchema: z.ZodType< BearerAuthMethod$Outbound, BearerAuthMethod > = z.object({ methodType: z.literal("bearer"), headers: z.nullable(z.array(ConnectorAuthenticationHeader$outboundSchema)) .optional(), }).transform((v) => { return remap$(v, { methodType: "method_type", }); }); export function bearerAuthMethodToJSON( bearerAuthMethod: BearerAuthMethod, ): string { return JSON.stringify( BearerAuthMethod$outboundSchema.parse(bearerAuthMethod), ); }