createReadOnly() is the no-signing, no-submission mode.
- no private key
- no signer
- no transaction building
- all read methods available
When to use it
- price widgets
- charts and dashboards
- analytics tools
- account views that display positions, orders, fills, or candles
Example
user and an Alchemy key:
INVALID_CONFIG in this mode.
Parameters
All fields are optional.| Field | Type | Default | Notes |
|---|---|---|---|
rpcUrl | string | public RPC | Arbitrum RPC URL for reads/simulation. |
testnet | boolean | false | Use Arbitrum Sepolia. |
subgraphUrl | string | mainnet/testnet subgraph | Override the subgraph endpoint. |
builderApiUrl | string | https://builder.ostium.io | Override the builder API base URL. |
alchemyApiKey | string | — | Required only to start streamAccountUpdates(). |
slippageBps or builder. See Client Configuration for the full reference.