Polling Data Export
Overview
In Woflow, data exports are processed asynchronously due to the potentially extensive nature of the data. While users can rely on a callback_url
to receive updates, another method to monitor the status of a data export is by polling. This approach involves sending periodic requests to check the progress of the export until completion.
Polling for Data Export
To check the status of a data export, make a request to the appropriate endpoint:
curl --location 'https://gateway.woflow.com/v1/data_exports/<data-export-id>' \
--header 'Content-Type: application/json' \
--header 'Authorization: Token api_key=<api_key>'
Example Response
When you poll the data export status, you'll receive a response like the one below:
{
"id": "a2f71a26-98ae-459c-bda9-45b7878ef9e6",
"state": "initiated",
"callback_url": null,
"delivery_url": null,
"delivery_url": "https://s3.us-west-1.amazonaws.com/data-delivery.woflow.com/e9cc92fb-js45-43af-9f8c-abc5be8a4e3e.json",
"job_type": "new_menu",
"client_mappings": {}
}
The state will indicate the current status of the export, and once completed, the delivery_url provides a link to download the exported data.