Skip to content

Latest commit

 

History

History
93 lines (62 loc) · 1.28 KB

File metadata and controls

93 lines (62 loc) · 1.28 KB

MENP Examples

This page contains safe public examples of common Mocha protocol flows.

These examples are intentionally illustrative rather than exhaustive. They are meant to explain the shape of the protocol, not to publish every private detail of authentication, routing, or service behavior.

Handshake example

Client:

VER <trid> MENP/1.0
CVR <trid> <client-identification>

Server:

VER <trid> OK MENP/1.0 Mocha Messenger Service
CVR <trid> OK Mocha Messenger

Sign-in example

Client:

USR <trid> <sign-in request>

Server:

USR <trid> OK <account state>

or

USR <trid> FAIL <error state>

Roster sync example

Client:

SYN <trid>

Server:

LST <trid> <contact> <payload>
LST <trid> <contact> <payload>
SYN <trid> OK <count>

Presence update example

Client:

CHG <trid> <status> <payload>

Server fanout:

NLN <account> <status> <payload>

Conversation routing example

Client:

XFR <trid> SB <target>

Server:

XFR <trid> SB <session routing information>

Media note

The current Mocha stack supports live audio and video behavior, but detailed transport and authentication internals are intentionally not published in this public examples page.