Skip to main content
← All documentation

Messages, threads and reactions

Core concepts

Messages are keyset-paginated by ULID in both directions. Pass before to walk backwards through history and after to catch up, and read hasMore rather than comparing the returned count to your limit.

curl "https://kemble.io/api/channels/$CHANNEL/messages?limit=50&before=$OLDEST_ID" \
  -H "authorization: Bearer $TOKEN"

Threads

A thread is rooted on a message. POST /api/messages/:message/thread starts one; replies are posted to the channel with the thread id attached. GET /api/threads/:thread returns the thread with its replies.

Reactions

  • POST /api/messages/:message/reactions with an emoji.
  • DELETE /api/messages/:message/reactions/:emoji removes your own.
  • GET /api/messages/:message/reactions lists each emoji with its count; add ?emoji= for the people behind one, fifty at a time (up to limit=100), and pass the returned nextCursor as ?after= for the next page.
  • DELETE /api/messages/:message/reactions/:emoji/users/:user removes one person’s reaction. Your own needs nothing more; anybody else’s needs message.delete_any in that channel, and the removal is written to the audit log.