Class: ParseError
Defined in: src/errors.ts:71
Thrown when Zod validation of the response fails.
Example
ts
import { ParseError } from 'sorbus';
try {
await api.invoices.show({ id: '1' });
} catch (error) {
if (error instanceof ParseError) {
console.log(error.cause);
}
}Extends
Error