Repository: Starisian-Technologies/sparxstar-user-environment-check
Package: starisian/sparxstar-user-environment-check
License: Proprietary (see LICENSE and LICENSE.md)
SPARXSTAR User Environment Check (UEC) is a WordPress plugin that captures high-fidelity client environment diagnostics (device/network/browser/runtime capabilities), sends them to a secured REST endpoint, sanitizes and normalizes payloads, and stores snapshots in a site-scoped custom table.
This repository contains the production plugin implementation for:
- client-side environment collection and profiling
- WordPress REST ingestion and persistence
- multisite-safe schema lifecycle and cleanup
- admin diagnostics and GeoIP configuration
- stable public consumer API (
StarUserEnv)
- Client-first diagnostics (client is source of truth)
- Consent-aware identifier collection path
- Snapshot persistence with cache and session integration
- Optional GeoIP enrichment (ipinfo or MaxMind)
- Multisite-aware activation/deactivation and uninstall
- PHP 8.2+
- WordPress 6.8+ (multisite supported)
- Composer
- Node.js 20+ and pnpm 8.6.0+
composer install
corepack enable
corepack prepare pnpm@8.6.0 --activate
pnpm installNote: This repository currently contains pre-existing lint/static-analysis issues unrelated to this documentation hardening pass.
composer run lint
composer run analyze
composer run test:unit
composer testpnpm run lint
pnpm run buildUse only the facade class:
\Starisian\SparxstarUEC\StarUserEnv
Examples:
StarUserEnv::get_snapshot()StarUserEnv::get_network_type()StarUserEnv::get_user_device()StarUserEnv::get_geolocation()
POST /wp-json/star-uec/v1/log
- requires
X-WP-Nonce(wp_rest) for snapshot ingestion - accepts JSON payload from client collector pipeline
Recorder telemetry endpoint:
POST /wp-json/star-uec/v1/recorder-log
- Create feature branch.
- Keep changes scoped and incremental.
- Run lint/analyze/test/build commands.
- Update docs for API/behavior changes.
- Open PR with security and testing notes.
See also:
CONTRIBUTING.mdDEVELOPMENT.mdARCHITECTURE.mdSECURITY.mdCHANGELOG.md