Skip to main content

Documentation Index

Fetch the complete documentation index at: https://docs.neuro-tech.io/llms.txt

Use this file to discover all available pages before exploring further.

The Messaging endpoints expose XMPP messaging features over HTTP — no persistent XMPP connection required. Use these endpoints to send chat messages, manage presence subscriptions, maintain your contact roster, and retrieve queued messages. All endpoints require a valid JWT bearer token. Messages are sent and received as XMPP stanzas via the authenticated account.

Endpoints

EndpointDescription
Send text messageSend a plain text chat message to an XMPP recipient.
Send formatted messageSend a rich/formatted XMPP message (e.g. with XML content).
Send presence subscriptionRequest a presence subscription from a contact.
Send presence unsubscriptionCancel an existing presence subscription.
Send subscription acceptedAccept an incoming presence subscription request.
Send subscription declinedDecline an incoming presence subscription request.
Presence probeProbe the presence of a contact to retrieve their current status and full JID.
Get rosterRetrieve the full contact roster for the authenticated account.
Get roster itemRetrieve a single contact entry from the roster.
Set roster itemAdd or update a contact in the roster.
Remove roster itemRemove a contact from the roster.
Clear messagesDelete queued offline messages stored on the broker.
Pop messagesRetrieve and remove queued messages from the broker (up to a specified count).
Information querySend an XMPP IQ (get or set) to a contact using their full JID.
Register event handlerRegister (or unregister) a client-side event handler for incoming XMPP messages of a given type, namespace, or local name.

Message retrieval

The Neuron broker queues messages for accounts that are not actively polling. Use Pop messages to retrieve queued messages and remove them from the server in one call. Use Clear messages to discard queued messages without reading them. For real-time push delivery, Register event handler lets you bind a JavaScript function to incoming message types via the /Events.js mechanism.

Presence and roster

Before you can probe a contact’s presence or send them an IQ, you need a mutual presence subscription. The typical flow:
  1. Call Send presence subscription to request access.
  2. The contact accepts — call Send subscription accepted on your end.
  3. Call Presence probe to get their full JID for IQ queries.