Install
Upload it under Plugins → Add New Plugin → Upload Plugin, then activate.
Install straight from GitHub with WP-CLI:
wp plugin install https://github.com/spyderbotlabs/spb-wordpress/releases/download/v0.3.2/spyderbot-tracking-0.3.2.zipSpyderBot Tracking — WordPress Plugin
WordPress plugin for SpyderBot AI Traffic: browser script (wfm.js) plus server-side bot capture. License: GPL-2.0-or-later.
v0.3.2 — GitHub releases.
Features
- Settings → SpyderBot Tracking
- Tracking key (stored in
wp_options, masked in the UI) - API environment: Production
- Toggles: browser script (
wfm.js), server-side bot tracking - Excluded path prefixes
- Page-cache notice + “Exclude AI bot UAs from page cache”
- Test connection (blocking POST, clear success/error)
- Tracking key (stored in
- Server-side bot tracking on front-end HTML (
GET/HEAD): fire-and-forget onshutdownwithwp_remote_post( blocking => false ), timeout ≤1–1.5s - Browser script: enqueue hosted
wfm.jsonce (async/defer) +preconnect; shares_spyd_sid - Cache compat: WP Rocket / LiteSpeed Cache / W3 Total Cache / WP Super Cache UA filters +
DONOTCACHEPAGEfor bots when PHP runs
Install
- Download
spyderbot-tracking-0.3.2.zipfrom Releases, or clone this repo and runcomposer build-zip. - Upload via Plugins → Add New → Upload Plugin (or unpack into
wp-content/plugins/spyderbot-tracking). - Activate, then open Settings → SpyderBot Tracking.
- Paste your AI Traffic project tracking key, save, and click Test connection.
Configuration
| Option | Default | Notes |
|---|---|---|
| Tracking key | (empty) | Never commit real keys |
| Environment | Production | https://api.spyderbot.net/server-track + script https://spyderbot.net/wfm.js |
| Browser script | on | Remote wfm.js?key=…&v=… |
| Server-side | on | Bots only (source: wordpress_plugin) |
| Excluded paths | (none) | One path prefix per line |
| Cache bot bypass | on | Filters listed above |
Ingest contract (body)
url, referrer, session_id, client_ip, country, method, status_code, utm_source, utm_medium, utm_campaign, source (= wordpress_plugin). Header X-Tracking-Key + visitor User-Agent.
client_ip from CF-Connecting-IP → X-Forwarded-For → REMOTE_ADDR. country from CF-IPCountry.
Page cache
| Situation | Coverage |
|---|---|
| WP Rocket / LiteSpeed / W3TC / WP Super Cache with bypass enabled | Bot UAs added to reject lists / non-cacheable; PHP can run and POST |
| Edge HTML cache with no origin hit (e.g. Cloudflare cache everything) | Not covered — use the Cloudflare Worker |
| Logged-in admins / AJAX / REST / cron / feeds | Skipped by design |
Development
# PHP 7.4+ / 8.x
composer install
composer test # or: vendor/bin/phpunit
composer build-zip
Tests use Brain Monkey (no full WordPress checkout).
Browser path is hosted wfm.js (no bundled client script).
Uninstall
uninstall.php deletes plugin options and the test-connection transient (including multisite per-blog cleanup).
License
Plugin PHP: GPL-2.0-or-later.
Hosted wfm.js is served by SpyderBot app origins.
Links
- Integrations: https://spyderbot.net/integrations
- Cloudflare Worker: https://github.com/spyderbotlabs/spb-cloudflare-worker
Releases
3 releases. Each count is every asset in that release; expand a row for the breakdown.