13. Node Interfaces (fleetmesh_node.interfaces)
The fleetmesh_node.interfaces module provides abstract base protocols and type contracts
shared across the Meshnode codebase.
13.1. Interfaces Reference
Formal interfaces, protocols, and data contracts for meshnode.
Standard library only. All wire types reflect the normative JSON Schemas in schemas/ and the protocol invariants verified in fleetmesh_core/.
- class fleetmesh_node.interfaces.DeliveryEnvelope[source]
Bases:
TypedDict- event: NostrEvent
- path: list[DeliveryHop]
- class fleetmesh_node.interfaces.GrantPayload[source]
Bases:
TypedDict- scope: GrantScope | Mapping[str, Any]
- class fleetmesh_node.interfaces.GrantScope[source]
Bases:
TypedDict- push: NostrFilter
- pull: NostrFilter
- class fleetmesh_node.interfaces.DIDCommAttachment[source]
Bases:
TypedDict- data: DIDCommAttachmentData
- class fleetmesh_node.interfaces.DIDCommMessage
Bases:
TypedDict- attachments: list[DIDCommAttachment]
- class fleetmesh_node.interfaces.HealthStatusDict[source]
Bases:
TypedDict- relays: Mapping[str, RelayHealthRow]
- receipts_refused: list[ReceiptRefusedRow]
- awaiting_ack: list[AwaitingAckRow]
- throttled: list[ThrottledRow]
- grants: list[GrantStatusRow]
- evaluations: list[EvaluationRow]
- repriced: list[RepricedRow]
- class fleetmesh_node.interfaces.NodeStatusDict
Bases:
TypedDict- visibility: VisibilityState
- grants: list[GrantStatusRow]
- pending_grants: list[PendingGrantRow]
- evaluations: list[EvaluationRow]
- repriced: list[RepricedRow]
- health: HealthStatusDict
- class fleetmesh_node.interfaces.CommandSpec[source]
Bases:
TypedDictOne control-socket command as the socket documents it under commands: the dispatch table is the documentation, so it cannot drift from it.
- class fleetmesh_node.interfaces.KeyStoreProtocol[source]
Bases:
ProtocolThe node keys and identity.
- __init__(*args, **kwargs)
- class fleetmesh_node.interfaces.TransportProtocol[source]
Bases:
ProtocolThe transport adapter interface: sends and receives DIDComm envelopes.
- __init__(*args, **kwargs)
- class fleetmesh_node.interfaces.EventStoreProtocol[source]
Bases:
ProtocolStorage for Nostr events and provenance.
- insert_event(event)[source]
- Parameters:
event (NostrEvent)
- Return type:
- get_event(event_id)[source]
- Parameters:
event_id (str)
- Return type:
NostrEvent | None
- __init__(*args, **kwargs)
- class fleetmesh_node.interfaces.CompartmentProtocol[source]
Bases:
ProtocolA compartment of the node, assembled and ticked uniformly.
- commands: Mapping[str, CommandSpec]
- __init__(*args, **kwargs)
- class fleetmesh_node.interfaces.ProtocolHealth[source]
Bases:
objectOperational telemetry and status of a protocol package.
- class fleetmesh_node.interfaces.RouteMatch[source]
Bases:
objectA matched HTTP or WebSocket route handler.
- class fleetmesh_node.interfaces.ProtocolHostRouter[source]
Bases:
ProtocolUnified HTTP / WebSocket multiplexer mounted on the node’s public port.
- __init__(*args, **kwargs)
- class fleetmesh_node.interfaces.ProtocolIdentityAdapter[source]
Bases:
ProtocolTranslates between Fleetmesh keys and foreign protocol identity models.
- __init__(*args, **kwargs)
- class fleetmesh_node.interfaces.ProtocolPackage[source]
Bases:
ProtocolThe formal interface implemented by every pluggable protocol package.
- identity_adapter(keystore)[source]
Return the identity and cryptographic adapter for this protocol family.
The node does not call this yet: packages build and use their adapters themselves, and nothing resolves an identity across packages. It is kept as the extension point for that, not as a contract anything exercises - an implementation is tested by its own suite, not by a running node (audit 2026-10-15). storage_adapter beside it was removed: every package already receives its stores in its constructor.
- Parameters:
keystore (Any)
- Return type:
ProtocolIdentityAdapter | None
- mount_ingress(host)[source]
Register HTTP and WebSocket route handlers onto the shared public host face.
- Parameters:
host (ProtocolHostRouter)
- Return type:
None
- transport_rung(context)[source]
Return an outbound TransportProtocol rung for TransportRouter, if supported.
- descriptor_capabilities()[source]
Return protocol capability tags (e.g. (‘c’, ‘https://example.org/atproto/…’)) for kind 11801.
- __init__(*args, **kwargs)