@cometchat/skills 4.4.2 → 5.0.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (490) hide show
  1. package/.claude-plugin/marketplace.json +55 -0
  2. package/.claude-plugin/plugin.json +14 -0
  3. package/CHANGELOG.md +36 -0
  4. package/LICENSE +21 -0
  5. package/README.md +41 -163
  6. package/RULES.md +114 -0
  7. package/bin/cometchat-skills.mjs +1180 -0
  8. package/bin/legacy-skills.json +95 -0
  9. package/catalogs/android-v6.json +1646 -0
  10. package/catalogs/flutter-v6.json +651 -0
  11. package/catalogs/ios-v5.json +1383 -0
  12. package/catalogs/rn-calls-v5.json +134 -0
  13. package/catalogs/rn-calls-v5.symbols.txt +58 -0
  14. package/catalogs/rn-sdk-v4.json +672 -0
  15. package/catalogs/rn-v5.json +449 -0
  16. package/catalogs/rn-v5.symbols.txt +216 -0
  17. package/catalogs/sdk-android-v5.json +514 -0
  18. package/contracts.android-calls-v5.json +122 -0
  19. package/contracts.android-v6.json +135 -0
  20. package/contracts.angular-v5.json +694 -0
  21. package/contracts.flutter-calls-v5.json +77 -0
  22. package/contracts.flutter-v6.json +126 -0
  23. package/contracts.ios-calls-v5.json +67 -0
  24. package/contracts.ios-v5.json +436 -0
  25. package/contracts.json +82 -0
  26. package/contracts.rn-calls-v5.json +77 -0
  27. package/contracts.rn-v5.json +727 -0
  28. package/contracts.sdk-android-v5.json +15 -0
  29. package/contracts.web-calls-v5.json +45 -0
  30. package/features.android-calls-v5.json +246 -0
  31. package/features.android-v6.json +65 -0
  32. package/features.angular-v5.json +521 -0
  33. package/features.flutter-calls-v5.json +286 -0
  34. package/features.flutter-v6.json +484 -0
  35. package/features.ios-calls-v5.json +236 -0
  36. package/features.ios-v5.json +573 -0
  37. package/features.json +61 -0
  38. package/features.rn-calls-v5.json +187 -0
  39. package/features.rn-v5.json +614 -0
  40. package/features.sdk-android-v5.json +40 -0
  41. package/features.sdk-jsv4.json +24 -0
  42. package/features.web-calls-v5.json +108 -0
  43. package/package.json +151 -74
  44. package/peers.yaml +312 -0
  45. package/registry/README.md +31 -0
  46. package/registry/android-calls-v5.json +54 -0
  47. package/registry/android-v6.json +137 -0
  48. package/registry/angular-v5.json +114 -0
  49. package/registry/flutter-calls-v5.json +54 -0
  50. package/registry/flutter-v6.json +119 -0
  51. package/registry/ios-calls-v5.json +59 -0
  52. package/registry/ios-v5.json +97 -0
  53. package/registry/rn-calls-v5.json +59 -0
  54. package/registry/rn-v5.json +129 -0
  55. package/registry/sdk-android-v5.json +53 -0
  56. package/registry/sdk-jsv4.json +53 -0
  57. package/registry/web-calls-v5.json +54 -0
  58. package/registry/web-v7.json +99 -0
  59. package/skills/cometchat/SKILL.md +42 -2096
  60. package/skills/cometchat-android-v5-calls-sdk/SKILL.md +206 -0
  61. package/skills/cometchat-android-v5-calls-sdk/references/build-truth.md +63 -0
  62. package/skills/cometchat-android-v5-calls-sdk/references/docs-map.md +119 -0
  63. package/skills/cometchat-android-v5-calls-sdk/references/method-map.md +53 -0
  64. package/skills/cometchat-android-v5-calls-sdk/references/pitfalls.md +72 -0
  65. package/skills/cometchat-android-v5-calls-sdk/references/ringing.md +92 -0
  66. package/skills/cometchat-android-v5-calls-sdk/references/user-switch.md +90 -0
  67. package/skills/cometchat-android-v5-sdk/SKILL.md +127 -0
  68. package/skills/cometchat-android-v5-sdk/references/app-surface.md +88 -0
  69. package/skills/cometchat-android-v5-sdk/references/docs-map.md +91 -0
  70. package/skills/cometchat-android-v6-builder-settings/SKILL.md +51 -137
  71. package/skills/cometchat-android-v6-calls/SKILL.md +128 -413
  72. package/skills/cometchat-android-v6-compose-components/SKILL.md +84 -194
  73. package/skills/cometchat-android-v6-compose-customization/SKILL.md +66 -411
  74. package/skills/cometchat-android-v6-compose-placement/SKILL.md +154 -237
  75. package/skills/cometchat-android-v6-core/SKILL.md +236 -672
  76. package/skills/cometchat-android-v6-core/references/anti-patterns.md +31 -0
  77. package/skills/cometchat-android-v6-core/references/component-props.md +168 -0
  78. package/skills/cometchat-android-v6-core/references/docs-map.md +153 -0
  79. package/skills/cometchat-android-v6-core/references/layout.md +112 -0
  80. package/skills/cometchat-android-v6-core/references/lifecycle.md +75 -0
  81. package/skills/cometchat-android-v6-core/references/setup-credentials.md +105 -0
  82. package/skills/cometchat-android-v6-core/references/troubleshooting.md +36 -0
  83. package/skills/cometchat-android-v6-events/SKILL.md +46 -184
  84. package/skills/cometchat-android-v6-extensions/SKILL.md +39 -179
  85. package/skills/cometchat-android-v6-features/SKILL.md +74 -143
  86. package/skills/cometchat-android-v6-kotlin-components/SKILL.md +75 -193
  87. package/skills/cometchat-android-v6-kotlin-customization/SKILL.md +67 -419
  88. package/skills/cometchat-android-v6-kotlin-placement/SKILL.md +77 -223
  89. package/skills/cometchat-android-v6-migration/SKILL.md +67 -378
  90. package/skills/cometchat-android-v6-production/SKILL.md +40 -179
  91. package/skills/cometchat-android-v6-push/SKILL.md +39 -289
  92. package/skills/cometchat-android-v6-testing/SKILL.md +50 -265
  93. package/skills/cometchat-android-v6-troubleshooting/SKILL.md +70 -254
  94. package/skills/cometchat-angular-v5-calls/SKILL.md +193 -0
  95. package/skills/cometchat-angular-v5-components/SKILL.md +131 -0
  96. package/skills/cometchat-angular-v5-components/references/catalog.md +111 -0
  97. package/skills/cometchat-angular-v5-components/references/host-composed.md +46 -0
  98. package/skills/cometchat-angular-v5-core/SKILL.md +300 -0
  99. package/skills/cometchat-angular-v5-core/references/anti-patterns.md +49 -0
  100. package/skills/cometchat-angular-v5-core/references/component-props.md +55 -0
  101. package/skills/cometchat-angular-v5-core/references/dependencies.md +66 -0
  102. package/skills/cometchat-angular-v5-core/references/docs-map.md +132 -0
  103. package/skills/cometchat-angular-v5-core/references/layout.md +64 -0
  104. package/skills/cometchat-angular-v5-core/references/lifecycle.md +202 -0
  105. package/skills/cometchat-angular-v5-core/references/setup-credentials.md +137 -0
  106. package/skills/cometchat-angular-v5-core/references/theming.md +70 -0
  107. package/skills/cometchat-angular-v5-core/references/troubleshooting.md +27 -0
  108. package/skills/cometchat-angular-v5-customization/SKILL.md +94 -0
  109. package/skills/cometchat-angular-v5-features/SKILL.md +107 -0
  110. package/skills/cometchat-angular-v5-features/references/custom-messages.md +133 -0
  111. package/skills/cometchat-angular-v5-features/references/formatters.md +28 -0
  112. package/skills/cometchat-angular-v5-features/references/host-composed-extensions.md +85 -0
  113. package/skills/cometchat-angular-v5-migration/SKILL.md +40 -0
  114. package/skills/cometchat-angular-v5-migration/references/migration-guide.md +165 -0
  115. package/skills/cometchat-angular-v5-patterns/SKILL.md +107 -0
  116. package/skills/cometchat-angular-v5-placement/SKILL.md +133 -0
  117. package/skills/cometchat-angular-v5-placement/references/combined-app.md +174 -0
  118. package/skills/cometchat-angular-v5-placement/references/core-surface.md +199 -0
  119. package/skills/cometchat-angular-v5-production/SKILL.md +101 -0
  120. package/skills/cometchat-angular-v5-push/SKILL.md +61 -0
  121. package/skills/cometchat-angular-v5-testing/SKILL.md +112 -0
  122. package/skills/cometchat-angular-v5-troubleshooting/SKILL.md +96 -0
  123. package/skills/cometchat-flutter-v5-sdk/SKILL.md +188 -0
  124. package/skills/cometchat-flutter-v5-sdk/references/doc-corrections.md +55 -0
  125. package/skills/cometchat-flutter-v5-sdk/references/docs-map.md +211 -0
  126. package/skills/cometchat-flutter-v5-sdk/references/platform-notes.md +48 -0
  127. package/skills/cometchat-flutter-v5-sdk/references/transcription.md +87 -0
  128. package/skills/cometchat-flutter-v6-calls/SKILL.md +75 -389
  129. package/skills/cometchat-flutter-v6-components/SKILL.md +88 -361
  130. package/skills/cometchat-flutter-v6-core/SKILL.md +154 -593
  131. package/skills/cometchat-flutter-v6-core/references/anti-patterns.md +55 -0
  132. package/skills/cometchat-flutter-v6-core/references/docs-map.md +143 -0
  133. package/skills/cometchat-flutter-v6-core/references/layout.md +45 -0
  134. package/skills/cometchat-flutter-v6-core/references/lifecycle.md +87 -0
  135. package/skills/cometchat-flutter-v6-core/references/setup-credentials.md +84 -0
  136. package/skills/cometchat-flutter-v6-core/references/troubleshooting.md +26 -0
  137. package/skills/cometchat-flutter-v6-customization/SKILL.md +70 -712
  138. package/skills/cometchat-flutter-v6-events/SKILL.md +79 -174
  139. package/skills/cometchat-flutter-v6-features/SKILL.md +55 -394
  140. package/skills/cometchat-flutter-v6-migration/SKILL.md +68 -367
  141. package/skills/cometchat-flutter-v6-migration/references/migration-guide.md +131 -0
  142. package/skills/cometchat-flutter-v6-patterns/SKILL.md +61 -0
  143. package/skills/cometchat-flutter-v6-placement/SKILL.md +94 -381
  144. package/skills/cometchat-flutter-v6-production/SKILL.md +58 -615
  145. package/skills/cometchat-flutter-v6-push/SKILL.md +46 -455
  146. package/skills/cometchat-flutter-v6-testing/SKILL.md +68 -299
  147. package/skills/cometchat-flutter-v6-troubleshooting/SKILL.md +54 -878
  148. package/skills/cometchat-ios-calls/SKILL.md +112 -563
  149. package/skills/cometchat-ios-components/SKILL.md +44 -834
  150. package/skills/cometchat-ios-core/SKILL.md +181 -1068
  151. package/skills/cometchat-ios-core/references/anti-patterns.md +80 -0
  152. package/skills/cometchat-ios-core/references/docs-map.md +123 -0
  153. package/skills/cometchat-ios-core/references/install.md +23 -0
  154. package/skills/cometchat-ios-core/references/layout.md +186 -0
  155. package/skills/cometchat-ios-core/references/setup-credentials.md +197 -0
  156. package/skills/cometchat-ios-core/references/swiftui.md +91 -0
  157. package/skills/cometchat-ios-core/references/troubleshooting.md +100 -0
  158. package/skills/cometchat-ios-customization/SKILL.md +33 -968
  159. package/skills/cometchat-ios-features/SKILL.md +29 -738
  160. package/skills/cometchat-ios-migration/SKILL.md +39 -0
  161. package/skills/cometchat-ios-placement/SKILL.md +51 -729
  162. package/skills/cometchat-ios-push/SKILL.md +24 -602
  163. package/skills/cometchat-ios-v5-sdk/SKILL.md +161 -0
  164. package/skills/cometchat-ios-v5-sdk/references/docs-map.md +326 -0
  165. package/skills/cometchat-js-v5-sdk/SKILL.md +95 -0
  166. package/skills/cometchat-js-v5-sdk/references/docs-map.md +114 -0
  167. package/skills/cometchat-onboarding/SKILL.md +89 -0
  168. package/skills/cometchat-onboarding/references/archetypes.md +51 -0
  169. package/skills/cometchat-onboarding/references/calling-first.md +77 -0
  170. package/skills/cometchat-onboarding/references/not-in-this-pack.md +8 -0
  171. package/skills/cometchat-onboarding/references/plan-artifact.md +133 -0
  172. package/skills/cometchat-onboarding/references/platforms.md +90 -0
  173. package/skills/cometchat-react-native-bare-patterns/SKILL.md +120 -0
  174. package/skills/cometchat-react-native-calls/SKILL.md +200 -0
  175. package/skills/cometchat-react-native-components/SKILL.md +142 -0
  176. package/skills/cometchat-react-native-core/SKILL.md +313 -0
  177. package/skills/cometchat-react-native-core/references/anti-patterns.md +79 -0
  178. package/skills/cometchat-react-native-core/references/component-props.md +105 -0
  179. package/skills/cometchat-react-native-core/references/dependencies.md +62 -0
  180. package/skills/cometchat-react-native-core/references/docs-map.md +126 -0
  181. package/skills/cometchat-react-native-core/references/layout.md +61 -0
  182. package/skills/cometchat-react-native-core/references/lifecycle.md +64 -0
  183. package/skills/cometchat-react-native-core/references/setup-credentials.md +39 -0
  184. package/skills/cometchat-react-native-customization/SKILL.md +198 -0
  185. package/skills/cometchat-react-native-expo-patterns/SKILL.md +116 -0
  186. package/skills/cometchat-react-native-features/SKILL.md +122 -0
  187. package/skills/cometchat-react-native-migration/SKILL.md +103 -0
  188. package/skills/cometchat-react-native-placement/SKILL.md +158 -0
  189. package/skills/cometchat-react-native-production/SKILL.md +78 -0
  190. package/skills/cometchat-react-native-push/SKILL.md +88 -0
  191. package/skills/cometchat-react-native-sdk/SKILL.md +126 -0
  192. package/skills/cometchat-react-native-sdk/references/method-map.md +239 -0
  193. package/skills/cometchat-react-native-sdk/references/page-map.md +96 -0
  194. package/skills/cometchat-react-native-testing/SKILL.md +94 -0
  195. package/skills/cometchat-react-native-troubleshooting/SKILL.md +116 -0
  196. package/skills/cometchat-react-native-v5-sdk/SKILL.md +150 -0
  197. package/skills/cometchat-react-native-v5-sdk/references/docs-map.md +127 -0
  198. package/skills/cometchat-react-native-v5-sdk/references/ringing-voip.md +369 -0
  199. package/skills/cometchat-react-v7-calls/SKILL.md +75 -0
  200. package/skills/cometchat-react-v7-components/SKILL.md +72 -0
  201. package/skills/cometchat-react-v7-core/SKILL.md +101 -0
  202. package/skills/cometchat-react-v7-core/references/anti-patterns.md +19 -0
  203. package/skills/cometchat-react-v7-core/references/component-props.md +82 -0
  204. package/skills/cometchat-react-v7-core/references/dependencies.md +23 -0
  205. package/skills/cometchat-react-v7-core/references/docs-map.md +117 -0
  206. package/skills/cometchat-react-v7-core/references/i18n-rtl-a11y.md +22 -0
  207. package/skills/cometchat-react-v7-core/references/layout.md +158 -0
  208. package/skills/cometchat-react-v7-core/references/lifecycle.md +74 -0
  209. package/skills/cometchat-react-v7-core/references/setup-credentials.md +58 -0
  210. package/skills/cometchat-react-v7-core/references/ssr.md +11 -0
  211. package/skills/cometchat-react-v7-core/references/theming.md +52 -0
  212. package/skills/cometchat-react-v7-core/references/troubleshooting.md +28 -0
  213. package/skills/cometchat-react-v7-customization/SKILL.md +84 -0
  214. package/skills/cometchat-react-v7-features/SKILL.md +92 -0
  215. package/skills/cometchat-react-v7-migration/SKILL.md +39 -0
  216. package/skills/cometchat-react-v7-migration/references/migration-guide.md +119 -0
  217. package/skills/cometchat-react-v7-patterns/SKILL.md +43 -0
  218. package/skills/cometchat-react-v7-placement/SKILL.md +106 -0
  219. package/skills/cometchat-react-v7-placement/references/recipes.md +354 -0
  220. package/skills/cometchat-react-v7-push/SKILL.md +53 -0
  221. package/test-suite/README.md +70 -0
  222. package/test-suite/catalogs/android-calls-v5.json +830 -0
  223. package/test-suite/catalogs/android-calls-v5.symbols.txt +499 -0
  224. package/test-suite/catalogs/android-v6.json +1646 -0
  225. package/test-suite/catalogs/android-v6.symbols.txt +298 -0
  226. package/test-suite/catalogs/angular-v5.json +7587 -0
  227. package/test-suite/catalogs/flutter-calls-v5.json +196 -0
  228. package/test-suite/catalogs/flutter-calls-v5.symbols.txt +59 -0
  229. package/test-suite/catalogs/flutter-v6.json +651 -0
  230. package/test-suite/catalogs/ios-calls-v5.json +158 -0
  231. package/test-suite/catalogs/ios-calls-v5.symbols.txt +70 -0
  232. package/test-suite/catalogs/ios-v5.json +1383 -0
  233. package/test-suite/catalogs/ios-v5.symbols.txt +699 -0
  234. package/test-suite/catalogs/rn-calls-v5.json +134 -0
  235. package/test-suite/catalogs/rn-sdk-v4.json +672 -0
  236. package/test-suite/catalogs/rn-v5.json +449 -0
  237. package/test-suite/catalogs/sdk-android-v5.json +514 -0
  238. package/test-suite/catalogs/sdk-android-v5.symbols.txt +254 -0
  239. package/test-suite/catalogs/sdk-jsv4.json +800 -0
  240. package/test-suite/catalogs/web-calls-v5.json +195 -0
  241. package/test-suite/catalogs/web-v7.json +1243 -0
  242. package/test-suite/scripts/build-registry.mjs +113 -0
  243. package/test-suite/scripts/catalog-refresh-dart.mjs +151 -0
  244. package/test-suite/scripts/catalog-refresh.mjs +100 -0
  245. package/test-suite/scripts/lint-skills.mjs +909 -0
  246. package/test-suite/scripts/measure-tokens.mjs +169 -0
  247. package/test-suite/scripts/typecheck-fences-dart.mjs +437 -0
  248. package/test-suite/scripts/typecheck-fences-kotlin.mjs +269 -0
  249. package/test-suite/scripts/typecheck-fences.mjs +206 -0
  250. package/test-suite/scripts/verify-catalog.mjs +242 -0
  251. package/test-suite/scripts/verify-contract-fences.mjs +94 -0
  252. package/test-suite/scripts/verify-detection.mjs +178 -0
  253. package/test-suite/scripts/verify-docs-base.mjs +91 -0
  254. package/test-suite/scripts/verify-family-agnostic.mjs +130 -0
  255. package/test-suite/scripts/verify-golden-path.mjs +138 -0
  256. package/test-suite/scripts/verify-oracle-components.mjs +133 -0
  257. package/test-suite/scripts/verify-template-bindings.mjs +148 -0
  258. package/test-suite/typecheck/angular-v5/package.json +21 -0
  259. package/test-suite/typecheck/angular-v5/tsconfig.json +21 -0
  260. package/test-suite/typecheck/flutter-v6/analysis_options.yaml +25 -0
  261. package/test-suite/typecheck/flutter-v6/pubspec.yaml +21 -0
  262. package/test-suite/typecheck/web-v7/package.json +18 -0
  263. package/test-suite/typecheck/web-v7/tsconfig.json +19 -0
  264. package/bin/install.js +0 -1003
  265. package/skills/.claude-plugin/marketplace.json +0 -86
  266. package/skills/cometchat/references/asking-questions.md +0 -48
  267. package/skills/cometchat-a11y/SKILL.md +0 -477
  268. package/skills/cometchat-android-v5/SKILL.md +0 -121
  269. package/skills/cometchat-android-v5-calls/SKILL.md +0 -429
  270. package/skills/cometchat-android-v5-calls/references/README.md +0 -53
  271. package/skills/cometchat-android-v5-calls/references/add-calls-to-existing-chat.md +0 -197
  272. package/skills/cometchat-android-v5-calls/references/audio-controls.md +0 -91
  273. package/skills/cometchat-android-v5-calls/references/background-handling.md +0 -168
  274. package/skills/cometchat-android-v5-calls/references/call-layouts.md +0 -131
  275. package/skills/cometchat-android-v5-calls/references/call-logs.md +0 -113
  276. package/skills/cometchat-android-v5-calls/references/call-session.md +0 -274
  277. package/skills/cometchat-android-v5-calls/references/custom-ui.md +0 -150
  278. package/skills/cometchat-android-v5-calls/references/event-listeners.md +0 -123
  279. package/skills/cometchat-android-v5-calls/references/group-calls.md +0 -205
  280. package/skills/cometchat-android-v5-calls/references/idle-timeout.md +0 -117
  281. package/skills/cometchat-android-v5-calls/references/in-call-chat.md +0 -134
  282. package/skills/cometchat-android-v5-calls/references/join-session.md +0 -120
  283. package/skills/cometchat-android-v5-calls/references/migration-v4-to-v5.md +0 -222
  284. package/skills/cometchat-android-v5-calls/references/participant-management.md +0 -110
  285. package/skills/cometchat-android-v5-calls/references/picture-in-picture.md +0 -106
  286. package/skills/cometchat-android-v5-calls/references/raise-hand.md +0 -248
  287. package/skills/cometchat-android-v5-calls/references/recording.md +0 -101
  288. package/skills/cometchat-android-v5-calls/references/ringing-integration.md +0 -152
  289. package/skills/cometchat-android-v5-calls/references/screen-sharing.md +0 -78
  290. package/skills/cometchat-android-v5-calls/references/server-fcm-voip.md +0 -215
  291. package/skills/cometchat-android-v5-calls/references/session-settings.md +0 -121
  292. package/skills/cometchat-android-v5-calls/references/setup.md +0 -137
  293. package/skills/cometchat-android-v5-calls/references/share-invite.md +0 -156
  294. package/skills/cometchat-android-v5-calls/references/video-controls.md +0 -87
  295. package/skills/cometchat-android-v5-calls/references/voip-calling.md +0 -526
  296. package/skills/cometchat-android-v5-components/SKILL.md +0 -431
  297. package/skills/cometchat-android-v5-core/SKILL.md +0 -486
  298. package/skills/cometchat-android-v5-customization/SKILL.md +0 -469
  299. package/skills/cometchat-android-v5-extensions/SKILL.md +0 -127
  300. package/skills/cometchat-android-v5-features/SKILL.md +0 -131
  301. package/skills/cometchat-android-v5-placement/SKILL.md +0 -277
  302. package/skills/cometchat-android-v5-production/SKILL.md +0 -95
  303. package/skills/cometchat-android-v5-push/SKILL.md +0 -619
  304. package/skills/cometchat-android-v5-testing/SKILL.md +0 -188
  305. package/skills/cometchat-android-v5-theming/SKILL.md +0 -167
  306. package/skills/cometchat-android-v5-troubleshooting/SKILL.md +0 -74
  307. package/skills/cometchat-android-v6/SKILL.md +0 -108
  308. package/skills/cometchat-android-v6-calls/references/add-calls-to-existing-chat.md +0 -97
  309. package/skills/cometchat-android-v6-calls/references/advanced-features.md +0 -87
  310. package/skills/cometchat-android-v6-calls/references/call-layouts.md +0 -100
  311. package/skills/cometchat-android-v6-calls/references/call-session.md +0 -163
  312. package/skills/cometchat-android-v6-calls/references/device-management.md +0 -172
  313. package/skills/cometchat-android-v6-calls/references/group-calls.md +0 -191
  314. package/skills/cometchat-android-v6-calls/references/idle-timeout.md +0 -110
  315. package/skills/cometchat-android-v6-calls/references/in-call-chat.md +0 -141
  316. package/skills/cometchat-android-v6-calls/references/raise-hand.md +0 -188
  317. package/skills/cometchat-android-v6-calls/references/ringing-integration.md +0 -176
  318. package/skills/cometchat-android-v6-calls/references/server-fcm-voip.md +0 -127
  319. package/skills/cometchat-android-v6-calls/references/share-invite.md +0 -105
  320. package/skills/cometchat-android-v6-compose-theming/SKILL.md +0 -250
  321. package/skills/cometchat-android-v6-kotlin-theming/SKILL.md +0 -233
  322. package/skills/cometchat-angular-calls/SKILL.md +0 -380
  323. package/skills/cometchat-angular-calls/references/add-calls-to-existing-chat.md +0 -96
  324. package/skills/cometchat-angular-calls/references/call-layouts.md +0 -123
  325. package/skills/cometchat-angular-calls/references/call-session.md +0 -167
  326. package/skills/cometchat-angular-calls/references/custom-ui.md +0 -239
  327. package/skills/cometchat-angular-calls/references/device-management.md +0 -154
  328. package/skills/cometchat-angular-calls/references/group-calls.md +0 -433
  329. package/skills/cometchat-angular-calls/references/idle-timeout.md +0 -161
  330. package/skills/cometchat-angular-calls/references/in-call-chat.md +0 -148
  331. package/skills/cometchat-angular-calls/references/lazy-loading-pitfalls.md +0 -205
  332. package/skills/cometchat-angular-calls/references/migration-v4-to-v5.md +0 -53
  333. package/skills/cometchat-angular-calls/references/ngzone-and-async-callbacks.md +0 -184
  334. package/skills/cometchat-angular-calls/references/picture-in-picture.md +0 -285
  335. package/skills/cometchat-angular-calls/references/raise-hand.md +0 -172
  336. package/skills/cometchat-angular-calls/references/recording-screen-share.md +0 -260
  337. package/skills/cometchat-angular-calls/references/ringing-integration.md +0 -133
  338. package/skills/cometchat-angular-calls/references/server-web-push-vapid.md +0 -100
  339. package/skills/cometchat-angular-calls/references/share-invite.md +0 -122
  340. package/skills/cometchat-angular-calls/references/virtual-background.md +0 -29
  341. package/skills/cometchat-angular-components/SKILL.md +0 -235
  342. package/skills/cometchat-angular-core/SKILL.md +0 -386
  343. package/skills/cometchat-angular-customization/SKILL.md +0 -616
  344. package/skills/cometchat-angular-features/SKILL.md +0 -329
  345. package/skills/cometchat-angular-patterns/SKILL.md +0 -256
  346. package/skills/cometchat-angular-placement/SKILL.md +0 -314
  347. package/skills/cometchat-angular-production/SKILL.md +0 -564
  348. package/skills/cometchat-angular-push/SKILL.md +0 -389
  349. package/skills/cometchat-angular-testing/SKILL.md +0 -605
  350. package/skills/cometchat-angular-theming/SKILL.md +0 -290
  351. package/skills/cometchat-angular-troubleshooting/SKILL.md +0 -364
  352. package/skills/cometchat-astro-patterns/SKILL.md +0 -708
  353. package/skills/cometchat-calls/SKILL.md +0 -364
  354. package/skills/cometchat-calls/references/use-case-broadcast.md +0 -199
  355. package/skills/cometchat-calls/references/use-case-marketplace.md +0 -157
  356. package/skills/cometchat-calls/references/use-case-support.md +0 -189
  357. package/skills/cometchat-calls/references/use-case-team.md +0 -180
  358. package/skills/cometchat-calls/references/use-case-telehealth.md +0 -153
  359. package/skills/cometchat-components/SKILL.md +0 -1142
  360. package/skills/cometchat-core/SKILL.md +0 -1048
  361. package/skills/cometchat-customization/SKILL.md +0 -580
  362. package/skills/cometchat-customization/references/component-catalog.md +0 -236
  363. package/skills/cometchat-features/SKILL.md +0 -861
  364. package/skills/cometchat-flutter-v5/SKILL.md +0 -173
  365. package/skills/cometchat-flutter-v5-calls/SKILL.md +0 -455
  366. package/skills/cometchat-flutter-v5-calls/references/add-calls-to-existing-chat.md +0 -193
  367. package/skills/cometchat-flutter-v5-calls/references/call-layouts.md +0 -103
  368. package/skills/cometchat-flutter-v5-calls/references/call-session.md +0 -285
  369. package/skills/cometchat-flutter-v5-calls/references/device-management.md +0 -124
  370. package/skills/cometchat-flutter-v5-calls/references/group-calls.md +0 -181
  371. package/skills/cometchat-flutter-v5-calls/references/idle-timeout.md +0 -99
  372. package/skills/cometchat-flutter-v5-calls/references/in-call-chat.md +0 -135
  373. package/skills/cometchat-flutter-v5-calls/references/migration-v4-to-v5.md +0 -210
  374. package/skills/cometchat-flutter-v5-calls/references/raise-hand.md +0 -255
  375. package/skills/cometchat-flutter-v5-calls/references/ringing-integration.md +0 -196
  376. package/skills/cometchat-flutter-v5-calls/references/server-push-bridge.md +0 -101
  377. package/skills/cometchat-flutter-v5-calls/references/share-invite.md +0 -148
  378. package/skills/cometchat-flutter-v5-conversations/SKILL.md +0 -118
  379. package/skills/cometchat-flutter-v5-core/SKILL.md +0 -239
  380. package/skills/cometchat-flutter-v5-customization/SKILL.md +0 -358
  381. package/skills/cometchat-flutter-v5-events/SKILL.md +0 -156
  382. package/skills/cometchat-flutter-v5-messages/SKILL.md +0 -259
  383. package/skills/cometchat-flutter-v5-production/SKILL.md +0 -216
  384. package/skills/cometchat-flutter-v5-push/SKILL.md +0 -285
  385. package/skills/cometchat-flutter-v5-testing/SKILL.md +0 -401
  386. package/skills/cometchat-flutter-v5-theming/SKILL.md +0 -161
  387. package/skills/cometchat-flutter-v5-troubleshooting/SKILL.md +0 -130
  388. package/skills/cometchat-flutter-v5-users-groups/SKILL.md +0 -152
  389. package/skills/cometchat-flutter-v6/SKILL.md +0 -446
  390. package/skills/cometchat-flutter-v6-calls/references/add-calls-to-existing-chat.md +0 -136
  391. package/skills/cometchat-flutter-v6-calls/references/advanced-features.md +0 -89
  392. package/skills/cometchat-flutter-v6-calls/references/call-layouts.md +0 -105
  393. package/skills/cometchat-flutter-v6-calls/references/call-session.md +0 -229
  394. package/skills/cometchat-flutter-v6-calls/references/device-management.md +0 -105
  395. package/skills/cometchat-flutter-v6-calls/references/group-calls.md +0 -190
  396. package/skills/cometchat-flutter-v6-calls/references/idle-timeout.md +0 -88
  397. package/skills/cometchat-flutter-v6-calls/references/in-call-chat.md +0 -125
  398. package/skills/cometchat-flutter-v6-calls/references/raise-hand.md +0 -275
  399. package/skills/cometchat-flutter-v6-calls/references/ringing-integration.md +0 -171
  400. package/skills/cometchat-flutter-v6-calls/references/server-push-bridge.md +0 -93
  401. package/skills/cometchat-flutter-v6-calls/references/share-invite.md +0 -102
  402. package/skills/cometchat-flutter-v6-conversations/SKILL.md +0 -238
  403. package/skills/cometchat-flutter-v6-messages/SKILL.md +0 -384
  404. package/skills/cometchat-flutter-v6-theming/SKILL.md +0 -293
  405. package/skills/cometchat-flutter-v6-users-groups/SKILL.md +0 -224
  406. package/skills/cometchat-i18n/SKILL.md +0 -419
  407. package/skills/cometchat-ios/SKILL.md +0 -325
  408. package/skills/cometchat-ios-calls/references/add-calls-to-existing-chat.md +0 -181
  409. package/skills/cometchat-ios-calls/references/audio-modes-and-controls.md +0 -45
  410. package/skills/cometchat-ios-calls/references/avaudiosession-routing.md +0 -188
  411. package/skills/cometchat-ios-calls/references/call-layouts.md +0 -76
  412. package/skills/cometchat-ios-calls/references/call-session.md +0 -218
  413. package/skills/cometchat-ios-calls/references/callkit-and-pushkit.md +0 -357
  414. package/skills/cometchat-ios-calls/references/custom-ui.md +0 -322
  415. package/skills/cometchat-ios-calls/references/device-management.md +0 -171
  416. package/skills/cometchat-ios-calls/references/group-calls.md +0 -359
  417. package/skills/cometchat-ios-calls/references/idle-timeout.md +0 -184
  418. package/skills/cometchat-ios-calls/references/in-call-chat.md +0 -179
  419. package/skills/cometchat-ios-calls/references/migration-v4-to-v5.md +0 -196
  420. package/skills/cometchat-ios-calls/references/picture-in-picture.md +0 -246
  421. package/skills/cometchat-ios-calls/references/raise-hand.md +0 -26
  422. package/skills/cometchat-ios-calls/references/recording-screen-share.md +0 -252
  423. package/skills/cometchat-ios-calls/references/ringing-integration.md +0 -143
  424. package/skills/cometchat-ios-calls/references/server-apns-pushkit.md +0 -267
  425. package/skills/cometchat-ios-calls/references/share-invite.md +0 -148
  426. package/skills/cometchat-ios-calls/references/swiftui-uikit-hosting.md +0 -246
  427. package/skills/cometchat-ios-calls/references/voip-cert-setup.md +0 -166
  428. package/skills/cometchat-ios-production/SKILL.md +0 -738
  429. package/skills/cometchat-ios-testing/SKILL.md +0 -376
  430. package/skills/cometchat-ios-theming/SKILL.md +0 -667
  431. package/skills/cometchat-ios-troubleshooting/SKILL.md +0 -1003
  432. package/skills/cometchat-native-bare-patterns/SKILL.md +0 -550
  433. package/skills/cometchat-native-calls/SKILL.md +0 -671
  434. package/skills/cometchat-native-calls/references/add-calls-to-existing-chat.md +0 -203
  435. package/skills/cometchat-native-calls/references/call-layouts.md +0 -125
  436. package/skills/cometchat-native-calls/references/call-session.md +0 -182
  437. package/skills/cometchat-native-calls/references/custom-ui.md +0 -254
  438. package/skills/cometchat-native-calls/references/device-management.md +0 -158
  439. package/skills/cometchat-native-calls/references/expo-vs-bare.md +0 -179
  440. package/skills/cometchat-native-calls/references/group-calls.md +0 -296
  441. package/skills/cometchat-native-calls/references/idle-timeout.md +0 -128
  442. package/skills/cometchat-native-calls/references/in-call-chat.md +0 -145
  443. package/skills/cometchat-native-calls/references/migration-v4-to-v5.md +0 -72
  444. package/skills/cometchat-native-calls/references/picture-in-picture.md +0 -276
  445. package/skills/cometchat-native-calls/references/raise-hand.md +0 -205
  446. package/skills/cometchat-native-calls/references/recording-screen-share.md +0 -169
  447. package/skills/cometchat-native-calls/references/ringing-integration.md +0 -118
  448. package/skills/cometchat-native-calls/references/server-push-bridge.md +0 -135
  449. package/skills/cometchat-native-calls/references/server-push-payloads.md +0 -193
  450. package/skills/cometchat-native-calls/references/share-invite.md +0 -146
  451. package/skills/cometchat-native-calls/references/voip-push-end-to-end.md +0 -319
  452. package/skills/cometchat-native-components/SKILL.md +0 -628
  453. package/skills/cometchat-native-core/SKILL.md +0 -679
  454. package/skills/cometchat-native-customization/SKILL.md +0 -716
  455. package/skills/cometchat-native-expo-patterns/SKILL.md +0 -552
  456. package/skills/cometchat-native-features/SKILL.md +0 -638
  457. package/skills/cometchat-native-placement/SKILL.md +0 -509
  458. package/skills/cometchat-native-production/SKILL.md +0 -700
  459. package/skills/cometchat-native-push/SKILL.md +0 -594
  460. package/skills/cometchat-native-testing/SKILL.md +0 -582
  461. package/skills/cometchat-native-theming/SKILL.md +0 -681
  462. package/skills/cometchat-native-troubleshooting/SKILL.md +0 -501
  463. package/skills/cometchat-nextjs-patterns/SKILL.md +0 -899
  464. package/skills/cometchat-placement/SKILL.md +0 -1360
  465. package/skills/cometchat-production/SKILL.md +0 -1027
  466. package/skills/cometchat-react-calls/SKILL.md +0 -752
  467. package/skills/cometchat-react-calls/references/add-calls-to-existing-chat.md +0 -146
  468. package/skills/cometchat-react-calls/references/call-layouts.md +0 -160
  469. package/skills/cometchat-react-calls/references/call-session.md +0 -235
  470. package/skills/cometchat-react-calls/references/custom-ui.md +0 -247
  471. package/skills/cometchat-react-calls/references/device-management.md +0 -210
  472. package/skills/cometchat-react-calls/references/group-calls.md +0 -257
  473. package/skills/cometchat-react-calls/references/idle-timeout.md +0 -188
  474. package/skills/cometchat-react-calls/references/in-call-chat.md +0 -212
  475. package/skills/cometchat-react-calls/references/migration-v4-to-v5.md +0 -170
  476. package/skills/cometchat-react-calls/references/picture-in-picture.md +0 -245
  477. package/skills/cometchat-react-calls/references/raise-hand.md +0 -238
  478. package/skills/cometchat-react-calls/references/recording-screen-share.md +0 -144
  479. package/skills/cometchat-react-calls/references/ringing-integration.md +0 -255
  480. package/skills/cometchat-react-calls/references/server-web-push-vapid.md +0 -241
  481. package/skills/cometchat-react-calls/references/share-invite.md +0 -175
  482. package/skills/cometchat-react-calls/references/testing-calls-on-web.md +0 -216
  483. package/skills/cometchat-react-calls/references/virtual-background.md +0 -32
  484. package/skills/cometchat-react-calls/references/voip-and-web-push.md +0 -165
  485. package/skills/cometchat-react-patterns/SKILL.md +0 -628
  486. package/skills/cometchat-react-push/SKILL.md +0 -634
  487. package/skills/cometchat-react-router-patterns/SKILL.md +0 -758
  488. package/skills/cometchat-react-testing/SKILL.md +0 -413
  489. package/skills/cometchat-theming/SKILL.md +0 -498
  490. package/skills/cometchat-troubleshooting/SKILL.md +0 -294
@@ -0,0 +1,369 @@
1
+ # Background ringing & background calls — the native half
2
+
3
+ Two DIFFERENT problems that get confused. Read the one you need.
4
+
5
+ | Problem | You need | Page |
6
+ |---|---|---|
7
+ | Callee's phone must ring while their app is **closed** | **VoIP push** + a native dialer (CallKit / ConnectionService) | `/calls/react-native/voip-calling` |
8
+ | A call already in progress must **survive backgrounding** | Background modes + a foreground service | `/calls/react-native/background-handling` |
9
+
10
+ Foreground ringing (`onIncomingCallReceived` over the Chat SDK websocket) is in the main SKILL. It works
11
+ only while the callee's app is open. Everything below is what makes ringing behave like a real phone call.
12
+
13
+ > **Where this comes from.** Almost everything here is transcribed from the two CometChat pages above —
14
+ > the Swift/Java modules, the manifest entries, the certificate and Firebase steps, the permission lists and
15
+ > the platform-behaviour tables. Three things are **not** from those pages and are labelled **`[not in the
16
+ > doc]`** inline so you can check them yourself:
17
+ > 1. the **typed token API** (`CometChatNotifications.registerPushToken` / `PushPlatforms` /
18
+ > `unregisterPushToken`) — read from the shipped `@cometchat/chat-sdk-react-native` `.d.ts`; the doc page
19
+ > still shows the legacy `CometChat.registerTokenForPushNotification` (DOCS-BACKLOG **C16**);
20
+ > 2. **register-after-login / unregister-on-logout** — from the pack's own `cometchat-react-native-push`
21
+ > skill; this page has no logout step at all;
22
+ > 3. the **`reportNewIncomingCall` termination rule** — Apple platform behaviour, not a CometChat claim.
23
+ >
24
+ > Nothing here is written from memory: if it is not on a CometChat page it is either in the SDK's types or
25
+ > labelled as outside guidance.
26
+
27
+ ---
28
+
29
+ # PART 1 — Ringing a CLOSED app (VoIP push)
30
+
31
+ The Chat SDK's call listener needs a live socket. A killed or backgrounded app has none, so the server must
32
+ wake it with a **push**, and the OS must show a **native call screen**. That is platform work — not JS.
33
+
34
+ ## 1a. iOS — VoIP push + CallKit
35
+
36
+ **Capabilities** (Xcode → target → Signing & Capabilities): add **Push Notifications**, add
37
+ **Background Modes**, enable **Voice over IP**.
38
+
39
+ **Certificate:** Apple Developer → Certificates, Identifiers & Profiles → create a **VoIP Services
40
+ Certificate** → download, install, export the `.p12`. Upload it (with its password) in the CometChat
41
+ Dashboard under **Notifications → Push Notifications**.
42
+
43
+ **Native module** — PushKit receives the wake-up, CallKit draws the system call UI:
44
+
45
+ ```swift
46
+ // ios/CallKitManager.swift
47
+ import CallKit
48
+ import PushKit
49
+
50
+ @objc(CallKitManager)
51
+ class CallKitManager: NSObject, CXProviderDelegate, PKPushRegistryDelegate {
52
+ static let shared = CallKitManager()
53
+ private let provider: CXProvider
54
+ private let callController = CXCallController()
55
+ private var voipRegistry: PKPushRegistry?
56
+
57
+ override init() {
58
+ let config = CXProviderConfiguration()
59
+ config.supportsVideo = true
60
+ config.maximumCallsPerCallGroup = 1
61
+ config.supportedHandleTypes = [.generic]
62
+ provider = CXProvider(configuration: config)
63
+ super.init()
64
+ provider.setDelegate(self, queue: nil)
65
+ }
66
+
67
+ @objc func registerForVoIPPushes() {
68
+ voipRegistry = PKPushRegistry(queue: .main)
69
+ voipRegistry?.delegate = self
70
+ voipRegistry?.desiredPushTypes = [.voIP]
71
+ }
72
+
73
+ // Token → hand to JS → CometChatNotifications.registerPushToken(token, APNS_REACT_NATIVE_VOIP)
74
+ func pushRegistry(_ registry: PKPushRegistry, didUpdate pushCredentials: PKPushCredentials, for type: PKPushType) {
75
+ let token = pushCredentials.token.map { String(format: "%02x", $0) }.joined()
76
+ NotificationCenter.default.post(name: NSNotification.Name("VoIPTokenReceived"), object: nil, userInfo: ["token": token])
77
+ }
78
+
79
+ // The wake-up. You MUST report an incoming call here or iOS kills the app.
80
+ func pushRegistry(_ registry: PKPushRegistry, didReceiveIncomingPushWith payload: PKPushPayload, for type: PKPushType, completion: @escaping () -> Void) {
81
+ guard type == .voIP else { return }
82
+ let callerId = payload.dictionaryPayload["callerId"] as? String ?? "Unknown"
83
+ let callerName = payload.dictionaryPayload["callerName"] as? String ?? "Unknown"
84
+ let hasVideo = payload.dictionaryPayload["hasVideo"] as? Bool ?? false
85
+ let update = CXCallUpdate()
86
+ update.remoteHandle = CXHandle(type: .generic, value: callerId)
87
+ update.localizedCallerName = callerName
88
+ update.hasVideo = hasVideo
89
+ provider.reportNewIncomingCall(with: UUID(), update: update) { _ in completion() }
90
+ }
91
+
92
+ func providerDidReset(_ provider: CXProvider) {}
93
+
94
+ func provider(_ provider: CXProvider, perform action: CXAnswerCallAction) {
95
+ NotificationCenter.default.post(name: NSNotification.Name("CallKitAnswerCall"), object: nil,
96
+ userInfo: ["callUUID": action.callUUID.uuidString])
97
+ action.fulfill()
98
+ }
99
+
100
+ func provider(_ provider: CXProvider, perform action: CXEndCallAction) {
101
+ NotificationCenter.default.post(name: NSNotification.Name("CallKitEndCall"), object: nil,
102
+ userInfo: ["callUUID": action.callUUID.uuidString])
103
+ action.fulfill()
104
+ }
105
+ }
106
+ ```
107
+
108
+ > ⚠️ **`reportNewIncomingCall` is not optional** — **`[not in the doc]`**, this is Apple's own PushKit rule:
109
+ > iOS terminates an app that accepts a VoIP push without reporting a call. The CometChat page shows the call
110
+ > being reported but does not say why it is mandatory. Report first, then do the CometChat work.
111
+
112
+ ## 1b. Android — FCM + a self-managed ConnectionService
113
+
114
+ **Firebase:** add Firebase to the Android project, then in `android/app/build.gradle`:
115
+
116
+ ```groovy
117
+ dependencies { implementation 'com.google.firebase:firebase-messaging:23.0.0' }
118
+ ```
119
+
120
+ Upload the Firebase server key in the CometChat Dashboard under **Notifications → Push Notifications**.
121
+
122
+ **ConnectionService** — registers the app as a self-managed dialer so the system rings:
123
+
124
+ ```java
125
+ // android/app/src/main/java/com/yourapp/CallConnectionService.java
126
+ package com.yourapp;
127
+
128
+ import android.telecom.Connection;
129
+ import android.telecom.ConnectionRequest;
130
+ import android.telecom.ConnectionService;
131
+ import android.telecom.PhoneAccountHandle;
132
+ import android.telecom.TelecomManager;
133
+
134
+ public class CallConnectionService extends ConnectionService {
135
+ @Override
136
+ public Connection onCreateIncomingConnection(PhoneAccountHandle h, ConnectionRequest request) {
137
+ CallConnection connection = new CallConnection();
138
+ connection.setConnectionProperties(Connection.PROPERTY_SELF_MANAGED);
139
+ connection.setCallerDisplayName(request.getExtras().getString("callerName"), TelecomManager.PRESENTATION_ALLOWED);
140
+ connection.setRinging();
141
+ return connection;
142
+ }
143
+
144
+ @Override
145
+ public Connection onCreateOutgoingConnection(PhoneAccountHandle h, ConnectionRequest request) {
146
+ CallConnection connection = new CallConnection();
147
+ connection.setConnectionProperties(Connection.PROPERTY_SELF_MANAGED);
148
+ connection.setDialing();
149
+ return connection;
150
+ }
151
+ }
152
+ ```
153
+
154
+ `AndroidManifest.xml`:
155
+
156
+ ```xml
157
+ <uses-permission android:name="android.permission.MANAGE_OWN_CALLS" />
158
+ <uses-permission android:name="android.permission.READ_PHONE_STATE" />
159
+
160
+ <service
161
+ android:name=".CallConnectionService"
162
+ android:permission="android.permission.BIND_TELECOM_CONNECTION_SERVICE"
163
+ android:exported="true">
164
+ <intent-filter><action android:name="android.telecom.ConnectionService" /></intent-filter>
165
+ </service>
166
+ ```
167
+
168
+ ## 1c. Register the token (both platforms)
169
+
170
+ > ⚠️ **`[not in the doc]` — the doc page uses the LEGACY token API.** `/calls/react-native/voip-calling` shows
171
+ > `CometChat.registerTokenForPushNotification(token, { voip: true })` — an untyped `settings` bag with no
172
+ > platform enum and no unregister counterpart. The SDK ships a **typed** replacement with a dedicated VoIP
173
+ > platform, and it is what the pack's `cometchat-react-native-push` skill uses. Prefer it. (DOCS-BACKLOG C16)
174
+
175
+ ```tsx
176
+ import { CometChatNotifications } from "@cometchat/chat-sdk-react-native";
177
+
178
+ const { PushPlatforms } = CometChatNotifications;
179
+
180
+ // iOS VoIP pushes are a DIFFERENT platform from ordinary iOS pushes — an app that rings AND sends
181
+ // message notifications registers two tokens on two platforms.
182
+ async function registerVoIPToken(token: string, platform: "ios" | "android"): Promise<void> {
183
+ try {
184
+ await CometChatNotifications.registerPushToken(
185
+ token,
186
+ platform === "ios" ? PushPlatforms.APNS_REACT_NATIVE_VOIP // the PushKit token
187
+ : PushPlatforms.FCM_REACT_NATIVE_ANDROID,
188
+ );
189
+ } catch (error) {
190
+ console.error("VoIP token registration failed", error);
191
+ }
192
+ }
193
+
194
+ // On logout — otherwise the next user on this device inherits the previous user's calls.
195
+ await CometChatNotifications.unregisterPushToken();
196
+ ```
197
+
198
+ Register **after login** — a token registered with no logged-in user is attached to nobody. Re-register on
199
+ token refresh, and unregister on logout. **`[not in the doc]`** — this ordering comes from the pack's
200
+ `cometchat-react-native-push` skill; the VoIP page states no login ordering and has no logout step.
201
+
202
+ ## 1d. Answer from the native call screen → join the session
203
+
204
+ The OS answer action comes back to JS; from there it is the SAME flow as foreground ringing:
205
+
206
+ > ⚠️ **`CallKitManager` is iOS-ONLY and emits EXACTLY three events** — `VoIPTokenReceived`,
207
+ > `CallKitAnswerCall`, `CallKitEndCall`. Subscribing to any other name throws at runtime:
208
+ > ``` `FcmTokenReceived` is not a supported event type for CallKitManager ```. In particular **the Android
209
+ > FCM token does NOT arrive through this module** — see § Android token below.
210
+
211
+ ```tsx
212
+ import { useEffect } from "react";
213
+ import { NativeEventEmitter, NativeModules, Platform } from "react-native";
214
+ import { CometChat } from "@cometchat/chat-sdk-react-native";
215
+ import { CometChatCalls } from "@cometchat/calls-sdk-react-native";
216
+
217
+ export default function useVoIPPush(onToken: (t: string) => void) {
218
+ useEffect(() => {
219
+ if (Platform.OS !== "ios") return; // Android: see § Android token
220
+ const emitter = new NativeEventEmitter(NativeModules.CallKitManager);
221
+
222
+ // The iOS token arrives HERE — PushKit hands it to Swift, Swift posts it, this consumes it.
223
+ // Without this listener the Swift side emits into nothing and no token is ever registered.
224
+ const tok = emitter.addListener("VoIPTokenReceived", (d: { token: string }) => {
225
+ void registerVoIPToken(d.token, "ios");
226
+ });
227
+
228
+ const answer = emitter.addListener("CallKitAnswerCall", async (data: { sessionId: string }) => {
229
+ await CometChat.acceptCall(data.sessionId); // signaling
230
+ const { token } = await CometChatCalls.generateToken(data.sessionId); // media
231
+ onToken(token); // render <CometChatCalls.Component>
232
+ });
233
+
234
+ const end = emitter.addListener("CallKitEndCall", () => CometChatCalls.leaveSession());
235
+
236
+ return () => { tok.remove(); answer.remove(); end.remove(); };
237
+ }, [onToken]);
238
+ }
239
+ ```
240
+
241
+ ### Android token — a DIFFERENT source
242
+
243
+ **`[not in the doc]`** — the VoIP page says to add Firebase but never says where the token comes from. It is
244
+ **not** an event on `CallKitManager` (that module is iOS-only). It comes from your messaging library, the
245
+ same one the pack's `cometchat-react-native-push` skill uses:
246
+
247
+ ```tsx
248
+ import messaging from "@react-native-firebase/messaging";
249
+
250
+ // once, after login
251
+ const fcmToken = await messaging().getToken();
252
+ await registerVoIPToken(fcmToken, "android");
253
+
254
+ // and whenever Firebase rotates it
255
+ const unsub = messaging().onTokenRefresh((t) => registerVoIPToken(t, "android"));
256
+ ```
257
+
258
+ So the two platforms differ in **where the token comes from**, not in what you do with it: iOS via the
259
+ PushKit → Swift → `VoIPTokenReceived` chain, Android via `messaging().getToken()`. Both end at the same
260
+ `registerPushToken` call with their own `PushPlatforms` value.
261
+
262
+ ---
263
+
264
+ # PART 2 — Keeping an ACTIVE call alive in the background
265
+
266
+ Different problem: the call already started and the user switches apps or locks the screen.
267
+
268
+ ## 2a. iOS
269
+
270
+ **Background Modes** → **Audio, AirPlay, and Picture in Picture** (add **Voice over IP** too if using Part 1).
271
+ The SDK configures the audio session itself; override only if you need to:
272
+
273
+ ```swift
274
+ // ios/AppDelegate.swift
275
+ import AVFoundation
276
+
277
+ try? AVAudioSession.sharedInstance().setCategory(
278
+ .playAndRecord, mode: .voiceChat,
279
+ options: [.allowBluetooth, .allowBluetoothA2DP, .defaultToSpeaker])
280
+ try? AVAudioSession.sharedInstance().setActive(true)
281
+ ```
282
+
283
+ | Scenario | iOS behaviour |
284
+ |---|---|
285
+ | App backgrounded | Audio continues, **video pauses** |
286
+ | Phone call arrives | Call audio interrupted, resumes after |
287
+ | Screen locked | Audio continues |
288
+
289
+ ## 2b. Android — the permissions most integrations miss
290
+
291
+ ```xml
292
+ <uses-permission android:name="android.permission.FOREGROUND_SERVICE" />
293
+ <uses-permission android:name="android.permission.FOREGROUND_SERVICE_MICROPHONE" />
294
+ <uses-permission android:name="android.permission.FOREGROUND_SERVICE_CAMERA" />
295
+ <uses-permission android:name="android.permission.FOREGROUND_SERVICE_MEDIA_PLAYBACK" />
296
+ <uses-permission android:name="android.permission.FOREGROUND_SERVICE_MEDIA_PROJECTION" />
297
+ <uses-permission android:name="android.permission.WAKE_LOCK" />
298
+ <uses-permission android:name="android.permission.POST_NOTIFICATIONS" />
299
+ ```
300
+
301
+ Android 10+ requires a **foreground service** for a call to continue in the background. The SDK ships
302
+ `com.cometchat.calls.services.CometChatOngoingCallService` and declares it in its own manifest, so it merges
303
+ into your app automatically — **you normally declare nothing**. Only if you must override it:
304
+
305
+ ```xml
306
+ <service android:name="com.cometchat.calls.services.CometChatOngoingCallService"
307
+ android:foregroundServiceType="camera|microphone|mediaProjection|mediaPlayback" />
308
+ ```
309
+
310
+ Wake locks are managed by the SDK. Do not add your own.
311
+
312
+ | Scenario | Android behaviour |
313
+ |---|---|
314
+ | App backgrounded | Audio continues **via the foreground service** |
315
+ | Phone call arrives | Call audio may be interrupted |
316
+ | Screen off | Audio continues (wake lock) |
317
+
318
+ ## 2c. App-state + connection wiring
319
+
320
+ ```tsx
321
+ import { useEffect, useRef } from "react";
322
+ import { AppState, AppStateStatus } from "react-native";
323
+ import { CometChatCalls } from "@cometchat/calls-sdk-react-native";
324
+
325
+ export default function useBackgroundCall(onEnded: () => void) {
326
+ const appState = useRef(AppState.currentState);
327
+
328
+ useEffect(() => {
329
+ const sub = AppState.addEventListener("change", (next: AppStateStatus) => {
330
+ if (appState.current.match(/active/) && next === "background") CometChatCalls.enablePictureInPictureLayout();
331
+ else if (appState.current === "background" && next === "active") CometChatCalls.disablePictureInPictureLayout();
332
+ appState.current = next;
333
+ });
334
+ return () => sub.remove();
335
+ }, []);
336
+
337
+ useEffect(() => {
338
+ const controller = new AbortController();
339
+ const { signal } = controller;
340
+ CometChatCalls.addEventListener("onConnectionLost", () => {}, { signal }); // show "reconnecting"
341
+ CometChatCalls.addEventListener("onConnectionRestored", () => {}, { signal }); // hide it
342
+ CometChatCalls.addEventListener("onConnectionClosed", onEnded, { signal });
343
+ return () => controller.abort();
344
+ }, [onEnded]);
345
+ }
346
+ ```
347
+
348
+ ---
349
+
350
+ ## Verifying this — and what "verified" honestly means
351
+
352
+ **None of Part 1 can be tested here.** VoIP push needs a real device, real certificates, and the app
353
+ genuinely backgrounded or killed. It does not work on an iOS Simulator (APNs is absent), it cannot run in CI,
354
+ and the pack's `sdk-smoke` cannot mount native code. Any "ringing works" claim without a two-device run on
355
+ real hardware is **unproven** — say so rather than implying coverage.
356
+
357
+ Test matrix that actually proves it:
358
+
359
+ | Check | How |
360
+ |---|---|
361
+ | Token registered | log the token, confirm registration resolves AFTER login |
362
+ | Push arrives, app backgrounded | background the callee app, call from device 2 → native call UI appears |
363
+ | Push arrives, app KILLED | swipe the callee app away, call → app wakes and rings |
364
+ | Answer → media | accept from the OS screen → `<CometChatCalls.Component>` mounts and audio flows |
365
+ | Reject / timeout | reject, and separately let it ring out (default 45s) |
366
+ | Call survives backgrounding | during an active call, background the app → audio continues |
367
+
368
+ **Two live clients are required** for every row. Two instances of the same build on one simulator share a
369
+ session and will not ring each other.
@@ -0,0 +1,75 @@
1
+ ---
2
+ name: cometchat-react-v7-calls
3
+ description: "Add voice & video calling to a React app with the CometChat v7 UI Kit — install the Calls SDK, enable calling on the UIKit settings, mount the incoming-call surface, and wire 1:1 ring / group join. Bakes the real gotchas (ms idle-timeout, zero-dimension call surface, Next.js SSR, no group-ring, HTTPS/getUserMedia). Triggers: 'add voice and video calls', 'add calling to my chat', 'enable video call', 'add call buttons', 'show call logs', 'cometchat calling react'."
4
+ license: "MIT"
5
+ compatibility: "React >=18 <21; @cometchat/chat-uikit-react ^7 (7.1.x, verified 7.1.0); @cometchat/chat-sdk-javascript ^4.1.9; @cometchat/calls-sdk-javascript ^5 (5.0.0 — separate, NOT bundled)"
6
+ metadata:
7
+ author: "CometChat"
8
+ version: "1.0.0"
9
+ tags: "cometchat react calls voice video calling webrtc v7 uikit"
10
+ ---
11
+
12
+ > **Ground truth:** calling is part of `@cometchat/chat-uikit-react@7` (the call UI ships INSIDE the kit — there is no separate calls-UI package), but the WebRTC engine is a SEPARATE, NOT-bundled dependency: `@cometchat/chat-uikit-react@^7` + `@cometchat/chat-sdk-javascript@^4.1.9` + **`@cometchat/calls-sdk-javascript@^5`** (major 5 — distinct from the chat SDK's v4). Every `CometChat*` symbol below exists in the `web-v7` catalog. Exhaustive props + advanced call surfaces are FETCHED from the docs `.md` twins via `cometchat-react-v7-core/references/docs-map.md`. **APPEND to the user's app — additive wiring only** (`RULES.md`).
13
+
14
+ ## Companion skills (read first)
15
+ - `cometchat-react-v7-core` — install, credentials, `init→login→render`, `CometChatProvider`. This skill ASSUMES it (calling is enabled on the SAME init).
16
+ - `cometchat-react-v7-components` — the component catalog (message header the call buttons live in).
17
+ - `cometchat-react-v7-features` — `voice-video-calls` is the feature entry; this skill is its operational depth.
18
+
19
+ ## Use this skill when
20
+ "add voice & video calls", "add calling to my chat", "enable video call", "add call buttons", "show call logs". Precondition: chat is already integrated (core done) — calling rides on the same init/login.
21
+
22
+ ## Prerequisites & install
23
+ Core setup done (init + login + `CometChatProvider`). Calling adds ONE package:
24
+ ```bash
25
+ npm install @cometchat/calls-sdk-javascript@5
26
+ ```
27
+ > The Calls SDK is **major 5** (not the chat SDK's v4) and is **NOT bundled** by the UI Kit — if it isn't installed, every call affordance stays hidden. Do not "upgrade" `@cometchat/chat-sdk-javascript` to a non-existent v7; it stays `^4.1.9`.
28
+
29
+ ## Enable calling (BAKED — the two-part contract, the #1 gotcha)
30
+ Calling is OFF until BOTH are true: the Calls SDK is installed (above) **and** calling is turned ON in the init settings. Since the core inits via **`CometChatUIKit.initFromSettings`** (telemetry — `RULES.md` §5 / AUDIT-084), enable calling IN the SAME settings object with a truthy **`uiKit.callsSDK`**:
31
+ ```tsx
32
+ import { CometChatUIKit } from "@cometchat/chat-uikit-react";
33
+
34
+ await CometChatUIKit.initFromSettings({
35
+ appId: APP_ID, region: REGION,
36
+ credentials: { authKey: AUTH_KEY }, // dev-only; prod → server-minted auth token
37
+ chatSDK: { presenceSubscription: { type: "ALL_USERS" } },
38
+ uiKit: { callsSDK: {} }, // ← turns calling ON (the initFromSettings equivalent of setCallingEnabled(true))
39
+ });
40
+ ```
41
+ > **How calling maps in the initFromSettings path (verified vs the compiled 7.1.x kit; DOCS-GAP).** The kit computes `callingEnabled = !!settings.uiKit.callsSDK`, so a **truthy `uiKit.callsSDK`** is the `initFromSettings` equivalent of `UIKitSettingsBuilder().setCallingEnabled(true)` — WITHOUT it, call buttons + incoming-call render nothing. The docs don't yet document this shape (owner: **docs** — confirm with a live call). The classic path still works — `CometChatUIKit.init(new UIKitSettingsBuilder()…setCallingEnabled(true).build())` — but it SKIPS the ai-agent telemetry attribution, so prefer `initFromSettings`.
42
+ > No separate `CometChatUIKitCalls.init()` is needed for the default path. (`CometChatUIKitCalls` is the kit's namespace for advanced call-settings builders; reach for it only on a custom surface — FETCH then.) `initFromSettings` routes the Calls SDK internally — do NOT call raw `CometChat.init()`.
43
+
44
+ ## Wire the UI (BAKED — least-code path)
45
+ Two moves cover ringing end-to-end:
46
+ 1. **Mount `CometChatIncomingCall` ONCE at the app root** (above your routes). It self-manages visibility — renders nothing when idle, rings on an inbound call — so **no conditional wrapper**. It attaches its own SDK listeners.
47
+ ```tsx
48
+ import { CometChatIncomingCall } from "@cometchat/chat-uikit-react";
49
+ // at the app shell, inside CometChatProvider, above the router:
50
+ <CometChatIncomingCall />
51
+ ```
52
+ 2. **Let `CometChatMessageHeader` surface the call buttons.** When a `user`/`group` is selected, the header composes voice/video call buttons itself once calling is enabled — you usually mount NOTHING extra. Only drop a standalone `CometChatCallButtons user={user}` (1:1) or `group={group}` on a CUSTOM header that has no `CometChatMessageHeader`. **Never mount both** — a standalone `CometChatCallButtons` next to a `CometChatMessageHeader` duplicates the buttons.
53
+
54
+ **Call logs** (optional history surface): `CometChatCallLogs` on a sidebar or a `/calls` route (`onItemClick`, `onCallButtonClicked`, `callLogRequestBuilder`). It does NOT auto-refresh on a new call — remount to refresh. **It shows the kit's "OOPS! …" screen when call logs aren't available — and, verified live, it renders that from its OWN INTERNAL error state WITHOUT throwing, so a host `CometChatErrorBoundary`/`fallbackView` CANNOT override it and `onError` may not fire. A fallbackView is NOT the fix (AUDIT-162).** **Enabling calling is NOT sufficient for `CometChatCallLogs`:** call-logs availability is a SEPARATE plan/capability gate — an app can have calling ON (Voice/Video buttons render) yet `CometChatCallLogs` still "OOPS" because call-logs isn't in the plan. **The only reliable protection is to GATE the Calls tab on real call-logs AVAILABILITY** (a one-time SDK probe you own — `new CometChatCalls.CallLogRequestBuilder().setLimit(1).setAuthToken(await CometChatUIKitCalls.generateToken(...)).build().fetchNext()`, show the tab only on success — or your known plan), NOT merely on calling being enabled; default the tab OFF so a plain app never dead-ends. **Import discipline (AUDIT-204): `CallLogRequestBuilder` is NOT a named export of `@cometchat/calls-sdk-javascript` — it is a STATIC on the `CometChatCalls` default-export class** (verified vs calls-sdk 5.0.5 `dist/index.d.ts`): use `import { CometChatCalls } from "@cometchat/calls-sdk-javascript"; new CometChatCalls.CallLogRequestBuilder()…` — a `import { CallLogRequestBuilder } from "@cometchat/calls-sdk-javascript"` FAILS (TS2614). `generateToken` is on `CometChatUIKitCalls` (from `@cometchat/chat-uikit-react`). (Gated Calls-tab recipe with the full probe + imports: `../cometchat-react-v7-placement/references/recipes.md` Combined-app recipe.)
55
+
56
+ ### 1:1 rings, groups JOIN (BAKED — no group-ring)
57
+ - **1:1:** call buttons → the kit initiates a call → the recipient's root `CometChatIncomingCall` RINGS → accept → the ongoing-call surface. The kit drives outgoing → ongoing for you.
58
+ - **Group:** call buttons on a group send a **group-call meeting message** into the chat; members **JOIN** from that message. There is **no "ring the whole group" primitive** — surface the join affordance, never wait for a ring.
59
+
60
+ ## Custom call surfaces (FETCH — don't bake)
61
+ For anything past the default ring/join — a custom ongoing-call screen (`CometChatOngoingCall`), a bespoke call manager (`CometChatOutgoingCall`), idle-timeout tuning, screen-share, picture-in-picture, device selection, recording, virtual background — FETCH the exact props/API from the docs `.md` twins via `cometchat-react-v7-core/references/docs-map.md` (rows: `call-buttons` · `incoming-call` · `outgoing-call` · `call-logs` · `calls-setup` · `calls-react-integration` · the per-feature Calls-SDK pages). These props change; never emit them from memory or read `.d.ts`.
62
+
63
+ ## Common pitfalls (BAKED — these bite in production)
64
+ - **Idle-timeout is in MILLISECONDS.** `180` = 180 ms, so the "are you still there?" prompt fires and exits instantly. Use `180_000` for 3 minutes. (Exact v7 field/clamp → FETCH the idle-timeout page.)
65
+ - **Zero-dimension call surface = crash/blank.** A custom ongoing-call container with 0 width/height throws or renders nothing (e.g. `h-full` on an auto-height flex parent). Give the call surface a content-INDEPENDENT height + width per the reflow-free-surface standard (`../cometchat-react-v7-core/references/layout.md`) — a pinned flex chain with `min-height:0`, or a `100dvw/100dvh` overlay. Same class of bug as the chat-collapse/reflow issue: the kit call UI fills its parent, so a content-driven box collapses or grows-into-place.
66
+ - **`Container dimensions and number of tiles must be positive` on leave (non-fatal).** Even the kit's DEFAULT ongoing-call dialog logs this error from a Jitsi `ResizeObserver` as the dialog collapses to 0×0 while unmounting on "Leave session". It's a Calls-SDK teardown race — **non-fatal: the app recovers to the chat surface** — but it's an uncaught console error every hang-up, so a strict "no console errors" gate must allowlist/filter it. Owner: uikit/calls-sdk (not a host bug). Don't try to "fix" it host-side.
67
+ - **HTTPS required.** `getUserMedia` (camera/mic) only works on `localhost` or HTTPS — calling silently no-ops on a plain-HTTP non-localhost origin.
68
+ - **Next.js SSR.** Render CometChat (and especially the calls SDK) client-only: `"use client"` + `dynamic(() => import(...), { ssr: false })`. If the build then fails with `Can't resolve 'fs'` / `'path'`, add a webpack fallback (`config.resolve.fallback = { fs: false, path: false }`) — a Calls-SDK-v5 bundling quirk. See `cometchat-react-v7-core/references/ssr.md`.
69
+ - **Cleanup on custom surfaces.** On a hand-rolled ongoing-call screen, end the session and stop the tracks (`stream.getTracks().forEach(t => t.stop())`) on hangup/unmount or the camera light stays on. The kit-driven `CometChatIncomingCall`/ongoing flow handles this for you — prefer it.
70
+ - **Screen-share / PiP / device-select / recording / virtual-background are NOT on by default** — each is separate wiring on its own Calls-SDK page. Don't claim the default screen includes them.
71
+
72
+ ## Verify it works
73
+ Calling is enabled (SDK installed + `uiKit:{callsSDK:{}}` on `initFromSettings` — the `initFromSettings` equivalent of the classic `setCallingEnabled(true)`); a 1:1 call from the header buttons RINGS the other user's root `CometChatIncomingCall`; accept connects audio+video in a non-collapsed surface; a group call posts a join message (no ring); hang-up releases the camera/mic (light off). If call buttons never appear: the SDK isn't installed or calling isn't enabled. If the call screen is blank: the container is zero-dimension or the origin isn't HTTPS.
74
+
75
+ **Close (after it builds):** end with the shared 3-option selectable menu and WAIT for the pick — **① add another feature** (suggest a few not-yet-wired) · **② customize theming** · **③ test it manually** (stop; let the user check). Same contract as the `cometchat-react-v7-core` close (`RULES.md` §19).
@@ -0,0 +1,72 @@
1
+ ---
2
+ name: cometchat-react-v7-components
3
+ description: "The React v7 UI Kit component catalog — which drop-in components exist and how to compose/swap them (conversations, messages, users, groups, threads, calling, bubbles). Triggers: 'what cometchat components are there', 'customize the message list', 'swap the message bubble', 'add a users list'."
4
+ license: "MIT"
5
+ compatibility: "React >=18; @cometchat/chat-uikit-react ^7 (7.1.x, verified 7.1.0)"
6
+ metadata:
7
+ author: "CometChat"
8
+ version: "1.0.1"
9
+ tags: "cometchat react components uikit catalog v7"
10
+ ---
11
+
12
+ > **Ground truth:** `@cometchat/chat-uikit-react@7`. Component names below are from the live v7 components docs (see `../cometchat-react-v7-core/references/docs-map.md` → `/ui-kit/react/components-overview`). Status: **catalog-verified vs installed 7.1.0 (exports-only `web-v7.json`).** Fetch each component's prop table from its **`.md` twin** (`../cometchat-react-v7-core/references/docs-map.md`) — do NOT bake it; never read `.d.ts`.
13
+
14
+ ## Companion skills (read first)
15
+ - `cometchat-react-v7-core` — install, credentials, `init→login→render`, provider. This skill ASSUMES it.
16
+
17
+ ## Use this skill when
18
+ Choosing, composing, or swapping UI Kit components; "which components exist"; customizing a list/message/bubble.
19
+
20
+ ## Prerequisites & install
21
+ Covered by core. This skill adds no new package.
22
+
23
+ ## Component catalog (BAKED closed list — from live v7 docs; confirm vs web-v7.json)
24
+ Conversations & lists: `CometChatConversations`, `CometChatUsers`, `CometChatGroups`, `CometChatGroupMembers`.
25
+ Messages: `CometChatMessageHeader`, `CometChatMessageList`, `CometChatMessageComposer`, `CometChatMessageBubble`, `CometChatThreadHeader`, `CometChatMessageInformation`, `CometChatReactions`, `CometChatReactionList`.
26
+ Message bubbles: `CometChatTextBubble`, `CometChatImagesBubble`, `CometChatVideosBubble`, `CometChatAudiosBubble`, `CometChatVoiceNoteBubble`, `CometChatFilesBubble`, `CometChatPollBubble`, `CometChatStickerBubble`, `CometChatCollaborativeDocumentBubble`, `CometChatCollaborativeWhiteboardBubble`, `CometChatCardBubble`, `CometChatGroupActionBubble`, `CometChatCallActionBubble`, `CometChatCallBubble`.
27
+ Calling UI: `CometChatCallButtons`, `CometChatIncomingCall`, `CometChatOutgoingCall`, `CometChatOngoingCall`, `CometChatCallLogs`.
28
+ Search & AI: `CometChatSearch`, `CometChatAIAssistantChat`, `CometChatSmartReplies`, `CometChatConversationStarter`, `CometChatConversationSummary`.
29
+ Moderation / notifications feed: `CometChatModerationView`, `CometChatNotificationFeed`, `CometChatFlagMessageDialog` (end-user report/flag dialog).
30
+ Interactive/dialogs: `CometChatCreatePoll` (poll-authoring dialog; pairs with `CometChatPollBubble`).
31
+ Base/util: `CometChatProvider`, `CometChatAvatar`, `CometChatButton`, `CometChatFullScreenViewer`, `CometChatConfirmDialog`, `CometChatContextMenu`, `CometChatErrorBoundary`.
32
+ > This is the closed list — if a name isn't here (and in `web-v7.json`), it does not exist; do not use it.
33
+ > **Phantoms removed 2026-07-30 (AUDIT-008 — reviewer G0 catalog sweep vs installed `@cometchat/chat-uikit-react@7.1.0` `.d.ts`).** These names were in earlier drafts but DO NOT exist in v7 — never emit them: `CometChatTypingIndicator` (typing renders inside `CometChatMessageHeader`; `CometChatTypingDisplay` is a *type*, not a component), `CometChatEmojiKeyboard` (emoji is the built-in EMOJI button in `CometChatMessageComposer`), `CometChatMediaRecorder` (voice recording is built into `CometChatMessageComposer`, `hideVoiceRecordingButton` default false), `CometChatListItem` (list items are internal item-views of the list components), `CometChatToast` (no standalone toast component). Note `CometChatNotifications` is a **Chat SDK** class (`@cometchat/chat-sdk-javascript`, push token registration) — NOT a UI Kit component; don't render it.
34
+
35
+ ## Swap / compose slots
36
+ - v7 components are **compound components**: compose behavior via namespace sub-components (e.g. `Root`, `View`, `EmptyState`) and prop-driven slots rather than deep prop sprawl. Fetch the exact composition API + props from the component's **`.md` twin** (`../cometchat-react-v7-core/references/docs-map.md`) before emitting — never the `.d.ts`.
37
+ - **Custom UI goes in a component's view slot, INSIDE it — never as a sibling on top.** Stable props + view slots for the 4 drop-ins are baked in `../cometchat-react-v7-core/references/component-props.md` (Conversations `headerView`/`searchView`, MessageHeader `trailingView`/`auxiliaryButtonView`, MessageList `headerView`/`footerView`, Composer `auxiliaryButtonView`/`headerView`) — use them before hand-rolling or hanging controls outside the component.
38
+ - Prefer configuring the highest-level component (e.g. `CometChatConversations`) over rebuilding it from base components.
39
+ - **Reuse built-in triggers before hand-rolling UI.** Map each requested action to an existing prop/callback/slot FIRST; only add custom buttons when none exists. Discovery order: prop table + each prop's "when to use it" note in docs → if undescribed, fetch the component's `.md` twin (`../cometchat-react-v7-core/references/docs-map.md`) → then custom. Known wiring points: `CometChatMessageHeader` `onItemClick` (open user/group profile on header click) and `onSearchOptionClicked` (built-in search button, `showSearchOption` default `true`); `CometChatConversations` `onSearchBarClicked` (conversation search); `CometChatMessageList` `onThreadRepliesClick` (thread panel). See AUDIT-006.
40
+
41
+ ## Creating a group (host-composed — NO kit component; offer ALL THREE types incl. password)
42
+ v7 ships **no `CometChatCreateGroup` component** — the create-group form is HOST-BUILT. Build it from the **`guide-group-chat-setup`** guide (docs-map "Task guides"), which shows the full form. **It MUST offer all THREE group types — Public · Private · Password-protected — not just public/private (AUDIT-081).** The Password type REQUIRES a password field; create the group with the Chat SDK (symbols verified vs installed 7.x SDK):
43
+ ```tsx
44
+ import { CometChat } from "@cometchat/chat-sdk-javascript";
45
+ // type ∈ CometChat.GROUP_TYPE.PUBLIC | .PRIVATE | .PASSWORD ("public" | "private" | "password")
46
+ const group = new CometChat.Group(guid, groupName, CometChat.GROUP_TYPE.PASSWORD, password); // 4th arg = password (REQUIRED for the PASSWORD type)
47
+ await CometChat.createGroup(group);
48
+ ```
49
+ Show the password input ONLY when the Password type is chosen, and require it before submit (public/private need no password). Dropping the Password option (offering only public/private) is a create-group defect — the SDK (`Group(guid, name, type, password?)`, `GROUP_TYPE.PASSWORD`) and the guide both support it.
50
+
51
+ ## Banned members — view + unban (SDK fallback; NO kit component or UI-Kit doc)
52
+ The group-details contract requires **`view-banned-members`**, but v7 ships **no banned-members drop-in** — `CometChatGroupMembers` shows only ACTIVE members (it exposes the ban ACTION via `hideBanMemberOption`, not a banned view), and the UI-Kit guide/component docs don't cover viewing banned users (AUDIT-082). So surface them via the **Chat SDK** (UI-Kit-first → SDK-fallback, `RULES.md` §13; symbols verified vs installed 7.x SDK + documented at `sdk/javascript/group-kick-ban-members`). Add a **scope-gated** "Banned members" affordance in group details (admins/owners only):
53
+ ```tsx
54
+ import { CometChat } from "@cometchat/chat-sdk-javascript";
55
+
56
+ // FETCH — paginate by calling fetchNext() again on the SAME request object (max limit 100)
57
+ const req = new CometChat.BannedMembersRequestBuilder(guid).setLimit(30).build(); // .setSearchKeyword(kw) optional
58
+ const banned = await req.fetchNext(); // Promise<CometChat.GroupMember[]>
59
+
60
+ // UNBAN (admin/owner only), then refresh the list
61
+ await CometChat.unbanGroupMember(guid, uid); // Promise<boolean>
62
+ ```
63
+ Gate the whole affordance on the logged-in user's group scope (`admin`/`owner`) — a plain member shouldn't see it. Render the banned list with an "Unban" action per row (refresh on success). Mirrors the official sample app's "Banned Members" section (the `sample_banned_members` string). This closes the ban round-trip: ban (in `CometChatGroupMembers`) → view banned → unban.
64
+
65
+ ## Common pitfalls (BAKED)
66
+ - **Default-on affordances that need stitching.** A drop-in can render a live-looking control BY DEFAULT that no-ops until the host wires a callback + companion panel. When FETCHing props, flag these and either wire or hide them — never let one dead-end. Known cases (v7): `CometChatConversations` `showSearchBar` (default `true`) only client-side-filters loaded names → wire `onSearchBarClicked`→`CometChatSearch` or set `showSearchBar={false}`; `CometChatMessageList` thread-reply indicator → wire `onThreadRepliesClick` + thread panel or set `hideReplyInThreadOption`. See `features.json` `needs_stitching` and AUDIT.md.
67
+ - Emitting a **contracted** component (e.g. `CometChatConversations`, `CometChatGroupMembers`) without its FULL `contracts.json` min_capabilities ships an incomplete/inconsistent screen — include the full minimum every time (a group details screen MUST have view/add/kick/ban/banned/scope).
68
+ - **Create-group form offering only Public/Private (AUDIT-081).** No kit create-group component exists, so the form is host-built — it MUST include the **Password-protected** type (with a password field required on submit), not just public/private. See "Creating a group" above.
69
+ - Referencing a component that isn't in the catalog (phantom). Rebuilding a drop-in from base parts when a prop/slot exists. Assuming v6 prop names — v7 changed the composition model; fetch current props.
70
+
71
+ ## Verify it works
72
+ The component renders and its data populates (list fills, message sends). If it's empty, confirm it's inside `CometChatProvider` with a logged-in user.