Better exception handling added.

- Includes 404 resource not found.
- Also raise an generic RequestException for other responses other
than 422, 401 and 404.