Check Sync Status
Monitor the synchronization status of a cookie update task
https://api.lobstr.io/v1/synchronize/{sync_task_id}This endpoint checks the synchronization status of a cookie update task using its hash ID. Use this to monitor whether your account cookies have been successfully synchronized.
Headers
AuthorizationstringheaderrequiredYour API authentication token. Value: Token YOUR_API_KEY
Path Parameters
sync_task_idstringpathrequiredThe synchronization task ID returned from Sync Account or Refresh Cookies. Example: 75bed0d425c4bc1912a17fe9fc4dd2a1
Response Field Explanations
idstringSynchronization task identifier. Example: "75bed0d425c4bc1912a17fe9fc4dd2a1"
objectstringAlways "synchronize-cookies". Example: "synchronize-cookies"
status_codeintegerTask status code (100=created, 120=synchronizing, 200=synchronized). Example: 200
status_textstringHuman-readable status. Example: "synchronized"
account_hashstringHash of the created/updated account. Example: "84efd37ebd21c0f232826b7763b403d3"
Poll this endpoint every few seconds after initiating a sync until status_code reaches 200 (synchronized) or an error state.
Once status_code is 200, use the returned account_hash to access the synchronized account with Get Account Details.
If synchronization remains at status_code 120 for more than 30 seconds, the cookies may be invalid. Try re-syncing with fresh cookies.
Code Examples
curl -X GET "https://api.lobstr.io/v1/synchronize/75bed0d425c4bc1912a17fe9fc4dd2a1" \ -H "Authorization: Token YOUR_API_KEY"
Response
{ "id": "75bed0d425c4bc1912a17fe9fc4dd2a1", "object": "synchronize-cookies", "status_code": 120, "status_text": "synchronizing", "account_hash": "84efd37ebd21c0f232826b7763b403d3" }
{ "id": "75bed0d425c4bc1912a17fe9fc4dd2a1", "object": "synchronize-cookies", "status_code": 200, "status_text": "synchronized", "account_hash": "84efd37ebd21c0f232826b7763b403d3" }
{ "detail": "Synchronization task not found." }