import { NextResponse } from 'next/server'
import { getRpcStatus } from '../../../lib/rpc-failover.js'

export async function GET() {
  try {
    const status = getRpcStatus()
    return NextResponse.json(status)
  } catch (error) {
    console.error('❌ RPC Status error:', error)
    return NextResponse.json({
      success: false,
      error: 'Failed to get RPC status',
      details: error.message
    }, { status: 500 })
  }
}
