-
Notifications
You must be signed in to change notification settings - Fork 0
Relay
src/relay/ owns the connector contract used when an external platform
connector talks to a gateway instead of running as a direct in-process provider.
CapabilityDescriptor is the handshake payload that describes a connector:
contract_versionplatformlabelmax_message_lengthsupports_draft_streamingsupports_editsupports_threadsmarkdown_dialectlen_unitemojiplatform_hintpii_safe
RelayPlatformEntry mirrors the platform metadata needed to build a descriptor.
RelayDescriptorOptions supplies live adapter capability bits.
Gateway-to-connector frames:
hellooutboundinterruptgoing_idleinbound_ack
Connector-to-gateway frames:
descriptorinboundoutbound_resultinterrupt_inboundgoing_idle_ackpassthrough_forward
Inbound and passthrough frames can carry a bufferId. The frame helpers can
derive the matching inbound acknowledgement. Authenticated inbound events strip
forged relay-trust fields from untrusted payloads before marking the event as
delivered through an authenticated relay.
relay_send_action_from_outbound_intent projects a normalized
ChannelOutboundIntent into the relay send action:
-
chat_idcomes fromconversation_id -
contentis derived from the outbound payload -
reply_tocarries reply linkage - metadata carries idempotency, channel, conversation, durability, thread, and non-text payload details
The relay auth module provides signed token and delivery payload helpers:
- upgrade token creation and verification
- delivery signature creation and verification
- timestamp skew and TTL defaults
- stable header names for delivery signatures and timestamps
The transport module defines the reconnectable frame I/O boundary:
RelayFrameIoRelayFrameDialerRelayTransportRelayReconnectPolicy- inbound, interrupt, and passthrough handlers
The relay-websocket feature enables the WebSocket transport module and exports
the WebSocket dialer/config helpers.
Relay code should not know OpenHuman runtime internals. It should authenticate, parse frames, normalize inbound events, project outbound intents, and delegate host-owned behavior through the same channel contracts as direct providers.
Channel and messaging contracts for OpenHuman.
Getting started
Concepts
Modules
Contributing