/* * Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT. * @generated-id: 4a48bbc8ec42 */ 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"; export type InsightsChatSummary = { /** * Number of current Monthly Active Users, in the specified departments. */ monthlyActiveUsers?: number | undefined; /** * Number of current Weekly Active Users, in the specified departments. */ weeklyActiveUsers?: number | undefined; /** * Total number of chats by users over the specified time period. */ numChats?: number | undefined; /** * Total number of distinct users who used Chat over the specified time period. */ numChatUsers?: number | undefined; }; /** @internal */ export const InsightsChatSummary$inboundSchema: z.ZodType< InsightsChatSummary, z.ZodTypeDef, unknown > = z.object({ monthlyActiveUsers: z.number().int().optional(), weeklyActiveUsers: z.number().int().optional(), numChats: z.number().int().optional(), numChatUsers: z.number().int().optional(), }); export function insightsChatSummaryFromJSON( jsonString: string, ): SafeParseResult { return safeParse( jsonString, (x) => InsightsChatSummary$inboundSchema.parse(JSON.parse(x)), `Failed to parse 'InsightsChatSummary' from JSON`, ); }