igneum/docs/build/first-contract.md
igneum-labs cb2b8a2578 Builder programme (8 October 2026): /build, /grants, the Devnet 3 faucet on build-1, docs/build as the source
- site/build.html and site/grants.html rendered by site/build.mjs from docs/build/build.md and docs/build/grants.md (the gate's site-only copy keeps the committed pages, as for /bench); site-relative links in the markdown renderer
- the nav's fourth group, Build (/build, /faucet, /grants), in the partial, the sheet, the footer, the sitemap and tools/ci/site-nav-check.mjs; the faucet leaves the Mine panel
- site/faucet.html is the Devnet 3 faucet: 10 IGN per address per day, 500 a day, chain id 4463, no value, resets without notice; the page posts to https://faucet.igneum.network/api/faucet and shows the balance
- infra/build-server/faucet: faucet.mjs (zero dependencies, signs with site/lib/eth.mjs, limiter self-test known-failed first, 100 IGN cap on the amount), the unit, faucet.sh install/status; live on build-1 behind Caddy since 10:16Z, funded 2,000 IGN by the fleet's funder at 10:01Z; first drip 0x8620e9d8 at 10:17Z
- docs/build: README, first-contract.md with its test script and the PASS line (24 s end to end through the public RPC and faucet, Foundry 1.8.5, Counter deployed at block 27055), rpc.md read from the node (75 methods probed, served and not served), faucet.md, verify-a-block.md, grants.md
- .forgejo/issue_template/grant.md: the grant application template on git.igneum.network

Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
2026-10-08 10:24:07 +00:00

3.4 KiB

Your first contract on Devnet 3, in five minutes

With Foundry. Tested end to end on Devnet 3 from a build box on 8 October 2026; the pass line and the exact output are at the end. Hardhat, ethers and viem work the same way: chain id 4463 and the RPC below.

0. What you need

  • Foundry: curl -L https://foundry.paradigm.xyz | bash && foundryup. About a minute.
  • The RPC. Devnet 3's public endpoint is https://rpc.devnet.igneum.network. A node you run yourself serves http://127.0.0.1:26790.
  • Nothing else. No account, no sign-up.
export RPC=https://rpc.devnet.igneum.network
cast chain-id --rpc-url $RPC          # 4463

1. A key, for the devnet only

cast wallet new

It prints an address and a private key. Keep the key for this walkthrough and nothing else: devnet coins have no value and the chain resets without notice.

export PK=0x...                       # the private key cast printed
export ME=$(cast wallet address $PK)

2. Coins from the faucet

Paste $ME into igneum.network/faucet. It sends 10 IGN and shows the transaction hash. Once per address per day.

cast balance $ME --rpc-url $RPC --ether      # 10.000000000000000000

3. Deploy

Foundry's template is a counter. Initialise it and deploy it as it is.

forge init counter && cd counter
forge create src/Counter.sol:Counter --rpc-url $RPC --private-key $PK --broadcast

Expected:

Deployer: 0x...
Deployed to: 0x...
Transaction hash: 0x...
export C=0x...                        # the Deployed to address

4. Call it

cast send $C "increment()" --rpc-url $RPC --private-key $PK
cast call $C "number()(uint256)" --rpc-url $RPC      # 1
cast send $C "setNumber(uint256)" 41 --rpc-url $RPC --private-key $PK
cast call $C "number()(uint256)" --rpc-url $RPC      # 41

cast send waits for the receipt. A block takes about a second.

5. See it

Paste the transaction hash into igneum.network/explorer. The receipt is also one call away:

cast receipt 0xTXHASH --rpc-url $RPC

What is different under the hood

  • Gas has two dimensions, execution and proving. The node folds the second into the price it quotes, so forge and cast estimate and pay as on Ethereum. igneum_estimateGas shows both numbers and whether a call exceeds the proving limit.
  • Your transaction is in a block within about a second, proven tens of seconds later, and locked by miner signatures in about two minutes. igneum_getTransactionStatus reports each stage.
  • A transaction signed for another chain id is refused. EIP-155, EIP-1559 and legacy envelopes are accepted.

The test record

Run on a build box against its own Devnet 3 node (the box that also fronts the public RPC and runs the faucet), with Foundry 1.8.5 and a fresh key, through docs/build/first-contract-test.sh. The pass line is appended below by the run.

PASS 10:17:23Z: Devnet 3 chain id 4463, faucet drip 0x8620e9d894484e824e4ac33002946a00e2f75823ea6db0da0ad29f1af142e8f2, deployed Counter at 0x6345265C6Db0b3713eb6645d795d0B52FE0a4201 (tx 0xcf77b4822d51f3c60ecdf6d7dbbe67524d42071f06c76e1cf9b0511d64783574), increment then setNumber(41) read back 41, receipt status 1 (success), block 27055, 24 s end to end, Foundry 1.8.5

Through the public endpoints, https://rpc.devnet.igneum.network and https://faucet.igneum.network, from the box: the first faucet drip and the first reader-path deploy on Devnet 3.