Chats & Messages service for NEAR Blockchain.
- nodeJS
- npm
- The Graph: @graphprotocol/graph-cli package
If you haven't installed dependencies during setup:
npm install
Build and deploy your contract to TestNet with a temporary dev account:
npm run deploy
Test your contract:
npm test
If you have a frontend, run npm start
. This will run a dev server.
graph init
? Protocol › near ? Subgraph name › vlodkomr/chatme ? Directory to create the subgraph in › thegraph ? NEAR network › near-testnet ? Contract account › .... contract address.... ? Contract Name · ChatMe
graph codegen && graph build
ACCESS_TOKEN=
graph auth https://api.thegraph.com/deploy/ $ACCESS_TOKEN
yarn deploy
near-message.testnet - Local chatme.testnet - TestNet chatme.near - MainNet
Testnet: https://test.chatme.page/ Mainnet: https://chatme.page/
Package used for message encryption: https://github.com/NEARFoundation/near-js-encryption-box Documentation: https://chatme.gitbook.io/chatme
CONTRACT_ID=chatme.near
CONTRACT_OWNER_ID=vlodkow.near
ACCOUNT_ID=
NEAR_ENV=mainnet near call $CONTRACT_ID admin_set_user_level '{"account":"'$ACCOUNT_ID'", "level":2}' --accountId $CONTRACT_OWNER_ID --depositYocto 1