Skip to content
Peer Discovery Implementation in TypeScript.
Branch: master
Clone or download
Latest commit e4168b3 Jun 10, 2019
Permalink
Type Name Latest commit message Commit time
Failed to load latest commit information.
.circleci first commit Jun 10, 2019
__tests__
src
.editorconfig first commit Jun 10, 2019
.gitignore
.prettierignore first commit Jun 10, 2019
.prettierrc.json first commit Jun 10, 2019
CHANGELOG.md
CODEOWNERS first commit Jun 10, 2019
LICENSE first commit Jun 10, 2019
README.md first commit Jun 10, 2019
banner.png first commit Jun 10, 2019
package.json first commit Jun 10, 2019
tsconfig.json first commit Jun 10, 2019
tslint.json first commit Jun 10, 2019
yarn.lock first commit Jun 10, 2019

README.md

@arkecosystem/peers

Latest Version Node Engine Build Status Codecov License: MIT

Installation

yarn global add @arkecosystem/peers

Usage

Peers via GitHub

import { PeerDiscovery } from "@arkecosystem/peers";

await PeerDiscovery.new("devnet")
	.withVersion(">=2.4.0-next.0")
	.withLatency(300)
	.sortBy("latency")
	.findPeersWithPlugin("core-api");

Peers via Relay

import { PeerDiscovery } from "@arkecosystem/peers";

await PeerDiscovery.new("http://dexplorer.ark.io/api/v2/peers")
	.withVersion(">=2.4.0-next.0")
	.withLatency(300)
	.sortBy("latency")
	.findPeersWithPlugin("core-api");

Testing

yarn test

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

This project exists thanks to all the people who contribute.

License

MIT © ARK Ecosystem

You can’t perform that action at this time.