Facade used to interact with Symbol blockchain.

Constructors

  • Creates a Symbol facade.

    Parameters

    • network: string | Network

      Symbol network or network name.

    Returns SymbolFacade

Properties

network: Network

Underlying network.

transactionFactory: SymbolTransactionFactory

Underlying transaction factory.

Address: typeof Address

Network address class type.

BIP32_CURVE_NAME: string

BIP32 curve name.

KeyPair: typeof KeyPair

Network key pair class type.

Verifier: typeof Verifier

Network verifier class type.

deriveSharedKey: ((keyPair, otherPublicKey) => SharedKey256)

Derives shared key from key pair and other party's public key.

Type declaration

Returns

Shared encryption key.

Accessors

  • get static(): typeof SymbolFacade
  • Gets class type.

    Returns typeof SymbolFacade

    Class type.

Methods

  • Creates a network compatible BIP32 path for the specified account.

    Parameters

    • accountId: number

      Id of the account for which to generate a BIP32 path.

    Returns number[]

    BIP32 path for the specified account.

  • Cosigns a Symbol transaction.

    Parameters

    • keyPair: KeyPair

      Key pair of the cosignatory.

    • transaction: models.Transaction

      Transaction object.

    • Optional detached: boolean

      \c true if resulting cosignature is appropriate for network propagation. \c false if resulting cosignature is appropriate for attaching to an aggregate.

    Returns Cosignature | DetachedCosignature

    Signed cosignature.

  • Creates a Symbol account from a private key.

    Parameters

    Returns SymbolAccount

    Symbol account.

  • Creates an embedded transaction from a (typed) transaction descriptor.

    Parameters

    • typedDescriptor: object

      Transaction (typed) descriptor.

    • signerPublicKey: PublicKey

      Signer public key.

    Returns EmbeddedTransaction

    Created embedded transaction.

  • Creates a Symbol public account from a public key.

    Parameters

    Returns SymbolPublicAccount

    Symbol public account.

  • Creates a transaction from a (typed) transaction descriptor.

    Parameters

    • typedDescriptor: object

      Transaction (typed) descriptor.

    • signerPublicKey: PublicKey

      Signer public key.

    • feeMultiplier: number

      Fee multiplier.

    • deadlineSeconds: number

      Approximate seconds from now for deadline.

    • Optional cosignatureCount: number

      Number of cosignature spaces to reserve.

    Returns models.Transaction

    Created transaction.

  • Gets the payload to sign given a Symbol transaction.

    Parameters

    Returns Uint8Array

    Verifiable data to sign.

  • Hashes a Symbol transaction.

    Parameters

    Returns Hash256

    Transaction hash.

  • Creates a network timestamp representing the current time.

    Returns NetworkTimestamp

    Network timestamp representing the current time.

  • Signs a Symbol transaction.

    Parameters

    Returns Signature

    Transaction signature.

  • Verifies a Symbol transaction.

    Parameters

    Returns boolean

    \c true if transaction signature is verified.

  • Derives a Symbol KeyPair from a BIP32 node.

    Parameters

    • bip32Node: Bip32Node

      BIP32 node.

    Returns KeyPair

    Derived key pair.

  • Cosigns a Symbol transaction hash.

    Parameters

    • keyPair: KeyPair

      Key pair of the cosignatory.

    • transactionHash: Hash256

      Transaction hash.

    • Optional detached: boolean

      \c true if resulting cosignature is appropriate for network propagation. \c false if resulting cosignature is appropriate for attaching to an aggregate.

    Returns Cosignature | DetachedCosignature

    Signed cosignature.

  • Hashes embedded transactions of an aggregate transaction.

    Parameters

    Returns Hash256

    Aggregate transactions hash.