REST API / Collections
prompts
Collection
Tracked AI prompts, their review state, topic folder and visible tags.
- Max rows per query
- 100
- Default order
- id asc
- 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. | ✓ | – |
text | string | Prompt text. | ✓ | ✓ |
category | string | Analytical category.AWARENESS CONSIDERATION COMPARISON BRANDED TROUBLESHOOTING OTHER | ✓ | ✓ |
active | boolean | Whether collection is enabled. | ✓ | ✓ |
source | string | Creation source. | ✓ | ✓ |
review_status | string | Review state.pending accepted rejected | ✓ | ✓ |
tags redacted | string[] | Visible content and custom tag slugs. | – | – |
topic_idnullable | string | Resolved topic folder ID. | – | – |
intentnullable | string | Query intent. | ✓ | ✓ |
brandednullable | boolean | Whether the prompt names the project brand. | ✓ | ✓ |
locale | string | Locale. | ✓ | ✓ |
geo | string | Geographic target. | ✓ | ✓ |
created_at | datetime | Creation time. | ✓ | ✓ |
origin_refnullable Requires Perception | string | Perception source reference. Requires Perception lists. | ✓ | ✓ |
Examples
Example
SELECT id, project_id, text, category, active
FROM prompts
ORDER BY id ASC
LIMIT 25Calling it
MCP
Tool call
query({"sql":"SELECT id, project_id, text, category, active FROM prompts ORDER BY id ASC LIMIT 25"})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, text, category, active FROM prompts ORDER BY id ASC LIMIT 25"
}
JSONRow JSON Schema
json
{
"type": "object",
"description": "Tracked AI prompts, their review state, topic folder and visible tags.",
"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
},
"text": {
"type": "string",
"description": "Prompt text.",
"x-sensorhub-indexed": false,
"x-sensorhub-searchable": false,
"x-sensorhub-aggregatable": true,
"x-sensorhub-filterable": true,
"x-sensorhub-sortable": true
},
"category": {
"type": "string",
"description": "Analytical category.",
"enum": [
"AWARENESS",
"CONSIDERATION",
"COMPARISON",
"BRANDED",
"TROUBLESHOOTING",
"OTHER"
],
"x-sensorhub-filter-operators": [
"=",
"!=",
"<>",
"IN",
"NOT IN",
"IS NULL",
"IS NOT NULL"
],
"x-sensorhub-indexed": false,
"x-sensorhub-searchable": false,
"x-sensorhub-aggregatable": true,
"x-sensorhub-filterable": true,
"x-sensorhub-sortable": true
},
"active": {
"type": "boolean",
"description": "Whether collection is enabled.",
"x-sensorhub-indexed": false,
"x-sensorhub-searchable": false,
"x-sensorhub-aggregatable": true,
"x-sensorhub-filterable": true,
"x-sensorhub-sortable": true
},
"source": {
"type": "string",
"description": "Creation source.",
"x-sensorhub-indexed": false,
"x-sensorhub-searchable": false,
"x-sensorhub-aggregatable": true,
"x-sensorhub-filterable": true,
"x-sensorhub-sortable": true
},
"review_status": {
"type": "string",
"description": "Review state.",
"enum": [
"pending",
"accepted",
"rejected"
],
"x-sensorhub-filter-operators": [
"=",
"!=",
"<>",
"IN",
"NOT IN",
"IS NULL",
"IS NOT NULL"
],
"x-sensorhub-indexed": false,
"x-sensorhub-searchable": false,
"x-sensorhub-aggregatable": true,
"x-sensorhub-filterable": true,
"x-sensorhub-sortable": true
},
"tags": {
"type": "array",
"description": "Visible content and custom tag slugs.",
"items": {
"type": "string"
},
"x-sensorhub-indexed": false,
"x-sensorhub-searchable": false,
"x-sensorhub-aggregatable": false,
"x-sensorhub-filterable": false,
"x-sensorhub-sortable": false
},
"topic_id": {
"type": [
"string",
"null"
],
"description": "Resolved topic folder ID.",
"x-sensorhub-indexed": false,
"x-sensorhub-searchable": false,
"x-sensorhub-aggregatable": false,
"x-sensorhub-filterable": false,
"x-sensorhub-sortable": false
},
"intent": {
"type": [
"string",
"null"
],
"description": "Query intent.",
"x-sensorhub-indexed": false,
"x-sensorhub-searchable": false,
"x-sensorhub-aggregatable": true,
"x-sensorhub-filterable": true,
"x-sensorhub-sortable": true
},
"branded": {
"type": [
"boolean",
"null"
],
"description": "Whether the prompt names the project brand.",
"x-sensorhub-indexed": false,
"x-sensorhub-searchable": false,
"x-sensorhub-aggregatable": true,
"x-sensorhub-filterable": true,
"x-sensorhub-sortable": true
},
"locale": {
"type": "string",
"description": "Locale.",
"x-sensorhub-indexed": false,
"x-sensorhub-searchable": false,
"x-sensorhub-aggregatable": true,
"x-sensorhub-filterable": true,
"x-sensorhub-sortable": true
},
"geo": {
"type": "string",
"description": "Geographic target.",
"x-sensorhub-indexed": false,
"x-sensorhub-searchable": false,
"x-sensorhub-aggregatable": true,
"x-sensorhub-filterable": true,
"x-sensorhub-sortable": true
},
"created_at": {
"type": "string",
"description": "Creation time.",
"format": "date-time",
"x-sensorhub-indexed": false,
"x-sensorhub-searchable": false,
"x-sensorhub-aggregatable": true,
"x-sensorhub-filterable": true,
"x-sensorhub-sortable": true
},
"origin_ref": {
"type": [
"string",
"null"
],
"description": "Perception source reference. Requires Perception lists.",
"x-sensorhub-availability": "Requires Perception",
"x-sensorhub-indexed": false,
"x-sensorhub-searchable": false,
"x-sensorhub-aggregatable": true,
"x-sensorhub-filterable": true,
"x-sensorhub-sortable": true
}
},
"additionalProperties": false
}