Skip to content
OpenAgentSkill
Browsing is open · Catalog captured 2026-11-21 · Automatic updates and account services are paused.
Design & UI

cometchat-android-v5-calls

CometChat Calls SDK v5 integration for native Android (V5 stable, Java + Kotlin Views). Covers SDK setup (Cloudsmith Maven, CallAppSettings, init), the dual-SDK ringing pattern (Chat SDK initiateCall + Calls SDK joinSession), session settings, event listeners, call logs, recording, screen sharing, picture-in-picture, foreground service for ongoing calls, VoIP push via FCM + ConnectionService, audio/video/participant controls, custom UI, and in-call chat. Use in standalone mode (calls is the product) or additive mode (calls layered on top of an existing CometChat Android v5 chat integration).

cometchat · AI review on file

Installation

Read the source and dependencies before running a command. Copying does not install or execute anything.

npx skills add cometchat/cometchat-skills --skill cometchat-android-v5-calls

About this skill


name: cometchat-android-v5-calls description: CometChat Calls SDK v5 integration for native Android (V5 stable, Java + Kotlin Views). Covers SDK setup (Cloudsmith Maven, CallAppSettings, init), the dual-SDK ringing pattern (Chat SDK initiateCall + Calls SDK joinSession), session settings, event listeners, call logs, recording, screen sharing, picture-in-picture, foreground service for ongoing calls, VoIP push via FCM + ConnectionService, audio/video/participant controls, custom UI, and in-call chat. Use in standalone mode (calls is the product) or additive mode (calls layered on top of an existing CometChat Android v5 chat integration). license: "MIT" compatibility: "Android Studio Hedgehog+, JDK 17, Gradle 8+, AGP 8+, minSdk 26+, compileSdk 35; com.cometchat:calls-sdk-android:5.x; com.cometchat:chat-sdk-android:4.x (when ringing)" metadata: author: "CometChat" version: "4.0.0" tags: "cometchat android v5 calls voice video webrtc kotlin java cloudsmith callappsettings session-settings call-logs recording screen-sharing pip foreground-service voip fcm connectionservice"

Purpose

Production-grade voice + video calling for native Android v5. Loaded by the cometchat-calls dispatcher when the project is Android v5 (detected from chat-sdk-android:4.x / chatuikit-android:5.x or asked when greenfield). Operates in two modes:

  • Standalone — calls is the product. No chatuikit-android UI Kit; just chat-sdk-android (for signaling) + calls-sdk-android + your own UI surfaces (CallButton on profile, CallLogsActivity, OngoingCallActivity).
  • Additive — calls layered onto an existing v5 chat integration. The kit's CometChatMessageHeader already exposes call buttons; this skill wires them to the Calls SDK and mounts the global IncomingCall listener at app root.

Read these other skills first:

  • cometchat-calls — the dispatcher (mode selection, hard rules, anti-patterns)
  • cometchat-android-v5-core — Chat SDK init, login order, local.properties + BuildConfig credential conventions, Application class wiring

Ground truth:

  • SDK source — calls-sdk-android-5/sdk/
  • Sample app — calls-sdk-android-5/samples/
  • Pre-authored topic docs — references/ in this skill (16 docs, ~2300 lines, audited against calls-sdk-android@5.0.x (v5 GA))
  • Public docs — https://www.cometchat.com/docs/calls/android/overview

How to use this skill

This SKILL.md is the index + hard rules + Android-specific gotchas. Deep topic content lives in references/. Always read this file end-to-end first; load references on demand.

TopicReference fileWhen to load
SDK setup (Cloudsmith, init, permissions, Jetifier)references/setup.mdStep 1 of every integration
Joining a session (SessionSettingsBuilder, voice vs video)references/join-session.mdStep 2 — every integration
Dual-SDK ringing (Chat SDK + Calls SDK together)references/ringing-integration.mdStandalone or additive — every integration with peer-to-peer call flow
All SessionSettingsBuilder options (layouts, mode, hide buttons)references/session-settings.mdWhen customizing in-call UI behavior
Event listeners (status, participant, media, button-click, layout)references/event-listeners.mdWhen wiring call lifecycle to app state
Call history listreferences/call-logs.mdWhen adding /calls route or in-app history
Recording (auto-start, recording events)references/recording.mdFeature add
Screen sharing (viewer + presenter status)references/screen-sharing.mdFeature add
Picture-in-picturereferences/picture-in-picture.mdFeature add
Foreground service for ongoing callsreferences/background-handling.mdRequired — every standalone integration on Android 14+
VoIP push (ConnectionService + FCM high-priority + PhoneAccount)references/voip-calling.mdRequired — every standalone integration; optional but strongly recommended in additive
Audio controls (mute/unmute, device switching)references/audio-controls.mdDefault UI customization
Video controls (camera on/off, switch camera)references/video-controls.mdDefault UI customization
Participant management (mute/kick/raise hand)references/participant-management.mdGroup calls / moderator features
Custom UI (control panel, participant list, layout)references/custom-ui.mdWhen the default UI doesn't fit
In-call chat (messaging during active session)references/in-call-chat.mdFeature add

references/README.md is a skim-friendly index of the same.


1. The seven hard rules

These are the production-grade non-negotiables from the cometchat-calls dispatcher, specialized for Android v5. Every integration this skill writes must satisfy all seven.

1.0 Calls SDK login is its own step (v5+)

The v5 Calls SDK has its own auth state, separate from the Chat SDK. After CometChat.login(uid, AUTH_KEY) succeeds, you MUST also call CometChatCalls.login(uid, AUTH_KEY, ...) — without it, the FIRST calls API call (initiateCall, joinSession, generateToken) throws "auth token cannot be null".

import com.cometchat.calls.core.CometChatCalls
import com.cometchat.calls.exceptions.CometChatException as CallsException
import com.cometchat.calls.model.CallUser   // ← callback type, NOT chat User

// ✓ RIGHT — chat login first, then calls login
CometChat.login(uid, AUTH_KEY, object : CometChat.CallbackListener<User>() {
  override fun onSuccess(user: User) {
    CometChatCalls.login(uid, AUTH_KEY,
      object : CometChatCalls.CallbackListener<CallUser>() {
        override fun onSuccess(callUser: CallUser) { /* both ready */ }
        override fun onError(e: CallsException) { /* surface */ }
      })
  }
  override fun onError(e: CometChatException) { /* surface */ }
})

Surprises:

  • The chat-side User object does NOT expose `authTok
Read the complete source ↗