SerenadaCore

class SerenadaCore(val config: SerenadaConfig, context: <Error class: unknown class>)

Main entry point for the Serenada SDK.

Create an instance with a SerenadaConfig, then use join to start a call session or createRoom to create a new room.

Constructors

Link copied to clipboard
constructor(config: SerenadaConfig, context: <Error class: unknown class>)

Types

Link copied to clipboard
object Companion

Properties

Link copied to clipboard

SDK configuration.

Link copied to clipboard

Callback delegate for session lifecycle events.

Link copied to clipboard

Logger instance for debug output.

Functions

Link copied to clipboard

Create a new room. Returns the room URL and ID. Call join to start the call.

Link copied to clipboard
suspend fun createRoomId(): String

Create a room ID without starting a session. Use this when you only need a room ID (e.g., for invite links).

Link copied to clipboard

Drops any persisted recovery record. Call this when the user explicitly declines the rejoin prompt so subsequent launches do not keep offering the same dead session.

Link copied to clipboard

Returns a recoverable session if the previous process ended abruptly (kill, OS LMK, crash) while a call was active and the persisted reconnect token is still within its TTL. Host apps should call this on launch and surface a "Rejoin call?" prompt — calling join with the returned roomId reattaches under the same CID.

Link copied to clipboard
fun join(url: String, displayName: String? = null, peerId: String? = null): SerenadaSession

Join a call using a full URL (e.g., "https://serenada.app/call/ABC123").

fun join(roomId: String, serverHost: String? = resolvedConfig.serverHost, displayName: String? = null, peerId: String? = null): SerenadaSession

Join a call using a room ID.