ethmoji-js
v0.0.27
Published
Add an Ethmoji avatar for users of your dapp
Readme
ethmoji-js
Let's developers interact with the Ethmoji game, starting with fetching your users' Ethmoji avatar.
Installation & Setup:
yarn add ethmoji-jsUsing ES6 style imports (recommended):
import EthmojiAPI from "ethmoji-js";
...
const ethmojiAPI = new EthmojiAPI(web3.currentProvider);
await ethmojiAPI.init();
await avatar = ethmojiAPI.getAvatar(ownerAddress);
=> Avatar {
name: Ethmoji name
tokenId: Ethmoji tokenId in the smart contract
imageUrl: Ethmoji image url for displaying
ownerAddress: Ethmoji ownerAddress
ownerUsername: Ethmojis ownerUsername on OpenSea
}