Options
All
  • Public
  • Public/Protected
  • All
Menu

Class Transaction

Structure representing a Stellar Transaction.

Hierarchy

  • Transaction

Implements

Index

Constructors

constructor

Properties

Private $effects

$effects: CallCollectionFunction<EffectRecord>

Get the effects of the transaction.

Private $operations

$operations: CallCollectionFunction<OperationRecord>

Get the operations of the transaction.

Private Optional _memo

_memo: string

The memo attached to the transaction (the payment id of the transaction if made using Pi Network SDK).

Readonly client

client: Client

createdAt

createdAt: Date

The transaction creation date.

createdTimestamp

createdTimestamp: number

The transaction creation timestamp.

envelopeXdr

envelopeXdr: string

A base64 encoded string of the raw TransactionEnvelope XDR struct for the transaction.

feeCharged

feeCharged: string | number

The fee (in micropi) paid by the source account to apply this transaction to the ledger.

feeMetaXdr

feeMetaXdr: string

A base64 encoded string of the raw LedgerEntryChanges XDR struct produced by taking fees for the transaction.

hash

hash: string

A hex-encoded SHA-256 hash of the transaction’s XDR-encoded form.

id

id: string

The id of the transaction.

ledgerSequence

ledgerSequence: number

The sequence number of the ledger that the transaction was included in.

maxFee

maxFee: string | number

The maximum fee (in micropi) that the source account was willing to pay.

memoType

memoType: MemoType

The type of memo. Potential values include none, id, text, hash and return.

operationCount

operationCount: number

The number of operations contained within the transaction.

pagingToken

pagingToken: string

A cursor value for use in pagination.

resultMetaXdr

resultMetaXdr: string

A base64 encoded string of the raw TransactionMeta XDR struct for the transaction.

resultXdr

resultXdr: string

A base64 encoded string of the raw TransactionResult XDR struct for the transaction.

signatures

signatures: string[]

The signatures used to sign the transaction.

sourceAccountId

sourceAccountId: string

The account that originates the transaction.

sourceAccountSequence

sourceAccountSequence: string

The source account’s sequence number that the transaction consumed.

Accessors

memo

  • get memo(): undefined | string
  • The memo of the transaction. If the transaction was made using the Pi Network SDK, the memo is equal to the platform payment id, so it retrieve the platform payment, then the memo from it.

    Returns undefined | string

Methods

$patch

  • $patch(data: TransactionRecord): void

getEffects

getLedger

  • getLedger(forceUpdate?: boolean): Promise<Ledger>
  • Get the ledger the trasaction belongs to.

    Parameters

    • forceUpdate: boolean = false

      If set to true, it will not check in the cache and directly make a request to retrieve the ledger instead.

    Returns Promise<Ledger>

    The ledger the trasaction belongs to.

getOperations

getPayment

  • getPayment(forceUpdate?: boolean): Promise<undefined | Payment>
  • Get the platform payment of the transaction if made using Pi Network SDK.

    Parameters

    • forceUpdate: boolean = false

      If set to true, it will not check in the cache and directly make a request to retrieve the platform payment instead.

    Returns Promise<undefined | Payment>

    The platform payment of the transaction if made using Pi Network SDK.

getSourceAccount

  • getSourceAccount(forceUpdate?: boolean): Promise<Account>
  • Get the source account of the transaction.

    Parameters

    • forceUpdate: boolean = false

      If set to true, it will not check in the cache and directly make a request to retrieve the source account instead.

    Returns Promise<Account>

    The source account of the transaction.

Generated using TypeDoc