NetworkConfig
Configuration for a Midnight network environment.
URL Conventions:
indexerBaseUrl: Base URL for indexer API (without /graphql suffix)
IndexerClientImpl appends /graphql for HTTP and /graphql/ws for WebSocket
nodeRpcUrl: Full URL for node JSON-RPC endpoint
proofServerUrl: Full URL for proof server (appends /prove-tx internally)
Localhost host resolution (see DeviceType.localhostHost):
Emulator:
10.0.2.2(Android emulator's special host alias)Physical device:
127.0.0.1(requiresadb reverse tcp:<port> tcp:<port>for the indexer/node/proof-server ports). See./gradlew adbReverseLocalnet.
The localnet (UNDEPLOYED) network uses this for all three services. PREPROD and PREVIEW use it only for the local proof server.
Constructors
Properties
If true, allows HTTP connections (for local testing only)
Indexer API base URL
True only for the LOCAL dev chain (localnet / MidnightNetwork.UNDEPLOYED) — the one place a chain RESET is a routine event and wiping the wallet's caches on detection is safe.
The network this configuration is for
Node RPC URL
Proof server URL