import * as httpAssert from 'http-assert'; import { HttpError } from 'http-errors'; try { httpAssert.equal('hello', 'hello'); httpAssert(false, 401, 'authentication failed'); } catch (err) { console.log(( err).status); console.log(( err).message); console.log(( err).expose); }