/* * Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT. */ 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 GetSubscriberNotificationsCountResponseDto = { /** * The count of notifications matching the filter */ count: number; /** * The filter applied */ filter: { [k: string]: any }; }; /** @internal */ export const GetSubscriberNotificationsCountResponseDto$inboundSchema: z.ZodType = z.object({ count: z.number(), filter: z.record(z.any()), }); export function getSubscriberNotificationsCountResponseDtoFromJSON( jsonString: string, ): SafeParseResult< GetSubscriberNotificationsCountResponseDto, SDKValidationError > { return safeParse( jsonString, (x) => GetSubscriberNotificationsCountResponseDto$inboundSchema.parse( JSON.parse(x), ), `Failed to parse 'GetSubscriberNotificationsCountResponseDto' from JSON`, ); }