UNPKG

@unito/integration-sdk

Version:

Integration SDK

14 lines (10 loc) 344 B
import { Request, Response, NextFunction } from 'express'; import { Error as APIError } from '@unito/integration-api'; function notFound(req: Request, res: Response, _next: NextFunction) { const error: APIError = { code: '404', message: `Path ${req.path} not found.`, }; res.status(404).json(error); } export default notFound;