Skip to content

aerenetwork/aere-examples

Repository files navigation

AERE Network examples

Small, honest, runnable examples for the AERE Network L1 (chain ID 2800). Every example talks to the public RPC and the live mainnet contracts. Wherever possible the examples are read-only, so they run with no funds and no private key. Where a step genuinely needs funds, the README says so explicitly and the code stops at the last read-only step.

Nothing here invents contract behavior. Every call is built from the real ABIs of the deployed AERE contracts.

Network parameters

Chain name AERE Network
Chain ID 2800 (0xAF0)
HTTP RPC https://rpc.aere.network
WebSocket RPC wss://wss.aere.network
Explorer https://explorer.aere.network
Native token AERE (18 decimals)

Examples

Folder What it shows Runs without funds?
read-onchain-proof Fetch bytecode and read live constants from the Falcon-512 verifier and the modular account factory. Yes, fully read-only
verify-pqc-signature Verify an official NIST Falcon-512 KAT vector against the live on-chain verifier via eth_call. Yes, fully read-only
session-key-wallet Build a modular smart account, register a scoped session key, and sign a session userOp (dry run). Yes for the dry run; sending needs a funded account
aere402-agent-payment Pay a provider per request over HTTP-402 through the facilitator. Handshake is free; settle needs a funded, registered agent

Contracts these examples touch

Contract Address
AereFalcon512Verifier 0x4E8e9682329e646784fB3bd01430aA4bA54D8fFC
AereModularAccountFactory 0xE3f45Ed4a81f982fF25ad172A72456a1833a440E
AereSessionKeyValidator 0x6e03A3D7A4c90d6f8dD6F0BA1F6e8aB1F8990D26
AereEntryPointV2 0x8D6f40598d552fF0Cb358b6012cF4227B86aF770
AereAgentV2 0x3FAcb997eb4252341052e7c84a86fCa0513c4490
AERE402FacilitatorV2 0xFC2f7FAa94919caF1126b3c995F0F6AcCef291de
WAERE 0x7e84d7d66d5da4cfE46Da67CDEeB05B323e1f5e8

All addresses are public mainnet deployments; verify any of them on the explorer. They are also collected in addresses.js, which every example imports so you can repoint them at a fork or a local node in one place.

Requirements

  • Node.js 18 or newer (for global fetch and ESM).
  • npm install at the repo root installs ethers v6 (and express for the HTTP-402 provider example).

Quick start

git clone <this-repo-url> aere-examples
cd aere-examples
npm install

# fully read-only, no key needed:
node read-onchain-proof/read-onchain-proof.js
node verify-pqc-signature/verify-pqc-signature.js
node session-key-wallet/session-key-wallet.js

The official SDK

These examples use ethers v6 directly against public addresses so they stay dependency-light and easy to read. In a real app you would usually reach for the official @aere/sdk package, which wraps the same contracts with typed clients and ships createAere402Middleware for the HTTP-402 flow.

Honesty notes

  • Read-only examples make only eth_getCode and eth_call requests.
  • The Falcon-512 verifier is real on-chain lattice cryptography (SHAKE256 HashToPoint, 14-bit public-key decode, negacyclic NTT multiply mod q = 12289, l2-norm bound). It is Falcon-512 (NIST security level 1), not Falcon-1024.
  • Session-key sending and HTTP-402 settlement are the only paths that spend gas; both READMEs list exactly what must be funded first.

License

MIT. See LICENSE.

About

Runnable examples for building on AERE Network: session-key wallet, AERE402 agent payments, lending client, on-chain proof verification.

Topics

Resources

License

Stars

0 stars

Watchers

0 watching

Forks

Packages

 
 
 

Contributors