/* * Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT. */ import * as z from "zod"; import { safeParse } from "../../lib/schemas.js"; import { Result as SafeParseResult } from "../../types/fp.js"; import { SDKValidationError } from "../errors/sdkvalidationerror.js"; export type DeleteApiV1IndexerIdRequest = { id: number; }; /** @internal */ export const DeleteApiV1IndexerIdRequest$inboundSchema: z.ZodType< DeleteApiV1IndexerIdRequest, z.ZodTypeDef, unknown > = z.object({ id: z.number().int(), }); /** @internal */ export type DeleteApiV1IndexerIdRequest$Outbound = { id: number; }; /** @internal */ export const DeleteApiV1IndexerIdRequest$outboundSchema: z.ZodType< DeleteApiV1IndexerIdRequest$Outbound, z.ZodTypeDef, DeleteApiV1IndexerIdRequest > = z.object({ id: z.number().int(), }); /** * @internal * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module. */ export namespace DeleteApiV1IndexerIdRequest$ { /** @deprecated use `DeleteApiV1IndexerIdRequest$inboundSchema` instead. */ export const inboundSchema = DeleteApiV1IndexerIdRequest$inboundSchema; /** @deprecated use `DeleteApiV1IndexerIdRequest$outboundSchema` instead. */ export const outboundSchema = DeleteApiV1IndexerIdRequest$outboundSchema; /** @deprecated use `DeleteApiV1IndexerIdRequest$Outbound` instead. */ export type Outbound = DeleteApiV1IndexerIdRequest$Outbound; } export function deleteApiV1IndexerIdRequestToJSON( deleteApiV1IndexerIdRequest: DeleteApiV1IndexerIdRequest, ): string { return JSON.stringify( DeleteApiV1IndexerIdRequest$outboundSchema.parse( deleteApiV1IndexerIdRequest, ), ); } export function deleteApiV1IndexerIdRequestFromJSON( jsonString: string, ): SafeParseResult { return safeParse( jsonString, (x) => DeleteApiV1IndexerIdRequest$inboundSchema.parse(JSON.parse(x)), `Failed to parse 'DeleteApiV1IndexerIdRequest' from JSON`, ); }