Services
A service is a typed interface with an implementation:Schema with Services
Some schemas require services.Address.Checksummed needs KeccakService:
Available Services
| Service | Live Implementation | Purpose |
|---|---|---|
KeccakService | KeccakLive | Keccak256 hashing |
Secp256k1Service | Secp256k1Live | ECDSA signing |
ProviderService | Provider | JSON-RPC calls |
SignerService | Signer | Transaction signing |
TransportService | HttpTransport | HTTP/WS transport |
Composing Layers
Stack multiple services withLayer.merge:
Testing
Swap implementations for tests:Per-Request Configuration
FiberRef-based helpers provide scoped overrides without changing services:Why Services?
Tree-shaking - Crypto not imported until provided. If you never use checksums,KeccakLive is not in your bundle.
Testability - Swap ProviderLive for ProviderTest without changing code.
Explicit dependencies - Type signature shows exactly what a program needs.
No globals - No hidden singletons or ambient imports.

