/* * Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT. */ import * as z from "zod/v3"; import { remap as remap$ } from "../../lib/primitives.js"; import { safeParse } from "../../lib/schemas.js"; import { Result as SafeParseResult } from "../../types/fp.js"; import { SDKValidationError } from "../errors/sdkvalidationerror.js"; export type ReputationEvidenceThreat = { lastObservedTime?: string | undefined; threatId?: string | undefined; threatTypes?: Array | null | undefined; }; /** @internal */ export const ReputationEvidenceThreat$inboundSchema: z.ZodType< ReputationEvidenceThreat, z.ZodTypeDef, unknown > = z.object({ last_observed_time: z.string().optional(), threat_id: z.string().optional(), threat_types: z.nullable(z.array(z.string())).optional(), }).transform((v) => { return remap$(v, { "last_observed_time": "lastObservedTime", "threat_id": "threatId", "threat_types": "threatTypes", }); }); export function reputationEvidenceThreatFromJSON( jsonString: string, ): SafeParseResult { return safeParse( jsonString, (x) => ReputationEvidenceThreat$inboundSchema.parse(JSON.parse(x)), `Failed to parse 'ReputationEvidenceThreat' from JSON`, ); }