This repository has been archived by the owner. It is now read-only.
A JSON-RPC 2.0 Specification compliant server to interact with the ARK blockchain.
Branch: master
Clone or download
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Permalink
Type Name Latest commit message Commit time
Failed to load latest commit information.
.github
__tests__
bin
lib
.dockerignore
.editorconfig
.eslintignore
.eslintrc
.gitignore
.travis.yml
Dockerfile
LICENSE
README.md
banner.png
jest.config.js
package.json
yarn.lock

README.md

⚠️ DEPRECATED IN FAVOR OF https://github.com/ArkEcosystem/core/tree/master/packages/core-json-rpc WHICH IS PART OF CORE V2 ⚠️

ARK JSON-RPC

A JSON-RPC 2.0 Specification compliant server to interact with the ARK blockchain.

Security Warning for Production

All calls should be made from the server where JSON-RPC is running at (i.e., localhost or 127.0.0.1). The JSON-RPC server should never be publicly accessible. If you wish to access JSON-RPC server from a remote address, you can whitelist the address with --allow <address>. Addresses allow you to use wildcards, eg. 192.168.1.* or 10.0.*.*.

If you do want to allow access from all remotes, start the JSON-RPC server with the --allow-remote commandline switch. This can be dangerous.

Installation

Before you can get started with ARK RPC you will need to install node.js. If you are not on Ubuntu, headover to the installation instructions to find more details for your operating system.

$ curl -sL https://deb.nodesource.com/setup_10.x | sudo -E bash -
$ sudo apt-get install -y nodejs

After you have installed node.js and made sure it is working you are ready to setup pm2 and ARK JSON-RPC.

$ npm install pm2 -g
$ npm install @arkecosystem/json-rpc

Running the JSON-RPC Server

pm2

The recommended way of running and keeping your JSON-RPC server alive is pm2.

$ pm2 start ark-json-rpc

Docker

If you would like to run from a docker environment, you will first need to build the container by running:

$ docker build -t ark-json-rpc .

You will need to run the container with the --allow-remote option to allow the host machine to access the container.

$ docker run --name ark-json-rpc -d -p 8080:8080 ark-json-rpc -e "--allow-remote"

Security

If you discover a security vulnerability within this package, please send an e-mail to security@ark.io. All security vulnerabilities will be promptly addressed.

Credits

License

MIT © ArkEcosystem