/* * 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 WebhookBillingStatementCreated = { statementID: string; }; /** @internal */ export const WebhookBillingStatementCreated$inboundSchema: z.ZodType< WebhookBillingStatementCreated, z.ZodTypeDef, unknown > = z.object({ statementID: z.string(), }); /** @internal */ export type WebhookBillingStatementCreated$Outbound = { statementID: string; }; /** @internal */ export const WebhookBillingStatementCreated$outboundSchema: z.ZodType< WebhookBillingStatementCreated$Outbound, z.ZodTypeDef, WebhookBillingStatementCreated > = z.object({ statementID: z.string(), }); export function webhookBillingStatementCreatedToJSON( webhookBillingStatementCreated: WebhookBillingStatementCreated, ): string { return JSON.stringify( WebhookBillingStatementCreated$outboundSchema.parse( webhookBillingStatementCreated, ), ); } export function webhookBillingStatementCreatedFromJSON( jsonString: string, ): SafeParseResult { return safeParse( jsonString, (x) => WebhookBillingStatementCreated$inboundSchema.parse(JSON.parse(x)), `Failed to parse 'WebhookBillingStatementCreated' from JSON`, ); }