Support hashes for tags in content API helpers

Instead of having to pass in slugs for some of the content API helper methods, being able to pass in hashes means we can change more fields in the stubbed responses.

Also refactor and tidy the tag response generation code to remove a lot of the duplication.