# MusePort operations

Canonical version `2026.10.09.001`; WordPress 6.4+, PHP 8.1+, HTTPS and MySQL/MariaDB InnoDB. Developer/copyright MatthewxMurphy.com. This new generic observer does not replace the existing MusePost CLI or private CPH Communications Hub.

Activation creates only the current site's prefixed `museport_agents`, `museport_events` and `museport_runs` tables, a non-autoloaded schema-version option and one daily retention cron event. No accounts, credentials, external connections, content, prices or marketing messages are created. Register an agent deliberately in native administration; store its one-time writer key privately on the intended worker. Keys are never retained as plaintext by WordPress. Rotating WordPress authentication salts invalidates existing writer hashes.

Back up this plugin and its three tables before upgrades. Keep runtime backups, original mail records and worker credentials outside Git and downloadable source packages. Deploy only a frozen checked ZIP, record SHA-256 and canonical version, then verify activation, role isolation, event attribution, duplicate request behavior, redaction and rendered administration. An installed/active plugin is distinct from a connected or productive agent.

The source includes no uninstall deletion. Deactivation clears the retention schedule and preserves its tables; rollback restores the selected prior plugin and considers only these tables. Do not overwrite newer unrelated content, users, credentials or current agent observations. Deliberate full removal requires an administrator-reviewed export/retention decision and deletion of only the three MusePort tables, its schema option and cron hook.

Retention is 90 days and 10,000 events. Daily WordPress cron and ingestion prune expired observations and old runs. If a worker is rate-limited or the retained row ceiling is full, preserve its stable request ID; do not manufacture successful observations. WP-Cron depends on the site's existing cron/traffic setup. An offline worker produces no heartbeat; the last received time remains visible without inventing connectivity.

State is agent reported. Server receipt time is recorded by WordPress. Proof references are opaque agent-supplied identifiers and are not fetched or independently verified. “Succeeded” must never be rewritten as platform-verified delivery. Accepted, partial, rejected and uncertain SMTP states remain distinct, and mail delivery remains unconfirmed without a specifically reported provider receipt.

## Verification

Offline: `php tests/event.php` and `python3 -m unittest discover -s tests -p 'test_*.py' -v`. All Python transports are fake by default. Lint every PHP runtime file and compare VERSION/header/constants/readme/changelog before packaging.

The generic worker sender validates already prepared observations and defaults to offline output. Install `worker/event_sender.py` beside `worker/receipt_adapter.py`; keep the writer config privately owned with mode 0600. Explicit publishing uses exactly that configured HTTPS origin, refuses all redirects and makes one request. HTTP conflicts or uncertain receipts preserve the original idempotency ID for reconciliation. A registered writer is not a worker execution service. Site administrators must verify a real event from the intended environment before marking that specific connection working.

Native WordPress: `tests/wordpress.php` refuses to execute unless `WP_ENVIRONMENT_TYPE` is `staging` or `development`. Run via `wp eval-file` in the explicitly selected isolated stage. It creates only marked temporary agent/event/run rows, tests actual REST permissions and storage, and removes its own rows in `finally`. It creates no WordPress users, contacts, public activity, mail messages or external agent connections. Never run it against production.

Browser: use the isolated stage's existing administrator session. Inspect the native page, key-management permissions, task/mail/heartbeat distinctions, responsive table scrolling and escaped summary content. Do not expose fixture writer keys in screenshots or tool outputs. Synthetic tests remain stage fixtures, never production activity.
