/*
 * Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.
 */

import * as z from "zod/v4-mini";
import {
  BenefitCustomCreate,
  BenefitCustomCreate$Outbound,
  BenefitCustomCreate$outboundSchema,
} from "./benefitcustomcreate.js";
import {
  BenefitDiscordCreate,
  BenefitDiscordCreate$Outbound,
  BenefitDiscordCreate$outboundSchema,
} from "./benefitdiscordcreate.js";
import {
  BenefitDownloadablesCreate,
  BenefitDownloadablesCreate$Outbound,
  BenefitDownloadablesCreate$outboundSchema,
} from "./benefitdownloadablescreate.js";
import {
  BenefitFeatureFlagCreate,
  BenefitFeatureFlagCreate$Outbound,
  BenefitFeatureFlagCreate$outboundSchema,
} from "./benefitfeatureflagcreate.js";
import {
  BenefitGitHubRepositoryCreate,
  BenefitGitHubRepositoryCreate$Outbound,
  BenefitGitHubRepositoryCreate$outboundSchema,
} from "./benefitgithubrepositorycreate.js";
import {
  BenefitLicenseKeysCreate,
  BenefitLicenseKeysCreate$Outbound,
  BenefitLicenseKeysCreate$outboundSchema,
} from "./benefitlicensekeyscreate.js";
import {
  BenefitMeterCreditCreate,
  BenefitMeterCreditCreate$Outbound,
  BenefitMeterCreditCreate$outboundSchema,
} from "./benefitmetercreditcreate.js";
import {
  BenefitSlackSharedChannelCreate,
  BenefitSlackSharedChannelCreate$Outbound,
  BenefitSlackSharedChannelCreate$outboundSchema,
} from "./benefitslacksharedchannelcreate.js";

export type BenefitCreate =
  | BenefitCustomCreate
  | BenefitDiscordCreate
  | BenefitDownloadablesCreate
  | BenefitFeatureFlagCreate
  | BenefitGitHubRepositoryCreate
  | BenefitLicenseKeysCreate
  | BenefitMeterCreditCreate
  | BenefitSlackSharedChannelCreate;

/** @internal */
export type BenefitCreate$Outbound =
  | BenefitCustomCreate$Outbound
  | BenefitDiscordCreate$Outbound
  | BenefitDownloadablesCreate$Outbound
  | BenefitFeatureFlagCreate$Outbound
  | BenefitGitHubRepositoryCreate$Outbound
  | BenefitLicenseKeysCreate$Outbound
  | BenefitMeterCreditCreate$Outbound
  | BenefitSlackSharedChannelCreate$Outbound;

/** @internal */
export const BenefitCreate$outboundSchema: z.ZodMiniType<
  BenefitCreate$Outbound,
  BenefitCreate
> = z.union([
  BenefitCustomCreate$outboundSchema,
  BenefitDiscordCreate$outboundSchema,
  BenefitDownloadablesCreate$outboundSchema,
  BenefitFeatureFlagCreate$outboundSchema,
  BenefitGitHubRepositoryCreate$outboundSchema,
  BenefitLicenseKeysCreate$outboundSchema,
  BenefitMeterCreditCreate$outboundSchema,
  BenefitSlackSharedChannelCreate$outboundSchema,
]);

export function benefitCreateToJSON(benefitCreate: BenefitCreate): string {
  return JSON.stringify(BenefitCreate$outboundSchema.parse(benefitCreate));
}
