Overview
Any sample can be opened directly from a URL. The app reads the crop from the path and the sample from the query string, then fills the Single-sample form and runs the diagnosis automatically.
https://<host>/<crop>?region=<code>&stage=<code>&<nutrient>=<value> … &id=<label>
Parameters
| Location | Parameter | Meaning |
|---|---|---|
| path | <crop> required | Crop slug, e.g. corn. Defaults to corn if the path is empty. |
| query | region required | Any one of: the region number code (e.g. 2), a US state abbreviation (e.g. TX → its DRIS region), or the full region name. |
| query | stage required | Growth-stage letter code (e.g. B). |
| query | nutrient symbols | One per tissue value, e.g. N=3.89, P=0.21. Macros in %, micros in ppm. Include only the ones you have. |
| query | id optional | Free-text customer / field label shown on the report & PDF. |
Backward compatible: older #load={json} links still open correctly.
Live builder
Reference codes
Pulled live from this server, so they always match the current data.
Fetch codes programmatically
Two read-only JSON endpoints expose everything the builder uses:
List crops
GET /api/crops → [ { "slug": "corn", "name": "Corn" }, … ]
Crop bundle (codes live under meta)
GET /api/crops/corn → { "meta": { "labels": ["N","P","K", …], // nutrient symbols "regionCodes": { "South/Delta": "2", … }, // name → region code "stages": ["A","B","C", …], // stage codes "stageDesc": { "B": "V5–V8", … }, // stage code → label "units": { "N": "%", "Zn": "ppm", … } }, … }