Changed
- Expose the internal resin-request and resin-token instances
- Corrected `environmentVariables.getAll` in documentation to `.getAllByApplication`
- Add support for hooks to intercept requests, responses, and errors.
- Deprecated `resin.models.application.getApiKey()` (use `.generateApiKey()` instead).
- **Breaking!** Removed the (already deprecated) `resin.models.device.restart()` method, in favor of `resin.models.device.restartApplication()`
- Add factory function defaults so all options are optional. Example: `require('resin-sdk')();`
- Allow device & application ids for all methods, in addition to device uuids & application names, if the argument is a number instead of a string.