Shred Delivery and Sender are now live! Get earliest access to raw Solana data and optimized transaction sending. Learn about Shred Delivery | Learn about Sender
简体中文
高性能 Solana RPC 基础设施,响应时间快 95%。完整指南涵盖 RPC 方法、优化和最佳实践。
前往仪表板
创建计划
前往端点部分
复制您的端点
import { Connection } from '@solana/web3.js'; // Your Helius RPC URL from dashboard const rpcUrl = 'YOUR_HELIUS_RPC_URL'; const connection = new Connection(rpcUrl); // Test the connection const testConnection = async () => { try { const version = await connection.getVersion(); const slot = await connection.getSlot(); console.log('Connection successful!'); console.log(`Solana version: ${version['solana-core']}`); console.log(`Current slot: ${slot}`); } catch (error) { console.error('Connection failed:', error); } }; testConnection();
此页面对您有帮助吗?