/* * Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT. */ import * as z from "zod/v3"; import { Region, Region$outboundSchema } from "./region.js"; export type CreateRoomParams = { /** * System generated id for a deployment. */ deploymentId?: string | undefined; /** * An optional list of client IP addresses to whitelist for DDoS protection. */ clientIPs?: Array | undefined; /** * Optional configuration parameters for the room. Can be any string including stringified JSON. It is accessible from the room via [`GetRoomInfo()`](https://hathora.dev/api#tag/RoomV2/operation/GetRoomInfo). */ roomConfig?: string | undefined; region: Region; }; /** @internal */ export type CreateRoomParams$Outbound = { deploymentId?: string | undefined; clientIPs?: Array | undefined; roomConfig?: string | undefined; region: string; }; /** @internal */ export const CreateRoomParams$outboundSchema: z.ZodType< CreateRoomParams$Outbound, z.ZodTypeDef, CreateRoomParams > = z.object({ deploymentId: z.string().optional(), clientIPs: z.array(z.string()).optional(), roomConfig: z.string().optional(), region: Region$outboundSchema, }); export function createRoomParamsToJSON( createRoomParams: CreateRoomParams, ): string { return JSON.stringify( CreateRoomParams$outboundSchema.parse(createRoomParams), ); }