Check setup status when making API responses

Closes #3303, Closes #3299
- Check whether or not setup has been completed when deciding
  how to respond to certain API requests.
- Add tests.
Merge pull request #3322 from jaswilli/check-setup

Check setup status when making API responses