def encode_transaction(value):
    """Encode a transaction (dict) to Base64."""

    return base64.b64encode(json.dumps(value).encode('utf8')).decode('utf8')
Encode a transaction (dict) to Base64.
bigchaindb/tendermint_utils.py