POST/api/v4/locations/cancel_archive

Cancel scheduled location archival

Cancels a pending archival for locations in ARCHIVE_SCHEDULED status, restoring them to active.

Requires an API key. See Authentication for header format and key rotation.

Parameters

Body

NameTypeRequiredDescription
input.locationIdsarray of stringsrequiredBase64-encoded location node IDs whose scheduled archival should be cancelled.
input.clientMutationIdstringoptionalOptional idempotency/echo token returned unchanged in the response.

Sample request

Ready-to-paste body. Replace placeholder IDs and values with yours.

{
  "input": {
    "locationIds": [
      "TG9jYXRpb246MTgwMDI4OQ=="
    ]
  }
}

Responses

200Archival cancelled. Locations return to ACTIVE status.
{
  "data": {
    "cancelLocationsArchive": {
      "clientMutationId": null,
      "bulkEditTaskId": null,
      "errors": null,
      "success": null,
      "result": [
        {
          "locationId": "TG9jYXRpb246MTgwMDI4OQ==",
          "status": "ACTIVE",
          "success": true,
          "errors": null
        }
      ]
    }
  }
}
400Bad request — invalid or empty `locationIds`.
401Unauthenticated — missing or invalid API key.
404Location not found or not in ARCHIVE_SCHEDULED status.

Cancels the scheduled archival for locations currently in ARCHIVE_SCHEDULED — the state set by archive locations before the billing cycle closes. Only locations still awaiting archival (not yet fully archived) can be cancelled. Once cancelled, the location returns to ACTIVE and billing continues normally.

Use case — reverse an accidental or reversed decision. A store slated for closure gets a reprieve before the invoice runs. Submit its base64 ID here to pull it out of the archival queue; the response result[] confirms each location is back to ACTIVE. Because it is batch-oriented, you can cancel several scheduled archivals in a single call and read per-location success flags.

Gotcha — timing and eligibility. This only works while the location is still ARCHIVE_SCHEDULED. After the billing cycle closes the location is fully archived and this call returns 404 for it — use the activate/reactivate flow to restore an already-archived location instead.

curl -X POST 'https://listingsapi.com/api/v4/locations/cancel_archive' \
  -H "Authorization: API $LISTINGSAPI_KEY" \
  -H 'Content-Type: application/json' \
  -d '{
    "input.locationIds": "<input.locationIds>",
    "input.clientMutationId": "<input.clientMutationId>"
  }'