Appearance
Migrating from Alchemy
Standard EVM JSON-RPC migrates with a URL swap; Alchemy's proprietary alchemy_*/NFT/webhook APIs need the mapping table below.
The one-line diff
diff
- const RPC_URL = `https://eth-mainnet.g.alchemy.com/v2/${ALCHEMY_KEY}`
+ const RPC_URL = `https://rpc.lab.au.ro/eth?apikey=${YOUR_API_KEY}`| Alchemy | AU.RO |
|---|---|
https://eth-mainnet.g.alchemy.com/v2/KEY | https://rpc.lab.au.ro/eth?apikey=KEY |
https://bnb-mainnet.g.alchemy.com/v2/KEY | https://rpc.lab.au.ro/bsc?apikey=KEY |
https://polygon-mainnet.g.alchemy.com/v2/KEY | https://rpc.lab.au.ro/polygon?apikey=KEY |
https://avax-mainnet.g.alchemy.com/v2/KEY | https://rpc.lab.au.ro/avax?apikey=KEY |
Use the header in production
The ?apikey= form above is the fastest drop-in, but a key in the URL leaks into proxy logs, browser history and Referer headers. For anything but a quick test, pass the key as the apikey header instead — the snippet is in Migrating from Infura.
If you use the alchemy-sdk package, replace it with ethers v6 or viem on our URL for core RPC; the SDK's convenience namespaces map as follows.
Alchemy-specific API mapping
| Alchemy API | Replacement here |
|---|---|
alchemy_getTokenBalances | eth_call multicall against an aggregator contract (e.g. Multicall3) — or loop balanceOf |
alchemy_getAssetTransfers | not available — needs an indexer; keep Alchemy for this or run your own |
NFT API (getNFTs, …) | not available (indexer product) |
| Notify webhooks (address activity) | Webhooks: new_block, address_activity, token_transfer events with HMAC signatures |
eth_subscribe over WSS | not yet — WebSockets roadmap; poll instead |
Semantics to re-check
- Compute units: Alchemy also meters CU but with different weights — re-estimate cost with our table; notable:
eth_getLogsis 75 CU and 1/min here. - Reliability features: Alchemy auto-retries 429s inside its SDK; with plain ethers/viem add the backoff snippet.