REST API / Collections
search_rankings
CollectionLarge: filter on indexed fields
Captured search rankings with project-scoped indexed filtering.
- Max rows per query
- 100
- Default order
- id asc
- Required filter
- one of project_id, id
- Max offset
- 2000
- Cursor paging
- by id
Use read report_* for dashboard headline metrics and anchored comparison windows.
Fields
| Field | Type | Description | Filter | Sort |
|---|---|---|---|---|
id indexed | string | Unique row ID. | ✓ | ✓ |
project_id indexed | string | Project ID from projects. | ✓ | – |
query indexed | string | Tracked query. | ✓ | ✓ |
engine | string | Search engine. | – | – |
marketnullable | string | Locale or market. | – | – |
devicenullable | string | Device class. | – | – |
url | string | Ranking URL. | – | – |
domain | string | Ranking domain. | – | – |
position | integer | One-based ranking position. | – | – |
ownership | string | Domain ownership.OWNED COMPETITOR THIRD_PARTY | – | – |
competitor_namenullable | string | Competitor name. | – | – |
serp_features | string[] | Observed search features. | – | – |
captured_at indexed | datetime | Capture time. | ✓ | ✓ |
opportunity_scorenullable indexed | number | Opportunity score. | ✓ | ✓ |
starred indexed | boolean | Whether starred. | ✓ | ✓ |
seen_atnullable indexed | datetime | When last marked seen. | ✓ | ✓ |
archived_atnullable indexed | datetime | When archived. | ✓ | ✓ |
Examples
Example
SELECT id, project_id, query, engine, market
FROM search_rankings
WHERE project_id = $1
ORDER BY id ASC
LIMIT 25Calling it
MCP
Tool call
query({"sql":"SELECT id, project_id, query, engine, market FROM search_rankings WHERE project_id = $1 ORDER BY id ASC LIMIT 25","params":["<value 1>"]})REST
curl
curl -X POST "https://app.sensorhub.ai/api/v1/query" \
-H "Authorization: Bearer $API_KEY" \
-H "Content-Type: application/json" \
--data-binary @- <<'JSON'
{
"sql": "SELECT id, project_id, query, engine, market FROM search_rankings WHERE project_id = $1 ORDER BY id ASC LIMIT 25",
"params": [
"<value 1>"
]
}
JSONRow JSON Schema
json
{
"type": "object",
"description": "Captured search rankings with project-scoped indexed filtering.",
"properties": {
"id": {
"type": "string",
"description": "Unique row ID.",
"x-sensorhub-indexed": true,
"x-sensorhub-searchable": false,
"x-sensorhub-aggregatable": true,
"x-sensorhub-filterable": true,
"x-sensorhub-sortable": true
},
"project_id": {
"type": "string",
"description": "Project ID from projects.",
"x-sensorhub-indexed": true,
"x-sensorhub-searchable": false,
"x-sensorhub-aggregatable": true,
"x-sensorhub-filterable": true,
"x-sensorhub-sortable": false
},
"query": {
"type": "string",
"description": "Tracked query.",
"x-sensorhub-indexed": true,
"x-sensorhub-searchable": false,
"x-sensorhub-aggregatable": true,
"x-sensorhub-filterable": true,
"x-sensorhub-sortable": true
},
"engine": {
"type": "string",
"description": "Search engine.",
"x-sensorhub-indexed": false,
"x-sensorhub-searchable": false,
"x-sensorhub-aggregatable": true,
"x-sensorhub-filterable": false,
"x-sensorhub-sortable": false
},
"market": {
"type": [
"string",
"null"
],
"description": "Locale or market.",
"x-sensorhub-indexed": false,
"x-sensorhub-searchable": false,
"x-sensorhub-aggregatable": true,
"x-sensorhub-filterable": false,
"x-sensorhub-sortable": false
},
"device": {
"type": [
"string",
"null"
],
"description": "Device class.",
"x-sensorhub-indexed": false,
"x-sensorhub-searchable": false,
"x-sensorhub-aggregatable": true,
"x-sensorhub-filterable": false,
"x-sensorhub-sortable": false
},
"url": {
"type": "string",
"description": "Ranking URL.",
"x-sensorhub-indexed": false,
"x-sensorhub-searchable": false,
"x-sensorhub-aggregatable": true,
"x-sensorhub-filterable": false,
"x-sensorhub-sortable": false
},
"domain": {
"type": "string",
"description": "Ranking domain.",
"x-sensorhub-indexed": false,
"x-sensorhub-searchable": false,
"x-sensorhub-aggregatable": true,
"x-sensorhub-filterable": false,
"x-sensorhub-sortable": false
},
"position": {
"type": "integer",
"description": "One-based ranking position.",
"x-sensorhub-indexed": false,
"x-sensorhub-searchable": false,
"x-sensorhub-aggregatable": true,
"x-sensorhub-filterable": false,
"x-sensorhub-sortable": false
},
"ownership": {
"type": "string",
"description": "Domain ownership.",
"enum": [
"OWNED",
"COMPETITOR",
"THIRD_PARTY"
],
"x-sensorhub-filter-operators": [],
"x-sensorhub-indexed": false,
"x-sensorhub-searchable": false,
"x-sensorhub-aggregatable": true,
"x-sensorhub-filterable": false,
"x-sensorhub-sortable": false
},
"competitor_name": {
"type": [
"string",
"null"
],
"description": "Competitor name.",
"x-sensorhub-indexed": false,
"x-sensorhub-searchable": false,
"x-sensorhub-aggregatable": true,
"x-sensorhub-filterable": false,
"x-sensorhub-sortable": false
},
"serp_features": {
"type": "array",
"description": "Observed search features.",
"items": {
"type": "string"
},
"x-sensorhub-indexed": false,
"x-sensorhub-searchable": false,
"x-sensorhub-aggregatable": false,
"x-sensorhub-filterable": false,
"x-sensorhub-sortable": false
},
"captured_at": {
"type": "string",
"description": "Capture time.",
"format": "date-time",
"x-sensorhub-indexed": true,
"x-sensorhub-searchable": false,
"x-sensorhub-aggregatable": true,
"x-sensorhub-filterable": true,
"x-sensorhub-sortable": true
},
"opportunity_score": {
"type": [
"number",
"null"
],
"description": "Opportunity score.",
"x-sensorhub-indexed": true,
"x-sensorhub-searchable": false,
"x-sensorhub-aggregatable": true,
"x-sensorhub-filterable": true,
"x-sensorhub-sortable": true
},
"starred": {
"type": "boolean",
"description": "Whether starred.",
"x-sensorhub-indexed": true,
"x-sensorhub-searchable": false,
"x-sensorhub-aggregatable": true,
"x-sensorhub-filterable": true,
"x-sensorhub-sortable": true
},
"seen_at": {
"type": [
"string",
"null"
],
"description": "When last marked seen.",
"format": "date-time",
"x-sensorhub-indexed": true,
"x-sensorhub-searchable": false,
"x-sensorhub-aggregatable": true,
"x-sensorhub-filterable": true,
"x-sensorhub-sortable": true
},
"archived_at": {
"type": [
"string",
"null"
],
"description": "When archived.",
"format": "date-time",
"x-sensorhub-indexed": true,
"x-sensorhub-searchable": false,
"x-sensorhub-aggregatable": true,
"x-sensorhub-filterable": true,
"x-sensorhub-sortable": true
}
},
"additionalProperties": false
}