Skip to content
node of the decentralized oracle network, bridging on and off-chain computation
Go TypeScript JavaScript Solidity Rust Shell Other
Branch: develop
Clone or download
j16r Merge pull request #2177 from smartcontractkit/fix/170651351-0x-parsi…
…ng-error

eth: Fix parsing of hex value
Latest commit d8f08a8 Jan 21, 2020
Permalink
Type Name Latest commit message Commit time
Failed to load latest commit information.
.circleci Add tests to styleguide Jan 15, 2020
.githooks Add rebase check to CI Dec 18, 2019
.github/ISSUE_TEMPLATE add startup command to node operator issue Oct 21, 2019
core Merge pull request #2177 from smartcontractkit/fix/170651351-0x-parsi… Jan 21, 2020
docs feat(issues): [templates] Add Issue Templates Oct 17, 2019
evm Convert v05 chainlink test to typescript Jan 20, 2020
examples Add nodejs version lock to remaining non-public packages Dec 27, 2019
explorer Bump redux from 4.0.4 to 4.0.5 Jan 20, 2020
integration-scripts Bump request-promise from 4.2.4 to 4.2.5 Jan 13, 2020
integration Bump webpack from 4.41.3 to 4.41.5 Jan 6, 2020
operator_ui Bump redux from 4.0.4 to 4.0.5 Jan 20, 2020
packr make install embeds eth/contracts.go w packr Dec 20, 2019
styleguide Bump @storybook/addon-info from 5.2.8 to 5.3.7 Jan 20, 2020
tools Bump redux from 4.0.4 to 4.0.5 Jan 20, 2020
.codeclimate.yml Configure eslint on codeclimate Feb 27, 2019
.dockerignore Move sgx/ to core/ Dec 19, 2019
.eslintignore Prettier + eslint as workspace commands Dec 17, 2019
.eslintrc.js remove react-hooks @types and enable hook linting Jan 7, 2020
.gitattributes Enable syntax highlighting for solidity files Jan 30, 2019
.gitignore Prettier + eslint as workspace commands Dec 17, 2019
.nvmrc Update .nvmrc config file to nodejs 10.16.3 Nov 27, 2019
.prettierignore Prettier + eslint as workspace commands Dec 17, 2019
.prettierrc.js Prettier + eslint as workspace commands Dec 17, 2019
.solhint.json mark solhint errors Jul 29, 2019
.solhintignore Remove unused examples Nov 11, 2019
GNUmakefile Build contracts as part of the make install Dec 20, 2019
LICENSE add license Feb 15, 2018
README.md README: Use 'make contracts' in prep for Golang testing Dec 27, 2019
VERSION bump patch version Dec 26, 2019
babel.config.js Run eslint --fix Dec 17, 2019
box-img-lg.png update Truffle Box logos May 17, 2019
box-img-sm.png update Truffle Box logos May 17, 2019
go.mod Merge pull request #2184 from smartcontractkit/dependabot/go_modules/… Jan 20, 2020
go.sum Merge pull request #2184 from smartcontractkit/dependabot/go_modules/… Jan 20, 2020
kit.json Add support for OpenZeppelin Starter Kits Aug 12, 2019
notes.md bump parity postgres CI box size Oct 30, 2019
package.json Bump eslint from 6.7.2 to 6.8.0 Jan 20, 2020
requirements.txt bump slither version Dec 20, 2019
truffle-box.json Move Dockerfiles for core to core/ Dec 19, 2019
tsconfig.base.json Add base tsconfig Aug 1, 2019
tsconfig.json Use eslint with a typescript parser to replace tslint Apr 16, 2019
unbox.sh Add support for OpenZeppelin Starter Kits Aug 12, 2019
yarn.lock Bump redux from 4.0.4 to 4.0.5 Jan 20, 2020

README.md

Chainlink

Join the chat at https://gitter.im/smartcontractkit-chainlink/Lobby CircleCI Go Report Card GoDoc Maintainability Test Coverage

Chainlink is middleware to simplify communication with blockchains. Here you'll find the Chainlink Golang node, currently in alpha. This initial implementation is intended for use and review by developers, and will go on to form the basis for Chainlink's decentralized oracle network. Further development of the Chainlink Node and Chainlink Network will happen here, if you are interested in contributing please see our contribution guidelines. The current node supports:

  • easy connectivity of on-chain contracts to any off-chain computation or API
  • multiple methods for scheduling both on-chain and off-chain computation for a user's smart contract
  • automatic gas price bumping to prevent stuck transactions, assuring your data is delivered in a timely manner
  • push notification of smart contract state changes to off-chain systems, by tracking Ethereum logs
  • translation of various off-chain data types into EVM consumable types and transactions
  • easy to implement smart contract libraries for connecting smart contracts directly to their preferred oracles
  • easy to install node, which runs natively across operating systems, blazingly fast, and with a low memory footprint

Examples of how to utilize and integrate Chainlinks can be found in the examples directory.

Install

  1. Install Go 1.12+, and add your GOPATH's bin directory to your PATH
  2. Install NodeJS & Yarn
  3. Download Chainlink: git clone https://github.com/smartcontractkit/chainlink && cd chainlink
  4. Build and install Chainlink: make install
  5. Run the node: chainlink help

Ethereum Node Requirements

In order to run the Chainlink node you must have access to a running Ethereum node with an open websocket connection. Any Ethereum based network will work once you've configured the chain ID. Ethereum node versions currently tested and supported:

Run

NOTE: By default, chainlink will run in TLS mode. For local development you can either disable this by setting CHAINLINK_DEV to true, or generate self signed certificates using tools/bin/self-signed-certs or manually.

To start your Chainlink node, simply run:

$ chainlink local node

By default this will start on port 6688, where it exposes a REST API.

Once your node has started, you can view your current jobs with:

$ chainlink jobspecs

View details of a specific job with:

$ chainlink show $JOB_ID

To find out more about the Chainlink CLI, you can always run chainlink help.

Check out the wiki's pages on Adapters and Initiators to learn more about how to create Jobs and Runs.

Configure

You can configure your node's behavior by setting environment variables which can be, along with default values that get used if no corresponding environment variable is found. The latest information on configuration variables are available in the docs.

Project Directory

This project contains several sub-projects, some with their own documentation.

External Adapters

External adapters are what make Chainlink easily extensible, providing simple integration of custom computations and specialized APIs. A Chainlink node communicates with external adapters via a simple REST API.

For more information on creating and using external adapters, please see our external adapters page.

Development Setup

For the latest information on setting up a development environment, see the guide here.

Build your current version

$ go build -o chainlink ./core/
  • Run the binary:
$ ./chainlink

Test

  1. Install Yarn

  2. Build contracts:

$ yarn
$ make contracts
  1. Ready for testing:
$ go test -parallel=1 ./...

Solidity Development

  1. Install Yarn
  2. Install the dependencies:
$ cd evm
$ yarn install
  1. Run tests:
$ yarn run test-sol

Development Tips

For more tips on how to build and test Chainlink, see our development tips page.

Contributing

Chainlink's source code is licensed under the MIT License, and contributions are welcome.

Please check out our contributing guidelines for more details.

Thank you!

You can’t perform that action at this time.