Giter Site home page Giter Site logo

arkecosystem / exchange-json-rpc Goto Github PK

View Code? Open in Web Editor NEW
5.0 2.0 9.0 1.69 MB

A JSON-RPC 2.0 specification compliant server for Exchanges to interact with the ARK Blockchain.

License: MIT License

JavaScript 0.77% TypeScript 99.10% Batchfile 0.04% Shell 0.10%

exchange-json-rpc's Introduction

@arkecosystem/exchange-json-rpc

Latest Version Node Engine Build Status License: MIT

Lead Maintainer: Brian Faust

Disclaimer

The Exchange JSON-RPC is only maintained for exchanges, as the name suggests. We do not offer any support or guidance unless you are an Exchange in which case you most likely will already be in touch with us.

Installation

yarn global add @arkecosystem/exchange-json-rpc-cli

Usage

All commands support a -h flag to show help for the specified command.

$ exchange-json-rpc
A JSON-RPC 2.0 specification compliant server for Exchanges to interact with the ARK Blockchain.

VERSION
  @arkecosystem/exchange-json-rpc-cli/1.0.0 darwin-x64 node-v10.16.0

USAGE
  $ exchange-json-rpc [COMMAND]

COMMANDS
  autocomplete  display autocomplete installation instructions
  command
  commands      list all the commands
  help          display help for exchange-json-rpc
  log           Show the log
  restart       Restart the JSON-RPC
  run           Run the JSON-RPC (without pm2)
  start         Start the JSON-RPC
  status        Show the JSON-RPC status
  stop          Stop the JSON-RPC
  update        Update the exchange-json-rpc installation

start

Start the JSON-RPC

exchange-json-rpc start
Flag Description Default Required
--[no-]allowRemote allow remote connections which are filtered by a whitelist n/a No
--network= the name of the network that should be used mainnet No
--token= the name of the token that should be used ark No
--host= the host that should be used to expose the RPC 0.0.0.0 No
--port= the port that should be used to expose the RPC 8008 No
--peer= the peer you want to use for communication, defaults to random network peers n/a No
--whitelist= a comma separated list of IPs that can access the RPC 127.0.0.1,::ffff:127.0.0.1 No

restart

Restart the JSON-RPC

exchange-json-rpc restart

stop

Stop the JSON-RPC

exchange-json-rpc stop
Flag Description Default Required
--kill kill the process or daemon n/a No

run

Run the JSON-RPC without pm2 (exits on CTRL+C)

exchange-json-rpc run
Flag Description Default Required
--[no-]allowRemote allow remote connections which are filtered by a whitelist n/a No
--network= the name of the network that should be used mainnet No
--token= the name of the token that should be used ark No
--host= the host that should be used to expose the RPC 0.0.0.0 No
--port= the port that should be used to expose the RPC 8008 No
--peer= the peer you want to use for communication, defaults to random network peers n/a No
--whitelist= a comma separated list of IPs that can access the RPC 127.0.0.1,::ffff:127.0.0.1 No

status

Show the JSON-RPC status

exchange-json-rpc status

update

Update the JSON-RPC installation

exchange-json-rpc update

log

Show the log

exchange-json-rpc log
Flag Description Default Required
--error= only show error output n/a No
--lines= number of lines to tail 15 No

Security

If you discover a security vulnerability within this package, please send an e-mail to [email protected]. All security vulnerabilities will be promptly addressed.

Credits

This project exists thanks to all the people who contribute.

License

MIT ยฉ ARK Ecosystem

exchange-json-rpc's People

Contributors

boldninja avatar dated avatar dependabot[bot] avatar faustbrian avatar itsanametoo avatar renovate[bot] avatar spkjp avatar vulet avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar

exchange-json-rpc's Issues

[Weekly Digest] Mar 15, 2021 - Mar 21, 2021

Here's the Weekly Digest from Mon, Mar 15, 2021 12:00 AM to Sun, Mar 21, 2021 11:59 PM for ArkEcosystem/exchange-json-rpc.

Issues

Last week there was 1 issue. It is closed now.

Closed

@faustbrian

Pull Requests

Last week, no pull-requests were opened, closed or merged.

Releases

Last week there were no releases.

Contributors

Last week there were no contributors.

Star Gazers

Last week there were no stargazers.


That's all activities since Mon, Mar 15, 2021 12:00 AM, please Watch and Star the repository ArkEcosystem/exchange-json-rpc to receive upcoming weekly updates.

You can also view all Weekly Digests by clicking here.

[Weekly Digest] Mar 15, 2021 - Mar 21, 2021

Here's the Weekly Digest from Mon, Mar 15, 2021 12:00 AM to Sun, Mar 21, 2021 11:59 PM for ArkEcosystem/exchange-json-rpc.

Issues

Last week there was 1 issue. It is closed now.

Closed

@faustbrian

Pull Requests

Last week, no pull-requests were opened, closed or merged.

Releases

Last week there were no releases.

Contributors

Last week there were no contributors.

Star Gazers

Last week there were no stargazers.


That's all activities since Mon, Mar 15, 2021 12:00 AM, please Watch and Star the repository ArkEcosystem/exchange-json-rpc to receive upcoming weekly updates.

You can also view all Weekly Digests by clicking here.

[Weekly Digest] Feb 3, 2020 - Feb 9, 2020

Here's the Weekly Digest from Mon, Feb 3, 2020 12:00 AM to Sun, Feb 9, 2020 11:59 PM for ArkEcosystem/exchange-json-rpc.

Issues

Last week there were no issues.

Pull Requests

Last week, 2 pull-requests were opened, closed or merged.

Merged

Last week, 2 pull-requests were merged.

@faustbrian

@ItsANameToo

Releases

Last week there were no releases.

Contributors

Last week there were 2 contributors.

@faustbrian @ItsANameToo

Thank you for your contributions! ๐ŸŽ‰

Star Gazers

Last week there were no stargazers.


That's all activities since Mon, Feb 3, 2020 12:00 AM, please Watch and Star the repository ArkEcosystem/exchange-json-rpc to receive upcoming weekly updates.

You can also view all Weekly Digests by clicking here.

[Weekly Digest] Dec 16, 2019 - Dec 22, 2019

Here's the Weekly Digest from Mon, Dec 16, 2019 12:00 AM to Sun, Dec 22, 2019 11:59 PM for ArkEcosystem/exchange-json-rpc.

Issues

Last week there were 2 issues. Of these, 1 issues have been closed and 1 issues are still open.

Opened

@faustbrian

Closed

@faustbrian

Pull Requests

Last week, 2 pull-requests were opened, closed or merged.

Releases

Last week there were no releases.

Contributors

Last week there were 2 contributors.

@faustbrian @ItsANameToo

Thank you for your contributions! ๐ŸŽ‰

Star Gazers

Last week there were no stargazers.


That's all activities since Mon, Dec 16, 2019 12:00 AM, please Watch and Star the repository ArkEcosystem/exchange-json-rpc to receive upcoming weekly updates.

You can also view all Weekly Digests by clicking here.

[Weekly Digest] Feb 24, 2020 - Mar 1, 2020

Here's the Weekly Digest from Mon, Feb 24, 2020 12:00 AM to Sun, Mar 1, 2020 11:59 PM for ArkEcosystem/exchange-json-rpc.

Issues

Last week there were no issues.

Pull Requests

Last week, 1 pull-request was opened, closed or merged.

Closed

Last week, 1 pull-request was closed.

@faustbrian

Releases

Last week there were no releases.

Contributors

Last week there were no contributors.

Star Gazers

Last week there were no stargazers.


That's all activities since Mon, Feb 24, 2020 12:00 AM, please Watch and Star the repository ArkEcosystem/exchange-json-rpc to receive upcoming weekly updates.

You can also view all Weekly Digests by clicking here.

[Weekly Digest] Feb 10, 2020 - Feb 16, 2020

Here's the Weekly Digest from Mon, Feb 10, 2020 12:00 AM to Sun, Feb 16, 2020 11:59 PM for ArkEcosystem/exchange-json-rpc.

Issues

Last week there were no issues.

Pull Requests

Last week, 2 pull-requests were opened, closed or merged.

Opened

Last week, 1 pull-request was opened.

@ItsANameToo

Merged

Last week, 1 pull-request was merged.

@faustbrian

Releases

Last week there were no releases.

Contributors

Last week there were 2 contributors.

@faustbrian @ItsANameToo

Thank you for your contributions! ๐ŸŽ‰

Star Gazers

Last week there were no stargazers.


That's all activities since Mon, Feb 10, 2020 12:00 AM, please Watch and Star the repository ArkEcosystem/exchange-json-rpc to receive upcoming weekly updates.

You can also view all Weekly Digests by clicking here.

[Weekly Digest] Mar 23, 2020 - Mar 29, 2020

Here's the Weekly Digest from Mon, Mar 23, 2020 12:00 AM to Sun, Mar 29, 2020 11:59 PM for ArkEcosystem/exchange-json-rpc.

Issues

Last week there were no issues.

Pull Requests

Last week, no pull-requests were opened, closed or merged.

Releases

Last week there were no releases.

Contributors

Last week there were no contributors.

Star Gazers

Last week there was 1 stargazer.

@mausconi

You are the star! ๐ŸŒŸ


That's all activities since Mon, Mar 23, 2020 12:00 AM, please Watch and Star the repository ArkEcosystem/exchange-json-rpc to receive upcoming weekly updates.

You can also view all Weekly Digests by clicking here.

[Weekly Digest] May 13, 2019 - May 19, 2019

Here's the Weekly Digest from Mon, May 13, 2019 12:00 AM to Sun, May 19, 2019 11:59 PM for ArkEcosystem/json-rpc.

Issues

Last week there were no issues.

Pull Requests

Last week, 6 pull-requests were opened, closed or merged.

Merged

Last week, 6 pull-requests were merged.

@faustbrian

Releases

Last week there were no releases.

Contributors

Last week there was 1 contributor.

@faustbrian

Thank you for your contribution! ๐ŸŽ‰

Star Gazers

Last week there were no stargazers.


That's all activities since Mon, May 13, 2019 12:00 AM, please Watch and Star the repository ArkEcosystem/json-rpc to receive upcoming weekly updates.

You can also view all Weekly Digests by clicking here.

Hard-coded value in core-exchange-json-rpc

Expected Behavior

Installing core with the RPC module should allow users to communicate with the node and the network that the node is using.

Current Behavior

Instead of connecting to the network of the node, it grabs hard-coded values from 'exchange-json-rpc' that pulls data from the Ark network.

The package.json in 'core-exchange-json-rpc' shows a dependency called 'exchange-json-rpc' at line 24.

Heading over to this dependency in the 'network.ts' file, it pulls network data from Ark peers:
https://github.com/ArkEcosystem/exchange-json-rpc/blob/master/packages/rpc/src/services/network.ts

At line: 112 and 122.

Possible Solution

It should take the peers and port from a local folder or config file.
Probably in this format: ${resolve(process.env.CORE_PATH_CONFIG)}/peers.json

Steps to Reproduce (for bugs)

  1. Install a node from a bridgechain that is on the same node version as Ark. (Qredit is already patched with a temporary fix Qredit/core@28c6d10)
  2. Enable RPC
  3. Enter: curl -X POST -H "Content-Type: application/vnd.api+json" http://127.0.0.1:8080/ -d '{"jsonrpc":"2.0", "id":"1", "method":"transactions.info", "params":{"id":"b094b11e61c6f7ff8afb45aa1f264f1b14b175c6d40a8be6bb217989e40f18fe"}}'
  4. Replace transaction ID with the one that belongs to the bridgechain.
  5. It will return that the tx is not found, unless its a Ark transaction.

(any other command, like blockheight, network information etc will also return data from the Ark blockchain)

Context

Was trying to help TradeSatoshi integrate a bridgechain on their exchange using RPC.

Your Environment

Used core-control to install the node.

[Weekly Digest] Jan 6, 2020 - Jan 12, 2020

Here's the Weekly Digest from Mon, Jan 6, 2020 12:00 AM to Sun, Jan 12, 2020 11:59 PM for ArkEcosystem/exchange-json-rpc.

Issues

Last week there was 1 issue. It is closed now.

Closed

@faustbrian

Pull Requests

Last week, 1 pull-request was opened, closed or merged.

Opened

Last week, 1 pull-request was opened.

@faustbrian

Releases

Last week there were no releases.

Contributors

Last week there was 1 contributor.

@faustbrian

Thank you for your contribution! ๐ŸŽ‰

Star Gazers

Last week there were no stargazers.


That's all activities since Mon, Jan 6, 2020 12:00 AM, please Watch and Star the repository ArkEcosystem/exchange-json-rpc to receive upcoming weekly updates.

You can also view all Weekly Digests by clicking here.

[Weekly Digest] Nov 4, 2019 - Nov 10, 2019

Here's the Weekly Digest from Mon, Nov 4, 2019 12:00 AM to Sun, Nov 10, 2019 11:59 PM for ArkEcosystem/exchange-json-rpc.

Issues

Last week there was 1 issue. It is closed now.

Closed

@faustbrian

Pull Requests

Last week, 3 pull-requests were opened, closed or merged.

Merged

Last week, 3 pull-requests were merged.

@dated

@faustbrian

Releases

Last week there were no releases.

Contributors

Last week there were 2 contributors.

@dated @faustbrian

Thank you for your contributions! ๐ŸŽ‰

Star Gazers

Last week there were no stargazers.


That's all activities since Mon, Nov 4, 2019 12:00 AM, please Watch and Star the repository ArkEcosystem/exchange-json-rpc to receive upcoming weekly updates.

You can also view all Weekly Digests by clicking here.

[Weekly Digest] Jul 15, 2019 - Jul 21, 2019

Here's the Weekly Digest from Mon, Jul 15, 2019 12:00 AM to Sun, Jul 21, 2019 11:59 PM for ArkEcosystem/exchange-json-rpc.

Issues

Last week there were no issues.

Pull Requests

Last week, no pull-requests were opened, closed or merged.

Releases

Last week there were 3 releases.

  • 1.0.1 at Mon, Jul 15, 2019 8:14 AM
  • 1.0.3 at Mon, Jul 15, 2019 8:16 AM
  • 1.0.0 at Mon, Jul 15, 2019 8:13 AM

Contributors

Last week there were no contributors.

Star Gazers

Last week there were no stargazers.


That's all activities since Mon, Jul 15, 2019 12:00 AM, please Watch and Star the repository ArkEcosystem/exchange-json-rpc to receive upcoming weekly updates.

You can also view all Weekly Digests by clicking here.

[Weekly Digest] Mar 30, 2020 - Apr 5, 2020

Here's the Weekly Digest from Mon, Mar 30, 2020 12:00 AM to Sun, Apr 5, 2020 11:59 PM for ArkEcosystem/exchange-json-rpc.

Issues

Last week there were no issues.

Pull Requests

Last week, 1 pull-request was opened, closed or merged.

Closed

Last week, 1 pull-request was closed.

@ItsANameToo

Releases

Last week there were no releases.

Contributors

Last week there were no contributors.

Star Gazers

Last week there were no stargazers.


That's all activities since Mon, Mar 30, 2020 12:00 AM, please Watch and Star the repository ArkEcosystem/exchange-json-rpc to receive upcoming weekly updates.

You can also view all Weekly Digests by clicking here.

[Weekly Digest] Aug 26, 2019 - Sep 1, 2019

Here's the Weekly Digest from Mon, Aug 26, 2019 12:00 AM to Sun, Sep 1, 2019 11:59 PM for ArkEcosystem/exchange-json-rpc.

Issues

Last week there were no issues.

Pull Requests

Last week, no pull-requests were opened, closed or merged.

Releases

Last week there was 1 release.

  • at Sun, Sep 1, 2019 4:11 AM

Contributors

Last week there were no contributors.

Star Gazers

Last week there were no stargazers.


That's all activities since Mon, Aug 26, 2019 12:00 AM, please Watch and Star the repository ArkEcosystem/exchange-json-rpc to receive upcoming weekly updates.

You can also view all Weekly Digests by clicking here.

[Weekly Digest] Sep 9, 2019 - Sep 15, 2019

Here's the Weekly Digest from Mon, Sep 9, 2019 12:00 AM to Sun, Sep 15, 2019 11:59 PM for ArkEcosystem/exchange-json-rpc.

Issues

Last week there was 1 issue. It is still open.

Opened

@NayiemWillems

Pull Requests

Last week, no pull-requests were opened, closed or merged.

Releases

Last week there was 1 release.

  • at Wed, Sep 11, 2019 10:30 AM

Contributors

Last week there were no contributors.

Star Gazers

Last week there were no stargazers.


That's all activities since Mon, Sep 9, 2019 12:00 AM, please Watch and Star the repository ArkEcosystem/exchange-json-rpc to receive upcoming weekly updates.

You can also view all Weekly Digests by clicking here.

[Weekly Digest] Jun 15, 2020 - Jun 21, 2020

Here's the Weekly Digest from Mon, Jun 15, 2020 12:00 AM to Sun, Jun 21, 2020 11:59 PM for ArkEcosystem/exchange-json-rpc.

Issues

Last week there were no issues.

Pull Requests

Last week, 2 pull-requests were opened, closed or merged.

Merged

Last week, 2 pull-requests were merged.

@faustbrian

Releases

Last week there were no releases.

Contributors

Last week there was 1 contributor.

@faustbrian

Thank you for your contribution! ๐ŸŽ‰

Star Gazers

Last week there were no stargazers.


That's all activities since Mon, Jun 15, 2020 12:00 AM, please Watch and Star the repository ArkEcosystem/exchange-json-rpc to receive upcoming weekly updates.

You can also view all Weekly Digests by clicking here.

[Weekly Digest] Sep 16, 2019 - Sep 22, 2019

Here's the Weekly Digest from Mon, Sep 16, 2019 12:00 AM to Sun, Sep 22, 2019 11:59 PM for ArkEcosystem/exchange-json-rpc.

Issues

Last week there were no issues.

Pull Requests

Last week, 3 pull-requests were opened, closed or merged.

Opened

Last week, 1 pull-request was opened.

@faustbrian

Merged

Last week, 2 pull-requests were merged.

@faustbrian

Releases

Last week there were no releases.

Contributors

Last week there was 1 contributor.

@faustbrian

Thank you for your contribution! ๐ŸŽ‰

Star Gazers

Last week there were no stargazers.


That's all activities since Mon, Sep 16, 2019 12:00 AM, please Watch and Star the repository ArkEcosystem/exchange-json-rpc to receive upcoming weekly updates.

You can also view all Weekly Digests by clicking here.

[Weekly Digest] May 13, 2019 - May 19, 2019

Here's the Weekly Digest from Mon, May 13, 2019 12:00 AM to Sun, May 19, 2019 11:59 PM for ArkEcosystem/exchange-json-rpc.

Issues

Last week there were no issues.

Pull Requests

Last week, 6 pull-requests were opened, closed or merged.

Merged

Last week, 6 pull-requests were merged.

@faustbrian

Releases

Last week there were no releases.

Contributors

Last week there was 1 contributor.

@faustbrian

Thank you for your contribution! ๐ŸŽ‰

Star Gazers

Last week there were no stargazers.


That's all activities since Mon, May 13, 2019 12:00 AM, please Watch and Star the repository ArkEcosystem/exchange-json-rpc to receive upcoming weekly updates.

You can also view all Weekly Digests by clicking here.

Disable network connection for nock

5ee7f94 introduced nock for tests so that they no longer rely on a network connection or live servers.

Currently for the initial setup they still rely on a network connection because some URLs that are called by @arkecosystem/peers are not handled via nock and the isReachable package also performs network calls that are not handled via nock.

[Weekly Digest] Jul 22, 2019 - Jul 28, 2019

Here's the Weekly Digest from Mon, Jul 22, 2019 12:00 AM to Sun, Jul 28, 2019 11:59 PM for ArkEcosystem/exchange-json-rpc.

Issues

Last week there were no issues.

Pull Requests

Last week, 2 pull-requests were opened, closed or merged.

Merged

Last week, 2 pull-requests were merged.

@faustbrian

Releases

Last week there were no releases.

Contributors

Last week there was 1 contributor.

@faustbrian

Thank you for your contribution! ๐ŸŽ‰

Star Gazers

Last week there were no stargazers.


That's all activities since Mon, Jul 22, 2019 12:00 AM, please Watch and Star the repository ArkEcosystem/exchange-json-rpc to receive upcoming weekly updates.

You can also view all Weekly Digests by clicking here.

[Weekly Digest] Sep 23, 2019 - Sep 29, 2019

Here's the Weekly Digest from Mon, Sep 23, 2019 12:00 AM to Sun, Sep 29, 2019 11:59 PM for ArkEcosystem/exchange-json-rpc.

Issues

Last week there were no issues.

Pull Requests

Last week, 3 pull-requests were opened, closed or merged.

Merged

Last week, 3 pull-requests were merged.

@faustbrian

@supaiku0

Releases

Last week there were no releases.

Contributors

Last week there were 2 contributors.

@faustbrian @supaiku0

Thank you for your contributions! ๐ŸŽ‰

Star Gazers

Last week there were no stargazers.


That's all activities since Mon, Sep 23, 2019 12:00 AM, please Watch and Star the repository ArkEcosystem/exchange-json-rpc to receive upcoming weekly updates.

You can also view all Weekly Digests by clicking here.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.