Skip to main content

fetchTransaction

Callable

  • fetchTransaction(link: string | URL, account: PublicKey, connection: Connection, commitment?: Commitment): Promise<Transaction>

  • Fetch a transaction from a Solana Pay transaction request link.

    @throws

    {FetchTransactionError}


    Parameters

    • link: string | URL

      link in the Solana Pay spec.

    • account: PublicKey

      Public key of a signer account.

    • connection: Connection

      A connection to the cluster.

    • optionalcommitment: Commitment

      Commitment level for the recent blockhash.

    Returns Promise<Transaction>