Hub
HUMAN Website
  • HUMAN Protocol Document Hub
  • HUMAN Tech Docs
    • Architecture
      • Components
        • Smart Contracts
          • Escrow.sol
          • EscrowFactory.sol
          • Contract Addresses
        • Dashboard
        • Job Launcher
          • Standard
          • HUMAN Job Launcher
        • Exchange Oracle
          • Standard
        • Recording Oracle
          • Standard
        • Reputation Oracle
          • Standard
          • HUMAN Reputation Oracle
        • HUMAN App
        • Annotation Tools
          • CVAT
          • hCaptcha
          • Fortune (test)
      • Protocol Features
        • Routing Protocol
        • Abuse System
        • Qualifications System
        • Governance
    • SDK
    • Tutorials
      • Job Requesters
        • Signup
        • Launch Jobs
          • Fortune
      • Workers
        • Sign Up
        • KYC Verification
        • Wallet address registration
      • Operators
        • Sign Up
      • HMToken
        • Bridge
          • Ethereum <--> Polygon
          • Ethereum <--> Binance Smart Chain
    • Developer
      • Prerequisites
      • Initial setup
      • Run web3 in Docker
      • Run services in Docker
      • Setting up Oracles
      • Running HUMAN Protocol with CVAT
        • Running CVAT
        • Setting up Worker user
        • Launch simple CVAT job
      • FAQ
  • Routing Protocol Tokenomics
    • Status
    • Premise
    • Token design
    • Proposition for a governance minimization model
    • Liquidity provision /market making
    • Alternate Conviction voting model
    • Voting model
    • The HUMAN-RP Magistrate
    • Voting process
    • Security
    • Policies
    • Slashing and Soft-freezing
    • Staking for tool vendors
  • Grants Program
    • Introduction and Program Overview
    • Application Process
      • Application Process of the HUMAN Grants Program
    • Funded Projects
    • Community
    • Help & FAQs
    • Terms and condition
  • Guide to the HUMAN Protocol SDK's
Powered by GitBook
LogoLogo

© 2023 HPF. HUMAN Protocol® is a registered trademark

On this page

Was this helpful?

  1. HUMAN Tech Docs
  2. Developer

FAQ

Here you can find answers on frequently asked question, some hints and "how-tos" that might help you deal with common routines.

PreviousLaunch simple CVAT jobNextRouting Protocol Tokenomics

Last updated 9 days ago

Was this helpful?

How can I get some HMT tokens in testnet?

You can use Faucet:

How to generate ES256 key pair?

In order to generate ES256 key pair you first need to generate private key:

openssl ecparam -name prime256v1 -genkey -noout -out jwt-private.pem

You can choose any path and name instead of jwt-private.pem . When you have private key - you can use it to generate public key:

openssl ec -in jwt-private.pem -pubout -out jwt-public.pem
How to generate PGP key pair?

In order to generate PGP keys you can use gpg wizard:

gpg --full-generate-key

When going through the process:

  • choose RSA and RSA or ECC (recommended) key type to be able to encrypt/decrypt messages

  • choose 0 expiration (key does not expire) so there will be no need to rotate keys

  • remember/write your passphrase somewhere, because you will need it

Once you have your keys generated, export them to text files:

To export public key
gpg --export --armor [email protected] > public_key.asc
To export private key
gpg --export-secret-keys --armor [email protected] > private_key.asc
How can I pass captcha verification for API calls on local environment?

For local/developer environment . You can find a response token that corresponds to environment sitekey and use it in API requests.

How to clear the DNS cache on my PC?

MacOS:

sudo killall -HUP mDNSResponder

Linux:

sudo systemctl restart systemd-resolved

Windows:

ipconfig /flushdns
How can I pass KYC for workers w/o setting up KYC provider?

In order to synthetically pass KYC you will need to connect to Reputation Oracle database and insert an item like on example below to kycs table:

{
  "id": <user-id-to-approve-kyc>, // unique kyc record id
  "created_at": "YYYY-MM-DD HH:MM:SS.000000 +00:00",
  "updated_at": "YYYY-MM-DD HH:MM:SS.000000 +00:00",
  "session_id": <kyc-sesion-id>, // unique
  "status": "approved",
  "message": null,
  "user_id": <user-id-to-approve-kyc>,
  "country": null,
  "url": <kyc-verification-url> // unique
}

In case you are already logged in you will need to re-login or refresh your token in order to get updated KYC status

How can I set up KV Store values for oracle?

You can use this sample Node.js script to set up oracle's KV Store:

/* eslint-disable no-console */
import { ChainId, KVStoreClient, KVStoreKeys, KVStoreUtils, Role } from '@human-protocol/sdk';
import { Wallet, JsonRpcProvider } from 'ethers';

const rpcUrl = 'https://rpc-amoy.polygon.technology';
const chainId = ChainId.POLYGON_AMOY;
const address = 'oracle_address';
const privateKey = 'oracle_private_key';

async function setupOracleKV() {
  const provider = new JsonRpcProvider(rpcUrl);
  const signer = new Wallet(privateKey, provider);
  const kvStoreClient = await KVStoreClient.build(signer);

  // Pick oracle role from pre-defined values
  const role = Role.ExchangeOracle;
  // Fee percentage: valid integer from 0
  const fee = 1;
  // Full Oracle URL
  const url = 'http://exchange-oracle:5000';
  // Webhook url as per standard
  const webhookUrl = `${url}/webhook`;
  // Job types supported by oracle
  const jobTypes = 'image_points,image_boxes,image_boxes_from_points,image_skeletons_from_boxes,image_polygons';

  await kvStoreClient.setBulk(
    [
      KVStoreKeys.role,
      KVStoreKeys.fee,
      KVStoreKeys.url,
      KVStoreKeys.webhookUrl,
      KVStoreKeys.jobTypes,
    ],
    [
      role,
      `${fee}`,
      url,
      webhookUrl,
      jobTypes,
    ],
  );

  // Publicly accessible url where PGP public key is stored
  const pgpPublicKeyUrl = 'http://minio:9000/exchange-oracle/pgp-public-key';
  await kvStoreClient.setFileUrlAndHash(
    pgpPublicKeyUrl,
    KVStoreKeys.publicKey
  );

  /**
   * These keys are valid only for Exchange Oracle
   * in case it requires extra registration step
   */
  await kvStoreClient.setBulk([
    KVStoreKeys.registrationNeeded,
    KVStoreKeys.registrationInstructions,
  ], [
    'true',
    'http://how-to-register.url'
  ]);

  const result = await KVStoreUtils.getKVStoreData(
    chainId,
    address
  );
  console.log('Oracle KV:', result);
}

(async () => {
  try {
    await setupOracleKV();
    process.exit(0);
  } catch (error) {
    console.log('Failed to set up oracle KV', error);
    process.exit(1);
  }
})();

or write a similar on Python using Python SDK

What are the default hardhat local node accounts?
Account #0: 0xf39Fd6e51aad88F6F4ce6aB8827279cffFb92266
Private Key: 0xac0974bec39a17e36ba4a6b4d238ff944bacb478cbed5efcae784d7bf4f2ff80

Account #1: 0x70997970C51812dc3A010C7d01b50e0d17dc79C8
Private Key: 0x59c6995e998f97a5a0044966f0945389dc9e86dae88c7a8412f4603b6b78690d

Account #2: 0x3C44CdDdB6a900fa2b585dd299e03d12FA4293BC
Private Key: 0x5de4111afa1a4b94908f83103eb1f1706367c2e68ca870fc3fb9a804cdab365a

Account #3: 0x90F79bf6EB2c4f870365E785982E1f101E93b906
Private Key: 0x7c852118294e51e653712a81e05800f419141751be58f605c371e15141b007a6

Account #4: 0x15d34AAf54267DB7D7c367839AAf71A00a2C6A65
Private Key: 0x47e179ec197488593b187f80a00eb0da91f1b9d0b13f8733639f19c30a34926a

Account #5: 0x9965507D1a55bcC2695C58ba16FB37d819B0A4dc
Private Key: 0x8b3a350cf5c34c9194ca85829a2df0ec3153be0318b5e2d3348e872092edffba

Account #6: 0x976EA74026E726554dB657fA54763abd0C3a0aa9
Private Key: 0x92db14e403b83dfe3df233f83dfa3a0d7096f21ca9b0d6d6b8d88b2b4ec1564e

Account #7: 0x14dC79964da2C08b23698B3D3cc7Ca32193d9955
Private Key: 0x4bbbf85ce3377467afe5d46f804f221813b2bb87f24d81f60f1fcdbf7cbf4356

Account #8: 0x23618e81E3f5cdF7f54C3d65f7FBc0aBf5B21E8f
Private Key: 0xdbda1821b80551c9d65939329250298aa3472ba22feea921c0cf5d620ea67b97

Account #9: 0xa0Ee7A142d267C1f36714E4a8F75612F20a79720
Private Key: 0x2a871d0798f97d79848a013d4936a73bf4cc922c825d33c1cf7073dff6d409c6

Account #10: 0xBcd4042DE499D14e55001CcbB24a551F3b954096
Private Key: 0xf214f2b2cd398c806f84e317254e0f0b801d0643303237d97a22a48e01628897

Account #11: 0x71bE63f3384f5fb98995898A86B02Fb2426c5788
Private Key: 0x701b615bbdfb9de65240bc28bd21bbc0d996645a3dd57e7b12bc2bdf6f192c82

Account #12: 0xFABB0ac9d68B0B445fB7357272Ff202C5651694a
Private Key: 0xa267530f49f8280200edf313ee7af6b827f2a8bce2897751d06a843f644967b1

Account #13: 0x1CBd3b2770909D4e10f157cABC84C7264073C9Ec
Private Key: 0x47c99abed3324a2707c28affff1267e45918ec8c3f20b8aa892e8b065d2942dd

Account #14: 0xdF3e18d64BC6A983f673Ab319CCaE4f1a57C7097
Private Key: 0xc526ee95bf44d8fc405a158bb884d9d1238d99f0612e9f33d006bb0789009aaa

Account #15: 0xcd3B766CCDd6AE721141F452C550Ca635964ce71
Private Key: 0x8166f546bab6da521a8369cab06c5d2b9e46670292d85c875ee9ec20e84ffb61

Account #16: 0x2546BcD3c84621e976D8185a91A922aE77ECEc30
Private Key: 0xea6c44ac03bff858b476bba40716402b03e41b8e97e276d1baec7c37d42484a0

Account #17: 0xbDA5747bFD65F08deb54cb465eB87D40e51B197E
Private Key: 0x689af8efa8c651a91ad287602527f3af2fe9f6501a7ac4b061667b5a93e037fd

Account #18: 0xdD2FD4581271e230360230F9337D5c0430Bf44C0
Private Key: 0xde9be858da4a475276426320d5e9262ecfc3ba460bfac56360bfa6c4c28b4ee0

Account #19: 0x8626f6940E2eb28930eFb4CeF49B2d1F2C9C1199
Private Key: 0xdf57089febbacf7ba0bc227dafbffa9fc08a93fdc68e1e42411a14efcf23656e
https://faucet.humanprotocol.org
hCaptcha test keys are used