Default to returning base64 encoded content

Depending on encoding header, return either utf-8 or base64 encoded
data. This is similar behavior to github's blob api.