This page is available in English.

This page is available in 日本語.

PolySwarm Hive

What is Hive

PolySwarm Hive is a set of (currently invite-only) testnets that facilitate the development of Microengines, Ambassadors, and Arbiters.

How to Apply

Hive is (currently) operated on invite-only basis. Reach out to us on Twitter, join our Discord or otherwise hunt us down for an invite :)

Connecting to Hive

Once you’re approved for access to Hive, you will be provided with:

  1. hive.apikey: An API key that will provide you with access to 1 or more Hive testnets
  2. wallet.json: An Ethereum wallet JSON associated with this API key. This wallet will contain testnet Nectar tokens to play around with.

Hive Testnets

polyswarmd is hosted for you in the Hive environment.

Friendly Name polyswarmd Endpoint
Production https://gamma-polyswarmd.prod.polyswarm.network
Staging https://gamma-polyswarmd.stage.polyswarm.network

Connecting with polyswarm-client

We’ll connect an EICAR-detecting Microengine (discussed in Tutorial 0) to the PolySwarm Hive Staging testnet.

Grab a copy of polyswarm-client:

git clone https://github.com/polyswarm/polyswarm-client

Copy your provisioned wallet.json into the project:

cp wallet.json polyswarm-client/docker/
pushd polyswarm-client
docker build -t polyswarm/polyswarm-client:tutorial -f docker/Dockerfile .

Run our EICAR-detecting Microengine, hooked into Hive:

docker run polyswarm/polyswarm-client:tutorial \
    microengine \
    --api-key "<YOUR API KEY HERE>" \
    --keyfile "docker/wallet.json" \
    --password "password" \
    --polyswarmd-addr "gamma-polyswarmd.stage.polyswarm.network" \
    --backend "eicar"

That’s it!

Using with Custom Client

If you’re building a custom client, please ensure that all API requests to Hive hosted polyswarmd instances must contain your API key in the headers:

Authorization: [API KEY]

Furthermore, please ensure that the wallet utilized by your custom client matches the API key sent in all API calls.

For more details on the polyswarmd API, please refer to our API specification polyswarmd API Documentation.