Skip to content

OlehBandrivskyi/notifi-near-integration

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

3 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Created by Timur Ruziev (participant of stakewars-iii)

You can see my challenge report here: https://github.com/ruziev-dev/near-stakewars-iii

Getting credentials to integrate service with your node

Complete form (you can find link in # integration-requests in Discord channel) and you will get credentials for integration on e-mail.

img

Installation:

Clone repository & install dependencies

git clone https://github.com/ruziev-dev/notifi-near-integration.git

cd notifi-near-integration

npm i

Make your .env file by example example.env

cp example.env .env

nano .env
POOL_ID="xx.factory.shardnet.near"
NODE_IP=127.0.0.1
SID=******************************
SECRET='****************************************'
TOPIC=*******************************
npm run build

Run to check

node build/index.js

If everything is ok you will get e-mail message

img

To automate running script find path to Node.js

which node

# use this path to in crontask
> /usr/bin/node

Add chron task midnight

crontab -e

Add this row with setting path to Node.js and script

# set your <USERNAME> to path
0 0 * * * cd /home/<USERNAME>/notifi-near-integration && /usr/bin/node build/index.js > /dev/null 2>&1

About

Node.js script to notify stake data with Notifi Network

Resources

Stars

Watchers

Forks

Packages

No packages published

Languages

  • TypeScript 97.8%
  • Shell 2.2%