Get harvest production sessions with per-worker breakdown
curl --request GET \
--url https://api.hydrobit.ag/api/control/harvest \
--header 'Authorization: Bearer <token>'import requests
url = "https://api.hydrobit.ag/api/control/harvest"
headers = {"Authorization": "Bearer <token>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {Authorization: 'Bearer <token>'}};
fetch('https://api.hydrobit.ag/api/control/harvest', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://api.hydrobit.ag/api/control/harvest",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "https://api.hydrobit.ag/api/control/harvest"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("Authorization", "Bearer <token>")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.get("https://api.hydrobit.ag/api/control/harvest")
.header("Authorization", "Bearer <token>")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.hydrobit.ag/api/control/harvest")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
request["Authorization"] = 'Bearer <token>'
response = http.request(request)
puts response.read_body{
"status": "success",
"data": [
{
"sessionId": "665f1a2b3c4d5e6f7a8b9c0d",
"localId": "62159da9-9a81-4085-bcd1-fff452689abf",
"projectId": "proj_123",
"sectorId": "sector_001",
"sector_name": "Lote A-1",
"crop": "Blueberry",
"variety": "Biloxi",
"day": "2026-06-10T00:00:00.000Z",
"openedAt": "2026-06-10T14:29:48.675Z",
"closedAt": "2026-06-10T21:31:40.718Z",
"createdAt": "2026-06-10T14:29:52.134Z",
"status": "closed",
"closedBy": "user",
"closedReason": "manual",
"timezone": "America/Mexico_City",
"unit": "box",
"maxDurationHours": 16,
"harvestUnitId": "harvest_unit_123",
"harvestLotCode": "HL-20260610-C299128B",
"workerCount": 12,
"notes": "Initial harvest notes",
"finalNotes": "Closed manually after final count",
"license_plate": "ABC-123",
"driver_name": "Juan Perez",
"totalUnits": 320,
"needsRecalc": false,
"qualityBreakdownAt": "2026-06-10T21:33:10.284Z",
"responsible": {
"auth0Id": "auth0|697797d7095fa22599ac90bb",
"name": "Maria Lopez",
"email": "maria@example.com",
"role": "supervisor",
"picture": "https://example.com/avatar.jpg"
},
"qualityBreakdown": [
{
"qualityId": "Q1",
"qualityName": "Primera",
"units": 240,
"percent": 75
}
],
"workers": [
{
"workerId": "W1",
"worker_name": "Juan Perez",
"validUnits": 120,
"netUnits": 110,
"recordCount": 42,
"voidedCount": 3,
"qualityBreakdown": [
{
"qualityId": "Q1",
"qualityName": "Primera",
"validUnits": 90,
"recordCount": 30
}
]
}
]
}
],
"meta": {
"sessionCount": 1,
"startTime": "2026-06-01",
"endTime": "2026-06-15"
}
}{
"error": "Internal server error",
"message": "Detailed error message"
}{
"error": "Internal server error",
"message": "Detailed error message"
}{
"error": "Internal server error",
"message": "Detailed error message"
}{
"error": "Internal server error",
"message": "Detailed error message"
}{
"error": "Internal server error",
"message": "Detailed error message"
}Harvest
Get harvest production sessions with per-worker breakdown
Retrieves production sessions within a date range, each enriched with aggregated production records per worker and per quality.
Requires API token authentication with the read:production scope:
Authorization: Bearer <keyId>.<token>.
The companyId is always taken from the authenticated token. Optional
projectId and sectorId filters are validated against that token’s
company before data is returned.
GET
/
api
/
control
/
harvest
Get harvest production sessions with per-worker breakdown
curl --request GET \
--url https://api.hydrobit.ag/api/control/harvest \
--header 'Authorization: Bearer <token>'import requests
url = "https://api.hydrobit.ag/api/control/harvest"
headers = {"Authorization": "Bearer <token>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {Authorization: 'Bearer <token>'}};
fetch('https://api.hydrobit.ag/api/control/harvest', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://api.hydrobit.ag/api/control/harvest",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "https://api.hydrobit.ag/api/control/harvest"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("Authorization", "Bearer <token>")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.get("https://api.hydrobit.ag/api/control/harvest")
.header("Authorization", "Bearer <token>")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.hydrobit.ag/api/control/harvest")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
request["Authorization"] = 'Bearer <token>'
response = http.request(request)
puts response.read_body{
"status": "success",
"data": [
{
"sessionId": "665f1a2b3c4d5e6f7a8b9c0d",
"localId": "62159da9-9a81-4085-bcd1-fff452689abf",
"projectId": "proj_123",
"sectorId": "sector_001",
"sector_name": "Lote A-1",
"crop": "Blueberry",
"variety": "Biloxi",
"day": "2026-06-10T00:00:00.000Z",
"openedAt": "2026-06-10T14:29:48.675Z",
"closedAt": "2026-06-10T21:31:40.718Z",
"createdAt": "2026-06-10T14:29:52.134Z",
"status": "closed",
"closedBy": "user",
"closedReason": "manual",
"timezone": "America/Mexico_City",
"unit": "box",
"maxDurationHours": 16,
"harvestUnitId": "harvest_unit_123",
"harvestLotCode": "HL-20260610-C299128B",
"workerCount": 12,
"notes": "Initial harvest notes",
"finalNotes": "Closed manually after final count",
"license_plate": "ABC-123",
"driver_name": "Juan Perez",
"totalUnits": 320,
"needsRecalc": false,
"qualityBreakdownAt": "2026-06-10T21:33:10.284Z",
"responsible": {
"auth0Id": "auth0|697797d7095fa22599ac90bb",
"name": "Maria Lopez",
"email": "maria@example.com",
"role": "supervisor",
"picture": "https://example.com/avatar.jpg"
},
"qualityBreakdown": [
{
"qualityId": "Q1",
"qualityName": "Primera",
"units": 240,
"percent": 75
}
],
"workers": [
{
"workerId": "W1",
"worker_name": "Juan Perez",
"validUnits": 120,
"netUnits": 110,
"recordCount": 42,
"voidedCount": 3,
"qualityBreakdown": [
{
"qualityId": "Q1",
"qualityName": "Primera",
"validUnits": 90,
"recordCount": 30
}
]
}
]
}
],
"meta": {
"sessionCount": 1,
"startTime": "2026-06-01",
"endTime": "2026-06-15"
}
}{
"error": "Internal server error",
"message": "Detailed error message"
}{
"error": "Internal server error",
"message": "Detailed error message"
}{
"error": "Internal server error",
"message": "Detailed error message"
}{
"error": "Internal server error",
"message": "Detailed error message"
}{
"error": "Internal server error",
"message": "Detailed error message"
}Authorizations
Scoped API token for external B2B endpoints. Send it in the
Authorization header as Bearer <keyId>.<token>.
Query Parameters
Start date in YYYY-MM-DD format.
Pattern:
^\d{4}-\d{2}-\d{2}$End date in YYYY-MM-DD format.
Pattern:
^\d{4}-\d{2}-\d{2}$Optional project filter. Must belong to the token's company.
Optional sector filter. Must belong to the token's company.
⌘I