Chainlink Developers

Welcome to the Chainlink documentation site. You'll find comprehensive guides and documentation to help you start working with Chainlink as quickly as possible, as well as support if you get stuck. Click here for an introductory walkthrough on how to create a Chainlink request on the Ropsten test network!

Building on Chainlink? Click here to get started!

Get Started

Run an Ethereum Client

In order to run a Chainlink node, it must be able to connect to an Ethereum client with an active websocket connection. This is accomplished by running either Geth, Parity, or using a 3rd party connection. The examples below show how to run Geth and Parity in their official Docker containers for each network that they support.

If you choose to run either Geth or Parity with their native clients, please be sure to enable the websockets API, since it is required for the Chainlink node to communicate with the Ethereum blockchain.

We use light clients in these examples for test networks to save disk space. This should only be done for test networks and not for the Ethereum main network as it reduces security. The commands for Mainnet will have you run a full node. Keep in mind that the hardware requirements for running a full node are significantly higher than that of a light client.

Geth

Geth's Documentation

The Geth client can be used for the Ropsten and Rinkeby test networks, as well as the Ethereum main network.

Download the latest version:

docker pull ethereum/client-go:latest

Create a local directory to persist the data:

mkdir ~/.geth-ropsten
mkdir ~/.geth-rinkeby
mkdir ~/.geth

Run the container:

docker run --name eth -p 8546:8546 -v ~/.geth-ropsten:/geth -it \
           ethereum/client-go --testnet --syncmode light --ws \
           --wsaddr 0.0.0.0 --wsorigins="*" --datadir /geth --ipcdisable
docker run --name eth -p 8546:8546 -v ~/.geth-rinkeby:/geth -it \
           ethereum/client-go --rinkeby --syncmode light --ws \
           --wsaddr 0.0.0.0 --wsorigins="*" --datadir /geth --ipcdisable
docker run --name eth -p 8546:8546 -v ~/.geth:/geth -it \
           ethereum/client-go --syncmode fast --ws \
           --wsaddr 0.0.0.0 --wsorigins="*" --datadir /geth --ipcdisable

Once the Ethereum client is running, you can use Ctrl + P, Ctrl + Q to detach from the container without stopping it. You will need to leave the container running for the Chainlink node to connect to it.

If the container was stopped and you need to run it again, you can simply use the following command:

docker start -i eth

Return to Running a Chainlink Node.

Parity

Parity's Documentation

The Parity client can be used for the Ropsten and Kovan test networks, as well as the Ethereum main network.

Download the latest version:

docker pull parity/parity:stable

Create a local directory to persist the data:

mkdir ~/.parity-ropsten
mkdir ~/.parity-kovan
mkdir ~/.parity

Run the container:

docker run --name eth -p 8546:8546 \
           -v ~/.parity-ropsten:/home/parity/.local/share/io.parity.ethereum/ \
           -it parity/parity:stable --chain=ropsten \
           --ws-interface=all --ws-origins="all" --light \
           --base-path /home/parity/.local/share/io.parity.ethereum/
docker run -h eth --name eth -p 8546:8546 \
           -v ~/.parity-kovan:/home/parity/.local/share/io.parity.ethereum/ \
           -it parity/parity:stable --chain=kovan \
           --ws-interface=all --ws-origins="all" --light \
           --base-path /home/parity/.local/share/io.parity.ethereum/
docker run --name eth -p 8546:8546 \
           -v ~/.parity:/home/parity/.local/share/io.parity.ethereum/ \
           -it parity/parity:stable --ws-interface=all --ws-origins="all" \
           --base-path /home/parity/.local/share/io.parity.ethereum/

Once the Ethereum client is running, you can use Ctrl + P, Ctrl + Q to detach from the container without stopping it. You will need to leave the container running for the Chainlink node to connect to it.

If the container was stopped and you need to run it again, you can simply use the following command:

docker start -i eth

Return to Running a Chainlink Node.

External Services

The following services offer Ethereum clients with websockets connectivity known to work with the Chainlink node.

Fiews

Example connection setting

ETH_URL=wss://cl-ropsten.fiews.io/v1/yourapikey
ETH_URL=wss://cl-rinkeby.fiews.io/v1/yourapikey
ETH_URL=wss://cl-main.fiews.io/v1/yourapikey

Infura

Example connection setting

ETH_URL=wss://ropsten.infura.io/ws
ETH_URL=wss://rinkeby.infura.io/ws
ETH_URL=wss://kovan.infura.io/ws
ETH_URL=wss://mainnet.infura.io/ws

LinkPool

Example connection setting

ETH_URL=wss://ropsten-rpc.linkpool.io/ws
ETH_URL=wss://main-rpc.linkpool.io/ws

Run an Ethereum Client


Suggested Edits are limited on API Reference Pages

You can only suggest edits to Markdown body content, but not to the API spec.