/* * 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 GetFoldersFolderIdSharingsSharingIdInternalServerErrorData = { error?: string | undefined; }; /** * Internal server error */ export class GetFoldersFolderIdSharingsSharingIdInternalServerError extends WistiaError { error?: string | undefined; /** The original data that was passed to this error instance. */ data$: GetFoldersFolderIdSharingsSharingIdInternalServerErrorData; constructor( err: GetFoldersFolderIdSharingsSharingIdInternalServerErrorData, 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 = "GetFoldersFolderIdSharingsSharingIdInternalServerError"; } } /** * Resource not found */ export type GetFoldersFolderIdSharingsSharingIdNotFoundErrorData = { error?: string | undefined; }; /** * Resource not found */ export class GetFoldersFolderIdSharingsSharingIdNotFoundError extends WistiaError { error?: string | undefined; /** The original data that was passed to this error instance. */ data$: GetFoldersFolderIdSharingsSharingIdNotFoundErrorData; constructor( err: GetFoldersFolderIdSharingsSharingIdNotFoundErrorData, 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 = "GetFoldersFolderIdSharingsSharingIdNotFoundError"; } } /** * Unauthorized, invalid or missing token */ export type GetFoldersFolderIdSharingsSharingIdUnauthorizedErrorData = { error?: string | undefined; }; /** * Unauthorized, invalid or missing token */ export class GetFoldersFolderIdSharingsSharingIdUnauthorizedError extends WistiaError { error?: string | undefined; /** The original data that was passed to this error instance. */ data$: GetFoldersFolderIdSharingsSharingIdUnauthorizedErrorData; constructor( err: GetFoldersFolderIdSharingsSharingIdUnauthorizedErrorData, 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 = "GetFoldersFolderIdSharingsSharingIdUnauthorizedError"; } } /** @internal */ export const GetFoldersFolderIdSharingsSharingIdInternalServerError$inboundSchema: z.ZodType< GetFoldersFolderIdSharingsSharingIdInternalServerError, z.ZodTypeDef, unknown > = z.object({ error: z.string().optional(), request$: z.instanceof(Request), response$: z.instanceof(Response), body$: z.string(), }) .transform((v) => { return new GetFoldersFolderIdSharingsSharingIdInternalServerError(v, { request: v.request$, response: v.response$, body: v.body$, }); }); /** @internal */ export const GetFoldersFolderIdSharingsSharingIdNotFoundError$inboundSchema: z.ZodType< GetFoldersFolderIdSharingsSharingIdNotFoundError, z.ZodTypeDef, unknown > = z.object({ error: z.string().optional(), request$: z.instanceof(Request), response$: z.instanceof(Response), body$: z.string(), }) .transform((v) => { return new GetFoldersFolderIdSharingsSharingIdNotFoundError(v, { request: v.request$, response: v.response$, body: v.body$, }); }); /** @internal */ export const GetFoldersFolderIdSharingsSharingIdUnauthorizedError$inboundSchema: z.ZodType< GetFoldersFolderIdSharingsSharingIdUnauthorizedError, z.ZodTypeDef, unknown > = z.object({ error: z.string().optional(), request$: z.instanceof(Request), response$: z.instanceof(Response), body$: z.string(), }) .transform((v) => { return new GetFoldersFolderIdSharingsSharingIdUnauthorizedError(v, { request: v.request$, response: v.response$, body: v.body$, }); });