extract the request params
improve error handling