Skip to main content

Protocol Binary Installation

This guide will help you set up and run a Masa Node using a Go Binary ready for configuration and deployment.

Prerequisites

Before you begin, ensure you have the following installed:

  • Go 1.22 (do not use 1.23)
  • Yarn or npm (for installing contracts)
  • Make
  • Sepolia ETH to get Sepolia MASA tokens from the faucet
info

Only Go 1.22 is supported for building the node: brew install [email protected].

Clone the repository

git clone https://github.com/masa-finance/masa-oracle.git
cd masa-oracle

Install contracts

Navigate to the contract directory:

cd contracts

Install dependencies using yarn or npm

yarn install

or

npm install

Return to the root directory

cd ..

Environment Configuration

Set up environment variables to connect your node to run your node in Local configuration

info

This guide will configure your node as a Local, for a list of network bootnodes, please refer to the Bootnode Configuration bootnode configuration documentation.

Create a .env file in the root directory with these essential variables:

# Default .env configuration

RPC_URL=https://ethereum-sepolia.publicnode.com
ENV=test
FILE_PATH=.
VALIDATOR=false
PORT=8080
info

For more .env options, see our Environment Configuration Guide.

Build the node

make build

Start the node

make run

You will see the following output:

#######################################
# __ __ _ ____ _ #
# | \/ | / \ / ___| / \ #
# | |\/| | / _ \ \___ \ / _ \ #
# | | | |/ ___ \ ___) / ___ \ #
# |_| |_/_/ \_\____/_/ \_\ #
# #
#######################################

Multiaddress: /ip4/192.168.1.8/udp/4001/quic-v1/p2p/16Uiu2HAmDXWNV9RXVoRsbt9z7pFSsKS2KdpN7HHFVLdFZmS7iCvo
IP Address: /ip4/127.0.0.1/udp/4001/quic-v1
Public Key: 0x5dA36a3eB07fd1624B054b99D6417DdF2904e826
Is Staked: false
Is Validator: false
Is TwitterScraper: false
Is DiscordScraper: false
Is TelegramScraper: false
tip

You now have a running node in Local Bootnode configuration

Configure your node

You can now configure your node to start scraping data as a worker, to fetch data from the network or to start participating in the network as a validator.

Set up a scraper: Worker Node

If you want your node to earn rewards configure it to to scrape data on the Masa Protocol.

info

You need to have setup your node and staked your node first to be able to scrape data:

Get data from the Network: Developer Node

AI developers can get data from the Masa Protocol for free by running a Masa node locally or by using our API (coming soon).

info

To get data from the Masa Protocol as a developer you need to stake your node (no free leech) - you need Sepolia ETH to stake.

Secure the Network: Validator Node

Earn MASA rewards by securing the network:

Advanced Configuration

For more detailed setup options:

Troubleshooting and Support

If you encounter any issues:

Choose the path that best fits your needs and follow the respective guide for detailed instructions.