Add a callback URL
Include callback_url in an asynchronous job. Use a public HTTPS receiver that your application controls. The notification contains job metadata and links for retrieving content.
{
"source": "universal",
"url": "https://example.com/",
"callback_url": "https://your-app.example/jobs/callback"
}Process the notification
Read the job id and terminal status, record the event, and acknowledge it promptly with a successful HTTP response. Fetch the actual content separately using the API credentials. Keep expensive parsing and storage work outside the notification response path.
Validate incoming events
Treat the callback body as untrusted input. Check its job ID against jobs your application submitted, validate the resource host before sending API credentials to a returned URL, and deduplicate processing by job ID. Keep polling as a recovery path for missed notifications.
Retrieve the result
Find the entry with rel: "results" in _links. Fetch that resource with HTTP Basic authentication. Check storage statuses separately when the job also writes to a bucket.