/* * Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT. */ import * as z from "zod/v3"; import { WistiaError } from "./wistiaerror.js"; /** * Internal server error */ export type DeleteMediasMediaIdCustomizationsInternalServerErrorData = { error?: string | undefined; }; /** * Internal server error */ export class DeleteMediasMediaIdCustomizationsInternalServerError extends WistiaError { error?: string | undefined; /** The original data that was passed to this error instance. */ data$: DeleteMediasMediaIdCustomizationsInternalServerErrorData; constructor( err: DeleteMediasMediaIdCustomizationsInternalServerErrorData, httpMeta: { response: Response; request: Request; body: string }, ) { const message = "message" in err && typeof err.message === "string" ? err.message : `API error occurred: ${JSON.stringify(err)}`; super(message, httpMeta); this.data$ = err; if (err.error != null) this.error = err.error; this.name = "DeleteMediasMediaIdCustomizationsInternalServerError"; } } /** * Resource not found */ export type DeleteMediasMediaIdCustomizationsNotFoundErrorData = { error?: string | undefined; }; /** * Resource not found */ export class DeleteMediasMediaIdCustomizationsNotFoundError extends WistiaError { error?: string | undefined; /** The original data that was passed to this error instance. */ data$: DeleteMediasMediaIdCustomizationsNotFoundErrorData; constructor( err: DeleteMediasMediaIdCustomizationsNotFoundErrorData, httpMeta: { response: Response; request: Request; body: string }, ) { const message = "message" in err && typeof err.message === "string" ? err.message : `API error occurred: ${JSON.stringify(err)}`; super(message, httpMeta); this.data$ = err; if (err.error != null) this.error = err.error; this.name = "DeleteMediasMediaIdCustomizationsNotFoundError"; } } /** * Unauthorized, invalid or missing token */ export type DeleteMediasMediaIdCustomizationsUnauthorizedErrorData = { error?: string | undefined; }; /** * Unauthorized, invalid or missing token */ export class DeleteMediasMediaIdCustomizationsUnauthorizedError extends WistiaError { error?: string | undefined; /** The original data that was passed to this error instance. */ data$: DeleteMediasMediaIdCustomizationsUnauthorizedErrorData; constructor( err: DeleteMediasMediaIdCustomizationsUnauthorizedErrorData, httpMeta: { response: Response; request: Request; body: string }, ) { const message = "message" in err && typeof err.message === "string" ? err.message : `API error occurred: ${JSON.stringify(err)}`; super(message, httpMeta); this.data$ = err; if (err.error != null) this.error = err.error; this.name = "DeleteMediasMediaIdCustomizationsUnauthorizedError"; } } /** @internal */ export const DeleteMediasMediaIdCustomizationsInternalServerError$inboundSchema: z.ZodType< DeleteMediasMediaIdCustomizationsInternalServerError, z.ZodTypeDef, unknown > = z.object({ error: z.string().optional(), request$: z.instanceof(Request), response$: z.instanceof(Response), body$: z.string(), }) .transform((v) => { return new DeleteMediasMediaIdCustomizationsInternalServerError(v, { request: v.request$, response: v.response$, body: v.body$, }); }); /** @internal */ export const DeleteMediasMediaIdCustomizationsNotFoundError$inboundSchema: z.ZodType< DeleteMediasMediaIdCustomizationsNotFoundError, z.ZodTypeDef, unknown > = z.object({ error: z.string().optional(), request$: z.instanceof(Request), response$: z.instanceof(Response), body$: z.string(), }) .transform((v) => { return new DeleteMediasMediaIdCustomizationsNotFoundError(v, { request: v.request$, response: v.response$, body: v.body$, }); }); /** @internal */ export const DeleteMediasMediaIdCustomizationsUnauthorizedError$inboundSchema: z.ZodType< DeleteMediasMediaIdCustomizationsUnauthorizedError, z.ZodTypeDef, unknown > = z.object({ error: z.string().optional(), request$: z.instanceof(Request), response$: z.instanceof(Response), body$: z.string(), }) .transform((v) => { return new DeleteMediasMediaIdCustomizationsUnauthorizedError(v, { request: v.request$, response: v.response$, body: v.body$, }); });