Add request object

This is essentially a bag of everything relating to the request.

Fixes #552.
Should the `strtoupper()` happen within `set_method()` so we can be sure it always conforms? I see you're already using it twice here.