services
Sensors
Tools Reference

Sensors Tools Reference

Reference for Sensors REST and MCP: registry tools and sensor-scoped behavior.

Try it out

Registry MCP Tools

Available at POST /api/v1/sensors/registry/mcp (JSON-RPC 2.0).

ToolDescription
list_sensorsList sensors with optional filters: sensor_type, provider, status, data_types, latitude, longitude, radius_km, limit, page. Returns id, external_id, name, sensor_type, status, data_types, provider_slug, feed_id, connected_service.
sensor_connected_servicesResolve which service backs a sensor. Arguments: sensor_id (UUID or external_id) or feed_id.
sensor_cleaned_streamFetch data for a sensor or feed. Arguments: sensor_id or feed_id, optional data_format (cleaned | raw), days, since, until, limit.
sensor_last_readingGet the most recent reading (timestamp, measurements, location). Arguments: sensor_id or feed_id.

Sensor MCP Endpoint

POST /api/v1/sensors/:id/mcp — Run MCP for one sensor (:id must be the sensor UUID). The API looks up the sensor’s feed and connected_service, then forwards the request to that service. Tools exposed are those of the connected service (e.g. NDBC, AirNow).

Context injected when calling tools via this endpoint:

  • sensor_id — sensor UUID
  • sensor_external_id — e.g. NDBC station id
  • sensor_name — display name
  • feed_slug — feed slug when available

Tools can use sensor_external_id from context when arguments like station_id are omitted.

REST Endpoints Summary

  • GET /api/v1/sensors — List sensors (includes data_types filter)
  • GET /api/v1/sensors/types — Sensor types
  • GET /api/v1/sensors/statuses — Statuses
  • GET /api/v1/sensors/registry — Registry list (includes data_types filter)
  • GET /api/v1/sensors/:id — Sensor details (UUID or external_id)
  • GET /api/v1/sensors/:id/readings/latest — Latest reading (data_format: cleaned | raw)
  • GET /api/v1/sensors/:id/readings — Time-series readings (data_format, parameter filter)
  • POST /api/v1/sensors/:id/mcp — Sensor MCP (UUID only)
  • POST /api/v1/sensors/registry/mcp — Registry MCP

Full REST and MCP details: API Reference → Sensors.

Examples

See Sensors Examples for usage examples.