MOON
Internals
Crate path, key types, adjacent protocols for MOON.
MOON (Multi-Agentic Organizational & Operational Nexus) lives in protocols/moon-lib. This page covers where to find the implementation, the key Rust types, and how it composes with adjacent protocols.
Source
| Path | Contains |
|---|---|
protocols/moon-lib/src/lib.rs | ProtocolModule impl, operation dispatch |
protocols/moon-lib/src/protocol.rs | core protocol logic |
protocols/moon-lib/src/types.rs | request/response types (derive schemars::JsonSchema) |
protocols/moon-lib/tests/ | unit + integration tests |
schemas/moon/v1/ | published JSON Schemas |
ProtocolModule contract
impl ProtocolModule for MoonProtocol {
fn protocol_name(&self) -> &'static str { "MOON" }
fn version(&self) -> &'static str { "v1.0.0" }
fn operations(&self) -> Vec<&'static str> {
vec![
"submit_manifest",
"execute_workflow",
"workflow_status",
"agent_deployment_status",
"scale_deployment",
"update_manifest",
]
}
async fn invoke(&self, op: &str, payload: Value, ctx: &InvokeContext)
-> Result<Response, ProtocolError>
{
match op {
"submit_manifest" => self.submit_manifest(payload, ctx).await,
"execute_workflow" => self.execute_workflow(payload, ctx).await,
"workflow_status" => self.workflow_status(payload, ctx).await,
"agent_deployment_status" => self.agent_deployment_status(payload, ctx).await,
"scale_deployment" => self.scale_deployment(payload, ctx).await,
"update_manifest" => self.update_manifest(payload, ctx).await,
_ => Err(ProtocolError::UnknownOperation(op.into())),
}
}
}Adjacent
| Relation | Members |
|---|---|
| Consults | — |
| Records to | MAX · MOTET · MOMENT |
| Subject to | MAXIM · MOAT (cross-org) · MOOT (disputes) |
| Settled with | MEAL · MANA · MADE |
Status
Implemented · production-grade.
Tests
cargo test -p moon-lib --all-featuresSee also
ProtocolModuletrait — the contract- Engine pipeline — the 8 stages
- Plugins — author your own