- Solana
- Mainnet Beta
- Testnet
- Devnet
- Eclipse
- Mainnet Beta
- Testnet
- Devnet2
Install via your favorite package manager:
npm install @arrangedev/detect-cluster
Additionally, you can load the source code via unpkg:
https://unpkg.com/@joeymeere/dreamcast@latest
import { getClusterName } from "@arrangedev/detect-cluster";
const cluster = await getClusterName("https://api.mainnet-beta.solana.com");
console.log(cluster); // solana/mainnet-beta