NV oOS Pro Toolkit Security Operations
The Pro Toolkit Security Operations system provides a complete security
management framework built on WordPress Custom Post Types. It manages the
full security lifecycle: audit → detect → respond → maintain.
All entities are stored as CPT records accessible via the toolkit_cpt MCP tool.
WP-CLI Commands
Key mcp-ai WP-CLI commands for security ops. Run via terminal:
| Command |
Use for |
wp mcp-ai health |
Verify system health before/after incidents and maintenance windows |
wp mcp-ai log errors --limit=20 |
Review recent error log entries for incident investigation |
wp mcp-ai log activity --type=tool_execution |
Filter activity log by tool executions for audit review |
wp mcp-ai log prune --yes |
Prune old log entries after audit review is complete |
wp mcp-ai queue stats |
Check background job queue health for maintenance transitions |
wp mcp-ai queue process |
Trigger processing of queued maintenance status transitions |
wp mcp-ai queue retry <job-id> |
Retry a failed security ops background job |
When to use this skill
Trigger when ANY of the following is true:
- Viewing, searching, or filtering audit events, training modules, maintenance windows, or incidents.
- Creating audit trail entries for agent actions, tool executions, or session events.
- Managing security training programs — creating modules, tracking completion, assigning roles.
- Scheduling maintenance windows with start/end times, service scoping, and notification channels.
- Investigating or responding to security/operational incidents.
- Moving an incident through its lifecycle phases (detected → investigating → identified → monitoring → resolved).
- Checking for active maintenance windows before making infrastructure changes.
- Reviewing incident post-mortems via linked lessons learned.
- Triaging active incidents or checking maintenance window overlap.
- Automating audit event creation from agent workflows.
Mental model — audit → detect → respond → maintain
The Security Ops system is organized around four core entity types connected
by an operational lifecycle:
AUDIT_EVENT ──(logged)──→ persistent, immutable trail
│
├── reveals anomalies
▼
INCIDENT ──(detected)──→ investigating ──→ identified ──→ monitoring ──→ resolved
│
└──→ LESSON (linked via lesson_id)
MAINTENANCE ──(scheduled)──→ in_progress ──→ completed
│ │
└──→ cancelled └── linked via post_id to incidents it prevented
TRAINING ── assigned to roles → tracking completions → compliance reporting
Relationships:
- An Incident links to a lessons learned record via
_mcp_ai_incident_lesson_id.
- A Maintenance Window may be linked to incidents via the post content (editor) field as cross-references.
- Audit Events are immutable — they are never updated or deleted, only created and read.
- Training modules have role-based assignment and per-user completion tracking stored in user meta.
Security Ops Entity Types
All security ops entities are managed through the toolkit_cpt MCP tool.
Use the appropriate post_type slug for each entity:
| CPT Slug |
Label |
Supports |
Purpose |
Key Meta Fields |
mcp_ai_audit_event |
Audit Events |
title |
Immutable security audit trail entries |
_wp_mcp_ai_audit_trail_id, _wp_mcp_ai_audit_session_id, _wp_mcp_ai_audit_assistant_id, _wp_mcp_ai_audit_provider, _wp_mcp_ai_audit_model, _wp_mcp_ai_audit_step_type, _wp_mcp_ai_audit_timestamp, _wp_mcp_ai_audit_sequence, _wp_mcp_ai_audit_data, _wp_mcp_ai_audit_event_hash |
mcp_ai_training |
Security Training |
title, editor, excerpt |
Training modules and compliance programs |
_training_role, _training_type, _training_duration, _training_mandatory |
mcp_ai_maintenance |
Maintenance Windows |
title, editor |
Planned maintenance and scheduled downtime |
_mcp_ai_maintenance_status, _mcp_ai_maintenance_start, _mcp_ai_maintenance_end, _mcp_ai_maintenance_services, _mcp_ai_maintenance_notify_channels, _mcp_ai_maintenance_banner_enabled |
mcp_ai_incident |
Incidents |
title |
Security/operational incident records |
_mcp_ai_incident_phase, _mcp_ai_incident_severity, _mcp_ai_incident_services, _mcp_ai_incident_timeline, _mcp_ai_incident_resolved_at, _mcp_ai_incident_lesson_id |
Audit Event Meta Fields (detailed)
| Field |
Type |
Description |
Example |
_wp_mcp_ai_audit_trail_id |
string |
Unique trail identifier |
"trail_20260812_a1b2c3" |
_wp_mcp_ai_audit_session_id |
string |
Session identifier |
"sess_d4e5f6" |
_wp_mcp_ai_audit_assistant_id |
int |
Assistant post ID |
"42" |
_wp_mcp_ai_audit_provider |
string |
AI provider name |
"openai", "gemini" |
_wp_mcp_ai_audit_model |
string |
AI model used |
"gpt-4o" |
_wp_mcp_ai_audit_step_type |
string |
Event step type |
"tool_call", "planning", "decision" |
_wp_mcp_ai_audit_timestamp |
int |
Unix timestamp |
1723456789 |
_wp_mcp_ai_audit_sequence |
int |
Sequence number within trail |
3 |
_wp_mcp_ai_audit_data |
mixed |
Serialized event payload |
JSON string of tool arguments/output |
_wp_mcp_ai_audit_event_hash |
string |
Cryptographic hash of event |
"sha256:abc123..." |
_wp_mcp_ai_audit_prev_hash |
string |
Hash of previous event (chain integrity) |
"sha256:def456..." |
_wp_mcp_ai_audit_tool_slug |
string |
Tool slug (if tool_call step) |
"toolkit_cpt" |
_wp_mcp_ai_audit_duration_ms |
int |
Duration in milliseconds |
1250 |
_wp_mcp_ai_audit_status |
string |
Outcome status |
"success", "error" |
_wp_mcp_ai_audit_user_id |
int |
WordPress user ID |
1 |
Audit events are append-only. The title follows the format:
"{trail_id} | {step_type} | #{sequence} | {ISO 8601 timestamp}".
Training Meta Fields (detailed)
| Field |
Type |
Description |
Example / Enum |
_training_role |
string |
Target role for this module |
"developer", "administrator", "security_team", "support_staff", "all_users" |
_training_type |
string |
Module type category |
"awareness", "technical", "compliance", "incident", "policy" |
_training_duration |
int |
Duration in minutes |
45 |
_training_mandatory |
bool |
Required for compliance ("1" = true) |
"1", "" |
Training roles: developer, administrator, security_team, support_staff, all_users
Module types: awareness (Security Awareness), technical (Technical Security), compliance (Compliance Training), incident (Incident Response), policy (Policy Training)
Maintenance Meta Fields (detailed)
| Field |
Type |
Description |
Example |
_mcp_ai_maintenance_status |
string |
Current window status |
"scheduled", "in_progress", "completed", "cancelled" |
_mcp_ai_maintenance_start |
string |
Scheduled start (ISO 8601) |
"2026-08-15T02:00:00+00:00" |
_mcp_ai_maintenance_end |
string |
Scheduled end (ISO 8601) |
"2026-08-15T04:00:00+00:00" |
_mcp_ai_maintenance_services |
array |
Affected service slugs |
["api", "database", "cache"] |
_mcp_ai_maintenance_notify_channels |
array |
Notification channel IDs |
["email", "slack"] |
_mcp_ai_maintenance_notify_before |
int |
Minutes before start to send reminder |
60 |
_mcp_ai_maintenance_banner_enabled |
bool |
Show frontend banner during window |
true, false |
_mcp_ai_maintenance_reminder_sent |
bool |
Whether reminder was sent (auto-managed) |
true, false |
Status transitions (valid):
scheduled → in_progress (auto at _mcp_ai_maintenance_start)
scheduled → cancelled
in_progress → completed (auto at _mcp_ai_maintenance_end)
in_progress → cancelled
Incident Meta Fields (detailed)
| Field |
Type |
Description |
Example |
_mcp_ai_incident_phase |
string |
Current phase |
"detected", "investigating", "identified", "monitoring", "resolved" |
_mcp_ai_incident_severity |
string |
Severity level |
"minor", "major", "critical" |
_mcp_ai_incident_services |
array |
Affected service slugs |
["api", "auth"] |
_mcp_ai_incident_timeline |
array |
Append-only timeline entries |
See timeline entry structure below |
_mcp_ai_incident_resolved_at |
string |
ISO 8601 when resolved (auto-set) |
"2026-08-15T16:30:00+00:00" |
_mcp_ai_incident_lesson_id |
int |
Linked mcp_ai_lesson post ID |
89 |
_mcp_ai_incident_notify_channels |
array |
Notification channel IDs |
["email", "pagerduty"] |
Timeline entry structure:
{
"timestamp": 1723456789,
"phase": "investigating",
"message": "Database connection pool exhausted — traced to connection leak in cron worker.",
"operator_id": 1
}
Phase transitions (valid):
detected → investigating, resolved
investigating → identified, resolved
identified → monitoring, resolved
monitoring → resolved
resolved → (terminal)
Severity classification:
| Severity |
When to use |
Example |
minor |
Affects non-critical service, no user impact |
Slow admin dashboard |
major |
Partial service degradation, workaround exists |
API rate limiting, cache miss spike |
critical |
Complete service outage, no workaround |
Site down, auth broken |
Available Tools
All security ops operations use the toolkit_cpt MCP tool as the primary
interface for CRUD operations.
Discovery
# List all available security ops post types
toolkit_cpt(action: "list_types")
# Get field schema for any security ops type
toolkit_cpt(action: "get_schema", post_type: "mcp_ai_incident")
Reading records
// List recent audit events
{ "action": "list_items", "post_type": "mcp_ai_audit_event", "orderby": "date", "order": "DESC" }
// Find active (non-resolved) incidents
{ "action": "list_items", "post_type": "mcp_ai_incident",
"filters": [{ "key": "_mcp_ai_incident_phase", "value": "resolved", "compare": "!=" }] }
// Get upcoming scheduled maintenance windows
{ "action": "list_items", "post_type": "mcp_ai_maintenance",
"filters": [{ "key": "_mcp_ai_maintenance_status", "value": "scheduled" }] }
// Search training modules
{ "action": "list_items", "post_type": "mcp_ai_training", "search": "ISO 27001" }
Creating records
// Create an incident with initial timeline
{ "action": "create_item", "post_type": "mcp_ai_incident",
"fields": {
"title": "API Gateway returning 503 errors",
"_mcp_ai_incident_phase": "detected",
"_mcp_ai_incident_severity": "critical",
"_mcp_ai_incident_services": ["api", "gateway"],
"_mcp_ai_incident_timeline": [{
"timestamp": 1723456789, "phase": "detected",
"message": "Health check monitor detected 503 responses from API gateway.", "operator_id": 0
}],
"_mcp_ai_incident_notify_channels": ["email", "slack"]
}
}
// Schedule a maintenance window
{ "action": "create_item", "post_type": "mcp_ai_maintenance",
"fields": {
"title": "Database upgrade to PostgreSQL 16",
"content": "Upgrading primary database from v15 to v16. Expected downtime: 45 min.",
"_mcp_ai_maintenance_status": "scheduled",
"_mcp_ai_maintenance_start": "2026-08-20T02:00:00+00:00",
"_mcp_ai_maintenance_end": "2026-08-20T04:00:00+00:00",
"_mcp_ai_maintenance_services": ["database", "api"],
"_mcp_ai_maintenance_notify_before": 60,
"_mcp_ai_maintenance_banner_enabled": true
}
}
// Create a training module
{ "action": "create_item", "post_type": "mcp_ai_training",
"fields": {
"title": "Phishing Awareness 2026",
"excerpt": "Learn to identify and report phishing attempts.",
"_training_role": "all_users", "_training_type": "awareness",
"_training_duration": 30, "_training_mandatory": "1"
}
}
Updating records
// Transition an incident to investigating
{ "action": "update_item", "post_type": "mcp_ai_incident", "item_id": 12345,
"fields": { "_mcp_ai_incident_phase": "investigating" } }
// Resolve an incident with linked lesson
{ "action": "update_item", "post_type": "mcp_ai_incident", "item_id": 12345,
"fields": { "_mcp_ai_incident_phase": "resolved", "_mcp_ai_incident_lesson_id": 89 } }
// Cancel a maintenance window
{ "action": "update_item", "post_type": "mcp_ai_maintenance", "item_id": 678,
"fields": { "_mcp_ai_maintenance_status": "cancelled" } }
Common Workflows
Incident response lifecycle
1. Detection: create_item(mcp_ai_incident, phase: "detected", severity: <level>)
→ Timeline entry with initial observations.
2. Investigation: update_item(mcp_ai_incident, phase: "investigating")
→ Check logs: wp mcp-ai log errors --limit=50
→ Check health: wp mcp-ai health
→ Add timeline entries with findings.
3. Identification: update_item(mcp_ai_incident, phase: "identified")
→ Document root cause in timeline.
→ Assess scope — add affected services.
4. Monitoring: update_item(mcp_ai_incident, phase: "monitoring")
→ Verify fix is holding.
→ Add timeline entries confirming stability.
5. Resolution: update_item(mcp_ai_incident, phase: "resolved")
→ Create lessons learned post.
→ Link via _mcp_ai_incident_lesson_id.
→ Review audit events for contributing factors.
Maintenance window scheduling
1. Check for conflicts:
list_items(mcp_ai_maintenance, filters: [{key: "_mcp_ai_maintenance_status", value: "scheduled"}])
→ Verify no overlapping windows for the same services.
2. Check active incidents:
list_items(mcp_ai_incident, filters: [{key: "_mcp_ai_incident_phase", value: "resolved", compare: "!="}])
→ Critical incidents may require postponing maintenance.
3. Create window:
create_item(mcp_ai_maintenance, with start/end times, services, notification channels)
→ _mcp_ai_maintenance_notify_before controls reminder timing.
4. Notify stakeholders:
The system auto-sends reminders _mcp_ai_maintenance_notify_before minutes before start.
→ Verify channels in _mcp_ai_maintenance_notify_channels.
5. During window:
Status auto-transitions to "in_progress" at start time.
→ Monitor health: wp mcp-ai health
6. After window:
Status auto-transitions to "completed" at end time.
→ Verify all services healthy.
→ If issues: create incident linked to this maintenance window.
Audit review
1. List audit events by step type:
list_items(mcp_ai_audit_event, filters: [{key: "_wp_mcp_ai_audit_step_type", value: "tool_call"}])
2. Trace a specific session:
list_items(mcp_ai_audit_event, filters: [{key: "_wp_mcp_ai_audit_session_id", value: "sess_abc123"}],
orderby: "date", order: "ASC")
→ The event chain is verifiable via _wp_mcp_ai_audit_event_hash → _wp_mcp_ai_audit_prev_hash.
3. Review error events:
list_items(mcp_ai_audit_event, filters: [{key: "_wp_mcp_ai_audit_status", value: "error"}])
4. Cross-reference with WP-CLI logs:
wp mcp-ai log activity --type=tool_execution
Training management
1. Create training modules by role and type:
create_item(mcp_ai_training, with _training_role, _training_type, _training_duration, _training_mandatory)
2. Review compliance coverage:
list_items(mcp_ai_training, filters: [{key: "_training_mandatory", value: "1"}])
→ Check that each role has required modules.
3. Track completions:
Training completion is stored in user meta (wp_mcp_ai_training_completions).
→ Use the admin Training Statistics page for reporting.
→ Use the `design-analytics-reporting` skill for compliance dashboards.
4. Send reminders:
Annual reminders run via wp_mcp_ai_annual_training_reminder cron hook.
Critical Rules
- Never delete audit events — they are an immutable, cryptographically chained audit trail. Deletion breaks hash-chain integrity and violates compliance requirements.
- Audit events are append-only — use
create_item only. Never update_item or delete_item on mcp_ai_audit_event.
- Incident phase transitions are validated — only specific transitions are allowed (see phase transition table above). Attempting invalid transitions will fail.
- Incident severity must match impact —
minor = no user impact, major = partial degradation, critical = complete outage. Misclassifying severity skews response priority.
- Maintenance windows auto-transition — the system automatically moves
scheduled → in_progress at start time and in_progress → completed at end time. Do not manually set these transitions unless the cron system is down.
- Check for overlapping maintenance windows — before scheduling, list existing scheduled windows for the same services to avoid conflicts.
- Link incidents to lessons learned — every resolved incident should have
_mcp_ai_incident_lesson_id set. This builds organizational knowledge.
- Timeline entries are append-only — when updating incident phase, also append a new timeline entry with the reason for the transition.
- Training role assignment drives compliance — mandatory modules (
_training_mandatory: "1") assigned to all_users apply to every user. Use specific roles (developer, administrator) for targeted training.
- Always use
get_schema first before creating or updating a record to verify available field keys and types.
Common Mistakes
WRONG — deleting an audit event
{ "action": "delete_item", "post_type": "mcp_ai_audit_event", "item_id": 99999 }
// Audit events are immutable. This breaks the hash chain and violates compliance.
RIGHT — audit events are never deleted
// There is no delete path for audit events. They are retained for the
// retention period configured in the audit trail system.
WRONG — skipping incident phases
// Moving from "detected" directly to "resolved" with no investigation.
// The transition is not valid and will be rejected by the CPT.
RIGHT — advance phase-by-phase with timeline entries
1. update_item: _mcp_ai_incident_phase: "investigating"
+ append timeline entry: "Began investigation, reviewing error logs."
2. update_item: _mcp_ai_incident_phase: "identified"
+ append timeline entry: "Root cause: connection pool exhaustion."
3. update_item: _mcp_ai_incident_phase: "monitoring"
+ append timeline entry: "Fix deployed, monitoring for 30 minutes."
4. update_item: _mcp_ai_incident_phase: "resolved"
+ set _mcp_ai_incident_lesson_id: <lesson_post_id>
WRONG — scheduling maintenance during an active critical incident
// Creating a maintenance window while a critical incident (phase != resolved)
// impacts the same services. This risks compounding the outage.
RIGHT — check for active incidents before scheduling
1. list_items(mcp_ai_incident, filters: [{key: "_mcp_ai_incident_phase", value: "resolved", compare: "!="}])
2. If critical incidents exist for overlapping services, postpone maintenance.
WRONG — classifying a complete outage as "minor"
{ "_mcp_ai_incident_severity": "minor" }
// Site is down — this is "critical". Misclassification delays response.
RIGHT — use the severity classification table
// minor: no user impact (e.g., slow admin dashboard)
// major: partial degradation with workaround (e.g., cache miss spike)
// critical: complete outage, no workaround (e.g., site down, auth broken)
WRONG — manually setting maintenance status transitions
{ "_mcp_ai_maintenance_status": "completed" }
// When done manually before the scheduled end time, the auto-transition
// cron may re-fire and create a duplicate completed transition event.
RIGHT — let the cron system handle auto-transitions
// Use update_item only for cancelling a window.
// The system auto-handles scheduled→in_progress and in_progress→completed.
WRONG — creating a training module without a role assignment
{ "title": "GDPR Basics", "_training_type": "compliance" }
// Missing _training_role — the module has no audience.
RIGHT — always assign a target role
{ "title": "GDPR Basics", "_training_role": "all_users", "_training_type": "compliance",
"_training_duration": 20, "_training_mandatory": "1" }
Cross-References
- Run
design-crm to link security incidents to support tickets (mcp_ai_ticket) for customer-facing outage tracking.
- Run
design-pro-schedule-manager to manage cron-based maintenance window transitions and training reminders.
- Run
design-pro-workflow-builder to automate incident response workflows (auto-create incidents from health checks, auto-escalate based on severity).
- Run
wp-security-audit to perform code-level security reviews — complements security ops at the compliance/operational layer.
- Run
wp-security-deep for SSRF, deserialization, and advanced vulnerability checks that feed into incident creation.
- Run
wp-security-secrets to audit hardcoded secrets — findings can be logged as mcp_ai_audit_event entries.
- Run
design-document-generation to create incident post-mortem PDFs and training certificates.
- Run
design-analytics-reporting to build compliance dashboards from training completion data and incident metrics.
What This Skill Does NOT Cover
- Agent audit trail internals (hash chaining, cryptographic verification) — use
mcp_ai_audit_event CPT via toolkit_cpt for reading; the audit trail system manages creation automatically.
- Health check service monitoring — the health check system auto-creates incidents via
wp_mcp_ai_service_status_changed hook. This skill covers manual incident management.
- Security training completion tracking at the user level — use the admin Training Statistics page or query
wp_mcp_ai_training_completions user meta directly.
- Lessons learned (
mcp_ai_lesson) CPT management — use toolkit_cpt with post_type: "mcp_ai_lesson" for post-mortem records.
- Notification delivery (email, Slack, PagerDuty) — this skill covers the entity data; notification dispatch is handled by the system.
- Security posture scoring and Site Health integration — use the
wp-security-audit skill and the /wp-admin/site-health.php dashboard.
- Access control and capabilities — managed via WordPress roles; training roles (
_training_role) are for training assignment, not access control.
References
- NV oOS Pro Toolkit Security Ops admin:
/wp-admin/admin.php?page=nvoos-pro-dashboard
- Incidents admin page:
/wp-admin/edit.php?post_type=mcp_ai_incident
- Maintenance admin page:
/wp-admin/edit.php?post_type=mcp_ai_maintenance
- Security Training admin:
/wp-admin/admin.php?page=nvoos-security-training
toolkit_cpt MCP tool — the primary interface for all security ops operations.
- ISO 27001:2022 Control A.6.3 — Information Security Awareness, Education and Training.
- ISO 27001:2022 Control A.16.1 — Management of Information Security Incidents and Improvements.
1---2type: Skill3name: design-security-ops4description: "Manage the NV oOS Pro Toolkit Security Operations system — audit events, security training, maintenance windows, and incident records. Covers the full security ops lifecycle: audit logging, incident detection/response, maintenance scheduling, and compliance training tracking. Use when working with security audit trails, investigating incidents, scheduling maintenance windows, managing security training programs, or troubleshooting security operations data."5license: Proprietary. See LICENSE.txt6metadata:7 source: https://skillmd.com/skills/nvdigitalsolutions/design-security-ops8 type: Skill9---1011# NV oOS Pro Toolkit Security Operations1213The Pro Toolkit Security Operations system provides a complete security14management framework built on WordPress Custom Post Types. It manages the15full security lifecycle: **audit → detect → respond → maintain**.16All entities are stored as CPT records accessible via the `toolkit_cpt` MCP tool.1718## WP-CLI Commands1920Key `mcp-ai` WP-CLI commands for security ops. Run via `terminal`:2122| Command | Use for |23|---|---|24| `wp mcp-ai health` | Verify system health before/after incidents and maintenance windows |25| `wp mcp-ai log errors --limit=20` | Review recent error log entries for incident investigation |26| `wp mcp-ai log activity --type=tool_execution` | Filter activity log by tool executions for audit review |27| `wp mcp-ai log prune --yes` | Prune old log entries after audit review is complete |28| `wp mcp-ai queue stats` | Check background job queue health for maintenance transitions |29| `wp mcp-ai queue process` | Trigger processing of queued maintenance status transitions |30| `wp mcp-ai queue retry <job-id>` | Retry a failed security ops background job |3132## When to use this skill3334Trigger when ANY of the following is true:3536- Viewing, searching, or filtering audit events, training modules, maintenance windows, or incidents.37- Creating audit trail entries for agent actions, tool executions, or session events.38- Managing security training programs — creating modules, tracking completion, assigning roles.39- Scheduling maintenance windows with start/end times, service scoping, and notification channels.40- Investigating or responding to security/operational incidents.41- Moving an incident through its lifecycle phases (detected → investigating → identified → monitoring → resolved).42- Checking for active maintenance windows before making infrastructure changes.43- Reviewing incident post-mortems via linked lessons learned.44- Triaging active incidents or checking maintenance window overlap.45- Automating audit event creation from agent workflows.4647## Mental model — audit → detect → respond → maintain4849The Security Ops system is organized around four core entity types connected50by an operational lifecycle:5152```53AUDIT_EVENT ──(logged)──→ persistent, immutable trail54 │55 ├── reveals anomalies56 ▼57INCIDENT ──(detected)──→ investigating ──→ identified ──→ monitoring ──→ resolved58 │59 └──→ LESSON (linked via lesson_id)6061MAINTENANCE ──(scheduled)──→ in_progress ──→ completed62 │ │63 └──→ cancelled └── linked via post_id to incidents it prevented6465TRAINING ── assigned to roles → tracking completions → compliance reporting66```6768**Relationships:**69- An **Incident** links to a **lessons learned** record via `_mcp_ai_incident_lesson_id`.70- A **Maintenance Window** may be linked to incidents via the post content (editor) field as cross-references.71- **Audit Events** are immutable — they are never updated or deleted, only created and read.72- **Training** modules have role-based assignment and per-user completion tracking stored in user meta.7374## Security Ops Entity Types7576All security ops entities are managed through the **`toolkit_cpt`** MCP tool.77Use the appropriate `post_type` slug for each entity:7879| CPT Slug | Label | Supports | Purpose | Key Meta Fields |80|---|---|---|---|---|81| `mcp_ai_audit_event` | Audit Events | `title` | Immutable security audit trail entries | `_wp_mcp_ai_audit_trail_id`, `_wp_mcp_ai_audit_session_id`, `_wp_mcp_ai_audit_assistant_id`, `_wp_mcp_ai_audit_provider`, `_wp_mcp_ai_audit_model`, `_wp_mcp_ai_audit_step_type`, `_wp_mcp_ai_audit_timestamp`, `_wp_mcp_ai_audit_sequence`, `_wp_mcp_ai_audit_data`, `_wp_mcp_ai_audit_event_hash` |82| `mcp_ai_training` | Security Training | `title`, `editor`, `excerpt` | Training modules and compliance programs | `_training_role`, `_training_type`, `_training_duration`, `_training_mandatory` |83| `mcp_ai_maintenance` | Maintenance Windows | `title`, `editor` | Planned maintenance and scheduled downtime | `_mcp_ai_maintenance_status`, `_mcp_ai_maintenance_start`, `_mcp_ai_maintenance_end`, `_mcp_ai_maintenance_services`, `_mcp_ai_maintenance_notify_channels`, `_mcp_ai_maintenance_banner_enabled` |84| `mcp_ai_incident` | Incidents | `title` | Security/operational incident records | `_mcp_ai_incident_phase`, `_mcp_ai_incident_severity`, `_mcp_ai_incident_services`, `_mcp_ai_incident_timeline`, `_mcp_ai_incident_resolved_at`, `_mcp_ai_incident_lesson_id` |8586### Audit Event Meta Fields (detailed)8788| Field | Type | Description | Example |89|---|---|---|---|90| `_wp_mcp_ai_audit_trail_id` | string | Unique trail identifier | `"trail_20260812_a1b2c3"` |91| `_wp_mcp_ai_audit_session_id` | string | Session identifier | `"sess_d4e5f6"` |92| `_wp_mcp_ai_audit_assistant_id` | int | Assistant post ID | `"42"` |93| `_wp_mcp_ai_audit_provider` | string | AI provider name | `"openai"`, `"gemini"` |94| `_wp_mcp_ai_audit_model` | string | AI model used | `"gpt-4o"` |95| `_wp_mcp_ai_audit_step_type` | string | Event step type | `"tool_call"`, `"planning"`, `"decision"` |96| `_wp_mcp_ai_audit_timestamp` | int | Unix timestamp | `1723456789` |97| `_wp_mcp_ai_audit_sequence` | int | Sequence number within trail | `3` |98| `_wp_mcp_ai_audit_data` | mixed | Serialized event payload | JSON string of tool arguments/output |99| `_wp_mcp_ai_audit_event_hash` | string | Cryptographic hash of event | `"sha256:abc123..."` |100| `_wp_mcp_ai_audit_prev_hash` | string | Hash of previous event (chain integrity) | `"sha256:def456..."` |101| `_wp_mcp_ai_audit_tool_slug` | string | Tool slug (if tool_call step) | `"toolkit_cpt"` |102| `_wp_mcp_ai_audit_duration_ms` | int | Duration in milliseconds | `1250` |103| `_wp_mcp_ai_audit_status` | string | Outcome status | `"success"`, `"error"` |104| `_wp_mcp_ai_audit_user_id` | int | WordPress user ID | `1` |105106**Audit events are append-only.** The title follows the format:107`"{trail_id} | {step_type} | #{sequence} | {ISO 8601 timestamp}"`.108109### Training Meta Fields (detailed)110111| Field | Type | Description | Example / Enum |112|---|---|---|---|113| `_training_role` | string | Target role for this module | `"developer"`, `"administrator"`, `"security_team"`, `"support_staff"`, `"all_users"` |114| `_training_type` | string | Module type category | `"awareness"`, `"technical"`, `"compliance"`, `"incident"`, `"policy"` |115| `_training_duration` | int | Duration in minutes | `45` |116| `_training_mandatory` | bool | Required for compliance (`"1"` = true) | `"1"`, `""` |117118**Training roles:** `developer`, `administrator`, `security_team`, `support_staff`, `all_users`119**Module types:** `awareness` (Security Awareness), `technical` (Technical Security), `compliance` (Compliance Training), `incident` (Incident Response), `policy` (Policy Training)120121### Maintenance Meta Fields (detailed)122123| Field | Type | Description | Example |124|---|---|---|---|125| `_mcp_ai_maintenance_status` | string | Current window status | `"scheduled"`, `"in_progress"`, `"completed"`, `"cancelled"` |126| `_mcp_ai_maintenance_start` | string | Scheduled start (ISO 8601) | `"2026-08-15T02:00:00+00:00"` |127| `_mcp_ai_maintenance_end` | string | Scheduled end (ISO 8601) | `"2026-08-15T04:00:00+00:00"` |128| `_mcp_ai_maintenance_services` | array | Affected service slugs | `["api", "database", "cache"]` |129| `_mcp_ai_maintenance_notify_channels` | array | Notification channel IDs | `["email", "slack"]` |130| `_mcp_ai_maintenance_notify_before` | int | Minutes before start to send reminder | `60` |131| `_mcp_ai_maintenance_banner_enabled` | bool | Show frontend banner during window | `true`, `false` |132| `_mcp_ai_maintenance_reminder_sent` | bool | Whether reminder was sent (auto-managed) | `true`, `false` |133134**Status transitions (valid):**135```136scheduled → in_progress (auto at _mcp_ai_maintenance_start)137scheduled → cancelled138in_progress → completed (auto at _mcp_ai_maintenance_end)139in_progress → cancelled140```141142### Incident Meta Fields (detailed)143144| Field | Type | Description | Example |145|---|---|---|---|146| `_mcp_ai_incident_phase` | string | Current phase | `"detected"`, `"investigating"`, `"identified"`, `"monitoring"`, `"resolved"` |147| `_mcp_ai_incident_severity` | string | Severity level | `"minor"`, `"major"`, `"critical"` |148| `_mcp_ai_incident_services` | array | Affected service slugs | `["api", "auth"]` |149| `_mcp_ai_incident_timeline` | array | Append-only timeline entries | See timeline entry structure below |150| `_mcp_ai_incident_resolved_at` | string | ISO 8601 when resolved (auto-set) | `"2026-08-15T16:30:00+00:00"` |151| `_mcp_ai_incident_lesson_id` | int | Linked `mcp_ai_lesson` post ID | `89` |152| `_mcp_ai_incident_notify_channels` | array | Notification channel IDs | `["email", "pagerduty"]` |153154**Timeline entry structure:**155```json156{157 "timestamp": 1723456789,158 "phase": "investigating",159 "message": "Database connection pool exhausted — traced to connection leak in cron worker.",160 "operator_id": 1161}162```163164**Phase transitions (valid):**165```166detected → investigating, resolved167investigating → identified, resolved168identified → monitoring, resolved169monitoring → resolved170resolved → (terminal)171```172173**Severity classification:**174175| Severity | When to use | Example |176|---|---|---|177| `minor` | Affects non-critical service, no user impact | Slow admin dashboard |178| `major` | Partial service degradation, workaround exists | API rate limiting, cache miss spike |179| `critical` | Complete service outage, no workaround | Site down, auth broken |180181## Available Tools182183All security ops operations use the **`toolkit_cpt`** MCP tool as the primary184interface for CRUD operations.185186### Discovery187188```189# List all available security ops post types190toolkit_cpt(action: "list_types")191192# Get field schema for any security ops type193toolkit_cpt(action: "get_schema", post_type: "mcp_ai_incident")194```195196### Reading records197198```json199// List recent audit events200{ "action": "list_items", "post_type": "mcp_ai_audit_event", "orderby": "date", "order": "DESC" }201202// Find active (non-resolved) incidents203{ "action": "list_items", "post_type": "mcp_ai_incident",204 "filters": [{ "key": "_mcp_ai_incident_phase", "value": "resolved", "compare": "!=" }] }205206// Get upcoming scheduled maintenance windows207{ "action": "list_items", "post_type": "mcp_ai_maintenance",208 "filters": [{ "key": "_mcp_ai_maintenance_status", "value": "scheduled" }] }209210// Search training modules211{ "action": "list_items", "post_type": "mcp_ai_training", "search": "ISO 27001" }212```213214### Creating records215216```json217// Create an incident with initial timeline218{ "action": "create_item", "post_type": "mcp_ai_incident",219 "fields": {220 "title": "API Gateway returning 503 errors",221 "_mcp_ai_incident_phase": "detected",222 "_mcp_ai_incident_severity": "critical",223 "_mcp_ai_incident_services": ["api", "gateway"],224 "_mcp_ai_incident_timeline": [{225 "timestamp": 1723456789, "phase": "detected",226 "message": "Health check monitor detected 503 responses from API gateway.", "operator_id": 0227 }],228 "_mcp_ai_incident_notify_channels": ["email", "slack"]229 }230}231232// Schedule a maintenance window233{ "action": "create_item", "post_type": "mcp_ai_maintenance",234 "fields": {235 "title": "Database upgrade to PostgreSQL 16",236 "content": "Upgrading primary database from v15 to v16. Expected downtime: 45 min.",237 "_mcp_ai_maintenance_status": "scheduled",238 "_mcp_ai_maintenance_start": "2026-08-20T02:00:00+00:00",239 "_mcp_ai_maintenance_end": "2026-08-20T04:00:00+00:00",240 "_mcp_ai_maintenance_services": ["database", "api"],241 "_mcp_ai_maintenance_notify_before": 60,242 "_mcp_ai_maintenance_banner_enabled": true243 }244}245246// Create a training module247{ "action": "create_item", "post_type": "mcp_ai_training",248 "fields": {249 "title": "Phishing Awareness 2026",250 "excerpt": "Learn to identify and report phishing attempts.",251 "_training_role": "all_users", "_training_type": "awareness",252 "_training_duration": 30, "_training_mandatory": "1"253 }254}255```256257### Updating records258259```json260// Transition an incident to investigating261{ "action": "update_item", "post_type": "mcp_ai_incident", "item_id": 12345,262 "fields": { "_mcp_ai_incident_phase": "investigating" } }263264// Resolve an incident with linked lesson265{ "action": "update_item", "post_type": "mcp_ai_incident", "item_id": 12345,266 "fields": { "_mcp_ai_incident_phase": "resolved", "_mcp_ai_incident_lesson_id": 89 } }267268// Cancel a maintenance window269{ "action": "update_item", "post_type": "mcp_ai_maintenance", "item_id": 678,270 "fields": { "_mcp_ai_maintenance_status": "cancelled" } }271```272273## Common Workflows274275### Incident response lifecycle276277```2781. Detection: create_item(mcp_ai_incident, phase: "detected", severity: <level>)279 → Timeline entry with initial observations.2802812. Investigation: update_item(mcp_ai_incident, phase: "investigating")282 → Check logs: wp mcp-ai log errors --limit=50283 → Check health: wp mcp-ai health284 → Add timeline entries with findings.2852863. Identification: update_item(mcp_ai_incident, phase: "identified")287 → Document root cause in timeline.288 → Assess scope — add affected services.2892904. Monitoring: update_item(mcp_ai_incident, phase: "monitoring")291 → Verify fix is holding.292 → Add timeline entries confirming stability.2932945. Resolution: update_item(mcp_ai_incident, phase: "resolved")295 → Create lessons learned post.296 → Link via _mcp_ai_incident_lesson_id.297 → Review audit events for contributing factors.298```299300### Maintenance window scheduling301302```3031. Check for conflicts:304 list_items(mcp_ai_maintenance, filters: [{key: "_mcp_ai_maintenance_status", value: "scheduled"}])305 → Verify no overlapping windows for the same services.3063072. Check active incidents:308 list_items(mcp_ai_incident, filters: [{key: "_mcp_ai_incident_phase", value: "resolved", compare: "!="}])309 → Critical incidents may require postponing maintenance.3103113. Create window:312 create_item(mcp_ai_maintenance, with start/end times, services, notification channels)313 → _mcp_ai_maintenance_notify_before controls reminder timing.3143154. Notify stakeholders:316 The system auto-sends reminders _mcp_ai_maintenance_notify_before minutes before start.317 → Verify channels in _mcp_ai_maintenance_notify_channels.3183195. During window:320 Status auto-transitions to "in_progress" at start time.321 → Monitor health: wp mcp-ai health3223236. After window:324 Status auto-transitions to "completed" at end time.325 → Verify all services healthy.326 → If issues: create incident linked to this maintenance window.327```328329### Audit review330331```3321. List audit events by step type:333 list_items(mcp_ai_audit_event, filters: [{key: "_wp_mcp_ai_audit_step_type", value: "tool_call"}])3343352. Trace a specific session:336 list_items(mcp_ai_audit_event, filters: [{key: "_wp_mcp_ai_audit_session_id", value: "sess_abc123"}],337 orderby: "date", order: "ASC")338 → The event chain is verifiable via _wp_mcp_ai_audit_event_hash → _wp_mcp_ai_audit_prev_hash.3393403. Review error events:341 list_items(mcp_ai_audit_event, filters: [{key: "_wp_mcp_ai_audit_status", value: "error"}])3423434. Cross-reference with WP-CLI logs:344 wp mcp-ai log activity --type=tool_execution345```346347### Training management348349```3501. Create training modules by role and type:351 create_item(mcp_ai_training, with _training_role, _training_type, _training_duration, _training_mandatory)3523532. Review compliance coverage:354 list_items(mcp_ai_training, filters: [{key: "_training_mandatory", value: "1"}])355 → Check that each role has required modules.3563573. Track completions:358 Training completion is stored in user meta (wp_mcp_ai_training_completions).359 → Use the admin Training Statistics page for reporting.360 → Use the `design-analytics-reporting` skill for compliance dashboards.3613624. Send reminders:363 Annual reminders run via wp_mcp_ai_annual_training_reminder cron hook.364```365366## Critical Rules367368- **Never delete audit events** — they are an immutable, cryptographically chained audit trail. Deletion breaks hash-chain integrity and violates compliance requirements.369- **Audit events are append-only** — use `create_item` only. Never `update_item` or `delete_item` on `mcp_ai_audit_event`.370- **Incident phase transitions are validated** — only specific transitions are allowed (see phase transition table above). Attempting invalid transitions will fail.371- **Incident severity must match impact** — `minor` = no user impact, `major` = partial degradation, `critical` = complete outage. Misclassifying severity skews response priority.372- **Maintenance windows auto-transition** — the system automatically moves `scheduled → in_progress` at start time and `in_progress → completed` at end time. Do not manually set these transitions unless the cron system is down.373- **Check for overlapping maintenance windows** — before scheduling, list existing scheduled windows for the same services to avoid conflicts.374- **Link incidents to lessons learned** — every resolved incident should have `_mcp_ai_incident_lesson_id` set. This builds organizational knowledge.375- **Timeline entries are append-only** — when updating incident phase, also append a new timeline entry with the reason for the transition.376- **Training role assignment drives compliance** — mandatory modules (`_training_mandatory: "1"`) assigned to `all_users` apply to every user. Use specific roles (`developer`, `administrator`) for targeted training.377- **Always use `get_schema` first** before creating or updating a record to verify available field keys and types.378379## Common Mistakes380381```382WRONG — deleting an audit event383{ "action": "delete_item", "post_type": "mcp_ai_audit_event", "item_id": 99999 }384// Audit events are immutable. This breaks the hash chain and violates compliance.385386RIGHT — audit events are never deleted387// There is no delete path for audit events. They are retained for the388// retention period configured in the audit trail system.389390WRONG — skipping incident phases391// Moving from "detected" directly to "resolved" with no investigation.392// The transition is not valid and will be rejected by the CPT.393394RIGHT — advance phase-by-phase with timeline entries3951. update_item: _mcp_ai_incident_phase: "investigating"396 + append timeline entry: "Began investigation, reviewing error logs."3972. update_item: _mcp_ai_incident_phase: "identified"398 + append timeline entry: "Root cause: connection pool exhaustion."3993. update_item: _mcp_ai_incident_phase: "monitoring"400 + append timeline entry: "Fix deployed, monitoring for 30 minutes."4014. update_item: _mcp_ai_incident_phase: "resolved"402 + set _mcp_ai_incident_lesson_id: <lesson_post_id>403404WRONG — scheduling maintenance during an active critical incident405// Creating a maintenance window while a critical incident (phase != resolved)406// impacts the same services. This risks compounding the outage.407408RIGHT — check for active incidents before scheduling4091. list_items(mcp_ai_incident, filters: [{key: "_mcp_ai_incident_phase", value: "resolved", compare: "!="}])4102. If critical incidents exist for overlapping services, postpone maintenance.411412WRONG — classifying a complete outage as "minor"413{ "_mcp_ai_incident_severity": "minor" }414// Site is down — this is "critical". Misclassification delays response.415416RIGHT — use the severity classification table417// minor: no user impact (e.g., slow admin dashboard)418// major: partial degradation with workaround (e.g., cache miss spike)419// critical: complete outage, no workaround (e.g., site down, auth broken)420421WRONG — manually setting maintenance status transitions422{ "_mcp_ai_maintenance_status": "completed" }423// When done manually before the scheduled end time, the auto-transition424// cron may re-fire and create a duplicate completed transition event.425426RIGHT — let the cron system handle auto-transitions427// Use update_item only for cancelling a window.428// The system auto-handles scheduled→in_progress and in_progress→completed.429430WRONG — creating a training module without a role assignment431{ "title": "GDPR Basics", "_training_type": "compliance" }432// Missing _training_role — the module has no audience.433434RIGHT — always assign a target role435{ "title": "GDPR Basics", "_training_role": "all_users", "_training_type": "compliance",436 "_training_duration": 20, "_training_mandatory": "1" }437```438439## Cross-References440441- Run `design-crm` to link security incidents to support tickets (`mcp_ai_ticket`) for customer-facing outage tracking.442- Run `design-pro-schedule-manager` to manage cron-based maintenance window transitions and training reminders.443- Run `design-pro-workflow-builder` to automate incident response workflows (auto-create incidents from health checks, auto-escalate based on severity).444- Run `wp-security-audit` to perform code-level security reviews — complements security ops at the compliance/operational layer.445- Run `wp-security-deep` for SSRF, deserialization, and advanced vulnerability checks that feed into incident creation.446- Run `wp-security-secrets` to audit hardcoded secrets — findings can be logged as `mcp_ai_audit_event` entries.447- Run `design-document-generation` to create incident post-mortem PDFs and training certificates.448- Run `design-analytics-reporting` to build compliance dashboards from training completion data and incident metrics.449450## What This Skill Does NOT Cover451452- Agent audit trail internals (hash chaining, cryptographic verification) — use `mcp_ai_audit_event` CPT via `toolkit_cpt` for reading; the audit trail system manages creation automatically.453- Health check service monitoring — the health check system auto-creates incidents via `wp_mcp_ai_service_status_changed` hook. This skill covers manual incident management.454- Security training completion tracking at the user level — use the admin Training Statistics page or query `wp_mcp_ai_training_completions` user meta directly.455- Lessons learned (`mcp_ai_lesson`) CPT management — use `toolkit_cpt` with `post_type: "mcp_ai_lesson"` for post-mortem records.456- Notification delivery (email, Slack, PagerDuty) — this skill covers the entity data; notification dispatch is handled by the system.457- Security posture scoring and Site Health integration — use the `wp-security-audit` skill and the `/wp-admin/site-health.php` dashboard.458- Access control and capabilities — managed via WordPress roles; training roles (`_training_role`) are for training assignment, not access control.459460## References461462- NV oOS Pro Toolkit Security Ops admin: `/wp-admin/admin.php?page=nvoos-pro-dashboard`463- Incidents admin page: `/wp-admin/edit.php?post_type=mcp_ai_incident`464- Maintenance admin page: `/wp-admin/edit.php?post_type=mcp_ai_maintenance`465- Security Training admin: `/wp-admin/admin.php?page=nvoos-security-training`466- `toolkit_cpt` MCP tool — the primary interface for all security ops operations.467- ISO 27001:2022 Control A.6.3 — Information Security Awareness, Education and Training.468- ISO 27001:2022 Control A.16.1 — Management of Information Security Incidents and Improvements.