Methods
importByPrivateKey
- importByPrivateKey(privateKey): Promise<WalletImportByPrivateKeyResponse>
-
- A promise that resolves to an object containing the private key, public key, public key bytes, address, and address with prefix.
publicKeyToAddress
- publicKeyToAddress(publicKey): Promise<string>
-
Returns Promise<string>
- A promise that resolves to the address derived from the public key.
signPayload
- signPayload(rawPayload, privateKey): Promise<Uint8Array>
-
Parameters
-
rawPayload: any
-
privateKey: string
Returns Promise<Uint8Array>
- A promise that resolves to the signature of the payload.
toHex
- toHex(_data): Promise<string>
-
Returns Promise<string>
- A promise that resolves to the hexadecimal representation of the input Uint8Array.
verifyPayload
- verifyPayload(_signature, _payload, _publicKey): Promise<boolean>
-
Parameters
-
_signature: string
-
-
_publicKey: string
Returns Promise<boolean>
- A promise that resolves to a boolean indicating whether the signature is valid.
A service class for managing L1X wallets, private keys, and signatures.
See
RawPayloadArg