Skip to content

feat(headless): capabilities for the daemon and CLI - #4215

Merged
jcbrand merged 22 commits into
masterfrom
headless-from-daemon
Nov 3, 2026
Merged

jcbrand merged 22 commits into
masterfrom
headless-from-daemon

Conversation

@jcbrand

@jcbrand jcbrand commented Nov 2, 2026

Copy link
Copy Markdown
Member

The headless capabilities that @converse/daemon and @converse/cli (#4200) need, split out so they can land on their own. None of them are daemon-specific, so the web UI can use them too.

New in headless

  • api.contacts.resolve: resolve a name to roster contacts
  • api.rooms.discover: list the rooms a MUC service hosts, following XEP-0059 paging
  • sendMessage options to reply to, or correct, a given message
  • api.reactions.send: send XEP-0444 reactions, encrypted when the chat uses OMEMO
  • api.archive.search: XEP-0431 full-text search of the server archive. Matches are held in their conversations, with placeholders for the history around them that isn't fetched yet.
  • fetchArchivedMessages returns the archive query's answer
  • Message.getArchiveID and Message.getReferenceID

Fixes

  • Chats no longer hang on servers without XEP-0191
  • afterMessageCreated listeners after the reactions plugin get the message
  • A resent message that fails again keeps its new failure
  • Disco entity and resource session stores are keyed by account
  • A contact goes offline when an unknown resource goes unavailable
  • api.rooms.open with a list of JIDs no longer throws a ReferenceError
  • A moderated message is found when the room's history has a gap
  • Name resolution doesn't match or name a contact by its JID
  • sendMessage refuses to correct a message that isn't an editable one of ours

Known gap

An archive search leaves a room's private messages out, because there's no correct place to hold them yet. They used to land in a 1:1 chat with the room's JID. Holding them in the occupant's chat is follow-up work.

sendMessage can now be told which message it replies to or corrects,
instead of only taking that from the chat's UI state.
Sending XEP-0444 reactions moves from the web UI into headless, so that
clients other than the web UI can react to messages.
@jcbrand
jcbrand force-pushed the headless-from-daemon branch from cfc87c7 to 73f6f13 Compare November 3, 2026 06:21
@jcbrand
jcbrand merged commit ff63a90 into master Nov 3, 2026
5 checks passed
@jcbrand
jcbrand deleted the headless-from-daemon branch November 3, 2026 06:38
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant