Documentation · Admin Reference

Import And Limits Reference

This document is a reference for the Import & Limits screen of the ADP Car Market Hub plugin (Car Market Hub → Import & Limits). It covers the trigger method, automatic schedule, manual import wizard, server cron setup, image processing limits, import defaults and the Full Sync danger zone option.

When to use this document

Use this reference when you are setting up automatic imports for the first time, switching between WordPress Cron and a real server cron job, tuning import performance for large inventories, or enabling Full Sync to remove vehicles that were taken offline.

Overview

The screen is organized into the following cards:

  1. Current Import Status — a dynamic summary sentence stating whether automatic imports are active (via Server Cron or WP Cron) or disabled, plus four KPI tiles: Imported Vehicles, Configured Sellers, Pending Images and Last Run Errors. A Show IDs / Hide IDs toggle reveals the configured seller IDs inline.
  2. Last Run + Manual Import — last import metrics and a guided wizard to start an import on demand.
  3. Automation Settings — choose the trigger method (WordPress Cron or Server Cron) and configure the schedule.
  4. Server Cron Setup — visible only in Server Cron mode; provides the REST trigger URL, the secret token, and example cron commands.
  5. Image Processing and Stability — limits per run and image-queue toggle to avoid PHP timeouts.
  6. Import Defaults — defaults applied to newly imported vehicles, including images and WebP conversion.
  7. Re-listing detection — recognises vehicles that were deleted and re-listed under a new AutoScout24 listing ID (same VIN) to prevent duplicates, keep the public URL stable, and track a price history.
  8. Danger Zone — Full Sync toggle, plus the soft-delete / grace-period option that controls how removed vehicles are handled.

Requirements or prerequisites

  • Working API credentials and at least one Seller ID configured in Settings.
  • For Server Cron mode: the ability to add cron jobs on your hosting environment, plus the ability to call WordPress REST URLs from the server.
  • For Full Sync: a recent backup is strongly recommended.

Step by step instructions

Run a manual import

  1. Open Car Market Hub → Import & Limits.
  2. In the Last Run / Manual Import card click Start Import Now.
  3. The wizard area appears, showing a status message, progress bar, ETA, and a counts table for inserted, updated, skipped, errors and full-sync deleted.
  4. Use Pause, Continue or Cancel as needed. If a paused queue is detected on a later visit, a Resume button is shown.

Switch to WordPress Cron and schedule automatic imports

  1. In Automation Settings, select WordPress Cron.
  2. Enable Run imports automatically via WordPress Cron.
  3. Choose an Import Frequency from the available WP-Cron schedules.
  4. For Daily or Twice Daily, set a Start Time in 24-hour HH:MM format. For the custom interval, set Interval (Minutes, min. 15).
  5. Click Save Import & Limits settings.

Switch to Server Cron

  1. In Automation Settings, select Server Cron. The plugin disables its WordPress-Cron schedule when this mode is active.
  2. The Server Cron Setup card appears with two steps: - Step 1: add define( 'DISABLE_WP_CRON', true ); to wp-config.php. - Step 2: add two server cron jobs — one to call the REST trigger URL, one to keep wp-cron.php running for image processing.
  3. If no token exists yet, click Generate Token (in Server Cron mode one is usually created automatically). Then copy the REST Trigger URL and the Secret Token from the card. Copy the URL right away — it is only shown for about 15 minutes, after which it is hidden until you regenerate the token.
  4. Use the Example Cron Commands as a starting point and adjust the frequency to your needs.
  5. Click Save Import & Limits settings.
  6. To rotate the secret, click Regenerate Token and update your server cron entry with the new URL.

Configure image processing for stability

  1. In Image Processing and Stability, set Vehicles per Run (0 means no limit; 50–80 is suggested for large catalogs).
  2. Keep Enable Image Queue turned on so only the first image is loaded immediately and the rest are processed asynchronously.
  3. Save.

Set defaults for newly imported vehicles

  1. In Import Defaults, choose Default Post Status (Publish or Draft).
  2. Optionally select a Default Post Author; choose (keep current user) to preserve the existing behavior.
  3. Toggle Import Images to control whether image attachments are downloaded.
  4. Optionally toggle Convert Images to WebP and pick a WebP Quality between 10% and 100% in 5% steps (recommended 75–85%).
  5. Set Max Images per Listing (0 = no limit) to cap the number of images downloaded per vehicle.
  6. Save.

Enable re-listing detection

  1. Open Car Market Hub → Import & Limits and find the Re-listing detection card.
  2. Keep Enable re-listing detection turned on (it is on by default).
  3. Save. From now on, when a vehicle is re-listed under a new AutoScout24 listing ID but with the same VIN, it is merged into the existing vehicle (no duplicate), the new price is applied, the public URL is preserved, and a price history plus a re-listing counter are recorded.

Enable Full Sync and choose how removed vehicles are handled (Danger Zone)

  1. Create a backup of your database and uploads directory.
  2. In the Danger Zone, toggle Enable Full Sync and confirm the warning dialog.
  3. Decide how removed vehicles are handled: - Soft delete (recommended, default): keep Hold removed vehicles (soft delete) on. A vehicle that disappears from AutoScout24 is hidden (set to draft) and kept for the Grace period (days) you configure (default 30). If it is re-listed within that window it is restored in place — same page, URL and price history. Only after the grace period expires is it permanently deleted by a daily cleanup. - Immediate delete: turn Hold removed vehicles (soft delete) off. A removed vehicle is deleted permanently on the next run, including its imported and featured images.
  4. Save.

Configuration reference

Current Import Status

At the top of the screen a dynamic sentence states whether automatic imports are currently active (and whether they run via Server Cron or WP Cron) or disabled. Below it are four KPI tiles:

TileMeaning
Imported VehiclesTotal vehicles currently imported into WordPress.
Configured SellersNumber of Seller IDs configured for imports. Use Show IDs / Hide IDs to reveal or hide the actual IDs inline.
Pending ImagesImages still queued for asynchronous processing.
Last Run ErrorsNumber of errors recorded during the most recent import run.

Last Run

The Last Run summary reports the metrics from the most recent import: inserted, updated, skipped and errors. When Full Sync is enabled it can also report, for vehicles no longer on AutoScout24, a Held counter (vehicles hidden as drafts during their grace period when soft delete is on) and a Deleted counter (vehicles permanently removed).

Trigger Method

OptionDescription
WordPress CronDefault. Works without server access but depends on site traffic to fire cron events.
Server CronRecommended for production. Requires you to disable WP-Cron and to add real cron jobs on the server.

WordPress Cron settings (visible only when WordPress Cron is selected)

FieldNotes
Run imports automatically via WordPress CronEnables the plugin's scheduled event.
Import FrequencyPulled from the plugin's scheduler. Includes a custom as24ci_custom schedule.
Start Time (HH:MM)Used by the Daily and Twice Daily schedules; 24-hour format. Invalid values fall back to 06:00.
Interval (Minutes, min. 15)Used by the custom schedule. Values below 15 are clamped to 15.

Server Cron settings (visible only when Server Cron is selected)

FieldNotes
REST Trigger URLPre-built URL containing the current secret token. Call it from your server cron job. It is only displayed for about 15 minutes after a token is generated; after that only a one-way hash of the token is stored, the URL is hidden, and a warning explains that you must regenerate the token to see a usable URL again. Copy it immediately and store it safely in your cron job.
Secret TokenTreat as a credential. Anyone who knows it can trigger an import. The field can be shown/hidden, copied, or (re)generated.
Example Cron CommandsIncludes a curl example for the import trigger and a php wp-cron.php example to keep image processing running.
Generate Token / Regenerate TokenWhen no token exists yet the button reads Generate Token and a "No cron secret token has been created yet" warning is shown. After a token exists the button reads Regenerate Token; using it creates and saves a new random token, and the previous URL stops working immediately.

Image Processing and Stability

FieldDefaultNotes
Vehicles per Run500 = no limit. Lower values improve stability on shared hosting.
Enable Image QueueOnLoads the first image immediately; remaining images are processed asynchronously.

Import Defaults

FieldDefaultNotes
Default Post StatusPublishAllowed values: publish, draft.
Default Post Author(keep current user)Any existing WordPress user can be selected.
Import ImagesOnDisabling skips the image download step entirely.
Convert Images to WebPOffRequires PHP GD or Imagick with WebP support on the server.
WebP Quality80%Allowed values: 10%–100% in 5% steps.
Max Images per Listing0 (no limit)Cap applied per vehicle during import.

Re-listing detection

FieldDefaultNotes
Enable re-listing detectionOnWhen on, an import that finds no vehicle for the AutoScout24 listing ID falls back to matching by VIN, so a re-listed vehicle updates the existing post instead of creating a duplicate. Developers can override this with the as24ci_enable_relisting_detection filter.

Danger Zone

FieldDefaultNotes
Enable Full SyncOffWhen enabled, vehicles that no longer exist in AutoScout24 are removed on each run. A confirmation dialog is shown when enabling. How they are removed depends on the soft-delete setting below.
Hold removed vehicles (soft delete)OnOnly relevant while Full Sync is enabled. When on, a removed vehicle is hidden as a draft and kept for the grace period instead of being deleted immediately; if it re-appears within that window it is restored in place. When off, removed vehicles are deleted permanently (including imported and featured images) on the next run.
Grace period (days)30How long a soft-deleted vehicle is kept before a daily cleanup permanently deletes it. Allowed range: 1–365 days.

How re-listing detection and price history work

Some dealers refresh their AutoScout24 ranking by deleting a listing and re-creating it. AutoScout24 then issues a new listing ID, often with a lower price, while the physical car keeps the same VIN (vehicle identification number). Because the importer normally matches vehicles by listing ID, such a re-listing would otherwise create a duplicate, or — with Full Sync — reset the car's history.

With Re-listing detection enabled, the import works as follows:

  1. The importer first tries to match the incoming listing by its AutoScout24 listing ID (as before).
  2. If no match is found, it falls back to matching by normalised VIN (uppercased, non-alphanumeric characters removed). A VIN that is empty or too short to be trustworthy is ignored, so listings without a VIN behave exactly as before.
  3. If exactly one existing vehicle has that VIN, it is updated in place: the new listing ID and the new price are applied, and the public slug/URL is kept unchanged so links and SEO are preserved. No duplicate is created.
  4. If the VIN is ambiguous (already present on more than one vehicle), the plugin does not auto-merge — it stays safe and leaves the records untouched.

What is recorded on a re-listed vehicle:

  • Price history — every price change (and the initial price) is stored as a dated entry, so a delete-and-re-list-cheaper pattern becomes visible.
  • Previous AutoScout24 listing IDs — the chain of listing IDs the car has had.
  • First seen — the original import date is preserved (and back-filled for existing vehicles), so days-on-lot stays accurate.
  • Re-listing counter and the latest price delta.

Where you see it:

  • Vehicle list column — a Re-listing column shows a Re-listed n× badge and the latest price change (▼ price drop / ▲ price increase).
  • Vehicle editor — a Re-listing & Price History box lists the first-seen date, the previous listing IDs and the full price history.

Developers can hook the as24ci_vehicle_relisted action ($post_id, $previous_listing_id, $current_listing_id, $delta) to integrate with other systems, and toggle the whole feature with the as24ci_enable_relisting_detection filter.

How soft delete and the grace period work

Soft delete only applies while Full Sync is enabled. It changes what happens to a vehicle that is no longer returned by the AutoScout24 API:

  1. On the first run where the vehicle is missing, it is hidden — its post status is set to draft (removed from the public frontend) and the removal date is recorded. It is not deleted.
  2. The vehicle is kept for the configured grace period (default 30 days).
  3. If the same vehicle is re-imported within the grace period — matched by listing ID or by VIN (see re-listing detection) — it is restored in place: the original post, URL and price history are kept, and it is set back to its previous status.
  4. A daily cleanup cron permanently deletes vehicles whose grace period has expired (removing imported and featured images), so nothing accumulates indefinitely.

This closes the gap where a vehicle is removed in one sync cycle and only re-listed in a later one: with immediate (hard) delete the original post would already be gone, but with soft delete it is still held as a draft and can be restored.

The vehicle editor shows a notice on a held vehicle, for example “Removed from AutoScout24 on … — scheduled for permanent deletion on … unless re-listed.” Developers can toggle the behaviour with the as24ci_enable_soft_delete filter.

Operational notes

  • Switching to Server Cron turns off the plugin's WP-Cron event automatically, so the same schedule will not run twice.
  • The cron token is auto-generated the first time the screen is rendered only in Server Cron mode, so the trigger URL is ready when you need it. In WP-Cron mode no token is generated automatically and the trigger URL is hidden; switch to Server Cron (or click Generate Token) to create one.
  • WebP conversion happens on the server. If the required PHP extension is not present, conversion is silently skipped — verify in the logs and the System & Help screen.
  • The image queue is independent of the Vehicles-per-Run limit. Both can be active at the same time.
  • The "Vehicles per Run" cap applies to scheduled imports. The manual import wizard can iterate through batches automatically until the entire inventory is processed.
  • Saving any of the per-card buttons saves the entire Import & Limits form (the form spans multiple cards).
  • The cron token, REST trigger URL and example cron commands shown in the admin UI are environment-specific. Do not copy values from documentation; always copy from your live screen.
  • Re-listing detection needs a VIN to merge a re-listed vehicle. Listings without a VIN are matched by listing ID only and behave as before.
  • Soft delete only takes effect while Full Sync is enabled. With Full Sync off, vehicles missing from the API are simply kept.
  • The soft-delete grace-period cleanup runs once per day via WordPress Cron. On very low-traffic sites (WP-Cron mode), expired vehicles may be deleted slightly later than the exact expiry date.

Troubleshooting

  • The schedule never runs (WP-Cron mode). WordPress Cron only fires when the site is visited. On low-traffic sites, switch to Server Cron for reliable execution.
  • The REST trigger returns 401/403. The token in the URL does not match. Copy the URL from the admin again or regenerate the token.
  • PHP timeouts during import. Lower Vehicles per Run (try 50), keep Enable Image Queue on, and consider raising server max_execution_time and memory_limit if your host allows it.
  • Images are not downloaded. Confirm Import Images is enabled and that the uploads directory is writable. Check Logs.
  • WebP conversion has no effect. Confirm PHP GD or Imagick has WebP support on the server. Verify in the System & Help screen.
  • Full Sync removed vehicles unexpectedly. Full Sync deletes anything missing from the API response. If you also use manual edits, restore from backup and disable Full Sync.
  • Manual import does not start. Check the browser console for AJAX errors and verify the Dashboard reports a healthy API connection.
  • The same car appears twice after a dealer re-listed it. Enable Re-listing detection so the new listing merges into the existing vehicle by VIN. Note that a vehicle whose listing has no VIN cannot be merged automatically.
  • A re-listed car was not merged. The listing has no VIN, or the VIN already exists on more than one vehicle (ambiguous). In the ambiguous case the plugin deliberately does not auto-merge; resolve the duplicate manually.
  • A removed car is still there as a draft. That is soft delete holding it during its grace period. It is restored automatically if the car is re-listed, and permanently deleted after the grace period. To delete removed vehicles immediately instead, turn off Hold removed vehicles (soft delete) in the Danger Zone.
  • Held vehicles are never cleaned up. The cleanup runs daily via WP-Cron. On low-traffic sites switch to Server Cron, or confirm WP-Cron is firing (System & Help).