Using Callback URLs with Asynchronous Jobs
Overview
The EON Platform supports asynchronous jobs for long-running tasks that operate outside the typical request-response cycle. These include actions such as generating item or label batches, performing bulk updates, or exporting large datasets. To notify your system when these jobs are complete, you can provide one or more callback_urls in the job request. Once the job finishes, the platform will POST a JSON payload to the specified URL(s).
How It Works
- Submit an async job request (e.g., batch generation, bulk update, export).
- Include a callback_urls parameter with one or more URLs.
- Once the job completes, EON will send a POST request with a JSON payload to each callback URL.
- The payload includes job metadata and a link to the results, when applicable.
Example Payloads
✅ Generating Item Batches Callback Payload
{
"status": "Success",
"batch_id": "50d32318-1517-48b4-a024-297511293513",
"results_url": "https://app.eongroup.co/api/v2/items/?batch_id=50d32318-1517-48b4-a024-297511293513",
"tags": ["PO-123456789", "Custom-Tag-1"]
}
🏷️ Generating Label Batches Callback Payload
{
"quantity": 10000,
"tags": ["PO-987654321"],
"batch_tag_name": "batch-50d32318-1517-48b4-a024-297511293513",
"batch_uuid": "50d32318-1517-48b4-a024-297511293513"
}
🛠️ Bulk Updating Items Callback Payload
{
"tags": ["tag1", "tag2"],
"items_updated": 5000,
"override_data": {
"color_name": "Crimson"
}
}
Notes
Callback requests are sent as POST with Content-Type: application/json. You are responsible for securing and handling incoming requests at your callback endpoints. If a callback fails (e.g., 4xx or 5xx), retries may be attempted, but delivery is not guaranteed.