@@ -346,6 +346,47 @@ async def get_tx_by_hash(self, tx_hash: str):
346346 req = explorer_rpc_pb .GetTxByTxHashRequest (hash = tx_hash )
347347 return await self .stubExplorer .GetTxByTxHash (req )
348348
349+ async def get_account_txs (self , address : str , ** kwargs ):
350+ req = explorer_rpc_pb .GetAccountTxsRequest (
351+ address = address ,
352+ before = kwargs .get ("before" ),
353+ after = kwargs .get ("after" ),
354+ limit = kwargs .get ("limit" ),
355+ skip = kwargs .get ("skip" ),
356+ type = kwargs .get ("type" ),
357+ module = kwargs .get ("module" ))
358+ return await self .stubExplorer .GetAccountTxs (req )
359+
360+ async def get_blocks (self , ** kwargs ):
361+ req = explorer_rpc_pb .GetBlocksRequest (
362+ before = kwargs .get ("before" ),
363+ after = kwargs .get ("after" ),
364+ limit = kwargs .get ("limit" )
365+ )
366+ return await self .stubExplorer .GetBlocks (req )
367+
368+ async def get_block (self , block_height : str ):
369+ req = explorer_rpc_pb .GetBlockRequest (id = block_height )
370+ return await self .stubExplorer .GetBlock (req )
371+
372+ async def get_txs (self , ** kwargs ):
373+ req = explorer_rpc_pb .GetTxsRequest (
374+ before = kwargs .get ("before" ),
375+ after = kwargs .get ("after" ),
376+ limit = kwargs .get ("limit" ),
377+ skip = kwargs .get ("skip" ),
378+ type = kwargs .get ("type" ),
379+ module = kwargs .get ("module" ))
380+ return await self .stubExplorer .GetTxs (req )
381+
382+ async def stream_txs (self ):
383+ req = explorer_rpc_pb .StreamTxsRequest ()
384+ return self .stubExplorer .StreamTxs (req )
385+
386+ async def stream_blocks (self ):
387+ req = explorer_rpc_pb .StreamBlocksRequest ()
388+ return self .stubExplorer .StreamBlocks (req )
389+
349390 # AccountsRPC
350391
351392 async def stream_subaccount_balance (self , subaccount_id : str ):
0 commit comments