Refactor and tidy up a a few things.
Add retrieving shared projects from the API.