Added CastError check and if so then send bad req

Jest now sends `Bad Request` when input parameters fails to cast.