/* * Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT. */ import * as z from "zod"; import { safeParse } from "../../lib/schemas.js"; import { Result as SafeParseResult } from "../../types/fp.js"; import { SDKValidationError } from "../errors/sdkvalidationerror.js"; export type V3DeviceRevokeRequest = { /** * A client-generated unique ID for a specific session. This can be used to identify specific requests. * * @remarks * The format of this ID is defined by the client - Prove recommends using a GUID, but any format can be accepted. * Do not include Personally Identifiable Information (PII) in this field. */ clientRequestId: string; /** * The unique identifier for the Prove Key on the device. */ deviceId: string; }; /** @internal */ export const V3DeviceRevokeRequest$inboundSchema: z.ZodType< V3DeviceRevokeRequest, z.ZodTypeDef, unknown > = z.object({ clientRequestId: z.string(), deviceId: z.string(), }); /** @internal */ export type V3DeviceRevokeRequest$Outbound = { clientRequestId: string; deviceId: string; }; /** @internal */ export const V3DeviceRevokeRequest$outboundSchema: z.ZodType< V3DeviceRevokeRequest$Outbound, z.ZodTypeDef, V3DeviceRevokeRequest > = z.object({ clientRequestId: z.string(), deviceId: z.string(), }); /** * @internal * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module. */ export namespace V3DeviceRevokeRequest$ { /** @deprecated use `V3DeviceRevokeRequest$inboundSchema` instead. */ export const inboundSchema = V3DeviceRevokeRequest$inboundSchema; /** @deprecated use `V3DeviceRevokeRequest$outboundSchema` instead. */ export const outboundSchema = V3DeviceRevokeRequest$outboundSchema; /** @deprecated use `V3DeviceRevokeRequest$Outbound` instead. */ export type Outbound = V3DeviceRevokeRequest$Outbound; } export function v3DeviceRevokeRequestToJSON( v3DeviceRevokeRequest: V3DeviceRevokeRequest, ): string { return JSON.stringify( V3DeviceRevokeRequest$outboundSchema.parse(v3DeviceRevokeRequest), ); } export function v3DeviceRevokeRequestFromJSON( jsonString: string, ): SafeParseResult { return safeParse( jsonString, (x) => V3DeviceRevokeRequest$inboundSchema.parse(JSON.parse(x)), `Failed to parse 'V3DeviceRevokeRequest' from JSON`, ); }