CARDANO | CANIUSE
Cardano Wallet API Compatiblity Matrix ⚡️
walletName
This is the field the wallet will inject itself as into the window.cardano
object
Flint | Nami | Eternl | Gero | NuFi | Begin | Lace | Yoroi |
---|---|---|---|---|---|---|---|
flint | nami | eternl | gerowallet | nufi | begin | lace | yoroi |
cardano.{walletName}.enable(): Promise<API>
Errors: APIError
This is the entrypoint to start communication with the user's wallet. The wallet should request the user's permission to connect the web page to the user's wallet, and if permission has been granted, the full API will be returned to the dApp to use. The wallet can choose to maintain a whitelist to not necessarily ask the user's permission every time access is requested, but this behavior is up to the wallet and should be transparent to web pages using this API. If a wallet is already connected this function should not request access a second time, and instead just return the API
object.
Flint | Nami | Eternl | Gero | NuFi | Begin | Lace | Yoroi |
---|---|---|---|---|---|---|---|
SUPPORTED | SUPPORTED | SUPPORTED | SUPPORTED | SUPPORTED | SUPPORTED | SUPPORTED | SUPPORTED |
cardano.{walletName}.isEnabled(): Promise<bool>
Errors: APIError
Returns true if the dApp is already connected to the user's wallet, or if requesting access would return true without user confirmation (e.g. the dApp is whitelisted), and false otherwise. If this function returns true, then any subsequent calls to wallet.enable()
during the current session should succeed and return the API
object.
Flint | Nami | Eternl | Gero | NuFi | Begin | Lace | Yoroi |
---|---|---|---|---|---|---|---|
SUPPORTED | SUPPORTED | SUPPORTED | SUPPORTED | SUPPORTED | SUPPORTED | SUPPORTED | SUPPORTED |
cardano.{walletName}.apiVersion: String
The version number of the API that the wallet supports.
Flint | Nami | Eternl | Gero | NuFi | Begin | Lace | Yoroi |
---|---|---|---|---|---|---|---|
SUPPORTED | SUPPORTED | SUPPORTED | SUPPORTED | SUPPORTED | SUPPORTED | SUPPORTED | SUPPORTED |
cardano.{walletName}.name: String
A name for the wallet which can be used inside of the dApp for the purpose of asking the user which wallet they would like to connect with.
Flint | Nami | Eternl | Gero | NuFi | Begin | Lace | Yoroi |
---|---|---|---|---|---|---|---|
SUPPORTED | SUPPORTED | SUPPORTED | SUPPORTED | SUPPORTED | SUPPORTED | SUPPORTED | SUPPORTED |
cardano.{walletName}.icon: String
A URI image (e.g. data URI base64 or other) for img src for the wallet which can be used inside of the dApp for the purpose of asking the user which wallet they would like to connect with.
Flint | Nami | Eternl | Gero | NuFi | Begin | Lace | Yoroi |
---|---|---|---|---|---|---|---|
SUPPORTED | SUPPORTED | SUPPORTED | SUPPORTED | SUPPORTED | SUPPORTED | SUPPORTED | SUPPORTED |
api.getNetworkId(): Promise<number>
Errors: APIError
Returns the network id of the currently connected account. 0 is testnet and 1 is mainnet but other networks can possibly be returned by wallets. Those other network ID values are not governed by this document. This result will stay the same unless the connected account has changed.
Flint | Nami | Eternl | Gero | NuFi | Begin | Lace | Yoroi |
---|---|---|---|---|---|---|---|
SUPPORTED | SUPPORTED | SUPPORTED | SUPPORTED | SUPPORTED | SUPPORTED | SUPPORTED | SUPPORTED |
api.getUtxos(amount: cbor<value> = undefined, paginate: Paginate = undefined): Promise<TransactionUnspentOutput[] | undefined>
Errors: APIError
, PaginateError
If amount
is undefined
, this shall return a list of all UTXOs (unspent transaction outputs) controlled by the wallet. If amount
is not undefined
, this request shall be limited to just the UTXOs that are required to reach the combined ADA/multiasset value target specified in amount
, and if this cannot be attained, undefined
shall be returned. The results can be further paginated by paginate
if it is not undefined
.
Flint | Nami | Eternl | Gero | NuFi | Begin | Lace | Yoroi |
---|---|---|---|---|---|---|---|
SUPPORTED | SUPPORTED | SUPPORTED | SUPPORTED | SUPPORTED | SUPPORTED | SUPPORTED | SUPPORTED |
api.getBalance(): Promise<cbor<value>>
Errors: APIError
Returns the total balance available of the wallet. This is the same as summing the results of api.getUtxos()
, but it is both useful to dApps and likely already maintained by the implementing wallet in a more efficient manner so it has been included in the API as well.
Flint | Nami | Eternl | Gero | NuFi | Begin | Lace | Yoroi |
---|---|---|---|---|---|---|---|
SUPPORTED | SUPPORTED | SUPPORTED | SUPPORTED | SUPPORTED | SUPPORTED | SUPPORTED | SUPPORTED |
api.getUsedAddresses(paginate: Paginate = undefined): Promise<cbor<address>[]>
Errors: APIError
Returns a list of all used (included in some on-chain transaction) addresses controlled by the wallet. The results can be further paginated by paginate
if it is not undefined
.
Flint | Nami | Eternl | Gero | NuFi | Begin | Lace | Yoroi |
---|---|---|---|---|---|---|---|
SUPPORTED | SUPPORTED | SUPPORTED | SUPPORTED | SUPPORTED | SUPPORTED | SUPPORTED | SUPPORTED |
api.getUnusedAddresses(): Promise<cbor<address>[]>
Errors: APIError
Returns a list of unused addresses controlled by the wallet.
Flint | Nami | Eternl | Gero | NuFi | Begin | Lace | Yoroi |
---|---|---|---|---|---|---|---|
SUPPORTED | SUPPORTED | SUPPORTED | SUPPORTED | SUPPORTED | SUPPORTED | SUPPORTED | SUPPORTED |
api.getChangeAddress(): Promise<cbor<address>>
Errors: APIError
Returns an address owned by the wallet that should be used as a change address to return leftover assets during transaction creation back to the connected wallet. This can be used as a generic receive address as well.
Flint | Nami | Eternl | Gero | NuFi | Begin | Lace | Yoroi |
---|---|---|---|---|---|---|---|
SUPPORTED | SUPPORTED | SUPPORTED | SUPPORTED | SUPPORTED | SUPPORTED | SUPPORTED | SUPPORTED |
api.getRewardAddress(): Promise<cbor<address>>
Errors: APIError
Returns the reward address owned by the wallet. This only returns a single address
Deprecated. See getRewardAddresses
Flint | Nami | Eternl | Gero | NuFi | Begin | Lace | Yoroi |
---|---|---|---|---|---|---|---|
DEPRECATED | SUPPORTED | UNKNOWN | SUPPORTED | UNKNOWN | DEPRECATED | NOT SUPPORTED | NOT SUPPORTED |
api.getRewardAddresses(): Promise<cbor<address>[]>
Errors: APIError
Returns the reward addresses owned by the wallet. This can return multiple addresses e.g. CIP-0018.
Flint | Nami | Eternl | Gero | NuFi | Begin | Lace | Yoroi |
---|---|---|---|---|---|---|---|
SUPPORTED | SUPPORTED | SUPPORTED | SUPPORTED | SUPPORTED | SUPPORTED | SUPPORTED | SUPPORTED |
api.getCollateral(): Promise<TransactionUnspentOutput[] | undefined>
Errors: Unknown
No documentation found.
Flint | Nami | Eternl | Gero | NuFi | Begin | Lace | Yoroi |
---|---|---|---|---|---|---|---|
EXPERIMENTAL SUPPORT | EXPERIMENTAL SUPPORT | EXPERIMENTAL SUPPORT | EXPERIMENTAL SUPPORT | EXPERIMENTAL SUPPORT | EXPERIMENTAL SUPPORT | EXPERIMENTAL SUPPORT | EXPERIMENTAL SUPPORT |
api.signTx(tx: cbor<transaction>, partialSign: bool = false): Promise<cbor<transaction_witness_set>>
Errors: APIError
, TxSignError
Requests that a user sign the unsigned portions of the supplied transaction. The wallet should ask the user for permission, and if given, try to sign the supplied body and return a signed transaction. If partialSign
is true, the wallet only tries to sign what it can. If partialSign
is false and the wallet could not sign the entire transaction, TxSignError
shall be returned with the ProofGeneration
code. Likewise if the user declined in either case it shall return the UserDeclined
code. Only the portions of the witness set that were signed as a result of this call are returned to encourage dApps to verify the contents returned by this endpoint while building the final transaction.
Flint | Nami | Eternl | Gero | NuFi | Begin | Lace | Yoroi |
---|---|---|---|---|---|---|---|
SUPPORTED | SUPPORTED | SUPPORTED | SUPPORTED | SUPPORTED | SUPPORTED | SUPPORTED | SUPPORTED |
api.signData: (addr: Cbor<address> | bech32, payload: HexString) => Promise<DataSignature>
Errors: APIError
, DataSignError
This endpoint utilizes the CIP-0008 signing spec for standardization/safety reasons. It allows the dApp to request the user to sign data conforming to said spec. The user's consent should be requested and the details of sig_structure
shown to them in an informative way. The Please refer to the CIP-0008 spec for details on how to construct the sig structure.
The return value has the following form:
type DataSignature = {
signature: cbor<COSE_Sign1>,
key: cbor<COSE_Key>,
};
Flint | Nami | Eternl | Gero | NuFi | Begin | Lace | Yoroi |
---|---|---|---|---|---|---|---|
SUPPORTED | SUPPORTED | SUPPORTED | SUPPORTED | SUPPORTED | SUPPORTED | SUPPORTED | SUPPORTED |
api.submitTx(tx: cbor<transaction>): Promise<hash32>
Errors: APIError
, TxSendError
As wallets should already have this ability, we allow dApps to request that a transaction be sent through it. If the wallet accepts the transaction and tries to send it, it shall return the transaction id for the dApp to track. The wallet is free to return the TxSendError
with code Refused
if they do not wish to send it, or Failure
if there was an error in sending it (e.g. preliminary checks failed on signatures).
Flint | Nami | Eternl | Gero | NuFi | Begin | Lace | Yoroi |
---|---|---|---|---|---|---|---|
SUPPORTED | SUPPORTED | SUPPORTED | SUPPORTED | SUPPORTED | SUPPORTED | SUPPORTED | SUPPORTED |
api.on(event: string, callback: Function): void
Errors: Unknown
Please see https://github.com/cardano-foundation/CIPs/pull/151.
Flint | Nami | Eternl | Gero | NuFi | Begin | Lace | Yoroi |
---|---|---|---|---|---|---|---|
UNKNOWN | EXPERIMENTAL SUPPORT | UNKNOWN | EXPERIMENTAL SUPPORT | UNKNOWN | EXPERIMENTAL SUPPORT | NOT SUPPORTED | NOT SUPPORTED |
api.off(event: string, callback: Function): void
Errors: Unknown
Please see https://github.com/cardano-foundation/CIPs/pull/151.
Flint | Nami | Eternl | Gero | NuFi | Begin | Lace | Yoroi |
---|---|---|---|---|---|---|---|
UNKNOWN | EXPERIMENTAL SUPPORT | UNKNOWN | EXPERIMENTAL SUPPORT | UNKNOWN | EXPERIMENTAL SUPPORT | NOT SUPPORTED | NOT SUPPORTED |