automatically generate base64 for samples