add base64 encoding option