Meta Fields
API reference
GET /v1/meta/fields
Self-discovery: field + preset catalog with ETag-based caching.
GET
Meta Fields
When to use this
Hit/v1/meta/fields once at startup to discover the catalog. The
response sets ETag and Cache-Control: public, max-age=3600, so a
long-lived agent or service fetches it once an hour at most. The catalog
drives:
- Client-side validation — reject unknown field names before sending
a
/v1/fetchrequest. - Tool descriptions — agents that build their own UI from the catalog populate field pickers and preset selectors from this endpoint.
- LLM planners — third-party agents that route to Mireye via the MCP
server can render the catalog into their own planner system prompt,
same as Mireye’s
/v1/askdoes internally.
Response shape
Self-discovery flow
The recommended client pattern:If-None-Match returns 304 Not Modified with no body when the catalog
hasn’t changed. The ETag covers the whole payload, so any catalog
change — new fields, edited hints, preset changes — produces a fresh
ETag alongside the version bump (see the versioning
policy).
Each field object also carries honesty metadata: nullable marks fields
that can legitimately return null at valid coordinates, and
null_meaning says what such a null means (e.g. “no wetland within the
search radius”) so clients don’t misread semantic absence as a fetch
failure.
How the catalog drives the planner
Mireye’s own/v1/ask planner renders the catalog into its system
prompt:
Versioning
Theversion field is a manual SemVer bump maintained alongside the
catalog source (src/mireye_earth/ask/catalog.py, which carries the
version history as a changelog comment):
- Patch (e.g.,
0.6.0→0.6.1) — wording-only changes:descriptionorinterpretation_hintsimproved, no field added or changed. Safe to ignore for existing clients. - Minor (
0.5.x→0.6.0) — additive, backwards-compatible changes: new fields or new presets registered. Existing field names, types, and semantics are untouched. (This is the common case — the catalog moved0.2.0→0.6.0through additive field registrations.) - Major (
0.x.y→1.0.0) — breaking: field renamed, type changed, or removed. Clients hardcoding field names must be updated.
Response
200 - application/json
Successful Response