Headers
-
Idempotency-Key string
Body
-
latitude number(double) Required
-
longitude number(double) Required
-
image_url string(url) Required
Uploaded image that the API will read from and download.
-
supervisor object
-
species object
-
site object Required
-
device_id string
Device ID of the mobile device that took the photo.
-
planted_at string(date-time) Required
Date taken from image metadata, so it's as close to the actual planted date-time as possible.
POST /upload
curl \
-X POST https://hostname/upload \
-H "Authorization: Bearer $ACCESS_TOKEN" \
-H "Content-Type: application/json" \
-H "Idempotency-Key: string" \
-d '{"latitude":51.87351,"longitude":-1.90973,"image_url":"string","supervisor":{"id":"string"},"species":{"id":"string"},"site":{"id":"string"},"device_id":"string","planted_at":"2019-08-24T14:15:22Z"}'
Request example
# Headers
Idempotency-Key: string
# Payload
{
"latitude": 51.87351,
"longitude": -1.90973,
"image_url": "string",
"supervisor": {
"id": "string"
},
"species": {
"id": "string"
},
"site": {
"id": "string"
},
"device_id": "string",
"planted_at": "2019-08-24 14:15:22 UTC"
}