Natural-language queries against Hubble Solana blockchain data, paid per call via x402 on Base.
What it does
This x402-enabled endpoint lets callers query Hubble blockchain data using natural language. It currently supports Solana data and is built on the x402-hono payment gateway framework. You send a plain-English question (e.g. "Find the top 5 tokens by total trading volume in the past 7 days") and receive structured results back as JSON.
The endpoint accepts a POST request with three parameters: a required `question` string (10–500 characters), an optional `source` field (either "FILE" or "SINGLE", defaulting to "FILE"), and an optional `threshold` confidence value between 0 and 1 (default 0.7). The response includes a success boolean, an array of query results, and an ISO 8601 timestamp.
Payment is settled on Base network using USDC (contract 0x8335…2913). The maximum amount required per call is 50,000 base units, which equals $0.05 USD (USDC uses 6 decimals). The service also exposes a second endpoint at `/lego/api/v1/query/similar` for similarity-based queries, though no schema details are available for that route. There is no external documentation site; the service root returns a minimal JSON status page and all non-existent paths return a router listing.
Capabilities
Use cases
- —Querying Solana token trading volumes and rankings using plain English
- —Retrieving on-chain analytics without writing SQL or GraphQL
- —Agent-driven blockchain research with per-call micropayments
- —Finding similar blockchain data points via the /query/similar endpoint
Fit
Best for
- —AI agents that need on-demand Solana blockchain data
- —Developers who want natural-language access to on-chain metrics
- —Micropayment-based pay-per-query blockchain analytics
Not for
- —Querying non-Solana blockchains (only Solana is documented as supported)
- —High-throughput bulk data extraction (per-call payment model, 300s timeout)
- —Users who need detailed documentation or SLA guarantees
Quick start
curl -X POST https://x402.bedev.hubble-rpc.xyz/lego/api/v1/query \
-H "Content-Type: application/json" \
-H "X-PAYMENT: <x402_payment_token>" \
-d '{"question": "Find the top 5 tokens by total trading volume in the past 7 days", "source": "FILE", "threshold": 0.7}'Example
Request
{
"source": "FILE",
"question": "Find the top 5 tokens by total trading volume in the past 7 days",
"threshold": 0.7
}Response
{
"data": [
{
"token": "SOL",
"volume": 1234567890
},
{
"token": "USDC",
"volume": 987654321
}
],
"success": true,
"timestamp": "2025-01-15T12:00:00.000Z"
}Endpoint
Quality
The x402 challenge is live and includes a well-defined outputSchema with input/output specs and examples. However, there is no external documentation, no OpenAPI spec, no usage examples beyond the schema, and the /query/similar endpoint is undocumented. The response example is inferred from the schema rather than observed.
Warnings
- —No external documentation site exists; all non-endpoint paths return 404-style JSON
- —The /lego/api/v1/query/similar endpoint is listed but has no schema or description
- —Response data array structure is unspecified — actual field names are unknown
- —The example response is inferred from the outputSchema, not from a real API call
Citations
- —Endpoint returns 402 with x402 challenge requiring USDC payment on Base networkhttps://x402.bedev.hubble-rpc.xyz/lego/api/v1/query
- —Maximum amount required is 50000 base units of USDC (contract 0x833589fCD6eDb6E08f4c7C32D4f71b54bdA02913), equaling $0.05https://x402.bedev.hubble-rpc.xyz/lego/api/v1/query
- —Service identifies as X402 Payment Gateway (Simplified) v2.0.0 using x402-hono implementationhttps://x402.bedev.hubble-rpc.xyz
- —Two endpoints are available: /lego/api/v1/query and /lego/api/v1/query/similarhttps://x402.bedev.hubble-rpc.xyz/docs