Download OpenAPI specification:
Every number on the internet, queryable. Instant access to millions of trusted statistics through a single natural language query or API call.
Submit a natural-language request and get back a curated time series response. The response also includes the generated SQL so you can switch to the SQL endpoint for faster/cheaper repeated queries.
curl "https://api.qoery.com/v0/query/nl" \ -H "X-API-Key: your-api-key" \ -H "Content-Type: application/json" \ -d '{"query": "population of France"}'
{- "sql_query": "string",
- "series": [
- {
- "ts": "2019-08-24T14:15:22Z",
- "value": "string",
- "entity_name": "string",
- "entity_id": "string",
- "metric_name": "string",
- "metric_id": "string",
- "unit_name": "string",
- "unit_id": "string",
- "frequency": "string",
- "series_description": "string",
- "labels": { },
- "source": "string",
- "series_id": "string"
}
], - "metadata": { },
- "description": "string"
}
Execute a read-only SELECT query and receive the results as curated time series. The response includes the executed SQL query and optional metadata.
curl "https://api.qoery.com/v0/query/sql" \ -H "X-API-Key: your-api-key" \ -H "Content-Type: application/json" \ -d '{"query": "SELECT * FROM series LIMIT 10"}'
{- "series": [
- {
- "ts": "2019-08-24T14:15:22Z",
- "value": "string",
- "entity_name": "string",
- "entity_id": "string",
- "metric_name": "string",
- "metric_id": "string",
- "unit_name": "string",
- "unit_id": "string",
- "frequency": "string",
- "series_description": "string",
- "labels": { },
- "source": "string",
- "series_id": "string"
}
], - "sql_query": "string",
- "metadata": {
- "result_count": 0
}
}
Download a web page, and structured data as time series. Use query params html=true
and/or markdown=true
to include raw artifacts inline; otherwise artifact URLs are provided in artifacts
.
html | boolean Default: false Include page HTML inline in response |
markdown | boolean Default: false Include page markdown inline in response |
curl "https://api.qoery.com/v0/scrape" \ -H "X-API-Key: your-api-key" \ -H "Content-Type: application/json" \ -d '{"url": "https://example.com/statistics"}'
{- "series": [
- {
- "ts": "2019-08-24T14:15:22Z",
- "value": "string",
- "entity_name": "string",
- "entity_id": "string",
- "metric_name": "string",
- "metric_id": "string",
- "unit_name": "string",
- "unit_id": "string",
- "frequency": "string",
- "series_description": "string",
- "labels": { },
- "source": "string",
- "series_id": "string"
}
], - "artifacts": {
- "html_url": "string",
- "markdown_url": "string",
- "tables_base_url": "string"
}, - "cached": true,
- "source_id": "string",
- "metadata": {
- "result_count": 0
}, - "html": "string",
- "markdown": "string"
}
Get current usage and rate limit information per endpoint
uid required | string <uuid> User ID (UUID) |
curl "https://api.qoery.com/v0/usage?uid=your-user-id" \ -H "X-API-Key: your-api-key"
{- "period_start": "2019-08-24T14:15:22Z",
- "period_end": "2019-08-24T14:15:22Z",
- "plan": "string",
- "endpoints": {
- "nl": {
- "calls_used": 0,
- "calls_limit": "string",
- "tokens_in": 0,
- "tokens_out": 0,
- "errors": 0,
- "remaining": 0
}, - "sql": {
- "calls_used": 0,
- "calls_limit": "string",
- "tokens_in": 0,
- "tokens_out": 0,
- "errors": 0,
- "remaining": 0
}, - "scrape": {
- "calls_used": 0,
- "calls_limit": "string",
- "tokens_in": 0,
- "tokens_out": 0,
- "errors": 0,
- "remaining": 0
}
}
}