Real-Time Messaging SDK for Seamless Communication

Real-time messaging (RTM) has become an integral part of modern communication, enabling seamless and instantaneous interactions between individuals and groups. Sariska's Real-Time Messaging API provides a powerful and versatile platform for incorporating RTM capabilities into your applications and systems.

At the core of Sariska RTM is the utilization of the Erlang programming language, renowned for its concurrency model, process isolation, and fault-tolerant design. Erlang's capabilities make it an ideal foundation for real-time messaging systems, ensuring high availability and reliability even in the face of unexpected failures. Erlang's process isolation strengthens the system's resilience by preventing the failure of one component from affecting others. Additionally, Erlang's unique hot reload capabilities allow for seamless updates and modifications to the system without interruption, ensuring continuous operation.

Sariska RTM's architecture is not only robust but also distributed, allowing for scalable and efficient communication across a network of interconnected nodes. This distributed nature enhances its ability to handle large volumes of traffic seamlessly.

Key Features

  • Real-time communication: Deliver messages to users in real time, fostering continuous engagement and interaction.

  • Scalable architecture: Handle millions of connected clients simultaneously, ensuring seamless communication even at large scale.

  • Flexible channel management: Create and manage channels to organize and categorize messages effectively.

  • Multi-platform support: Integrate RTM functionality into web, mobile, and game development environments.

One of the standout features of Sariska RTM is its integration with Phoenix Channels. Phoenix, built on top of the Erlang ecosystem, leverages the power of Erlang's concurrency, process isolation, and fault-tolerance to facilitate soft real-time communication among millions of connected clients. This makes Phoenix Channels an essential component of Sariska RTM, enabling the efficient and scalable exchange of messages between users and applications.

Use Cases

Sariska's Real-Time Messaging API caters to a wide range of applications, including:

  • Chat rooms and messaging apps: Build real-time chat features for personal and professional communication.

  • Breaking news and alerts: Deliver real-time notifications for urgent updates and critical events.

  • Real-time tracking: Monitor the movement of objects, vehicles, or participants in real time.

  • Multiplayer game interactions: Facilitate real-time communication and synchronization in multiplayer games.

  • IoT device monitoring and control: Receive real-time sensor data and send control commands to IoT devices.

  • Browser notifications: Notify users of page updates or changes in web applications.

API Structure and Terminology


Channels are a way to organize and manage real-time communication between clients and a server in Socket.IO. They allow you to send and receive events to specific groups of clients, and they can be used to create a variety of applications, such as chat rooms, multiplayer games, and collaborative editing tools.

Channel Prefix

Each channel name starts with a prefix that determines the message serialization format and persistence behavior.

chat: Use this prefix for persisting messages to the database. This prefix requires a fixed schema and is ideal for chat applications.

 channel = socket.channel("chat:room123");

rtc: Use this prefix for scenarios where message persistence is not necessary. This prefix allows sending arbitrary JSON data, making it suitable for events in multiplayer games, IoT applications, and others.

channel = socket.channel("rtc:room123");

sariska: Use this prefix for performance-critical applications that utilize Flatbuffers as the serialization format and do not require message persistence. This prefix provides zero-copy serialization/deserialization, significantly enhancing performance.

channel = socket.channel("sariska:room123");

API Endpoints

Establishing a Socket Connection

To establish a socket connection for real-time messaging, use the following URL:


Connection with Flatbuffers as a Serializer

For performance-critical applications, consider using Flatbuffers, which offers near-zero serialization/deserialization time compared to JSON on both the device and server ends. Flatbuffers is particularly well-suited for use with mmap (or streaming), as it requires only a portion of the buffer to be in memory. Access speed is comparable to raw struct access, with only one additional indirection (a Vtable) to accommodate format evolution and optional fields. For more details, refer to the Flatbuffers documentation.

To establish a connection for real-time messaging (RTM) with Flatbuffers enabled, use the following URL:


Implement proper error handling and security measures when establishing connections, especially for high-performance applications.

Platform Support

Sariska's real-time messaging SDK offers versatile cross-platform communication across browsers, Android, iOS, Mac, Windows, Linux, and gaming consoles.

  • Server-side Phoenix Channel Implementations: Server-side implementations for Phoenix channels facilitate seamless message exchange from the server.

  • Unity Integration: Integration with the Unity game engine enables bidirectional messaging within Unity's cross-platform environment.

  • Godot Integration: Integration with the Godot game engine ensures bidirectional messaging within Godot's open-source ecosystem.

Last updated