Added base64 encoding