Transaction History

Swing SDK exposes a helper method to easily get a list of transactions made by this wallet.

const transactions = await sdk.wallet.getTransactions()

Unclaimed tokens

The above transactions can be used to check for pending, completed and unclaimed transactions.

for (const tx of transactions) {
  if (tx.status === 'Pending Destination Chain' && tx.needClaim) {
    // This is only required if the user closes the browser
    // before claiming their tokens during the transfer process
    await sdk.claim(tx)