This is the ThingsDB documentation for version v0, click here for the latest version!
Decode a Base64 encoded string.
See base64_encode for Base64 encoding.
This function does not generate an event.
base64_decode(encoded)
Argument | Type | Description |
---|---|---|
encoded | str/bytes | The string value to decode. |
Decoded bytes value is returned.
This code shows an example for base64_decode:
encoded = 'YmFzZTY0IGVuY29kZWQgc3RyaW5n';
// decode
data = base64_decode(encoded);
// result is of type bytes
assert(type(data) == 'bytes');
// return as string
str(data);
Return value in JSON format
"base64 encoded string"