Per code review feedback, the Go template library supports encoding variables in URL query format. Instead of exposing two different public key formats (unmodified string and a URL encoded string), just have the user apply the 'urlquery' modifier to their template.