Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
21 changes: 14 additions & 7 deletions .env.example
Original file line number Diff line number Diff line change
Expand Up @@ -7,13 +7,20 @@ CIRCLE_WALLET_SET_ID=
CIRCLE_WALLET_ID=
CIRCLE_WALLET_ADDRESS=

# ERC-8004 on Arc Testnet. ArcPay defaults to the official Arc Identity Registry
# below; only set ERC8004_AGENT_ID after ArcPay has actually been registered.
ERC8004_IDENTITY_REGISTRY_ADDRESS=0x8004A818BFB912233c491871b3d84c89A494BD9e
ERC8004_REPUTATION_REGISTRY_ADDRESS=0x8004B663056A597Dffe9eCcC1965A193B7388713
ERC8004_VALIDATION_REGISTRY_ADDRESS=0x8004Cb1BF31DAf7788923b405b754f57acEB4272
# Arc Mainnet public network profile.
# Verify the RPC returns chain ID 5042 before any funded transaction.
NEXT_PUBLIC_ARC_CHAIN_ID=5042
NEXT_PUBLIC_ARC_CHAIN_NAME=Arc Mainnet
NEXT_PUBLIC_ARC_RPC_URL=https://rpc.mainnet.arc.io
NEXT_PUBLIC_ARC_EXPLORER_URL=https://explorer.arc.io
ARC_MAINNET_RPC_URL=https://rpc.mainnet.arc.io

# ERC-8004 addresses below were configured for Arc Testnet.
# Do not reuse them for production until the mainnet registry addresses are verified.
ERC8004_IDENTITY_REGISTRY_ADDRESS=
ERC8004_REPUTATION_REGISTRY_ADDRESS=
ERC8004_VALIDATION_REGISTRY_ADDRESS=
ERC8004_AGENT_ID=

# Server RPC for telemetry and independent payment-proof verification.
# Must return Arc Testnet chain ID 5042002; other chains are rejected.
# Legacy testnet RPC retained only for explicit test/staging use.
ARC_TESTNET_RPC_URL=https://rpc.testnet.arc.network
4 changes: 2 additions & 2 deletions playwright.config.ts
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ export default defineConfig({
projects: [{ name: "chromium", use: { ...devices["Desktop Chrome"] } }],
webServer: [
{ command: "node tests/e2e/rpc-fixture.mjs", url: "http://127.0.0.1:4319", reuseExistingServer: false },
{ command: "npm run start -- --port 4318 --hostname 127.0.0.1", url: "http://127.0.0.1:4318", reuseExistingServer: false, timeout: 120_000,
env: { ARC_TESTNET_RPC_URL: "http://127.0.0.1:4319", CIRCLE_API_KEY: "", CIRCLE_ENTITY_SECRET: "" } },
{ command: "NEXT_PUBLIC_ARC_CHAIN_ID=5042002 NEXT_PUBLIC_ARC_CHAIN_NAME=\"Arc Testnet\" NEXT_PUBLIC_ARC_RPC_URL=http://127.0.0.1:4319 NEXT_PUBLIC_ARC_EXPLORER_URL=https://testnet.arcscan.app npm run build && npm run start -- --port 4318 --hostname 127.0.0.1", url: "http://127.0.0.1:4318", reuseExistingServer: false, timeout: 120_000,
env: { NEXT_PUBLIC_ARC_CHAIN_ID: "5042002", NEXT_PUBLIC_ARC_CHAIN_NAME: "Arc Testnet", NEXT_PUBLIC_ARC_RPC_URL: "http://127.0.0.1:4319", NEXT_PUBLIC_ARC_EXPLORER_URL: "https://testnet.arcscan.app", ARC_TESTNET_RPC_URL: "http://127.0.0.1:4319", CIRCLE_API_KEY: "", CIRCLE_ENTITY_SECRET: "" } },
],
});
8 changes: 4 additions & 4 deletions src/lib/arc-network.ts
Original file line number Diff line number Diff line change
@@ -1,17 +1,17 @@
const configuredChainId = Number(
process.env.NEXT_PUBLIC_ARC_CHAIN_ID ?? "5042002",
process.env.NEXT_PUBLIC_ARC_CHAIN_ID ?? "5042",
);

export const ARC_NETWORK = {
chainId: configuredChainId,
chainIdHex: `0x${configuredChainId.toString(16)}`,
chainName: process.env.NEXT_PUBLIC_ARC_CHAIN_NAME ?? "Arc Testnet",
chainName: process.env.NEXT_PUBLIC_ARC_CHAIN_NAME ?? "Arc Mainnet",
rpcUrl:
process.env.NEXT_PUBLIC_ARC_RPC_URL ??
"https://rpc.testnet.arc.network",
"https://rpc.mainnet.arc.io",
explorerUrl:
process.env.NEXT_PUBLIC_ARC_EXPLORER_URL ??
"https://testnet.arcscan.app",
"https://explorer.arc.io",
nativeCurrency: {
name: "USDC",
symbol: "USDC",
Expand Down
Loading