async def _build_rr_delta_json(self, rr_id: str, to: int, fro: int = None, fro_delta: dict = None) -> (str, int):
LOGGER.debug(<EOL>'<STR_LIT>',<EOL>rr_id,<EOL>to,<EOL>fro,<EOL>fro_delta)<EOL>rr_delta_json = None<EOL>ledger_timestamp = None<EOL>get_rr_delta_req_json = await ledger.build_get_revoc_reg_delta_request(self.did, rr_id, fro, to)<EOL>resp_json = await self._submit(get_rr_delta_req_json)<EOL>resp = json.loads(resp_json)<EOL>if resp.get('<STR_LIT:result>', {}).get('<STR_LIT:data>', None) and resp['<STR_LIT:result>']['<STR_LIT:data>'].get('<STR_LIT:value>', None):<EOL><INDENT>try:<EOL><INDENT>(_, rr_delta_json, ledger_timestamp) = await ledger.parse_get_revoc_reg_delta_response(resp_json)<EOL><DEDENT>except IndyError:  <EOL><INDENT>LOGGER.debug('<STR_LIT>', rr_id)<EOL>raise AbsentRevReg('<STR_LIT>'.format(rr_id))<EOL><DEDENT><DEDENT>else:<EOL><INDENT>LOGGER.debug(<EOL>'<STR_LIT>',<EOL>rr_id,<EOL>to)<EOL>raise BadRevStateTime('<STR_LIT>'.format(rr_id, to))<EOL><DEDENT>if fro and fro_delta:<EOL><INDENT>rr_delta_json = await anoncreds.issuer_merge_revocation_registry_deltas(<EOL>json.dumps(fro_delta),<EOL>rr_delta_json)<EOL><DEDENT>rv = (rr_delta_json, ledger_timestamp)<EOL>LOGGER.debug('<STR_LIT>', rv)<EOL>return rv<EOL>
Build rev reg delta json, potentially starting from existing (earlier) delta.

Return delta json and its timestamp on the distributed ledger.

Raise AbsentRevReg for no such revocation registry, or BadRevStateTime for a requested delta to
a time preceding revocation registry creation.

:param rr_id: rev reg id
:param to: time (epoch seconds) of interest; upper-bounds returned timestamp
:param fro: optional prior time of known delta json
:param fro_delta: optional known delta as of time fro
:return: rev reg delta json and ledger timestamp (epoch seconds)