Skip to content
Permalink
Branch: master
Find file Copy path
Find file Copy path
Fetching contributors…
Cannot retrieve contributors at this time
139 lines (97 sloc) 2.44 KB
id title
api_wallet
Wallet reference

Wallets are used to known the address of the Marmo wallet, and to sign intents to that wallet.

Constructor

Creates a new wallet instance

from marmopy import Wallet

Wallet(private or credentials, configuration (optional))

Parameters

  1. private_key - string | Credentials: The private key to use when creating the wallet. Used to sign Intents.
  2. configuration - Config: (semi-optional) The configuration to use in order to derivate the wallet address, by default uses the global configuration, throws if not available.

Return

Wallet object used to sign Intents and obtain the wallet address.

import { Wallet } from "marmojs"

new Wallet(key, config)

Parameters

  1. private_key - string: The private key to use when creating the wallet. Used to sign Intents.
  2. configuration - Config: (semi-optional) The configuration to use in order to derivate the wallet address, by default uses the global configuration, throws if not available.

Return

Wallet object used to sign Intents and obtain the wallet address.

todo

wallet address

The address of the wallet, can receive and send funds, eth, tokens, etc.

wallet.address

Property

  • string - Address of the Marmo wallet
wallet.address

Property

  • string - Address of the Marmo wallet
todo

wallet signer

The address signing the Intents, a regultar Ethereum address derivated from the private key.

wallet.signer

Property

  • string - Address of the wallet signer
wallet.signer

Property

  • string - Address of the wallet signer
todo

wallet sign ()

Signs an Intent using the wallet

wallet.sign(intent)

Parameters

  1. Intent - Intent to sign

Returns

SignedIntent, signature with intent attached

wallet.sign(intent)

Parameters

  1. Intent - Intent to sign

Returns

SignedIntent, signature with intent attached

todo
You can’t perform that action at this time.