/* * 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 DeleteInstructionRequest = { /** * The ID of the instruction. */ instructionId: string; }; /** @internal */ export const DeleteInstructionRequest$inboundSchema: z.ZodType< DeleteInstructionRequest, z.ZodTypeDef, unknown > = z.object({ instruction_id: z.string(), }).transform((v) => { return remap$(v, { "instruction_id": "instructionId", }); }); /** @internal */ export type DeleteInstructionRequest$Outbound = { instruction_id: string; }; /** @internal */ export const DeleteInstructionRequest$outboundSchema: z.ZodType< DeleteInstructionRequest$Outbound, z.ZodTypeDef, DeleteInstructionRequest > = z.object({ instructionId: z.string(), }).transform((v) => { return remap$(v, { instructionId: "instruction_id", }); }); export function deleteInstructionRequestToJSON( deleteInstructionRequest: DeleteInstructionRequest, ): string { return JSON.stringify( DeleteInstructionRequest$outboundSchema.parse(deleteInstructionRequest), ); } export function deleteInstructionRequestFromJSON( jsonString: string, ): SafeParseResult { return safeParse( jsonString, (x) => DeleteInstructionRequest$inboundSchema.parse(JSON.parse(x)), `Failed to parse 'DeleteInstructionRequest' from JSON`, ); }