OORT Wallet Developers

The OORT wallet development API and example codes.

The OORT wallet (Chrome Extension) API

The OORT wallet API provides tools for web developers interacting with MCP, the blockchain layer of CCN. The developers can use the API to transfer crypto assets, deploy smart contracts, and build dApps on MCP.

The OORT wallet provider's name is "aleereum".

Check if OORT wallet is installed

typeof window[“aleereum”] !== “undefined”
const provider = window[“aleereum”]

Check if OORT wallet is connected

const isConnected: boolean = provider.isConnected

Check if OORT wallet is locked

const islocked: boolean = provider.islocked

Get current network Id

const networkId: string = provider.networkId

NetworkId = 1: Mainnet (Under development)

NetworkId - 2: Dome-A Testnet

NetworkId = 3: Huygens Testnet

Get current account

Get an account balance

Connect or unlock the wallet

Listen to the change of account

Listen to the change of networkId

Listen to the change of isConnected status of the wallet

Listen to the change of lock/unlock status of the wallet

Examples

Vue.js example code

Send a transaction to smart contract

Last updated