6. Add Messaging

Add interactive message threads to your app

Threads are feeds consisting of linked and timestamped messages that enable decentralized peer-to-peer communication between one or more users by allowing these users to post messages in a sequence. Threads are great for adding commenting, chat, messaging, personal feeds, and content streams to your application. They are also great for sharing information between users.

Types of Threads

Threads are available as either persistent threads, where messages are available in a persistent OrbitDB feed store unless explicitly removed (by the author or a moderator), or ghost threads, where messages are not persisted in a database but whose history is kept in-memory by online peers and can be requested by new users. For ghost threads, if all peers go offline then messages disappear.

Use Cases for Persistent Threads

  • Commenting Systems

  • Reddit-like Forums

  • DAO Proposal Systems

  • Content Feeds

  • Personal Feeds

  • Public following or contact lists

  • Sharing data between users

Use Cases for Ghost Threads

  • Chat systems

  • Public Chatrooms

  • Disappearing messages

Getting Started with 3Box Threads

This section describes how to perform various interactive functionalities on a 3Box thread, including creating a new thread, joining a thread, posting messages to a thread, adding moderators, and more. To perform these actions, you must first authenticate the space.

If you only need to display public thread data for persistent threads, you can use the static read-only get methods described here.

Want to quickly get started with threads? Try 3Box Comments plugin!

We have created a 3Box comments plugin, which is the easiest way to add a persistent commenting section to your react application.

Explore the 3Box Comments Plugin

Jump to...