Skip to content

Instantly share code, notes, and snippets.

@ge0rg
Last active September 10, 2019 12:11
Show Gist options
  • Save ge0rg/a255cb521e45bbcb89573aa3218f0cd5 to your computer and use it in GitHub Desktop.
Save ge0rg/a255cb521e45bbcb89573aa3218f0cd5 to your computer and use it in GitHub Desktop.

Types of XMPP "References"

  • Thread (in-reply-to); largely off-scope for our discussion
  • References of things mentioned in the payload/body of a message (0372)
    • nicknames, URLs, old messages by means of xmpp: URI, etc.
    • multiple Reference elements are allowed
    • Can be used inside Attach-To to add References to a previous message
    • Can be sent by anyone
    • is irrelevant to MAM 2.0
  • Attach-To for content that only makes sense in the context of another message
    • Usable for Reactions, Edits (former LMC), Retraction, Image / website previews, Receipts(?), Read Markers(?)
    • A message can be attached at-most to one other message (nobody could think of a case where it would be needed, Ge0rG still objects)
    • allows grouping / special handling by MAM 2.0, e.g. for thin clients
    • generally, the attached payload SHOULD be inside of the element (e.g. reactions)
    • for E2EE and legacy Last Message Correction, an without a payload implies that the sibling elements need to be reviewed
    • Some kinds of Attach-To can only be sent by the original author or a privileged entity (bot/admin in MUCs)
    • Attach-To messages SHOULD NOT be nested, i.e. attach-to another Attach-To message
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment