Cometchat Ios Calls logo

Cometchat Ios Calls

Organization
cometchat
cometchat-ios-calls

Add voice and video calling to an iOS CometChat app — call buttons, incoming/ongoing call screens, call logs, and CallKit ringing. Triggers: 'add video calling ios', 'cometchat voice call swift', 'incoming call screen ios', 'call logs cometchat ios'.

Overview

Publishercometchat
Repositorycometchat-skills
Skill namecometchat-ios-calls
Stars
109
Forks
2
Bundled files
Instructions only
LicenseMIT
Links
  • Markdown instructions

    A SKILL.md file the model loads on demand, so it only costs tokens when a request actually matches.

  • Works with any LLM

    AI skills are plain Markdown, not provider-specific code, so this works with GPT, Claude, Gemini, Grok, or a local model.

  • Self-contained

    Everything the model needs lives in the instructions — no extra files to sync.

  • Open source

    Published by cometchat on GitHub. Read the source before you install it.

Installation

Install the Cometchat Ios Calls AI skill in TypingMind to use it with any LLM, or drop it into another agent that reads SKILL.md.

1

Install in TypingMind

TypingMind installs a skill straight from its GitHub folder — it reads SKILL.md, bundles the resource files, and stores the result locally.

  1. Open the app and go to Plugins → Skills.
  2. Choose "Install from GitHub".
  3. Paste the skill folder URL below and confirm.
  4. Enable the skill in any chat where you want it available.
Plugins → Skills → Add skill → From GitHub URL, then paste the folder URL and press Continue.
2

Install in another agent

Any agent that reads the Agent Skills format can use this skill — copy the folder into that agent's skills directory.

Claude Code — .claude/skills
git clone --depth 1 https://github.com/cometchat/cometchat-skills.git /tmp/cometchat-skills
mkdir -p .claude/skills
cp -r /tmp/cometchat-skills/skills/cometchat-ios-calls .claude/skills/cometchat-ios-calls
Restart Claude Code after copying so it picks up the new skill.

Use it in TypingMind

Enable Cometchat Ios Calls in any TypingMind chat and the model takes it from there. Its name and description sit in the system prompt, and the moment a request matches, the model loads the full instructions itself — you never invoke it by hand, and it costs no tokens until it is actually used.

The model loads Cometchat Ios Calls on its own as soon as a request matches it.

Works with any AI model

AI skills are plain Markdown instructions rather than provider-specific code, so Cometchat Ios Calls is not tied to the model it was written for. Install it once in TypingMind and use it with GPT-5, Claude, Gemini, Grok, DeepSeek, Mistral, Llama, or a local model you run yourself — all on your own API keys.

  • Loaded only when it is needed

    The system prompt carries just the name and description. The instructions are fetched on the first matching request, so an idle skill costs nothing.

  • Switch models mid-chat

    Because the skill is instructions rather than code, changing model does not break it — the next model reads the same SKILL.md.

Skill instructions

This is the SKILL.md content the model loads. Read it before installing — a skill is instructions your model will follow.

Companion skills (read first)

  • cometchat-ios-core owns setup and the chat surface. This skill ADDS calling. Note core ALREADY links CometChatCallsSDK at exactly 5.0.3 — on 5.1.22 (as since 5.1.19) the kit's interface imports it, so it is required even for chat-only builds. Do not add it twice or at a different version.

Use this skill when

"add voice/video calling", "show an incoming call screen", "add call history".

Calls has its OWN login — the UI Kit's login is not enough

CometChatUIKit.login(uid:) does NOT authenticate the Calls SDK. Built without the bootstrap below, CometChatCallLogs shows "Oops! Looks like something went wrong" — its request goes out with an EMPTY authToken (measured on 5.1.19/5.0.3). No error points at the cause. After the UI Kit login succeeds, run:

swift
// DEFAULT — the ai-agent / telemetry-attributed init (persists integrationSource="ai-agent").
// Takes NO settings argument: it reads the SAME bundled cometchat-settings.json the core skill
// already ships (Copy Bundle Resources) — do not build a second settings object.
_ = CometChatCalls.initFromSettings(onSuccess: { _ in
    guard let token = CometChat.getUserAuthToken() else { return }
    CometChatCalls.login(authToken: token,
                         onSuccess: { _ in /* calls surfaces are now live */ },
                         onError:   { error in debugPrint("calls login:", error.errorDescription) })
}, onError: { error in debugPrint("calls init:", error?.errorDescription ?? "nil") })

⚠️ Init the Calls SDK via CometChatCalls.initFromSettings, NOT the classic CometChatCalls(callsAppSettings: CallAppSettingsBuilder()…) builder — that path attributes the app to "manual" and loses the ai-agent telemetry (RULES §5 / AUDIT-175, the SAME rule the headless cometchat-ios-v5-sdk follows). The builder init is the FALLBACK ONLY, for an app that does not bundle cometchat-settings.json:

swift
// FALLBACK — only when no cometchat-settings.json is bundled. Loses ai-agent attribution.
let callSettings = CallAppSettingsBuilder().set(appID: appID).set(region: region).build()
_ = CometChatCalls(callsAppSettings: callSettings, onSuccess: { _ in /* … login as above … */ },
                   onError: { error in debugPrint("calls init:", error?.errorDescription ?? "nil") })

Never do both — a builder init AFTER initFromSettings re-attributes the app to "manual". initFromSettings fails SETTINGS_FILE_NOT_FOUND if the file is not in Copy Bundle Resources — the core skill already adds it for chat, so a UI-Kit app that shipped chat first already satisfies this.

The docs' calling-integration page says linking the SDK is enough; it is not — that gap is logged for the docs. Chat-only apps skip all of this (they link the Calls SDK purely to satisfy 5.1.19's import — see the core skill's install notes).

The five components

ComponentRole
CometChatCallButtonsVoice/video triggers. Has NO no-arg init — construct it as CometChatCallButtons(width:height:). set(user:) or set(group:), plus set(controller:). Put it in the message header's slot, not beside it.
CometChatIncomingCallThe ringing screen. set(call:), set(onAcceptClick:), set(onCancelClick:)decline is onCancelClick, there is no onDeclineClick.
CometChatOngoingCallThe in-call surface. set(sessionId:)lowercase d; set(sessionID:) does not compile. Also set(callSettingsBuilder:), set(callWorkFlow:).
CometChatOutgoingCallThe caller's ringing screen while the other side has not answered. set(call:), set(onCancelClick:).
CometChatCallLogsCall history. See the Any warning below — this component is the worst offender.

CometChatCallLogs callbacks are Any-typed — cast before touching anything. Unlike every other list component, five of its setters hand back untyped values and will not compile if you use them directly: set(onItemClick:)(_ callLog: Any) · set(onCallButtonClicked:)(Any) · set(options:)(_ callLog: Any) · set(onLoad:)([Any]) · set(onError:)(_ error: Any), not CometChatException like everywhere else.

swift
logs.set(onItemClick: { callLog in
    guard let log = callLog as? CallLog else { return }   // NOT `as? Call` — that cast FAILS at
// runtime and makes the tap a silent no-op (measured: RUNTIME TYPE = CallLog).
    // CallLog exposes status, type, mode, initiator, receiver — not the Call spellings
    // (callStatus/callType/callInitiator/callReceiver). CallLog is a Calls-SDK type.
})
logs.set(onError: { error in
    // The value is the CALLS SDK's exception type — casting to the chat SDK's
    // CometChatException fails and prints nothing useful (measured).
    debugPrint((error as? CometChatCallException)?.errorDescription ?? "\(error)")
})

sessionID vs sessionId — the same concept, spelled two ways. The SDK's Call exposes sessionID (capital), while the kit's CometChatOngoingCall takes set(sessionId:) (lowercase). Reading a log and starting a call in the same function means using both spellings; neither compiles in the other's place.

Voice/video click handlers on CometChatCallButtons are properties: callButtons.onVoiceCallClick = { user, group in … }, onVideoCallClick likewise. And it is set(callSettingsBuilder:)plural "Settings".

@MainActor if you construct these in a factory. Inside a UIViewController this wiring is free (already main-actor). But if you wrap it in a standalone factory/enum/static method, mark that context @MainActor — the components' setters are main-actor-isolated. CometChatOutgoingCall is the strictest: unlike CometChatIncomingCall/CometChatCallButtons it carries no @preconcurrency, so under Swift 5 its set(call:)/set(onCancelClick:) are a HARD ERROR from a nonisolated context ("call to main actor-isolated instance method … in a synchronous nonisolated context"), not just a warning. (Same rule as cometchat-ios-core's @MainActor-factory note.)

swift
// Minimum voice-video-calls wiring — all five components (inside a @MainActor context, e.g. a UIViewController)
let callButtons = CometChatCallButtons(width: 180, height: 40)
callButtons.set(user: user)          // or .set(group:) for a group call
callButtons.set(controller: self)
callButtons.onVoiceCallClick = { user, group in /* initiate voice call */ }
callButtons.onVideoCallClick = { user, group in /* initiate video call */ }

// Present incoming call over any screen via a global app-level listener
let incoming = CometChatIncomingCall()
incoming.set(call: incomingCall)
// accept/cancel closures are TWO-arg: (call: Call?, controller: UIViewController?). A one-arg
// `{ call in … }` does NOT compile ("expects 2 arguments, but 1 was used").
incoming.set(onAcceptClick: { call, _ in /* push CometChatOngoingCall */ })
incoming.set(onCancelClick: { call, _ in self.dismiss(animated: true) })

let outgoing = CometChatOutgoingCall()
outgoing.set(call: pendingCall)
outgoing.set(onCancelClick: { call, _ in self.dismiss(animated: true) })

let ongoing = CometChatOngoingCall()
// `Call.sessionID` (uppercase D, SDK) is OPTIONAL (String?); `set(sessionId:)` (lowercase d, kit)
// wants a non-optional String — so GUARD it. Passing the optional directly does not compile.
if let sid = pendingCall.sessionID { ongoing.set(sessionId: sid) }

let logs = CometChatCallLogs()
// NOTE: CometChatCallLogs has NO `set(controller:)` — present/push it like any UIViewController
// (e.g. UINavigationController(rootViewController: logs)). Its only setters are the Any-typed
// callbacks below plus set(callRequestBuilder:).
logs.set(onItemClick: { callLog in guard let log = callLog as? CallLog else { return } /* … */ })

Incoming calls are app-level, not screen-level

A call can arrive on any screen, so listen at the app level (CometChatCallEventListener / CometChatCallEvents) and present CometChatIncomingCall over whatever is showing. Wiring it inside one chat screen means calls are missed everywhere else.

Permissions and background

Camera and microphone usage descriptions in Info.plist, or the app crashes on first call rather than failing gracefully. Ringing while backgrounded is handled by the CometChatPushNotifications SDK — it owns CallKit + PushKit for you. Do NOT hand-roll PKPushRegistryDelegate / CXProviderDelegate or call UIKitSettings.set(voipToken:) (that setter is the legacy path the current docs no longer use). Full VoIP wiring: cometchat-ios-v5-sdk § "VoIP call notifications" and cometchat-ios-push; needs an APNs VoIP provider in the Dashboard and a physical device.

Gotchas

  • Simulator limits. No camera; a WebRTC surface may behave differently than on device. Verify calling on a real device.
  • Every call screen needs an exit. Accept, decline and hang-up must all lead somewhere.
  • Version lock. Kit 5.1.22 / SDK 4.1.7 / Calls 5.0.3 are exact; mixing versions fails to build or crashes at runtime.

Verify it works

On a device: the call button appears in the header, tapping it rings the other side, the incoming screen shows over whatever was on screen, accept connects with audio and video, hang-up releases camera and microphone, and the call appears in call logs.

Frequently asked questions

What does the Cometchat Ios Calls AI skill do?

Add voice and video calling to an iOS CometChat app — call buttons, incoming/ongoing call screens, call logs, and CallKit ringing. Triggers: 'add video calling ios', 'cometchat voice call swift', 'incoming call screen ios', 'call logs cometchat ios'.

Why use Cometchat Ios Calls on TypingMind?

Because you install it once and use it with any model. Cometchat Ios Calls is plain Markdown rather than provider-specific code, so the same skill runs on GPT-5, Claude, Gemini, Grok, or a local model — and you can switch model mid-chat without it breaking. TypingMind runs on your own API keys, so you pay providers directly instead of a per-seat subscription, and your skills and chats stay in your own storage.

How do I install Cometchat Ios Calls in TypingMind?

Open Plugins → Skills → Install from GitHub in TypingMind and paste https://github.com/cometchat/cometchat-skills/tree/main/skills/cometchat-ios-calls. TypingMind reads its SKILL.md and installs it as a skill you can enable per chat.

Which AI models can use Cometchat Ios Calls?

Any model you connect in TypingMind. AI skills are plain Markdown instructions rather than provider-specific code, so GPT, Claude, Gemini, Grok, and local models can all load this skill when a request matches it.

How many AI models can I use with Cometchat Ios Calls?

As many as you like. As long as a model supports skills, you can use Cometchat Ios Calls with it — GPT, Claude, Gemini, Grok, DeepSeek, Mistral, Llama and more — all on TypingMind with your own API keys.

Is the Cometchat Ios Calls AI skill free?

Yes. It is published on GitHub by cometchat under the MIT license. You only pay your own AI provider for the tokens you use.

What are AI skills?

An AI skill is a reusable instruction bundle that teaches an AI model how to do one specific task. It follows the open Agent Skills format: a SKILL.md file with a name and description, plus any scripts, templates or reference files the model may need. The model reads the instructions only when your request matches the skill, so an installed skill costs nothing until it is used.

How are AI skills different from plugins or MCP servers?

A plugin or MCP server gives a model new tools to call — code that runs somewhere and returns a result. An AI skill gives the model knowledge and process instead: how to approach a task, which steps to follow, what good output looks like. Skills are plain Markdown, so they need no server, no API key and no runtime, and they work with any model.

View all

Set up your own AI workspace now

Get notified about new features and future giveaways by subscribing to our newsletter 👇