Upload a location photo
Begins an upload in three steps: this call answers the location and an upload_url; PUT the bytes there; then call POST /knowledge/locations/{location_id}/photo/complete. A location has one photo: uploading another replaces it when the upload completes, and until then the current one stays.
Scope: knowledge:write.
bearerAuthAuthorizationBearer <token>An organization API key, rky_live_…, created in Settings → API. Send it only from a server.
location_id*stringLocation ID.
uuidIdempotency-Key?stringOptional. A value you choose, unique per logical write, 8–200 characters: a UUID or an ID from your system such as order-10482-ready. Retrying with the same key and body replays the first response instead of repeating the write.
8 <= length <= 200application/json- body
Begins an upload. Ricky answers where to PUT the bytes.
mime_type*stringFile type: JPEG or PNG, up to 5 MB.
"image/jpeg""image/png"size_bytes*integerExact size of the file you will upload.
1 <= value <= 9007199254740991Success.
application/json- response
data*A location, with its current photo, and where to put the bytes of the next one.
curl -X POST 'https://getricky.ai/api/v1/knowledge/locations/497f6eca-6276-4993-bfeb-53cbbbba6f08/photo' \ -H 'Idempotency-Key: order-10482-ready' \ -H 'Content-Type: application/json' \ -d '{ "mime_type": "image/jpeg", "size_bytes": 482133}'{ "data": { "location": { "id": "c3d4e5f6-a7b8-4c9d-8e0f-1a2b3c4d5e6f", "name": "Casa Nativa Albrook", "address": "Albrook Mall, local 214, Panamá", "latitude": 8.9733, "longitude": -79.5511, "street": "Albrook Mall, local 214", "city": "Panamá", "state": "Panamá", "postal_code": null, "country": "Panamá", "country_code": "PA", "phone": "+50760000000", "email": "albrook@example.com", "hours": "Lunes a sábado, 10:00 a 20:00", "photo": { "mime_type": "image/jpeg", "size_bytes": 482133, "download_url": null } }, "upload_url": "https://storage.example.com/upload/sign/media/d9e0f1a2-b3c4-4d5e-8f6a-7b8c9d0e1f2a/knowledge/locations/c3d4e5f6-a7b8-4c9d-8e0f-1a2b3c4d5e6f/f1a2b3c4-d5e6-4f7a-8b9c-0d1e2f3a4b5c.jpg?token=…" }}Delete a location DELETE
Deletes it for good and answers it as it was. Scope: `knowledge:write`.
Remove a location photo DELETE
Removes the photo and any upload in progress, and answers the location. Copies already sent in conversations stay there. A location without a photo stays as it is. Scope: `knowledge:write`.