From 5ff6c4a67fdf9b6c1ac4799b46a6163aa6b6f306 Mon Sep 17 00:00:00 2001 From: GitHub Action Date: Wed, 24 Jan 2024 17:19:20 +0000 Subject: [PATCH] Updating documentation: MHHukiewitz --- .../Ledger.ethereum.ETHLedgerAccount.html | 4 ++-- .../accounts.avalanche.AvalancheAccount.html | 10 ++++----- docs/classes/accounts.base.Account.html | 2 +- docs/classes/accounts.base.ECIESAccount.html | 2 +- docs/classes/accounts.base.EVMAccount.html | 2 +- .../accounts.cosmos.CosmosAccount.html | 2 +- .../classes/accounts.ethereum.ETHAccount.html | 10 ++++----- docs/classes/accounts.nuls2.NULS2Account.html | 16 +++++++------- docs/classes/accounts.solana.SOLAccount.html | 2 +- .../accounts.substrate.DOTAccount.html | 6 ++--- ...accounts.superfluid.SuperfluidAccount.html | 22 +++++++++---------- docs/classes/accounts.tezos.TEZOSAccount.html | 4 ++-- docs/enums/accounts.avalanche.ChainType.html | 2 +- docs/modules/Ledger.ethereum.html | 2 +- docs/modules/accounts.avalanche.html | 8 +++---- docs/modules/accounts.cosmos.html | 6 ++--- docs/modules/accounts.ethereum.html | 8 +++---- docs/modules/accounts.nuls2.html | 6 ++--- docs/modules/accounts.solana.html | 6 ++--- docs/modules/accounts.substrate.html | 8 +++---- docs/modules/accounts.superfluid.html | 2 +- docs/modules/accounts.tezos.html | 8 +++---- docs/modules/messages.aggregate.html | 4 ++-- docs/modules/messages.any.html | 6 ++--- docs/modules/messages.any.is.html | 2 +- docs/modules/messages.forget.html | 2 +- docs/modules/messages.html | 2 +- docs/modules/messages.instance.html | 2 +- docs/modules/messages.post.html | 4 ++-- docs/modules/messages.program.html | 2 +- docs/modules/messages.store.html | 6 ++--- docs/modules/utils.html | 12 +++++----- 32 files changed, 90 insertions(+), 90 deletions(-) diff --git a/docs/classes/Ledger.ethereum.ETHLedgerAccount.html b/docs/classes/Ledger.ethereum.ETHLedgerAccount.html index 5e2725b5..0fa0c918 100644 --- a/docs/classes/Ledger.ethereum.ETHLedgerAccount.html +++ b/docs/classes/Ledger.ethereum.ETHLedgerAccount.html @@ -1,8 +1,8 @@ ETHLedgerAccount | aleph-sdk-ts
Options
All
  • Public
  • Public/Protected
  • All
Menu

The ETHLedgerAccount represents an ETHAccount with Signing functionalities Instanciated from a Ledger device

-

Hierarchy

Index

Constructors

Properties

address: string
signer: default

Methods

  • GetChain(): Chain
  • Sign(message: BaseMessage): Promise<string>

Hierarchy

Index

Constructors

Properties

address: string
signer: default

Methods

  • GetChain(): Chain
  • Sign(message: BaseMessage): Promise<string>
  • getSignature(input: Buffer): Promise<string>

Generated using TypeDoc

\ No newline at end of file +

Returns Promise<string>

Generated using TypeDoc

\ No newline at end of file diff --git a/docs/classes/accounts.avalanche.AvalancheAccount.html b/docs/classes/accounts.avalanche.AvalancheAccount.html index 0378b4c1..d5dbf50d 100644 --- a/docs/classes/accounts.avalanche.AvalancheAccount.html +++ b/docs/classes/accounts.avalanche.AvalancheAccount.html @@ -1,13 +1,13 @@ AvalancheAccount | aleph-sdk-ts
Options
All
  • Public
  • Public/Protected
  • All
Menu

AvalancheAccount implements the Account class for the Avalanche protocol. It is used to represent an Avalanche account when publishing a message on the Aleph network.

-

Hierarchy

Index

Constructors

  • new AvalancheAccount(signerOrWallet: JsonRPCWallet | JsonRpcProvider | KeyPair | KeyPair, address: string, publicKey?: string): AvalancheAccount

Properties

address: string
keyPair?: KeyPair | KeyPair
publicKey: undefined | string
wallet?: JsonRPCWallet

Methods

  • GetChain(): Chain
  • Sign(message: BaseMessage): Promise<string>

Hierarchy

Index

Constructors

  • new AvalancheAccount(signerOrWallet: JsonRPCWallet | JsonRpcProvider | KeyPair | KeyPair, address: string, publicKey?: string): AvalancheAccount

Properties

address: string
keyPair?: KeyPair | KeyPair
publicKey: undefined | string
wallet?: JsonRPCWallet

Methods

  • GetChain(): Chain
  • Sign(message: BaseMessage): Promise<string>
  • The Sign method provides a way to sign a given Aleph message using an avalanche keypair. The full message is not used as the payload, only fields of the BaseMessage type are.

    The sign method of the keypair is used as the signature method.

    Parameters

    • message: BaseMessage

      The Aleph message to sign, using some of its fields.

      -

    Returns Promise<string>

  • askPubKey(): Promise<void>

Returns Promise<string>

  • askPubKey(): Promise<void>
  • Ask for a Provider Account a read Access to its encryption publicKey If the encryption public Key is already loaded, nothing happens

    This method will throw if:

    @@ -15,11 +15,11 @@
  • The account was not instanced with a provider.
  • The user denied the encryption public key sharing.
-

Returns Promise<void>

  • changeNetwork(chainOrRpc?: RpcType | RpcId): Promise<void>
  • decrypt(encryptedContent: string | Buffer): Promise<Buffer>
  • changeNetwork(chainOrRpc?: RpcType | RpcId): Promise<void>
  • decrypt(encryptedContent: string | Buffer): Promise<Buffer>
  • Decrypt a given content using the private key from the keypair.

    Parameters

    • encryptedContent: string | Buffer

      The encrypted content to decrypt.

      -

    Returns Promise<Buffer>

  • digestMessage(message: Buffer): Promise<Buffer>
  • encrypt(content: Buffer, delegateSupport?: string | ECIESAccount, encryptionMethod?: METAMASK): Promise<string | Buffer>

Returns Promise<Buffer>

  • digestMessage(message: Buffer): Promise<Buffer>
  • encrypt(content: Buffer, delegateSupport?: string | ECIESAccount, encryptionMethod?: METAMASK): Promise<string | Buffer>
  • Encrypt a content using the user's public key from the keypair

    Parameters

    • content: Buffer

      The content to encrypt.

      @@ -27,4 +27,4 @@

      Optional, if you want to encrypt data for another ECIESAccount (Can also be directly a public key)

    • encryptionMethod: METAMASK = ProviderEncryptionLabel.METAMASK

      Optional, chose the standard encryption method to use (With provider).

      -

    Returns Promise<string | Buffer>

  • getChainId(): Promise<number>
  • getRpcId(): Promise<RpcId>
  • getRpcUrl(): string

Generated using TypeDoc

\ No newline at end of file +

Returns Promise<string | Buffer>

Generated using TypeDoc

\ No newline at end of file diff --git a/docs/classes/accounts.base.Account.html b/docs/classes/accounts.base.Account.html index 16538d61..7c7e3513 100644 --- a/docs/classes/accounts.base.Account.html +++ b/docs/classes/accounts.base.Account.html @@ -2,4 +2,4 @@

The Account class is used to implement protocols related accounts - Ethereum, Solana, ... It contains the account's address and public key.

All inherited classes of account must implement the GetChain and Sign methods.

-

Hierarchy

Index

Constructors

Properties

Methods

Constructors

  • new Account(address: string): Account

Properties

address: string

Methods

  • GetChain(): Chain
  • Sign(message: BaseMessage): Promise<string>

Generated using TypeDoc

\ No newline at end of file +

Hierarchy

Index

Constructors

Properties

Methods

Constructors

  • new Account(address: string): Account

Properties

address: string

Methods

  • GetChain(): Chain
  • Sign(message: BaseMessage): Promise<string>

Generated using TypeDoc

\ No newline at end of file diff --git a/docs/classes/accounts.base.ECIESAccount.html b/docs/classes/accounts.base.ECIESAccount.html index a41f8761..b8eaabe5 100644 --- a/docs/classes/accounts.base.ECIESAccount.html +++ b/docs/classes/accounts.base.ECIESAccount.html @@ -2,4 +2,4 @@

The ECIESAccount class is used to implement protocols using secp256k1's curve. It extends the Account class by exposing an encryption publicKey and method

All inherited classes of ECIESAccount must implement the encrypt methods and expose a publicKey.

-

Hierarchy

Index

Constructors

  • new ECIESAccount(address: string, publicKey?: string): ECIESAccount

Properties

address: string
publicKey: undefined | string

Methods

  • GetChain(): Chain
  • Sign(message: BaseMessage): Promise<string>
  • askPubKey(): Promise<void>
  • decrypt(content: string | Buffer): Promise<Buffer>
  • encrypt(content: Buffer, delegateSupport?: string | ECIESAccount, encryptionMethod?: METAMASK): Promise<string | Buffer>
  • Parameters

    • content: Buffer
    • Optional delegateSupport: string | ECIESAccount
    • Optional encryptionMethod: METAMASK

    Returns Promise<string | Buffer>

Generated using TypeDoc

\ No newline at end of file +

Hierarchy

Index

Constructors

  • new ECIESAccount(address: string, publicKey?: string): ECIESAccount

Properties

address: string
publicKey: undefined | string

Methods

  • GetChain(): Chain
  • Sign(message: BaseMessage): Promise<string>
  • askPubKey(): Promise<void>
  • decrypt(content: string | Buffer): Promise<Buffer>
  • encrypt(content: Buffer, delegateSupport?: string | ECIESAccount, encryptionMethod?: METAMASK): Promise<string | Buffer>
  • Parameters

    • content: Buffer
    • Optional delegateSupport: string | ECIESAccount
    • Optional encryptionMethod: METAMASK

    Returns Promise<string | Buffer>

Generated using TypeDoc

\ No newline at end of file diff --git a/docs/classes/accounts.base.EVMAccount.html b/docs/classes/accounts.base.EVMAccount.html index b9dbd577..6b441d15 100644 --- a/docs/classes/accounts.base.EVMAccount.html +++ b/docs/classes/accounts.base.EVMAccount.html @@ -1 +1 @@ -EVMAccount | aleph-sdk-ts
Options
All
  • Public
  • Public/Protected
  • All
Menu

Class EVMAccount Abstract

Hierarchy

Index

Constructors

  • new EVMAccount(address: string, publicKey?: string): EVMAccount

Properties

address: string
publicKey: undefined | string
wallet?: JsonRPCWallet | Wallet

Methods

  • GetChain(): Chain
  • Sign(message: BaseMessage): Promise<string>
  • askPubKey(): Promise<void>
  • changeNetwork(chainOrRpc?: RpcType | RpcId): Promise<void>
  • decrypt(content: string | Buffer): Promise<Buffer>
  • encrypt(content: Buffer, delegateSupport?: string | ECIESAccount, encryptionMethod?: METAMASK): Promise<string | Buffer>
  • getChainId(): Promise<number>
  • getRpcId(): Promise<RpcId>
  • getRpcUrl(): string

Generated using TypeDoc

\ No newline at end of file +EVMAccount | aleph-sdk-ts
Options
All
  • Public
  • Public/Protected
  • All
Menu

Class EVMAccount Abstract

Hierarchy

Index

Constructors

  • new EVMAccount(address: string, publicKey?: string): EVMAccount

Properties

address: string
publicKey: undefined | string
wallet?: JsonRPCWallet | Wallet

Methods

  • GetChain(): Chain
  • Sign(message: BaseMessage): Promise<string>
  • askPubKey(): Promise<void>
  • changeNetwork(chainOrRpc?: RpcType | RpcId): Promise<void>
  • decrypt(content: string | Buffer): Promise<Buffer>
  • encrypt(content: Buffer, delegateSupport?: string | ECIESAccount, encryptionMethod?: METAMASK): Promise<string | Buffer>
  • getChainId(): Promise<number>
  • getRpcId(): Promise<RpcId>
  • getRpcUrl(): string

Generated using TypeDoc

\ No newline at end of file diff --git a/docs/classes/accounts.cosmos.CosmosAccount.html b/docs/classes/accounts.cosmos.CosmosAccount.html index 7c974355..8313d7ca 100644 --- a/docs/classes/accounts.cosmos.CosmosAccount.html +++ b/docs/classes/accounts.cosmos.CosmosAccount.html @@ -1,7 +1,7 @@ CosmosAccount | aleph-sdk-ts
Options
All
  • Public
  • Public/Protected
  • All
Menu

CosmosAccount implements the Account class for the Cosmos protocol. It is used to represent a Cosmos account when publishing a message on the Aleph network.

-

Hierarchy

Index

Constructors

  • new CosmosAccount(wallet: OfflineAminoSigner, address: string, accountNumber?: number): CosmosAccount

Properties

accountNumber: number
address: string
wallet: OfflineAminoSigner

Methods

  • GetChain(): Chain
  • Sign(message: BaseMessage): Promise<string>

Hierarchy

Index

Constructors

  • new CosmosAccount(wallet: OfflineAminoSigner, address: string, accountNumber?: number): CosmosAccount

Properties

accountNumber: number
address: string
wallet: OfflineAminoSigner

Methods

  • GetChain(): Chain
  • Sign(message: BaseMessage): Promise<string>
  • askPubKey(): Promise<void>
  • Ask for a Provider Account a read Access to its encryption publicKey If the encryption public Key is already loaded, nothing happens

    This method will throw if:

    @@ -15,11 +15,11 @@
  • The account was not instanced with a provider.
  • The user denied the encryption public key sharing.
-

Returns Promise<void>

  • changeNetwork(chainOrRpc?: RpcType | RpcId): Promise<void>
  • decrypt(encryptedContent: string | Buffer): Promise<Buffer>
  • changeNetwork(chainOrRpc?: RpcType | RpcId): Promise<void>
  • decrypt(encryptedContent: string | Buffer): Promise<Buffer>
  • Decrypt a given content using an ETHAccount.

    Parameters

    • encryptedContent: string | Buffer

      The encrypted content to decrypt.

      -

    Returns Promise<Buffer>

  • encrypt(content: Buffer, delegateSupport?: string | ECIESAccount, encryptionMethod?: METAMASK): Promise<string | Buffer>

Returns Promise<Buffer>

  • encrypt(content: Buffer, delegateSupport?: string | ECIESAccount, encryptionMethod?: METAMASK): Promise<string | Buffer>
  • Encrypt a content using the user's public key for an Ethereum account.

    Parameters

    • content: Buffer

      The content to encrypt.

      @@ -27,4 +27,4 @@

      Optional, if you want to encrypt data for another EthAccount (Can also be directly a public key)

    • encryptionMethod: METAMASK = ProviderEncryptionLabel.METAMASK

      Optional, chose the standard encryption method to use (With provider).

      -

    Returns Promise<string | Buffer>

  • getChainId(): Promise<number>
  • getRpcId(): Promise<RpcId>
  • getRpcUrl(): string

Generated using TypeDoc

\ No newline at end of file +

Returns Promise<string | Buffer>

Generated using TypeDoc

\ No newline at end of file diff --git a/docs/classes/accounts.nuls2.NULS2Account.html b/docs/classes/accounts.nuls2.NULS2Account.html index 4da7b2df..80c3b44f 100644 --- a/docs/classes/accounts.nuls2.NULS2Account.html +++ b/docs/classes/accounts.nuls2.NULS2Account.html @@ -1,7 +1,7 @@ NULS2Account | aleph-sdk-ts
Options
All
  • Public
  • Public/Protected
  • All
Menu

NULS2Account implements the Account class for the NULS2 protocol. It is used to represent a NULS2 account when publishing a message on the Aleph network.

-

Hierarchy

Index

Constructors

  • new NULS2Account(address: string, publicKey: string, privateKey: string): NULS2Account

Properties

address: string
privateKey: string
publicKey: undefined | string

Methods

  • EncodeSignature(signature: Uint8Array, recovery: number, compressed: boolean): Buffer

Hierarchy

Index

Constructors

  • new NULS2Account(address: string, publicKey: string, privateKey: string): NULS2Account

Properties

address: string
privateKey: string
publicKey: undefined | string

Methods

  • EncodeSignature(signature: Uint8Array, recovery: number, compressed: boolean): Buffer
  • Append the recovery of the signature to a signature and compress it if required.

    Parameters

    • signature: Uint8Array

      The signature to encode.

      @@ -9,38 +9,38 @@

      The recovery to append.

    • compressed: boolean

      The optional compress flag.

      -

    Returns Buffer

  • GetChain(): Chain
  • Sign(message: BaseMessage): Promise<string>

Returns Buffer

  • GetChain(): Chain
  • Sign(message: BaseMessage): Promise<string>
  • The Sign method provides a way to sign a given Aleph message using a NULS2 account. The full message is not used as the payload, only fields of the BaseMessage type are.

    The message's signature is based on secp256k1 package.

    Parameters

    • message: BaseMessage

      The Aleph message to sign, using some of its fields.

      -

    Returns Promise<string>

  • askPubKey(): Promise<void>

Returns Promise<string>

  • askPubKey(): Promise<void>
  • Ask for a Provider Account a read Access to its encryption publicKey. As NULS2 currently doesn't support instantiation through a provider, this method has no effect.

    -

    Returns Promise<void>

  • decrypt(encryptedContent: string | Buffer): Promise<Buffer>
  • decrypt(encryptedContent: string | Buffer): Promise<Buffer>
  • Decrypt a given content using a NULS2 account.

    Parameters

    • encryptedContent: string | Buffer

      The encrypted content to decrypt.

      -

    Returns Promise<Buffer>

  • encrypt(content: Buffer, delegateSupport?: string | ECIESAccount): Promise<Buffer>

Returns Promise<Buffer>

  • encrypt(content: Buffer, delegateSupport?: string | ECIESAccount): Promise<Buffer>
  • Encrypt a content using the user's public key for a NULS2 account.

    Parameters

    • content: Buffer

      The content to encrypt.

    • Optional delegateSupport: string | ECIESAccount

      Optional, if you want to encrypt data for another ECIESAccount (Can also be directly a public key)

      -

    Returns Promise<Buffer>

  • addressFromHash(hash: Uint8Array, prefix?: string): string

Returns Promise<Buffer>

  • addressFromHash(hash: Uint8Array, prefix?: string): string
  • Extract an address from a given hash.

    Parameters

    • hash: Uint8Array

      The hash containing the address.

    • Optional prefix: string

      The optional address prefix.

      -

    Returns string

  • magicHash(message: Buffer, messagePrefix?: string | Buffer): Buffer

Returns string

  • magicHash(message: Buffer, messagePrefix?: string | Buffer): Buffer
  • Creates a hash from a message.

    Parameters

    • message: Buffer

      The message used to create the hash.

    • messagePrefix: string | Buffer = "\u0018NULS Signed Message:\n"

      The optional message's hash prefix.

      -

    Returns Buffer

  • publicKeyToHash(publicKey: Uint8Array, __namedParameters?: ChainNAddress): Buffer

Returns Buffer

  • publicKeyToHash(publicKey: Uint8Array, __namedParameters?: ChainNAddress): Buffer
  • encrypt(content: Buffer): Buffer
  • alephPerHourToFlowRate(alephPerHour: number | Decimal): BigNumber
  • alephToWei(alephAmount: number | Decimal): BigNumber
  • askPubKey(): Promise<void>
  • Ask for a Provider Account a read Access to its encryption publicKey If the encryption public Key is already loaded, nothing happens

    This method will throw if:

    @@ -15,17 +15,17 @@
  • The account was not instanced with a provider.
  • The user denied the encryption public key sharing.
-

Returns Promise<void>

  • changeNetwork(chainOrRpc?: RpcType | RpcId): Promise<void>
  • decreaseALEPHxFlow(receiver: string, alephPerHour: number | Decimal): Promise<void>
  • changeNetwork(chainOrRpc?: RpcType | RpcId): Promise<void>
  • decreaseALEPHxFlow(receiver: string, alephPerHour: number | Decimal): Promise<void>
  • Decrease the ALEPHx flow rate to a given receiver. Deletes the flow if the new flow rate is 0.

    Parameters

    • receiver: string

      The receiver address.

    • alephPerHour: number | Decimal

      The amount of ALEPHx per hour to decrease the flow by.

      -

    Returns Promise<void>

  • decrypt(encryptedContent: string | Buffer): Promise<Buffer>

Returns Promise<void>

  • decrypt(encryptedContent: string | Buffer): Promise<Buffer>
  • Decrypt a given content using the private key from the keypair.

    Parameters

    • encryptedContent: string | Buffer

      The encrypted content to decrypt.

      -

    Returns Promise<Buffer>

  • encrypt(content: Buffer, delegateSupport?: string | ECIESAccount, encryptionMethod?: METAMASK): Promise<string | Buffer>

Returns Promise<Buffer>

  • encrypt(content: Buffer, delegateSupport?: string | ECIESAccount, encryptionMethod?: METAMASK): Promise<string | Buffer>
  • Encrypt a content using the user's public key from the keypair

    Parameters

    • content: Buffer

      The content to encrypt.

      @@ -33,20 +33,20 @@

      Optional, if you want to encrypt data for another ECIESAccount (Can also be directly a public key)

    • encryptionMethod: METAMASK = ProviderEncryptionLabel.METAMASK

      Optional, chose the standard encryption method to use (With provider).

      -

    Returns Promise<string | Buffer>

  • flowRateToAlephPerHour(flowRate: string | BigNumber): Decimal
  • getALEPHBalance(): Promise<Decimal>

Returns Promise<string | Buffer>

  • flowRateToAlephPerHour(flowRate: string | BigNumber): Decimal
  • getALEPHBalance(): Promise<Decimal>
  • getALEPHxBalance(): Promise<Decimal>
  • getALEPHxBalance(): Promise<Decimal>
  • getALEPHxFlow(receiver: string): Promise<Decimal>
  • getALEPHxFlow(receiver: string): Promise<Decimal>
  • Get the ALEPHx flow rate to a given receiver in ALEPHx per hour.

    Parameters

    • receiver: string

      The receiver address.

      -

    Returns Promise<Decimal>

  • getChainId(): Promise<number>
  • getNetALEPHxFlow(): Promise<Decimal>

Returns Promise<Decimal>

  • getChainId(): Promise<number>
  • getNetALEPHxFlow(): Promise<Decimal>
  • getRpcId(): Promise<RpcId>
  • getRpcUrl(): string
  • increaseALEPHxFlow(receiver: string, alephPerHour: number | Decimal): Promise<void>
  • getRpcId(): Promise<RpcId>
  • getRpcUrl(): string
  • increaseALEPHxFlow(receiver: string, alephPerHour: number | Decimal): Promise<void>
  • Increase the ALEPHx flow rate to a given receiver. Creates a new flow if none exists.

    Parameters

    • receiver: string

      The receiver address.

    • alephPerHour: number | Decimal

      The amount of ALEPHx per hour to increase the flow by.

      -

    Returns Promise<void>

  • init(): Promise<void>
  • weiToAleph(weiAmount: string | BigNumber): Decimal

Generated using TypeDoc

\ No newline at end of file +

Returns Promise<void>

Generated using TypeDoc

\ No newline at end of file diff --git a/docs/classes/accounts.tezos.TEZOSAccount.html b/docs/classes/accounts.tezos.TEZOSAccount.html index 987c93b6..3c234f64 100644 --- a/docs/classes/accounts.tezos.TEZOSAccount.html +++ b/docs/classes/accounts.tezos.TEZOSAccount.html @@ -1,14 +1,14 @@ TEZOSAccount | aleph-sdk-ts
Options
All
  • Public
  • Public/Protected
  • All
Menu

XTZAccount implements the Account class for the Tezos protocol. It is used to represent a Tezos account when publishing a message on the Aleph network.

-

Hierarchy

Index

Constructors

  • new TEZOSAccount(publicKey: string, wallet: BeaconWallet | InMemorySigner, dAppUrl?: string): TEZOSAccount

Hierarchy

Index

Constructors

  • new TEZOSAccount(publicKey: string, wallet: BeaconWallet | InMemorySigner, dAppUrl?: string): TEZOSAccount
  • Parameters

    • publicKey: string

      The public key encoded in base58. Needed due to asynchronous getter of the public key.

    • wallet: BeaconWallet | InMemorySigner

      The signer containing the private key used to sign the message.

    • Optional dAppUrl: string

      The URL of the dApp that is publishing the message. Defaults to "aleph.im". Used by wallets to display the requester of the signature.

      -

    Returns TEZOSAccount

Properties

address: string
dAppUrl: string
wallet: BeaconWallet | InMemorySigner

Methods

  • GetChain(): Chain
  • GetPublicKey(): Promise<string>
  • Sign(message: BaseMessage): Promise<string>

Returns TEZOSAccount

Properties

address: string
dAppUrl: string
wallet: BeaconWallet | InMemorySigner

Methods

  • GetChain(): Chain
  • GetPublicKey(): Promise<string>
  • Sign(message: BaseMessage): Promise<string>
  • getKeyPair(privateKey?: string, chain?: ChainType): Promise<KeyPair>

Generated using TypeDoc

\ No newline at end of file diff --git a/docs/modules/accounts.cosmos.html b/docs/modules/accounts.cosmos.html index a42bfe02..ed106b7c 100644 --- a/docs/modules/accounts.cosmos.html +++ b/docs/modules/accounts.cosmos.html @@ -1,7 +1,7 @@ -cosmos | aleph-sdk-ts
Options
All
  • Public
  • Public/Protected
  • All
Menu

Index

Functions

  • ImportAccountFromMnemonic(mnemonic: string, options?: Partial<Secp256k1HdWalletOptions>): Promise<CosmosAccount>
  • ImportAccountFromPrivateKey(privateKey: string): ETHAccount
  • Imports an ethereum account given a private key and the 'ethers' package.

    It creates an ethereum wallet containing information about the account, extracted in the ETHAccount constructor.

    Parameters

    • privateKey: string

      The private key of the account to import.

      -

    Returns ETHAccount

  • NewAccount(derivationPath?: string): { account: ETHAccount; mnemonic: string }

Returns ETHAccount

  • NewAccount(derivationPath?: string): { account: ETHAccount; mnemonic: string }
  • Creates a new ethereum account using a generated mnemonic following BIP 39 standard.

    Parameters

    • derivationPath: string = "m/44'/60'/0'/0/0"

    Returns { account: ETHAccount; mnemonic: string }

Generated using TypeDoc

\ No newline at end of file diff --git a/docs/modules/accounts.nuls2.html b/docs/modules/accounts.nuls2.html index 63ed32ff..776a4e49 100644 --- a/docs/modules/accounts.nuls2.html +++ b/docs/modules/accounts.nuls2.html @@ -1,13 +1,13 @@ -nuls2 | aleph-sdk-ts
Options
All
  • Public
  • Public/Protected
  • All
Menu

Index

Type Aliases

ChainNAddress: { address_type?: number; chain_id?: number }

Type declaration

  • Optional address_type?: number
  • Optional chain_id?: number
NULS2ImportConfig: { chain_id?: number; prefix?: string }

Type declaration

  • Optional chain_id?: number
  • Optional prefix?: string

Functions

  • Imports a NULS2 account given a private key.

    It creates an NULS2 account containing information about the account, extracted in the NULS2Account constructor.

    Parameters

    • privateKey: string

      The mnemonic of the account to import.

      -
    • __namedParameters: NULS2ImportConfig = ...

    Returns Promise<NULS2Account>

Returns Promise<NULS2Account>

Generated using TypeDoc

\ No newline at end of file diff --git a/docs/modules/accounts.solana.html b/docs/modules/accounts.solana.html index f916bc3d..00bfbed3 100644 --- a/docs/modules/accounts.solana.html +++ b/docs/modules/accounts.solana.html @@ -1,10 +1,10 @@ -solana | aleph-sdk-ts
Options
All
  • Public
  • Public/Protected
  • All
Menu

Index

Functions

  • GetAccountFromProvider(provider: MessageSigner): Promise<SOLAccount>
  • NewAccount(): { account: SOLAccount; privateKey: Uint8Array }

Generated using TypeDoc

\ No newline at end of file diff --git a/docs/modules/accounts.substrate.html b/docs/modules/accounts.substrate.html index b00169c8..fe6c6b82 100644 --- a/docs/modules/accounts.substrate.html +++ b/docs/modules/accounts.substrate.html @@ -1,18 +1,18 @@ -substrate | aleph-sdk-ts
Options
All
  • Public
  • Public/Protected
  • All
Menu

Namespace substrate

Index

Functions

  • GetAccountFromProvider(address?: string): Promise<DOTAccount>
  • ImportAccountFromMnemonic(mnemonic: string): Promise<DOTAccount>
  • Imports a substrate account given a mnemonic and the 'polkadot' package.

    It creates an substrate wallet containing information about the account, extracted in the DOTAccount constructor.

    Parameters

    • mnemonic: string

      The mnemonic of the account to import.

      -

    Returns Promise<DOTAccount>

  • ImportAccountFromPrivateKey(privateKey: string): Promise<DOTAccount>

Returns Promise<DOTAccount>

  • ImportAccountFromPrivateKey(privateKey: string): Promise<DOTAccount>
  • Imports a substrate account given a private key and the 'polkadot/keyring' package's class.

    It creates a substrate wallet containing information about the account, extracted in the DOTAccount constructor.

    Parameters

    • privateKey: string

      The private key of the account to import.

      -

    Returns Promise<DOTAccount>

  • NewAccount(): Promise<{ account: DOTAccount; mnemonic: string }>

Returns Promise<DOTAccount>

  • NewAccount(): Promise<{ account: DOTAccount; mnemonic: string }>
  • Creates a new substrate account using a randomly generated substrate keyring.

    Returns Promise<{ account: DOTAccount; mnemonic: string }>

Generated using TypeDoc

\ No newline at end of file diff --git a/docs/modules/accounts.superfluid.html b/docs/modules/accounts.superfluid.html index 2eb7189b..f3049446 100644 --- a/docs/modules/accounts.superfluid.html +++ b/docs/modules/accounts.superfluid.html @@ -1 +1 @@ -superfluid | aleph-sdk-ts
Options
All
  • Public
  • Public/Protected
  • All
Menu

Namespace superfluid

Index

Functions

  • GetAccountFromProvider(provider: ExternalProvider, requestedRpc?: ChangeRpcParam): Promise<SuperfluidAccount>

Generated using TypeDoc

\ No newline at end of file +superfluid | aleph-sdk-ts
Options
All
  • Public
  • Public/Protected
  • All
Menu

Namespace superfluid

Index

Functions

  • GetAccountFromProvider(provider: ExternalProvider, requestedRpc?: ChangeRpcParam): Promise<SuperfluidAccount>

Generated using TypeDoc

\ No newline at end of file diff --git a/docs/modules/accounts.tezos.html b/docs/modules/accounts.tezos.html index 7c4cd2a3..aedfad3e 100644 --- a/docs/modules/accounts.tezos.html +++ b/docs/modules/accounts.tezos.html @@ -1,7 +1,7 @@ -tezos | aleph-sdk-ts
Options
All
  • Public
  • Public/Protected
  • All
Menu

Index

Variables

STANDARD_DAPP_URL: "https://aleph.im" = "https://aleph.im"

Functions

  • ImportAccountFromBeaconWallet(wallet: BeaconWallet): Promise<TEZOSAccount>
  • ImportAccountFromFundraiserInfo(email: string, password: string, mnemonic: string): Promise<TEZOSAccount>
  • Imports a Tezos account given fundraiser information, using the @taquito/signer InMemorySigner class.

    Parameters

    • email: string

      The email used.

      @@ -9,12 +9,12 @@

      The password used.

    • mnemonic: string

      The mnemonic received during the fundraiser.

      -

    Returns Promise<TEZOSAccount>

  • ImportAccountFromPrivateKey(privateKey: string, passphrase?: string): Promise<TEZOSAccount>

Returns Promise<TEZOSAccount>

  • ImportAccountFromPrivateKey(privateKey: string, passphrase?: string): Promise<TEZOSAccount>
  • Imports a Tezos account given a private key, using the @taquito/signer InMemorySigner class.

    Parameters

    • privateKey: string

      The private key of the account to import.

    • Optional passphrase: string

      The password, if the key is encrypted.

      -

    Returns Promise<TEZOSAccount>

  • NewAccount(): Promise<{ privateKey: Uint8Array; signerAccount: TEZOSAccount }>

Returns Promise<TEZOSAccount>

  • NewAccount(): Promise<{ privateKey: Uint8Array; signerAccount: TEZOSAccount }>
  • Creates a new Tezos account (tz1) using a randomly generated Tezos keypair.

    Returns Promise<{ privateKey: Uint8Array; signerAccount: TEZOSAccount }>

Generated using TypeDoc

\ No newline at end of file diff --git a/docs/modules/messages.aggregate.html b/docs/modules/messages.aggregate.html index 989607ee..320132ff 100644 --- a/docs/modules/messages.aggregate.html +++ b/docs/modules/messages.aggregate.html @@ -1,9 +1,9 @@ -aggregate | aleph-sdk-ts
Options
All
  • Public
  • Public/Protected
  • All
Menu

Namespace aggregate

Index

Functions

Functions

  • Get<T>(configuration: AggregateGetConfiguration): Promise<T>
  • +aggregate | aleph-sdk-ts
    Options
    All
    • Public
    • Public/Protected
    • All
    Menu

    Namespace aggregate

    Index

    Functions

    Functions

    • Get<T>(configuration: AggregateGetConfiguration): Promise<T>
    • Retrieves an aggregate message on from the Aleph network. It uses the address & key(s) provided in the configuration given as a parameter to retrieve the wanted message.

      Type Parameters

      • T

      Parameters

      • configuration: AggregateGetConfiguration

        The configuration used to get the message, including the API endpoint.

        -

      Returns Promise<T>

    • Publish<T>(configuration: AggregatePublishConfiguration<T>): Promise<AggregateMessage<T>>

    Returns Promise<T>

  • Publish<T>(configuration: AggregatePublishConfiguration<T>): Promise<AggregateMessage<T>>
  • Publishes an aggregate message to the Aleph network.

    The message's content must respect the following format : { diff --git a/docs/modules/messages.any.html b/docs/modules/messages.any.html index 00e37052..b20c19df 100644 --- a/docs/modules/messages.any.html +++ b/docs/modules/messages.any.html @@ -1,12 +1,12 @@ -any | aleph-sdk-ts

    Options
    All
    • Public
    • Public/Protected
    • All
    Menu

    Index

    Functions

    • GetMessage<T>(configuration: GetMessageConfiguration): Promise<T>
    • GetMessages(configuration: GetMessagesConfiguration): Promise<MessageQueryResponse>
    • Retrieves Messages with query params.

      Parameters

      • configuration: GetMessagesConfiguration

        The message params to make the query.

        -

      Returns Promise<MessageQueryResponse>

    • GetMessagesSocket(configuration: GetMessagesSocketConfiguration): AlephSocket

    Returns Promise<MessageQueryResponse>

  • GetMessagesSocket(configuration: GetMessagesSocketConfiguration): AlephSocket
  • Retrieves all incoming messages by opening a WebSocket. Messages can be filtered with the params.

    Parameters

    • configuration: GetMessagesSocketConfiguration
      diff --git a/docs/modules/messages.any.is.html b/docs/modules/messages.any.is.html index 950eb681..1b9aefca 100644 --- a/docs/modules/messages.any.is.html +++ b/docs/modules/messages.any.is.html @@ -1 +1 @@ -is | aleph-sdk-ts
      Options
      All
      • Public
      • Public/Protected
      • All
      Menu

      Index

      Functions

      • Aggregate<T>(message: BaseMessage): message is AggregateMessage<T>
      • Forget(message: BaseMessage): message is ForgetMessage
      • Post<T>(message: BaseMessage): message is PostMessage<T>
      • Program(message: BaseMessage): message is ProgramMessage
      • Store(message: BaseMessage): message is StoreMessage

      Settings

      Theme

      Generated using TypeDoc

      \ No newline at end of file +is | aleph-sdk-ts
      Options
      All
      • Public
      • Public/Protected
      • All
      Menu

      Index

      Functions

      • Aggregate<T>(message: BaseMessage): message is AggregateMessage<T>
      • Forget(message: BaseMessage): message is ForgetMessage
      • Post<T>(message: BaseMessage): message is PostMessage<T>
      • Program(message: BaseMessage): message is ProgramMessage
      • Store(message: BaseMessage): message is StoreMessage

      Settings

      Theme

      Generated using TypeDoc

      \ No newline at end of file diff --git a/docs/modules/messages.forget.html b/docs/modules/messages.forget.html index 8f1db616..8850ce16 100644 --- a/docs/modules/messages.forget.html +++ b/docs/modules/messages.forget.html @@ -1,4 +1,4 @@ -forget | aleph-sdk-ts
      Options
      All
      • Public
      • Public/Protected
      • All
      Menu

      Index

      Functions

      Functions

      • Publish(configuration: ForgetPublishConfiguration): Promise<ForgetMessage>
      • +forget | aleph-sdk-ts
        Options
        All
        • Public
        • Public/Protected
        • All
        Menu

        Index

        Functions

        Functions

        • Publish(configuration: ForgetPublishConfiguration): Promise<ForgetMessage>
        • Submit a forget object to remove content from a Post message on the network.

          Account submitting the forget message. Should either be: The sender of the original message to forget. diff --git a/docs/modules/messages.html b/docs/modules/messages.html index 71f6628e..2e22ee1d 100644 --- a/docs/modules/messages.html +++ b/docs/modules/messages.html @@ -1,4 +1,4 @@ -messages | aleph-sdk-ts

          Options
          All
          • Public
          • Public/Protected
          • All
          Menu

          Namespace messages

          Index

          Functions

          • GetVerificationBuffer(message: BaseMessage): Buffer
          • +messages | aleph-sdk-ts
            Options
            All
            • Public
            • Public/Protected
            • All
            Menu

            Namespace messages

            Index

            Functions

            • GetVerificationBuffer(message: BaseMessage): Buffer
            • Extracts some fields from an Aleph message to sign it using an account.

              Parameters

              • message: BaseMessage

                The message used to extract data.

                diff --git a/docs/modules/messages.instance.html b/docs/modules/messages.instance.html index 25ebe74d..e920c03a 100644 --- a/docs/modules/messages.instance.html +++ b/docs/modules/messages.instance.html @@ -1 +1 @@ -instance | aleph-sdk-ts
                Options
                All
                • Public
                • Public/Protected
                • All
                Menu

                Namespace instance

                Index

                Functions

                Functions

                • publish(__namedParameters: InstancePublishConfiguration): Promise<InstanceMessage>

                Settings

                Theme

                Generated using TypeDoc

                \ No newline at end of file +instance | aleph-sdk-ts
                Options
                All
                • Public
                • Public/Protected
                • All
                Menu

                Namespace instance

                Index

                Functions

                Functions

                • publish(__namedParameters: InstancePublishConfiguration): Promise<InstanceMessage>

                Settings

                Theme

                Generated using TypeDoc

                \ No newline at end of file diff --git a/docs/modules/messages.post.html b/docs/modules/messages.post.html index 0e989cf1..a35cda15 100644 --- a/docs/modules/messages.post.html +++ b/docs/modules/messages.post.html @@ -1,10 +1,10 @@ -post | aleph-sdk-ts
                Options
                All
                • Public
                • Public/Protected
                • All
                Menu

                Index

                Functions

                Functions

                • Get<T>(configuration: PostGetConfiguration): Promise<PostQueryResponse<T>>
                • +post | aleph-sdk-ts
                  Options
                  All
                  • Public
                  • Public/Protected
                  • All
                  Menu

                  Index

                  Functions

                  Functions

                  • Get<T>(configuration: PostGetConfiguration): Promise<PostQueryResponse<T>>
                  • Retrieves a post message on from the Aleph network. It uses the type(s) provided in the configuration given as a parameter to retrieve the wanted message. It also uses the pagination and page parameter to limit the number of messages to retrieve.

                    Type Parameters

                    • T

                    Parameters

                    • configuration: PostGetConfiguration

                      The configuration used to get the message, including the API endpoint.

                      -

                    Returns Promise<PostQueryResponse<T>>

                  • Publish<T>(configuration: PostSubmitConfiguration<T>): Promise<PostMessage<T>>

                  Returns Promise<PostQueryResponse<T>>

                • Publish<T>(configuration: PostSubmitConfiguration<T>): Promise<PostMessage<T>>
                • Publishes a post message to the Aleph network.

                  This message must be indexed using a type, you can provide in the configuration.

                  You can amend the message using the type 'amend' and by providing the reference of the message to amend (its hash).

                  diff --git a/docs/modules/messages.program.html b/docs/modules/messages.program.html index a3aa3857..2c2a6b58 100644 --- a/docs/modules/messages.program.html +++ b/docs/modules/messages.program.html @@ -1 +1 @@ -program | aleph-sdk-ts
                  Options
                  All
                  • Public
                  • Public/Protected
                  • All
                  Menu

                  Namespace program

                  Index

                  Functions

                  Functions

                  • Spawn(__namedParameters: ProgramSpawnConfiguration): Promise<ProgramMessage>
                  • publish(__namedParameters: ProgramPublishConfiguration): Promise<ProgramMessage>

                  Settings

                  Theme

                  Generated using TypeDoc

                  \ No newline at end of file +program | aleph-sdk-ts
                  Options
                  All
                  • Public
                  • Public/Protected
                  • All
                  Menu

                  Namespace program

                  Index

                  Functions

                  Functions

                  • Spawn(__namedParameters: ProgramSpawnConfiguration): Promise<ProgramMessage>
                  • publish(__namedParameters: ProgramPublishConfiguration): Promise<ProgramMessage>

                  Settings

                  Theme

                  Generated using TypeDoc

                  \ No newline at end of file diff --git a/docs/modules/messages.store.html b/docs/modules/messages.store.html index 4a8d2861..da0a1bbc 100644 --- a/docs/modules/messages.store.html +++ b/docs/modules/messages.store.html @@ -1,13 +1,13 @@ -store | aleph-sdk-ts
                  Options
                  All
                  • Public
                  • Public/Protected
                  • All
                  Menu

                  Index

                  Functions

                  Functions

                  • Get(configuration: StoreGetConfiguration): Promise<ArrayBuffer>
                  • +store | aleph-sdk-ts
                    Options
                    All
                    • Public
                    • Public/Protected
                    • All
                    Menu

                    Index

                    Functions

                    Functions

                    • Get(configuration: StoreGetConfiguration): Promise<ArrayBuffer>
                    • Retrieves a store message, i.e. a message containing a File.

                      Parameters

                      • configuration: StoreGetConfiguration

                        The message hash and the API Server endpoint to make the query.

                        -

                      Returns Promise<ArrayBuffer>

                    • Pin(spc: StorePinConfiguration): Promise<StoreMessage>

                    Returns Promise<ArrayBuffer>

                  • Pin(spc: StorePinConfiguration): Promise<StoreMessage>
                  • Publishes a store message, containing a hash to pin an IPFS file. You also have to provide default message properties, such as the targeted channel or the account used to sign the message.

                    Parameters

                    • spc: StorePinConfiguration

                      The configuration used to pin the file.

                      -

                    Returns Promise<StoreMessage>

                  • Publish(spc: RequireOnlyOne<StorePublishConfiguration, "fileHash" | "fileObject">): Promise<StoreMessage>

                  Returns Promise<StoreMessage>

                • Publish(spc: RequireOnlyOne<StorePublishConfiguration, "fileHash" | "fileObject">): Promise<StoreMessage>
                • Publishes a store message, containing a File. You also have to provide default message properties, such as the targeted channel or the account used to sign the message.

                  Parameters

                  • spc: RequireOnlyOne<StorePublishConfiguration, "fileHash" | "fileObject">
                    diff --git a/docs/modules/utils.html b/docs/modules/utils.html index 78087abc..41ae3960 100644 --- a/docs/modules/utils.html +++ b/docs/modules/utils.html @@ -1,4 +1,4 @@ -utils | aleph-sdk-ts
                    Options
                    All
                    • Public
                    • Public/Protected
                    • All
                    Menu

                    Namespace utils

                    Index

                    Functions

                    • verifyAvalanche(message: BaseMessage | Buffer, signature: string, signerPKey: string): Promise<boolean>
                    • +utils | aleph-sdk-ts
                      Options
                      All
                      • Public
                      • Public/Protected
                      • All
                      Menu

                      Namespace utils

                      Index

                      Functions

                      • verifyAvalanche(message: BaseMessage | Buffer, signature: string, signerPKey: string): Promise<boolean>
                      • Provide a way to verify the authenticity of a signature associated with a given message. This method rely on the Keypair.recover() implementation.

                        Parameters

                        • message: BaseMessage | Buffer
                          @@ -7,14 +7,14 @@

                          The signature associated with the first params of this method.

                        • signerPKey: string

                          Optional, The publicKey associated with the signature to verify. It Needs to be under a hex serialized string.

                          -

                        Returns Promise<boolean>

                      • verifyCosmos(message: BaseMessage | Buffer, serializedSignature: string): Promise<boolean>

                      Returns Promise<boolean>

                    • verifyCosmos(message: BaseMessage | Buffer, serializedSignature: string): Promise<boolean>
                    • Provide a way to verify the authenticity of a signature associated with a given message. This method rely on the ethers.utils.verifyMessage() implementation.

                      Parameters

                      • message: BaseMessage | Buffer

                        The content of the signature to verify. It can be the result of GetVerificationBuffer() or directly a BaseMessage object.

                      • serializedSignature: string

                        The signature associated with the first params of this method.

                        -

                      Returns Promise<boolean>

                    • verifyEthereum(message: BaseMessage | Buffer, signature: string, signerAddress: string): boolean

                    Returns Promise<boolean>

                • verifyEthereum(message: BaseMessage | Buffer, signature: string, signerAddress: string): boolean
                • Provide a way to verify the authenticity of a signature associated with a given message. This method rely on the ethers.utils.verifyMessage() implementation.

                  Parameters

                  • message: BaseMessage | Buffer
                    @@ -23,14 +23,14 @@

                    The signature associated with the first params of this method.

                  • signerAddress: string

                    Optional, The address associated with the signature to verify. The current account address is used by default.

                    -

                  Returns boolean

                • verifySolana(message: BaseMessage | Buffer, serializedSignature: string): boolean

                Returns boolean

            • verifySolana(message: BaseMessage | Buffer, serializedSignature: string): boolean
            • Provide a way to verify the authenticity of a signature associated with a given message. This method rely on the nacl.sign.detached.verify() implementation.

              Parameters

              • message: BaseMessage | Buffer

                The content of the signature to verify. It can be the result of GetVerificationBuffer() or directly a BaseMessage object.

              • serializedSignature: string

                The signature associated with the first params of this method.

                -

              Returns boolean

            • verifySubstrate(message: BaseMessage | Buffer, signature: string, signerAddress: string): boolean

            Returns boolean

          • verifySubstrate(message: BaseMessage | Buffer, signature: string, signerAddress: string): boolean
          • Provide a way to verify the authenticity of a signature associated with a given message. This method rely on the signatureVerify() implementation from @polkadot/util-crypto.

            Parameters

            • message: BaseMessage | Buffer
              @@ -39,7 +39,7 @@

              The signature associated with the first params of this method.

            • signerAddress: string

              Optional, The address associated with the signature to verify. The current account address is used by default.

              -

            Returns boolean

          • verifyTezos(message: BaseMessage, signature: string): boolean

          Returns boolean

        • verifyTezos(message: BaseMessage, signature: string): boolean
        • Provide a way to verify the authenticity of a signature associated with a given message. This method rely on the verifySignature() implementation from taquito/utils.

          Parameters

          • message: BaseMessage