Class SearchForTransactions
- java.lang.Object
-
- com.algorand.algosdk.v2.client.common.Query
-
- com.algorand.algosdk.v2.client.indexer.SearchForTransactions
-
public class SearchForTransactions extends Query
Search for transactions. Transactions are returned oldest to newest unless the address parameter is used, in which case results are returned newest to oldest. /v2/transactions
-
-
Constructor Summary
Constructors Constructor Description SearchForTransactions(Client client)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description SearchForTransactions
address(Address address)
Only include transactions with this address in one of the transaction fields.SearchForTransactions
addressRole(Enums.AddressRole addressRole)
Combine with the address parameter to define what type of address to search for.SearchForTransactions
afterTime(Date afterTime)
Include results after the given time.SearchForTransactions
applicationId(Long applicationId)
Application IDSearchForTransactions
assetId(Long assetId)
Asset IDSearchForTransactions
beforeTime(Date beforeTime)
Include results before the given time.SearchForTransactions
currencyGreaterThan(Long currencyGreaterThan)
Results should have an amount greater than this value.SearchForTransactions
currencyLessThan(Long currencyLessThan)
Results should have an amount less than this value.SearchForTransactions
excludeCloseTo(Boolean excludeCloseTo)
Combine with address and address-role parameters to define what type of address to search for.Response<TransactionsResponse>
execute()
Execute the query.Response<TransactionsResponse>
execute(String[] headers, String[] values)
Execute the query with custom headers, there must be an equal number of keys and values or else an error will be generated.protected QueryData
getRequestString()
SearchForTransactions
limit(Long limit)
Maximum number of results to return.SearchForTransactions
maxRound(Long maxRound)
Include results at or before the specified max-round.SearchForTransactions
minRound(Long minRound)
Include results at or after the specified min-round.SearchForTransactions
next(String next)
The next page of results.SearchForTransactions
notePrefix(byte[] notePrefix)
Specifies a prefix which must be contained in the note field.SearchForTransactions
rekeyTo(Boolean rekeyTo)
Include results which include the rekey-to field.SearchForTransactions
round(Long round)
Include results for the specified round.SearchForTransactions
sigType(Enums.SigType sigType)
SigType filters just results using the specified type of signature: sig - Standard msig - MultiSig lsig - LogicSigSearchForTransactions
txid(String txid)
Lookup the specific transaction by ID.SearchForTransactions
txType(Enums.TxType txType)
-
Methods inherited from class com.algorand.algosdk.v2.client.common.Query
addPathSegment, addQuery, addToBody, addToBody, baseExecute, baseExecute, getRequestMethod, getRequestUrl, getRequestUrl, resetPathSegment
-
-
-
-
Constructor Detail
-
SearchForTransactions
public SearchForTransactions(Client client)
-
-
Method Detail
-
address
public SearchForTransactions address(Address address)
Only include transactions with this address in one of the transaction fields.
-
addressRole
public SearchForTransactions addressRole(Enums.AddressRole addressRole)
Combine with the address parameter to define what type of address to search for.
-
afterTime
public SearchForTransactions afterTime(Date afterTime)
Include results after the given time. Must be an RFC 3339 formatted string.
-
applicationId
public SearchForTransactions applicationId(Long applicationId)
Application ID
-
assetId
public SearchForTransactions assetId(Long assetId)
Asset ID
-
beforeTime
public SearchForTransactions beforeTime(Date beforeTime)
Include results before the given time. Must be an RFC 3339 formatted string.
-
currencyGreaterThan
public SearchForTransactions currencyGreaterThan(Long currencyGreaterThan)
Results should have an amount greater than this value. MicroAlgos are the default currency unless an asset-id is provided, in which case the asset will be used.
-
currencyLessThan
public SearchForTransactions currencyLessThan(Long currencyLessThan)
Results should have an amount less than this value. MicroAlgos are the default currency unless an asset-id is provided, in which case the asset will be used.
-
excludeCloseTo
public SearchForTransactions excludeCloseTo(Boolean excludeCloseTo)
Combine with address and address-role parameters to define what type of address to search for. The close to fields are normally treated as a receiver, if you would like to exclude them set this parameter to true.
-
limit
public SearchForTransactions limit(Long limit)
Maximum number of results to return. There could be additional pages even if the limit is not reached.
-
maxRound
public SearchForTransactions maxRound(Long maxRound)
Include results at or before the specified max-round.
-
minRound
public SearchForTransactions minRound(Long minRound)
Include results at or after the specified min-round.
-
next
public SearchForTransactions next(String next)
The next page of results. Use the next token provided by the previous results.
-
notePrefix
public SearchForTransactions notePrefix(byte[] notePrefix)
Specifies a prefix which must be contained in the note field.
-
rekeyTo
public SearchForTransactions rekeyTo(Boolean rekeyTo)
Include results which include the rekey-to field.
-
round
public SearchForTransactions round(Long round)
Include results for the specified round.
-
sigType
public SearchForTransactions sigType(Enums.SigType sigType)
SigType filters just results using the specified type of signature: sig - Standard msig - MultiSig lsig - LogicSig
-
txType
public SearchForTransactions txType(Enums.TxType txType)
-
txid
public SearchForTransactions txid(String txid)
Lookup the specific transaction by ID.
-
execute
public Response<TransactionsResponse> execute() throws Exception
Execute the query.
-
execute
public Response<TransactionsResponse> execute(String[] headers, String[] values) throws Exception
Execute the query with custom headers, there must be an equal number of keys and values or else an error will be generated.
-
getRequestString
protected QueryData getRequestString()
- Specified by:
getRequestString
in classQuery
-
-