LogoLogo
Visit Site
  • WELCOME
    • What is POKT?
    • $POKT Token
      • Bridging
        • Wrapped POKT (wPOKT)
          • Wrapping Walkthrough
          • Wrapping and Unwrapping FAQ
          • LP Staking Walkthrough
          • Liquidity Provider Staking FAQ
      • POKT Rewards
        • Stake POKT
      • Holding POKT
        • NodeWallet
        • Pocket Wallet
        • Ledger
  • WHO WE ARE
    • POKT Overview
  • POKT Protocol
    • Our evolution
    • The Morse Protocol
      • The Economics
    • The Shannon Upgrade
      • Technical Overview
        • Launch Roadmap
        • Morse -> Shannon Migration
          • PIP Migration
          • Other Migration
          • Expected Gaps
          • Future Features
        • Secondary DA Networks
      • Shannon Actors
        • Sovereign Applications
        • Gateways
        • Suppliers
        • Sources
      • Proposed Tokenomics
        • Token Logic Modules
        • Gaming Prevention
        • Aligned Incentives
        • Tokenomics Resources
      • Jump in to Shannon Today
  • Developers
    • Access RPC
    • Use a Gateway
      • Nodies
      • Grove
    • Use a Public Endpoint
  • Node Operators
    • Operate a Node
    • Manual Node Setup Guide
      • Part 1 - Server Setup
      • Part 2 - Software Installation
      • Part 3 - Pocket Configuration
      • Part 4 - Proxy Configuration
      • Part 5 - Going Live
  • Gateways
    • Host a Gateway
      • Gateway Server
      • Quick Onboarding Guide
      • Node Selection
      • API Endpoints
      • Relay Process
  • Community
    • DAO (OS)
    • Start Contributing
      • Bounties
      • Quick Grants
      • RFPs
      • Maintainers
      • How to Use Karma GAP
    • Governance
      • Earn Your Vote
      • Node Runners
      • App Developers
      • Community Shepherds
      • Contributors
      • CREDS - Governance Upgrade
        • Privacy & anonymity
        • Onboarding New Voters
        • Migration of Existing Voters
        • System Flow Design
    • Retro POKT Goods Funding
      • Timeline
      • Eligibility Criteria
      • Rules of Conduct
      • Voters & Voting
      • Voting Rubric
      • Support & FAQ
      • What is Retro POKT Goods funding Round 1?
    • Community Calls + Events
    • POKT Events Playbook
      • Hosting Your Event
        • Event Type
          • Small Events
          • Mid-sized Events
          • Large Events
      • Event Agenda
      • Speaker
      • Venue
      • Applying for Funding
      • Your Responsibilities as a Host
      • Resources
        • Email Templates
        • Social Media Templates
        • Survey Questions Template
  • Reference
    • Supported Chains
    • API Definition
Powered by GitBook
On this page
  • 1. Preparing the Application Stakes
  • 2. Create Encryption Password
  • 3. Configure Global Configuration Variables
  • 4. Run Migration Script
  • 5. Insert App Stake Private Keys
  • 6. Compile and Run Gateway Server
  • 7. Setup Chain Configuration and Altruist
  1. Gateways
  2. Host a Gateway

Quick Onboarding Guide

PreviousGateway ServerNextNode Selection

Last updated 1 year ago

1. Preparing the Application Stakes

Application stakes provides Gateway Operators access to the POKT Network for sending traffic.

Testnet Instructions
  1. Generate 5 accounts (wallets) through the

  2. Distribute POKT to all the wallets generated through the

  3. Stake each account into the network as an application stake with the chain id `0007` (a test chain that represents ETH Network).

  4. You can use the to simplify the process if you don't have access to the Pocket Core Executable or not familiar with the CLI commands.

Staking application stakes too complicated for you? No worries, we prestaked some shared applications stakes into POKT Testnet to help you get onboarded quicker.

Please do not submit stake transactions to avoid disruption for other gateway operator testers as the applications are already staked on your behalf in the correct chain. All applications are staked into chain 0007 with 10M POKT.

Testnet Application Private Keys:

  • 1d06f04dcf5199a7f93f625d4fa507c2e0aca2f94fa3ebc2022c5e589406a9133d7ec4fef2ef676b340ce1df6ec5d0264ce1f40fae7fe9e07c415fa06fc1ffd6

  • 2d0f9aab4396662db2a27d3388a1602e8081a49cb159471fdf4ef8aad4f9d120a1183ac69c10bf7f5df942b687b50a206fb1c54c66687c04c7710daed5f1e7a3

  • 1e33f2948223e6655d4e10f462ad48203e18e81865098f4c15153ba4027f2fa4822fbcb6a0f485b9c61d1e84e976cb75214edc3e388b733e3ca4d5b80671cb4f

  • 0bcdf221fb73f54a4acf4e61008a80c62ad155500846d99fd9cd190b46a9cf22157e1212fad906ac98bbf5a6b6ae50910ebd83e3fe789d3e4bd7f711abcd4ed1

  • 20bf258e9e9632a9c627bfd328be87e0ecd6f14eeb7c7dc2382048c3063d3c08ec25b1aad594814f2a046cd2e89579992ecbba0951fec2d0f4b6ef1ba16fa8b9

Mainnet Instructions

Application stakes in Morse are permissioned, therefore you must receive application stakes through the Pocket Network Foundation. If you are an authorized gateway operator, the Foundation will assist you in receiving the application stakes private keys.

2. Create Encryption Password

Create an encryption password for your app stake keys. This password will be used to encrypt/decrypt your app-stake private keys stored in a Postgres database. It can be any combination of plaintext, symbols, letters, etc.

3. Configure Global Configuration Variables

Fill out the .env variables for the gateway server. This can be done by injecting environment variables directly or using a .env file.

Env Variables Description

Variable Name
Description
Example Value

POKT_RPC_FULL_HOST

Used for dispatching sessions

https://pokt-testnet-rpc.nodies.org (a complimentary testnet dispatcher URL provided by Nodies)

HTTP_SERVER_PORT

Gateway server port

8080

POKT_RPC_TIMEOUT

Max response time for a POKT node to respond

10s

ALTRUIST_REQUEST_TIMEOUT

Max response time for an altruist backup to respond

10s

ENVIRONMENT_STAGE

Log verbosity

development, production

SESSION_CACHE_TTL

Duration for sessions to stay in cache

75m

POKT_APPLICATIONS_ENCRYPTION_KEY

User-generated encryption key

a1b2c3d4e5f6g7h8i9j0k1l2m3n4o5p6

DB_CONNECTION_URL

PostgreSQL Database connection URL

postgres://user:password@localhost:5432/postgres

4. Run Migration Script

Run the migration script to seed your PostgreSQL database.

./scripts/migration.sh -u

5. Insert App Stake Private Keys

Copy and paste the following SQL query to insert app stake private keys into the database:

INSERT INTO pokt_applications (encrypted_private_key) VALUES (pgp_sym_encrypt('{private_key}', '{encryption_key}'));

Note: Replace {private_key} and {encryption_key} in the SQL query with your actual private key and encryption key.

6. Compile and Run Gateway Server

go build cmd/gateway_server/main.go

7. Setup Chain Configuration and Altruist

Remember to keep sensitive information secure and follow best practices for handling private keys and passwords.

Here is an that you can use a reference

Copy and paste the following code to compile and run the gateway server. Hit the endpoint with a JSON-RPC payload.

If using testnet, send a request to chain 0007, . This testnet chain id represents Ethereum Node Operators and Nodies is currently supporting the chain id for reliable testing.

Alternatively, you can leverage our published

Upon startup of the gateway server, nodes within a session take time to be marked as healthy (~10 seconds), therefore the requests will be routed to the altruist (failover) node. It is suggested each chain that you support has a configured altruist. You can learn more about supplying altruist configurations through this.

testnet wallet URL
testnet faucet
application stake script
.env.sample
http://localhost/relay/{chain_id}
http://localhost/relay/0007
docker images
Altruist Chain Configuration guide