Page:
VOXMessage
Pages
Agent Lifecycle
Architecture Overview
Building Blocks
Capabilities Reference
Capability Contract
Capability Spec
Comm Gateway
Core Ontology
Creating an Agent
Filesystem Capability
Hierarchical Messaging Contract
Home
Messaging Contract
Orchestrator and Control Plane
Security Architecture
Segmented Persistence Forensic Traceability
VOXAgent
VOXApiServer
VOXCapability
VOXMessage
VOXOrchestrator
VOXRole
Versioning
War Room
WhatsApp Setup
No results
1
VOXMessage
jfabian edited this page 2026-08-13 11:15:47 -03:00
Table of Contents
VOXMessage
File: vox/messaging/models.py
The inter-agent envelope. All messages between agents follow this structure,
conforming to the Messaging Contract v1.0. VOXMessage is a frozen
pydantic.BaseModel (immutable) with UUID-typed identity fields.
class VOXMessage(BaseModel):
message_id: UUID # globally unique UUID
message_source: str # source of truth (e.g. interface name)
emitted_at: str # ISO-8601 datetime with timezone
source: UUID # UUID of the sender agent
target: UUID # UUID of the recipient agent
type: str # semantic intent
details: dict # event-specific variable payload
reply_to: UUID | None # UUID of the message this replies to
Model config: frozen=True (immutability), populate_by_name=True.
Message Types
The message type constants live in vox.messaging:
| Constant | Value | Direction | Purpose |
|---|---|---|---|
MSG_COMMAND_REQUEST |
"command_request" |
Parent → Child | Request execution of a named command |
MSG_ACKNOWLEDGED |
"message_acknowledged" |
Any → Any | Confirm receipt (auto-sent) |
MSG_COMMAND_RESULT |
"command_result" |
Child → Parent | Deliver execution result |
MSG_COMMAND_ERROR |
"command_error" |
Any → Any | Report delivery or execution failure |
Import
from vox.messaging import (
VOXMessage,
MSG_COMMAND_REQUEST, # "command_request"
MSG_ACKNOWLEDGED, # "message_acknowledged"
MSG_COMMAND_RESULT, # "command_result"
MSG_COMMAND_ERROR, # "command_error"
)
Where messages flow
Messages are routed through the orchestrator:
- Inbound (webhooks, capabilities):
orchestrator.dispatch_inbound_message( source=..., payload=...), wrapped to catchSecurityError(guardrail). The orchestrator sanitizes the payload and fans it out to the relevant agent viaagent.emit("inbound_message", source=..., **payload). - Events within an agent:
agent.emit(event_name, **kwargs)dispatches to role handlers (self.on(event_name)). - Delegation between agents follows the Hierarchical Messaging Contract.
The full message envelope specification, including event-specific payloads and logging contract, is documented in the Messaging Contract.
Overview
- Home
- Versioning
- Architecture Overview
- Building Blocks
Agent Model
- VOXAgent
- Agent Lifecycle
- VOXRole
- Creating an Agent
Capabilities
- VOXCapability
- Capabilities Reference
- Capability Contract
- Comm Gateway
- WhatsApp Setup
Messaging
- VOXMessage
- Messaging Contract
- Hierarchical Messaging Contract
- The War Room
Orchestrator & Control Plane
- VOXOrchestrator
- Orchestrator & Control Plane
- VOXApiServer
Persistence & Forensics
- Segmented Persistence & Forensic Traceability
Security & Governance
- Security Architecture
- Core Ontology (legacy)
- Capability Specification (legacy)
Status: v0.5.4