ManagedBlockchainQuery / Client / list_transactions

list_transactions#

ManagedBlockchainQuery.Client.list_transactions(**kwargs)#

Lists all of the transactions on a given wallet address or to a specific contract.

See also: AWS API Documentation

Request Syntax

response = client.list_transactions(
    address='string',
    network='ETHEREUM_MAINNET'|'ETHEREUM_SEPOLIA_TESTNET'|'BITCOIN_MAINNET'|'BITCOIN_TESTNET',
    fromBlockchainInstant={
        'time': datetime(2015, 1, 1)
    },
    toBlockchainInstant={
        'time': datetime(2015, 1, 1)
    },
    sort={
        'sortBy': 'TRANSACTION_TIMESTAMP',
        'sortOrder': 'ASCENDING'|'DESCENDING'
    },
    nextToken='string',
    maxResults=123
)
Parameters:
  • address (string) –

    [REQUIRED]

    The address (either a contract or wallet), whose transactions are being requested.

  • network (string) –

    [REQUIRED]

    The blockchain network where the transactions occurred.

  • fromBlockchainInstant (dict) –

    The container for time.

    • time (datetime) –

      The container of the Timestamp of the blockchain instant.

      Note

      This timestamp will only be recorded up to the second.

  • toBlockchainInstant (dict) –

    The container for time.

    • time (datetime) –

      The container of the Timestamp of the blockchain instant.

      Note

      This timestamp will only be recorded up to the second.

  • sort (dict) –

    Sorts items in an ascending order if the first page starts at fromTime. Sorts items in a descending order if the first page starts at toTime.

    • sortBy (string) –

      Defaults to the value TRANSACTION_TIMESTAMP.

    • sortOrder (string) –

      The container for the sort order for ListTransactions. The SortOrder field only accepts the values ASCENDING and DESCENDING. Not providing SortOrder will default to ASCENDING.

  • nextToken (string) – The pagination token that indicates the next set of results to retrieve.

  • maxResults (integer) –

    The maximum number of transactions to list.

    Note

    Even if additional results can be retrieved, the request can return less results than maxResults or an empty array of results.

    To retrieve the next set of results, make another request with the returned nextToken value. The value of nextToken is null when there are no more results to return

Return type:

dict

Returns:

Response Syntax

{
    'transactions': [
        {
            'transactionHash': 'string',
            'network': 'ETHEREUM_MAINNET'|'ETHEREUM_SEPOLIA_TESTNET'|'BITCOIN_MAINNET'|'BITCOIN_TESTNET',
            'transactionTimestamp': datetime(2015, 1, 1)
        },
    ],
    'nextToken': 'string'
}

Response Structure

  • (dict) –

    • transactions (list) –

      The array of transactions returned by the request.

      • (dict) –

        The container of the transaction output.

        • transactionHash (string) –

          The hash of the transaction. It is generated whenever a transaction is verified and added to the blockchain.

        • network (string) –

          The blockchain network where the transaction occurred.

        • transactionTimestamp (datetime) –

          The time when the transaction occurred.

    • nextToken (string) –

      The pagination token that indicates the next set of results to retrieve.

Exceptions

  • ManagedBlockchainQuery.Client.exceptions.ThrottlingException

  • ManagedBlockchainQuery.Client.exceptions.ValidationException

  • ManagedBlockchainQuery.Client.exceptions.AccessDeniedException

  • ManagedBlockchainQuery.Client.exceptions.InternalServerException

  • ManagedBlockchainQuery.Client.exceptions.ServiceQuotaExceededException