Register Consolidated EUDR Batch Async | AgriBackup
Create a new EUDR batch linked to verified polygon IDs. Returns 202 Accepted with a jobId. Triggers Copernicus satellite risk assessment automatically.
202 Accepted immediately with a jobId. Poll GET /api/v1/enterprise/eudr/jobs/{jobId} or listen for the batch.risk_assessed webhook to retrieve the final consolidatedRiskState.
Request Headers
| Header | Required | Description |
|---|---|---|
X-API-Key | ✅ | Your live API key, e.g. sk_live_.... |
Idempotency-Key | ✅ | A UUID v4 string. Replaying the same key within 24 hours returns the original job response without creating a duplicate batch. |
X-Sub-Organization-ID | ☐ | Optional subsidiary identifier to scope the batch to a specific business unit. |
Request Body
| Field | Type | Required | Description |
|---|---|---|---|
commodity | string | ✅ | EUDR commodity type, e.g. COFFEE, COCOA, SOYA. |
countryCode | string | ✅ | ISO 3-letter country code of origin (e.g. KEN for Kenya, BRA for Brazil). |
hsCode | string | ✅ | 6-digit Harmonised System (HS) code for the commodity, e.g. 090111. |
quantityKg | number | ✅ | Total commodity quantity in kilograms. |
polygonIds | array of strings | ✅ | Array of verified polygon IDs to include in this batch (max 5,000). All polygon IDs must have eudrStatus: COMPLIANT. |
vendorIds | array of strings | ☐ | Optional list of ERP vendor IDs to link this batch to your Tier-1 supply chain mapping. |
Response — 202 Accepted
| Field | Type | Description |
|---|---|---|
jobId | string | Use this ID to poll job status via GET /api/v1/enterprise/eudr/jobs/{jobId}. |
status | string | Always PENDING on acceptance. |
estimatedDurationSec | integer | Estimated seconds until risk assessment completes. |
createdAt | string (ISO-8601) | Timestamp when the job was accepted. |
Location header pointing to the job status endpoint.
Async Completion — batch.risk_assessed Webhook
When the Copernicus risk assessment finishes, AgriBackup fires a batch.risk_assessed event to your registered webhook URL. The event payload is signed with X-AgriBackup-Signature (HMAC-SHA256). Once the batch has a consolidatedRiskState of COMPLIANT, it is ready to be linked to a logistics shipment.
Code Examples
Authorizations
Enterprise API Key provided via the AgriBackup developer console.
Headers
Unique idempotency key (UUID) to prevent duplicate operations. Safely stored in Redis with a strict 24-hour TTL to prevent memory bloat during saturation attacks.
Optional identifier to partition compliance data (polygons, batches, declarations) for a specific subsidiary or regional business unit within the conglomerate.
Body
Payload for registering a new consolidated batch
EUDR Commodity type or name
"COFFEE"
ISO 3-letter country code of origin (e.g., KEN for Kenya, BRA for Brazil)
"KEN"
HS Code (mandatory for dynamic validation)
"090111"
Total quantity in kilograms
5000.5
Array of verified Polygon IDs forming this batch
5000Array of verified Polygon IDs forming this batch
Optional list of ERP Vendor IDs to explicitly map this batch to the Tier-1 Enterprise Supply Chain
Optional list of ERP Vendor IDs to explicitly map this batch to the Tier-1 Enterprise Supply Chain
Response
Batch registered and risk assessment queued
Response payload for asynchronously accepted jobs
The unique asynchronous tracking job ID
"job_998877"
Current execution status invariant
PENDING "PENDING"
Estimated duration in seconds before consensus or processing lock release
3
Timestamp when the job was accepted
"2026-06-15T12:00:00Z"