Module

Cardano.Wallet.Cip30

Interact with the wallet over CIP-30 interface description: https://cips.cardano.org/cip/CIP-0030

Code works by inspection of window.cardano object which should be injected by the wallet to the window.

#Bytes

type Bytes = String

#Cbor

type Cbor = String

#Api

data Api

A datatype representing a CIP-30 connection object.

#DataSignature

type DataSignature = { key :: Cbor, signature :: Cbor }

#Extension

type Extension = { cip :: Int }

#NetworkId

type NetworkId = Int

#Paginate

type Paginate = { limit :: Int, page :: Int }

#WalletName

#enable

enable :: WalletName -> Array Extension -> Aff Api

Enables wallet and reads Cip30 wallet API if wallet is available

#getAvailableWallets

getAvailableWallets :: Effect (Array WalletName)

Reads all wallets that are available in the browser.

#getBalance

#getChangeAddress

#getCollateral

#getExtensions

#getNetworkId

#getRewardAddresses

#getUnusedAddresses

#getUsedAddresses

#getUtxos

#isEnabled

isEnabled :: WalletName -> Aff Boolean

Checks weather wallet is enabled.

#signData

#signTx

#submitTx

Modules