Transaction
class Transaction
Class containing transaction details.
Properties
accountId
accountId: String
Returns the unique account identifier that transaction belongs to.
address
address: String
Returns counterparty's account address.
coin
coin: String
Returns coin name in string format, e.g. Bitcoin, Ether.
confirmedAt
confirmedAt: Moment | null
A Moment instance representing transaction confirmed timestamp. Use Moment Timezone to localize it to a timezone.
cost
cost: String
Returns transaction cost in transaction currency.
data
cost: String | null
Returns transaction data if available, otherwise returns null.
fiatCost
fiatCost: Object
Returns map of transaction cost in available fiat values at the time of the transaction.
Example
{
"USD": "0.323",
"EUR": "0.79",
"GBP": "0.635"
}
fiatValue
fiatValue: Object
Returns map of transaction value in available fiat values at the time of the transaction.
Example
{
"USD": "93.23",
"EUR": "84.79",
"GBP": "72.635"
}
fromAddress
fromAddress: String
Returns sender blockchain address.
fromUserId
fromAddress: String | null
Returns sender user id if available, otherwise null.
gasLimit
gasLimit: String | null
Returns the gas limit used to send the transaction. See Send Transaction for details.
gasPrice
gasPrice: Decimal
Returns the gas price used to send the transaction. See Send Transaction for details.
id
id: String
Returns the unique transaction identifier.
network
network: String
Returns network on which transaction was submitted, which can be one of the following:
- MAINNET: Bitcoin or Ethereum mainnet.
- TESTNET: Bitcoin Testnet.
- ROPSTEN: Ethereum Ropsten test network.
- RINKEBY: Ethereum Rinkeby test network.
- GOERLI: Ethereum Goerli test network.
- KOVAN: Ethereum Kovan test network.
nonce
nonce: String
Returns nonce for Ethereum account if greater than 0, otherwise returns null.
status
status: String
Returns transaction status, which can be one of the following:
- PENDING: Transaction has been submitted to blockchain.
- CONFIRMED: Transacion was confirmed and added to blockchain.
- FAILED: Transaction was rejected, try resubmitting transaction with increased fee rate.
- RESUBMITTED: Occurs when exactly the same transaction with same consecutive transaction number, e.g. nonce, was submitted but with higher fee rate was submitted before transaction was confirmed.
- CANCELLED: Occurs when differenet transaction was submitted but with higher fee rate and same consecutive transaction number, e.g nonce, was submitted before transaction was confirmed.
See Send Transaction for details on the order in which transaction statuses appear.
submittedAt
submittedAt: Moment | null
A Moment instance representing transaction submitted timestamp. Use Moment Timezone to localize it to a timezone.
symbol
symbol: String
Returns coin symbol in string format, e.g. BTC, ETH.
time
time: Moment | null
Transaction timestamp wrapped in Moment instance. Use Moment Timezone to localize it to a timezone.
timestamp
timestamp: Number | null
Returns transaction confirmed timestamp for confirmed transactions and transaction submitted timestamp for pending transactions.
userId
userId: String | null
Returns counterparty's user id.
toAddress
toAddress: String
Returns recipient blockchain address.
toUserId
toUserId: String | null
Returns recipient user id if available, otherwise null.
txHash
txHash: String | null
Returns transaction blockchain hash.
type
type: String
Returns trasaction type, which can be one of the following:
- OUTGOING,
- INCOMING.
value
value: Decimal
Returns transaction value in transaction currency.