Skip to main content

Dev Network

This article will describe how to debug local applications by connecting to the PlatON DevNet(development Network).

ChainId: 2206132

openapi:

https://devnet2openapi.platon.network/rpc or wss://devnet2openapi.platon.network/ws

faucet:

https://devnet2faucet.platon.network/faucet

explorer:

https://devnet2scan.platon.network

How to access the dev network to debug local applications?#

Step 1: Connect to the DevNet via RPC address#

https://devnet2openapi.platon.network/rpc or wss://devnet2openapi.platon.network/ws

Access method 1: Connect to the DevNet via the local PlatON node#

on the ubuntu 18.04 server, download and install the PlatON binary with the following command:

sudo wget https://download.platon.network/platon/platon/1.4.2/platon -P /usr/bin    

Connect to the development network by.

platon attach https://devnet2openapi.platon.network/rpc

Access method 2: Connect to the PlatON DevNet through the SDKs#

  • Use the Java SDK to connect to the DevNet, for example, as follows.
Web3j platonWeb3j = Web3j.build(new HttpService("https://devnet2openapi.platon.network/rpc"));
  • Use Python SDK to access the DevNet, the example is as follows.
w3 = Web3(HTTPProvider("https://devnet2openapi.platon.network/rpc"))
  • Use JS SDK to access the DevNet, the example is as follows.
var Web3 = require('web3');var web3 = new Web3('http://https://devnet2openapi.platon.network/rpc');
  • Using JSON RPC to access the DevNet, the example is as follows.
curl -X POST -H 'content-type: application/json' --data '{"jsonrpc": "2.0", "method": "web3_clientVersion", "params":[], "id":67}' https://devnet2openapi.platon.network/rpc

Not limited to the above language SDKs, you also have access through SDKs in other languages.

Step 2: Apply for DevNet Test Token#

Click faucet to receive the Test Token. If you have a large Test Token request, please send an email to support@latticex.foundation using the following format.

 Title: PlatON Development Network Token Request Your Name: Contact information: Wechart ID (or other instant messaging software) Amount: Use: Receiving addressA: Remarks:

After successfully accessing the DevNet, you can send transactions after completing the test Token collection to start your test journey and can check the transactions in DevNet Browser.

How to deploy a devnet node?#

If you want to deploy a DevNet verification node, please refer to Run a dev node.