/* * Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT. * @generated-id: 8c8d50bd257a */ import * as z from "zod/v3"; import { safeParse } from "../../lib/schemas.js"; import { Result as SafeParseResult } from "../../types/fp.js"; import { SDKValidationError } from "../errors/sdkvalidationerror.js"; /** * Describes the response body of the /getusercount API call */ export type GetUserCountResponse = { /** * Number of users corresponding to the specified custom datasource. */ userCount?: number | undefined; }; /** @internal */ export const GetUserCountResponse$inboundSchema: z.ZodType< GetUserCountResponse, z.ZodTypeDef, unknown > = z.object({ userCount: z.number().int().optional(), }); export function getUserCountResponseFromJSON( jsonString: string, ): SafeParseResult { return safeParse( jsonString, (x) => GetUserCountResponse$inboundSchema.parse(JSON.parse(x)), `Failed to parse 'GetUserCountResponse' from JSON`, ); }