Farm Picture
One property in full — the call that lists every paddock and every mob before a drench is recorded — whether it belongs to the signed-in user or to a business: its name and labels, the point the map opens on, area_ha, the live paddock_count / mob_count, its outline and its blocks, plus every paddock and every mob on it.
boundary — on the property and on each paddock — is an array of closed rings of [longitude, latitude] pairs, longitude first, never a GeoJSON object, or null while that outline has not been drawn. A paddock also carries block_id (its block, null in the home block), land use, crop, archive state and diary counters. A mob carries head_count, archive state, diary counters and current_paddock_id. Archived assets are included; paddock_count and mob_count stay live-only.
With Accept: application/vnd.api+json the assets are in included. With Accept: application/json they are inlined as paddocks and mobs on the farm. What is filed on one of those assets is listAssetResources. Any accepted member of the owning business can read; a personal property is readable by its owner alone; and so is anyone the property is shared with (visibility public, or link with the share token). Credentials are optional; a caller with none who may not see it is told 404.
Request
- Base URL: https://api.purplegrain.com/api/v1
- URL: https://api.purplegrain.com/api/v1/farms/{id}/picture
- Auth: one of:
- none
- HTTP bearer
Path parameters
Id of the property
Query parameters
Comma-separated snake_case relationship paths to embed (JSON:API included array, or inlined for application/json). Never embedded by default; unknown paths ignored; max 10 paths. Allowed paths: organization.
Response
The property with its paddocks and mobs. JSON:API puts them in included; the attributes adapter inlines paddocks and mobs.
Example response
{
"data": {
"type": "farm",
"blocks": [
{
"name": "Racecourse block",
"hull": {
"type": "Polygon"
}
}
]
}
}Changes
No recorded changes to this operation across all 1 revision of this API.