@cometchat/skills 4.2.1 → 4.4.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 (234) hide show
  1. package/LICENSE +21 -0
  2. package/README.md +33 -12
  3. package/bin/install.js +59 -4
  4. package/package.json +14 -1
  5. package/skills/cometchat/SKILL.md +460 -77
  6. package/skills/cometchat/references/asking-questions.md +48 -0
  7. package/skills/cometchat-a11y/SKILL.md +3 -2
  8. package/skills/cometchat-android-v5/SKILL.md +2 -1
  9. package/skills/cometchat-android-v5-calls/SKILL.md +36 -22
  10. package/skills/cometchat-android-v5-calls/references/README.md +1 -1
  11. package/skills/cometchat-android-v5-calls/references/add-calls-to-existing-chat.md +7 -5
  12. package/skills/cometchat-android-v5-calls/references/audio-controls.md +4 -4
  13. package/skills/cometchat-android-v5-calls/references/call-layouts.md +33 -25
  14. package/skills/cometchat-android-v5-calls/references/call-session.md +2 -2
  15. package/skills/cometchat-android-v5-calls/references/custom-ui.md +5 -5
  16. package/skills/cometchat-android-v5-calls/references/event-listeners.md +2 -2
  17. package/skills/cometchat-android-v5-calls/references/idle-timeout.md +20 -14
  18. package/skills/cometchat-android-v5-calls/references/in-call-chat.md +1 -1
  19. package/skills/cometchat-android-v5-calls/references/migration-v4-to-v5.md +43 -27
  20. package/skills/cometchat-android-v5-calls/references/participant-management.md +3 -3
  21. package/skills/cometchat-android-v5-calls/references/raise-hand.md +25 -19
  22. package/skills/cometchat-android-v5-calls/references/recording.md +2 -2
  23. package/skills/cometchat-android-v5-calls/references/ringing-integration.md +1 -1
  24. package/skills/cometchat-android-v5-calls/references/screen-sharing.md +5 -9
  25. package/skills/cometchat-android-v5-calls/references/session-settings.md +3 -3
  26. package/skills/cometchat-android-v5-calls/references/setup.md +1 -1
  27. package/skills/cometchat-android-v5-calls/references/share-invite.md +9 -4
  28. package/skills/cometchat-android-v5-calls/references/video-controls.md +4 -4
  29. package/skills/cometchat-android-v5-calls/references/voip-calling.md +2 -2
  30. package/skills/cometchat-android-v5-components/SKILL.md +4 -3
  31. package/skills/cometchat-android-v5-core/SKILL.md +20 -2
  32. package/skills/cometchat-android-v5-customization/SKILL.md +171 -7
  33. package/skills/cometchat-android-v5-extensions/SKILL.md +7 -4
  34. package/skills/cometchat-android-v5-features/SKILL.md +5 -4
  35. package/skills/cometchat-android-v5-placement/SKILL.md +2 -1
  36. package/skills/cometchat-android-v5-production/SKILL.md +2 -1
  37. package/skills/cometchat-android-v5-push/SKILL.md +2 -3
  38. package/skills/cometchat-android-v5-testing/SKILL.md +2 -1
  39. package/skills/cometchat-android-v5-theming/SKILL.md +2 -1
  40. package/skills/cometchat-android-v5-troubleshooting/SKILL.md +3 -2
  41. package/skills/cometchat-android-v6/SKILL.md +2 -1
  42. package/skills/cometchat-android-v6-builder-settings/SKILL.md +11 -7
  43. package/skills/cometchat-android-v6-calls/SKILL.md +79 -18
  44. package/skills/cometchat-android-v6-calls/references/advanced-features.md +87 -0
  45. package/skills/cometchat-android-v6-calls/references/call-layouts.md +24 -15
  46. package/skills/cometchat-android-v6-calls/references/call-session.md +2 -2
  47. package/skills/cometchat-android-v6-calls/references/device-management.md +17 -16
  48. package/skills/cometchat-android-v6-calls/references/idle-timeout.md +7 -4
  49. package/skills/cometchat-android-v6-calls/references/in-call-chat.md +13 -8
  50. package/skills/cometchat-android-v6-calls/references/raise-hand.md +6 -4
  51. package/skills/cometchat-android-v6-compose-components/SKILL.md +52 -29
  52. package/skills/cometchat-android-v6-compose-customization/SKILL.md +156 -1
  53. package/skills/cometchat-android-v6-compose-placement/SKILL.md +129 -40
  54. package/skills/cometchat-android-v6-compose-theming/SKILL.md +27 -1
  55. package/skills/cometchat-android-v6-core/SKILL.md +389 -9
  56. package/skills/cometchat-android-v6-events/SKILL.md +4 -1
  57. package/skills/cometchat-android-v6-extensions/SKILL.md +2 -1
  58. package/skills/cometchat-android-v6-features/SKILL.md +26 -2
  59. package/skills/cometchat-android-v6-kotlin-components/SKILL.md +31 -1
  60. package/skills/cometchat-android-v6-kotlin-customization/SKILL.md +172 -1
  61. package/skills/cometchat-android-v6-kotlin-placement/SKILL.md +20 -5
  62. package/skills/cometchat-android-v6-kotlin-theming/SKILL.md +36 -5
  63. package/skills/cometchat-android-v6-migration/SKILL.md +44 -42
  64. package/skills/cometchat-android-v6-production/SKILL.md +6 -3
  65. package/skills/cometchat-android-v6-push/SKILL.md +43 -2
  66. package/skills/cometchat-android-v6-testing/SKILL.md +11 -8
  67. package/skills/cometchat-android-v6-troubleshooting/SKILL.md +26 -5
  68. package/skills/cometchat-angular-calls/SKILL.md +256 -389
  69. package/skills/cometchat-angular-calls/references/add-calls-to-existing-chat.md +3 -2
  70. package/skills/cometchat-angular-calls/references/call-layouts.md +29 -12
  71. package/skills/cometchat-angular-calls/references/call-session.md +2 -2
  72. package/skills/cometchat-angular-calls/references/custom-ui.md +18 -10
  73. package/skills/cometchat-angular-calls/references/device-management.md +53 -34
  74. package/skills/cometchat-angular-calls/references/group-calls.md +45 -24
  75. package/skills/cometchat-angular-calls/references/idle-timeout.md +31 -15
  76. package/skills/cometchat-angular-calls/references/ngzone-and-async-callbacks.md +7 -6
  77. package/skills/cometchat-angular-calls/references/raise-hand.md +9 -4
  78. package/skills/cometchat-angular-calls/references/recording-screen-share.md +32 -39
  79. package/skills/cometchat-angular-calls/references/ringing-integration.md +3 -1
  80. package/skills/cometchat-angular-calls/references/share-invite.md +11 -5
  81. package/skills/cometchat-angular-calls/references/virtual-background.md +29 -0
  82. package/skills/cometchat-angular-components/SKILL.md +149 -620
  83. package/skills/cometchat-angular-core/SKILL.md +235 -293
  84. package/skills/cometchat-angular-customization/SKILL.md +415 -223
  85. package/skills/cometchat-angular-features/SKILL.md +216 -334
  86. package/skills/cometchat-angular-patterns/SKILL.md +168 -359
  87. package/skills/cometchat-angular-placement/SKILL.md +189 -560
  88. package/skills/cometchat-angular-production/SKILL.md +241 -92
  89. package/skills/cometchat-angular-push/SKILL.md +280 -294
  90. package/skills/cometchat-angular-testing/SKILL.md +430 -158
  91. package/skills/cometchat-angular-theming/SKILL.md +190 -265
  92. package/skills/cometchat-angular-troubleshooting/SKILL.md +192 -157
  93. package/skills/cometchat-astro-patterns/SKILL.md +22 -1
  94. package/skills/cometchat-calls/SKILL.md +25 -19
  95. package/skills/cometchat-calls/references/use-case-broadcast.md +15 -10
  96. package/skills/cometchat-calls/references/use-case-marketplace.md +2 -3
  97. package/skills/cometchat-calls/references/use-case-support.md +3 -4
  98. package/skills/cometchat-calls/references/use-case-team.md +23 -12
  99. package/skills/cometchat-calls/references/use-case-telehealth.md +3 -4
  100. package/skills/cometchat-components/SKILL.md +163 -25
  101. package/skills/cometchat-core/SKILL.md +412 -13
  102. package/skills/cometchat-customization/SKILL.md +50 -25
  103. package/skills/cometchat-features/SKILL.md +313 -34
  104. package/skills/cometchat-flutter-v5/SKILL.md +10 -4
  105. package/skills/cometchat-flutter-v5-calls/SKILL.md +188 -158
  106. package/skills/cometchat-flutter-v5-calls/references/add-calls-to-existing-chat.md +48 -24
  107. package/skills/cometchat-flutter-v5-calls/references/call-layouts.md +20 -15
  108. package/skills/cometchat-flutter-v5-calls/references/call-session.md +100 -145
  109. package/skills/cometchat-flutter-v5-calls/references/device-management.md +12 -8
  110. package/skills/cometchat-flutter-v5-calls/references/group-calls.md +30 -36
  111. package/skills/cometchat-flutter-v5-calls/references/idle-timeout.md +15 -13
  112. package/skills/cometchat-flutter-v5-calls/references/in-call-chat.md +12 -9
  113. package/skills/cometchat-flutter-v5-calls/references/migration-v4-to-v5.md +115 -65
  114. package/skills/cometchat-flutter-v5-calls/references/raise-hand.md +41 -30
  115. package/skills/cometchat-flutter-v5-calls/references/ringing-integration.md +17 -14
  116. package/skills/cometchat-flutter-v5-calls/references/share-invite.md +8 -2
  117. package/skills/cometchat-flutter-v5-conversations/SKILL.md +2 -1
  118. package/skills/cometchat-flutter-v5-core/SKILL.md +20 -2
  119. package/skills/cometchat-flutter-v5-customization/SKILL.md +136 -5
  120. package/skills/cometchat-flutter-v5-events/SKILL.md +2 -1
  121. package/skills/cometchat-flutter-v5-messages/SKILL.md +2 -1
  122. package/skills/cometchat-flutter-v5-production/SKILL.md +15 -6
  123. package/skills/cometchat-flutter-v5-push/SKILL.md +2 -1
  124. package/skills/cometchat-flutter-v5-testing/SKILL.md +17 -6
  125. package/skills/cometchat-flutter-v5-theming/SKILL.md +2 -1
  126. package/skills/cometchat-flutter-v5-troubleshooting/SKILL.md +7 -6
  127. package/skills/cometchat-flutter-v5-users-groups/SKILL.md +3 -2
  128. package/skills/cometchat-flutter-v6/SKILL.md +17 -16
  129. package/skills/cometchat-flutter-v6-calls/SKILL.md +78 -63
  130. package/skills/cometchat-flutter-v6-calls/references/add-calls-to-existing-chat.md +8 -6
  131. package/skills/cometchat-flutter-v6-calls/references/advanced-features.md +89 -0
  132. package/skills/cometchat-flutter-v6-calls/references/call-layouts.md +15 -12
  133. package/skills/cometchat-flutter-v6-calls/references/call-session.md +2 -2
  134. package/skills/cometchat-flutter-v6-calls/references/device-management.md +9 -3
  135. package/skills/cometchat-flutter-v6-calls/references/group-calls.md +10 -10
  136. package/skills/cometchat-flutter-v6-calls/references/idle-timeout.md +15 -7
  137. package/skills/cometchat-flutter-v6-calls/references/in-call-chat.md +6 -3
  138. package/skills/cometchat-flutter-v6-calls/references/raise-hand.md +23 -16
  139. package/skills/cometchat-flutter-v6-components/SKILL.md +32 -11
  140. package/skills/cometchat-flutter-v6-conversations/SKILL.md +39 -11
  141. package/skills/cometchat-flutter-v6-core/SKILL.md +348 -10
  142. package/skills/cometchat-flutter-v6-customization/SKILL.md +97 -25
  143. package/skills/cometchat-flutter-v6-events/SKILL.md +3 -2
  144. package/skills/cometchat-flutter-v6-features/SKILL.md +15 -6
  145. package/skills/cometchat-flutter-v6-messages/SKILL.md +111 -60
  146. package/skills/cometchat-flutter-v6-migration/SKILL.md +18 -25
  147. package/skills/cometchat-flutter-v6-placement/SKILL.md +79 -50
  148. package/skills/cometchat-flutter-v6-production/SKILL.md +13 -12
  149. package/skills/cometchat-flutter-v6-push/SKILL.md +43 -21
  150. package/skills/cometchat-flutter-v6-testing/SKILL.md +6 -6
  151. package/skills/cometchat-flutter-v6-theming/SKILL.md +38 -5
  152. package/skills/cometchat-flutter-v6-troubleshooting/SKILL.md +182 -17
  153. package/skills/cometchat-flutter-v6-users-groups/SKILL.md +12 -4
  154. package/skills/cometchat-i18n/SKILL.md +139 -78
  155. package/skills/cometchat-ios/SKILL.md +4 -2
  156. package/skills/cometchat-ios-calls/SKILL.md +225 -95
  157. package/skills/cometchat-ios-calls/references/add-calls-to-existing-chat.md +11 -9
  158. package/skills/cometchat-ios-calls/references/audio-modes-and-controls.md +45 -0
  159. package/skills/cometchat-ios-calls/references/avaudiosession-routing.md +6 -7
  160. package/skills/cometchat-ios-calls/references/call-layouts.md +31 -91
  161. package/skills/cometchat-ios-calls/references/call-session.md +51 -54
  162. package/skills/cometchat-ios-calls/references/callkit-and-pushkit.md +33 -29
  163. package/skills/cometchat-ios-calls/references/custom-ui.md +38 -38
  164. package/skills/cometchat-ios-calls/references/group-calls.md +33 -70
  165. package/skills/cometchat-ios-calls/references/idle-timeout.md +24 -25
  166. package/skills/cometchat-ios-calls/references/in-call-chat.md +19 -23
  167. package/skills/cometchat-ios-calls/references/migration-v4-to-v5.md +128 -70
  168. package/skills/cometchat-ios-calls/references/picture-in-picture.md +20 -20
  169. package/skills/cometchat-ios-calls/references/raise-hand.md +14 -227
  170. package/skills/cometchat-ios-calls/references/recording-screen-share.md +35 -122
  171. package/skills/cometchat-ios-calls/references/ringing-integration.md +17 -16
  172. package/skills/cometchat-ios-calls/references/share-invite.md +8 -12
  173. package/skills/cometchat-ios-calls/references/swiftui-uikit-hosting.md +4 -4
  174. package/skills/cometchat-ios-components/SKILL.md +200 -12
  175. package/skills/cometchat-ios-core/SKILL.md +281 -11
  176. package/skills/cometchat-ios-customization/SKILL.md +276 -110
  177. package/skills/cometchat-ios-features/SKILL.md +64 -36
  178. package/skills/cometchat-ios-placement/SKILL.md +15 -12
  179. package/skills/cometchat-ios-production/SKILL.md +12 -4
  180. package/skills/cometchat-ios-push/SKILL.md +53 -19
  181. package/skills/cometchat-ios-testing/SKILL.md +14 -9
  182. package/skills/cometchat-ios-theming/SKILL.md +39 -3
  183. package/skills/cometchat-ios-troubleshooting/SKILL.md +41 -21
  184. package/skills/cometchat-native-bare-patterns/SKILL.md +56 -18
  185. package/skills/cometchat-native-calls/SKILL.md +89 -19
  186. package/skills/cometchat-native-calls/references/add-calls-to-existing-chat.md +2 -2
  187. package/skills/cometchat-native-calls/references/call-layouts.md +15 -14
  188. package/skills/cometchat-native-calls/references/call-session.md +2 -2
  189. package/skills/cometchat-native-calls/references/custom-ui.md +12 -8
  190. package/skills/cometchat-native-calls/references/device-management.md +53 -30
  191. package/skills/cometchat-native-calls/references/group-calls.md +35 -30
  192. package/skills/cometchat-native-calls/references/idle-timeout.md +6 -6
  193. package/skills/cometchat-native-calls/references/in-call-chat.md +10 -8
  194. package/skills/cometchat-native-calls/references/migration-v4-to-v5.md +2 -2
  195. package/skills/cometchat-native-calls/references/raise-hand.md +15 -13
  196. package/skills/cometchat-native-calls/references/recording-screen-share.md +49 -170
  197. package/skills/cometchat-native-calls/references/share-invite.md +7 -5
  198. package/skills/cometchat-native-calls/references/voip-push-end-to-end.md +4 -2
  199. package/skills/cometchat-native-components/SKILL.md +91 -57
  200. package/skills/cometchat-native-core/SKILL.md +281 -9
  201. package/skills/cometchat-native-customization/SKILL.md +150 -28
  202. package/skills/cometchat-native-expo-patterns/SKILL.md +77 -27
  203. package/skills/cometchat-native-features/SKILL.md +79 -49
  204. package/skills/cometchat-native-placement/SKILL.md +19 -10
  205. package/skills/cometchat-native-production/SKILL.md +9 -3
  206. package/skills/cometchat-native-push/SKILL.md +2 -1
  207. package/skills/cometchat-native-testing/SKILL.md +1 -2
  208. package/skills/cometchat-native-theming/SKILL.md +54 -29
  209. package/skills/cometchat-native-troubleshooting/SKILL.md +71 -3
  210. package/skills/cometchat-nextjs-patterns/SKILL.md +48 -6
  211. package/skills/cometchat-placement/SKILL.md +42 -3
  212. package/skills/cometchat-production/SKILL.md +12 -5
  213. package/skills/cometchat-react-calls/SKILL.md +220 -10
  214. package/skills/cometchat-react-calls/references/add-calls-to-existing-chat.md +4 -3
  215. package/skills/cometchat-react-calls/references/call-layouts.md +5 -6
  216. package/skills/cometchat-react-calls/references/call-session.md +1 -1
  217. package/skills/cometchat-react-calls/references/custom-ui.md +61 -15
  218. package/skills/cometchat-react-calls/references/device-management.md +55 -51
  219. package/skills/cometchat-react-calls/references/group-calls.md +18 -23
  220. package/skills/cometchat-react-calls/references/idle-timeout.md +25 -12
  221. package/skills/cometchat-react-calls/references/in-call-chat.md +7 -7
  222. package/skills/cometchat-react-calls/references/migration-v4-to-v5.md +9 -11
  223. package/skills/cometchat-react-calls/references/raise-hand.md +14 -14
  224. package/skills/cometchat-react-calls/references/recording-screen-share.md +39 -38
  225. package/skills/cometchat-react-calls/references/ringing-integration.md +2 -2
  226. package/skills/cometchat-react-calls/references/share-invite.md +4 -5
  227. package/skills/cometchat-react-calls/references/testing-calls-on-web.md +20 -2
  228. package/skills/cometchat-react-calls/references/virtual-background.md +32 -0
  229. package/skills/cometchat-react-patterns/SKILL.md +57 -4
  230. package/skills/cometchat-react-push/SKILL.md +258 -72
  231. package/skills/cometchat-react-router-patterns/SKILL.md +43 -4
  232. package/skills/cometchat-react-testing/SKILL.md +14 -5
  233. package/skills/cometchat-theming/SKILL.md +181 -18
  234. package/skills/cometchat-troubleshooting/SKILL.md +40 -20
@@ -1,54 +1,59 @@
1
1
  ---
2
2
  name: cometchat-angular-production
3
- description: "Production-readiness for Angular — server-minted auth tokens, user management CRUD, external-backend recipes (Express / Hono / Firebase Functions / Vercel). Angular has no API routes, so the backend is always external."
3
+ description: "Production-readiness for CometChat Angular UI Kit v5 (@cometchat/chat-uikit-angular@5) — server-minted auth tokens via CometChatUIKit.loginWithAuthToken(authToken), user management CRUD, environment.prod.ts hardening (no authKey, no REST API Key), external-backend recipes (Express / Hono / Firebase Functions / Vercel), and the security checklist. Angular ships src/ to the client, so the REST API Key is always server-only."
4
4
  license: "MIT"
5
- compatibility: "Angular >=12 <=15; @cometchat/chat-uikit-angular ^4; @cometchat/chat-sdk-javascript ^4"
6
- allowed-tools: "shell, file-read, file-search, file-list, ask-user"
5
+ compatibility: "Angular >=17 <22; @cometchat/chat-uikit-angular ^5.0; @cometchat/chat-sdk-javascript ^4.1"
7
6
  metadata:
8
7
  author: "CometChat"
9
- version: "3.0.0"
10
- tags: "cometchat angular production auth token security user-management rest-api"
8
+ version: "4.0.0"
9
+ tags: "cometchat angular production auth token security user-management rest-api v5 standalone"
11
10
  ---
12
11
 
13
12
  ## Purpose
14
13
 
15
- Teaches Claude how to move an Angular CometChat integration from dev-mode Auth Key to production-ready server-minted auth tokens + user CRUD. Covers:
14
+ Teaches Claude how to move a CometChat **Angular UI Kit v5** (`@cometchat/chat-uikit-angular@5`) integration from dev-mode Auth Key to production-ready server-minted auth tokens + user CRUD. Covers:
16
15
 
17
16
  1. Why the dev `authKey` can't ship to production
18
17
  2. Auth Key vs REST API Key — which lives where
19
- 3. Server endpoint recipes (Express / Hono / Firebase Functions / Vercel)
20
- 4. Client-side: `CometChatUIKit.login({ authToken })` + token refresh
21
- 5. User CRUD endpoints + auth-provider integration (Firebase Auth / Supabase / Clerk / Auth0)
22
- 6. Security checklist
18
+ 3. The token auth pattern (4 steps)
19
+ 4. Server endpoint recipes (Express / Hono / Firebase Functions / Vercel) Angular has no API routes, so the backend is always external
20
+ 5. Client-side: `CometChatUIKit.loginWithAuthToken(authToken)` + token refresh
21
+ 6. User CRUD — the REST API (production path) and the client helpers (`CometChatUIKit.createUser` / `updateUser`)
22
+ 7. Environment files (`environment.ts` → `environment.prod.ts`) + production build
23
+ 8. Security checklist
23
24
 
24
- **Read `cometchat-angular-core` first** — production just swaps one call on the init service, but understanding the init lifecycle is the prerequisite.
25
+ **Read `cometchat-angular-core` first** — production just swaps one call on the init/login flow, but understanding the standalone `init → login → render` lifecycle is the prerequisite.
25
26
 
26
- Ground truth: `docs/ui-kit/angular/methods`, and the cross-platform REST API at `https://{APP_ID}.api-{REGION}.cometchat.io/v3/`.
27
+ Ground truth: `@cometchat/chat-uikit-angular@5.0.2` source (`projects/cometchat-uikit/src/lib/cometchat-uikit.ts` — the `CometChatUIKit` class with both static and injectable APIs), the sample-app login flow (`projects/sample-app/src` — `main.ts` init, `services/auth.service.ts` login/logout), `docs/ui-kit/angular/integration.mdx` + `docs/fundamentals/user-auth`, and the cross-platform REST API at `https://{APP_ID}.api-{REGION}.cometchat.io/v3/`. Verify any non-obvious symbol against the kit source before relying on it. **Official docs:** https://www.cometchat.com/docs/fundamentals/user-auth · **Docs MCP:** `claude mcp add --transport http cometchat-docs https://www.cometchat.com/docs/mcp` (or fetch the URL directly without MCP).
27
28
 
28
29
  ---
29
30
 
30
31
  ## 1. Why production auth matters
31
32
 
32
- In dev mode, `CometChatUIKit.login({ uid: "..." })` uses the `authKey` passed to `UIKitSettingsBuilder`. That key is bundled into your Angular JavaScript. Anyone can open DevTools → Sources → search for the key string and use it to log in as **ANY** user in your CometChat app — read private messages, send as other users, access every conversation.
33
+ In dev mode, `CometChatUIKit.login(uid)` uses the `authKey` passed to `UIKitSettingsBuilder.setAuthKey()`. That key is bundled into your Angular JavaScript. Anyone can open DevTools → Sources → search for the key string and use it to log in as **ANY** user in your CometChat app — read private messages, send as other users, access every conversation.
33
34
 
34
35
  Production MUST use server-side token generation:
35
36
 
36
37
  - Your **server** holds the REST API Key (a different key from the client Auth Key).
37
38
  - On user login, your server calls CometChat's REST API with the REST API Key to mint a short-lived **Auth Token** for that specific UID.
38
- - Your Angular client receives the Auth Token and calls `CometChatUIKit.login({ authToken })`.
39
+ - Your Angular client receives the Auth Token and calls `CometChatUIKit.loginWithAuthToken(authToken)`.
39
40
  - If the token leaks, the blast radius is one user session, not your whole app.
40
41
 
42
+ The dev `setAuthKey()` call MUST NOT ship in production builds. See §7 for the `environment.prod.ts` swap.
43
+
41
44
  ---
42
45
 
43
46
  ## 2. Auth Key vs REST API Key — two different keys
44
47
 
45
48
  | Key | Where in dashboard | Purpose | Where it lives |
46
49
  |---|---|---|---|
47
- | **Auth Key** | "Auth Keys" table | Client-side SDK `login({ uid })` in dev mode | **Client bundle** — dev only. Never in production builds. |
48
- | **REST API Key** | "REST API Keys" table | Server-to-server: token generation, user CRUD | **Server only.** Never in `environment.ts`, `environment.prod.ts`, or any Angular file. |
50
+ | **Auth Key** | API & Auth Keys → "Auth Keys" table | Client-side SDK `login(uid)` in dev mode | **Client bundle** — dev only. Never in production builds. |
51
+ | **REST API Key** | API & Auth Keys → "REST API Keys" table | Server-to-server: token generation, user CRUD | **Server only.** Never in `environment.ts`, `environment.prod.ts`, or any file under `src/`. |
49
52
 
50
53
  If the project only has an Auth Key, the user needs to generate a REST API Key in the dashboard: **API & Auth Keys → REST API Keys → Add Key**. Pick "Full Access" for server-side use.
51
54
 
55
+ **Why this matters more in Angular than elsewhere:** Angular has no server runtime and no `process.env` split. Everything under `src/` — including both `environment.ts` files — is compiled into the client bundle. There is no framework-prefix convention (`NEXT_PUBLIC_`, `VITE_`) that decides client vs server. So the rule is absolute: the REST API Key never appears in any Angular source file.
56
+
52
57
  ---
53
58
 
54
59
  ## 3. The token auth pattern (4 steps)
@@ -57,21 +62,30 @@ If the project only has an Auth Key, the user needs to generate a REST API Key i
57
62
  1. User logs into YOUR auth (Firebase Auth / Supabase / Clerk / Auth0 / custom)
58
63
 
59
64
  2. Angular app asks YOUR backend for a CometChat auth token
60
- ↓ (POST /api/cometchat-token with Authorization: Bearer <jwt>)
65
+ ↓ (POST /api/cometchat-token with Authorization: Bearer <your-jwt>)
61
66
  3. Backend calls CometChat REST API → gets an Auth Token for that UID
62
67
  ↓ POST https://{APP_ID}.api-{REGION}.cometchat.io/v3/users/{uid}/auth_tokens
63
68
  with header apiKey: <REST_API_KEY>
64
69
 
65
- 4. Angular calls CometChatUIKit.login({ authToken: "..." })
70
+ 4. Angular calls CometChatUIKit.loginWithAuthToken(authToken)
66
71
  ```
67
72
 
68
- The Angular client never sees the REST API Key. The server never ships a password or email to the client.
73
+ The Angular client never sees the REST API Key. The backend derives the UID from the authenticated session — never from the request body (see anti-patterns §9).
74
+
75
+ The CometChat REST API requires two headers on every server-to-server call:
76
+ - `appId` — your CometChat app ID
77
+ - `apiKey` — your **REST API Key** (NOT the Auth Key used in dev mode)
69
78
 
70
79
  ---
71
80
 
72
81
  ## 4. Server endpoint recipes
73
82
 
74
- Angular projects don't have built-in API routes. You need a separate backend.
83
+ Angular projects have **no built-in API routes**. You need a separate backend. The token endpoint does the same thing in every recipe:
84
+
85
+ 1. Validate the caller is authenticated (your existing auth middleware/guard).
86
+ 2. Derive the UID from the authenticated session.
87
+ 3. POST to `https://{APP_ID}.api-{REGION}.cometchat.io/v3/users/{uid}/auth_tokens` with the `apiKey` header.
88
+ 4. Return `{ authToken }` to the client.
75
89
 
76
90
  ### 4a. Express (Node.js backend)
77
91
 
@@ -86,7 +100,7 @@ const REGION = process.env.COMETCHAT_REGION!;
86
100
  const REST_API_KEY = process.env.COMETCHAT_REST_API_KEY!;
87
101
 
88
102
  router.post("/cometchat-token", requireAuth, async (req, res) => {
89
- const uid = req.user.id; // from authenticated session — NOT from request body
103
+ const uid = req.user.id; // from authenticated session — NOT from request body
90
104
 
91
105
  const r = await fetch(
92
106
  `https://${APP_ID}.api-${REGION}.cometchat.io/v3/users/${encodeURIComponent(uid)}/auth_tokens`,
@@ -102,6 +116,7 @@ router.post("/cometchat-token", requireAuth, async (req, res) => {
102
116
  );
103
117
 
104
118
  if (!r.ok) {
119
+ console.error("CometChat token error:", await r.text());
105
120
  return res.status(r.status).json({ error: "Failed to generate auth token" });
106
121
  }
107
122
 
@@ -112,6 +127,13 @@ router.post("/cometchat-token", requireAuth, async (req, res) => {
112
127
  export default router;
113
128
  ```
114
129
 
130
+ Enable CORS for your Angular origin (e.g. `http://localhost:4200` in dev) so the browser can call this endpoint:
131
+
132
+ ```typescript
133
+ import cors from "cors";
134
+ app.use(cors({ origin: "http://localhost:4200" }));
135
+ ```
136
+
115
137
  ### 4b. Hono (Cloudflare Workers / Bun / Node)
116
138
 
117
139
  ```typescript
@@ -210,6 +232,8 @@ export default async function handler(req: NextApiRequest, res: NextApiResponse)
210
232
 
211
233
  ## 5. Client-side: Angular service for production auth
212
234
 
235
+ The v5 production login call is **`CometChatUIKit.loginWithAuthToken(authToken)`** — it takes a **bare token string**, the same way v5 dev login takes a bare uid string (`CometChatUIKit.login(uid)`). Do NOT pass an object — `loginWithAuthToken({ authToken })` is a v4-ism and will not compile against the v5 types (verified: `static loginWithAuthToken(authToken: string): Promise<CometChat.User>`).
236
+
213
237
  ```typescript
214
238
  // cometchat-auth.service.ts
215
239
  import { Injectable } from "@angular/core";
@@ -223,11 +247,14 @@ export class CometChatAuthService {
223
247
  constructor(private http: HttpClient) {}
224
248
 
225
249
  async loginWithToken(appJwt: string): Promise<void> {
226
- // 1. Check if already logged in
227
- const existing = await CometChatUIKit.getLoggedinUser();
228
- if (existing) return;
229
-
230
- // 2. Fetch CometChat auth token from your backend
250
+ // 1. Already logged in? getLoggedInUser() (capital I) is the SYNC v5 accessor —
251
+ // returns CometChat.User | null from the cached BehaviorSubject, no await.
252
+ // (There is also an async getLoggedinUser() — lowercase i — returning
253
+ // Promise<CometChat.User | null>; the sample-app route guards use that one.
254
+ // Both are real v5 symbols; pick sync for a fast already-logged-in short-circuit.)
255
+ if (CometChatUIKit.getLoggedInUser()) return;
256
+
257
+ // 2. Fetch a CometChat auth token from your backend.
231
258
  const response = await firstValueFrom(
232
259
  this.http.post<{ authToken: string }>(
233
260
  environment.cometchat.tokenEndpoint,
@@ -236,8 +263,8 @@ export class CometChatAuthService {
236
263
  )
237
264
  );
238
265
 
239
- // 3. Login with the auth token
240
- await CometChatUIKit.login({ authToken: response.authToken });
266
+ // 3. Log in with the bare token string (v5 signature).
267
+ await CometChatUIKit.loginWithAuthToken(response.authToken);
241
268
  }
242
269
 
243
270
  async logout(): Promise<void> {
@@ -250,9 +277,13 @@ export class CometChatAuthService {
250
277
  // app.component.ts — production-aware init
251
278
  import { Component, OnInit } from "@angular/core";
252
279
  import { CometChatAuthService } from "./cometchat-auth.service";
253
- import { YourAuthService } from "./your-auth.service"; // your existing auth
280
+ import { YourAuthService } from "./your-auth.service"; // your existing auth
254
281
 
255
- @Component({ selector: "app-root", templateUrl: "./app.component.html" })
282
+ @Component({
283
+ selector: "app-root",
284
+ standalone: true,
285
+ templateUrl: "./app.component.html",
286
+ })
256
287
  export class AppComponent implements OnInit {
257
288
  isReady = false;
258
289
 
@@ -262,59 +293,95 @@ export class AppComponent implements OnInit {
262
293
  ) {}
263
294
 
264
295
  ngOnInit(): void {
265
- // CometChat.init() already called via APP_INITIALIZER
266
- this.yourAuth.getJwt().then((jwt) => {
267
- return this.cometChatAuth.loginWithToken(jwt);
268
- }).then(() => {
269
- this.isReady = true;
270
- }).catch(console.error);
296
+ // CometChatUIKit.init() already ran via APP_INITIALIZER (see cometchat-angular-core).
297
+ this.yourAuth
298
+ .getJwt()
299
+ .then((jwt) => this.cometChatAuth.loginWithToken(jwt))
300
+ .then(() => (this.isReady = true))
301
+ .catch(console.error);
271
302
  }
272
303
  }
273
304
  ```
274
305
 
275
- ### Production environment file
306
+ Gate the chat UI on `isReady` so no `<cometchat-*>` component renders before `loginWithAuthToken` resolves.
307
+
308
+ ### Token refresh on disconnect / expiry
309
+
310
+ CometChat auth tokens expire. When a token expires, the SDK disconnects. Re-mint and re-login through a single in-flight guard so concurrent triggers don't fire two logins (the SDK throws *"Please wait until the previous login request ends."* on a racing second `loginWithAuthToken`).
276
311
 
277
312
  ```typescript
278
- // src/environments/environment.prod.ts
279
- export const environment = {
280
- production: true,
281
- cometchat: {
282
- appId: "YOUR_APP_ID",
283
- region: "us",
284
- // No authKey in production
285
- tokenEndpoint: "https://api.yourapp.com/cometchat-token",
286
- },
287
- };
313
+ // In CometChatAuthService — module/instance-level guard.
314
+ private refreshInFlight: Promise<void> | null = null;
315
+
316
+ async refreshSession(appJwt: string): Promise<void> {
317
+ if (this.refreshInFlight) {
318
+ await this.refreshInFlight; // another caller already triggered a refresh
319
+ return;
320
+ }
321
+ this.refreshInFlight = (async () => {
322
+ const response = await firstValueFrom(
323
+ this.http.post<{ authToken: string }>(
324
+ environment.cometchat.tokenEndpoint,
325
+ {},
326
+ { headers: new HttpHeaders({ Authorization: `Bearer ${appJwt}` }) }
327
+ )
328
+ );
329
+ await CometChatUIKit.loginWithAuthToken(response.authToken);
330
+ })();
331
+ try {
332
+ await this.refreshInFlight;
333
+ } finally {
334
+ this.refreshInFlight = null;
335
+ }
336
+ }
288
337
  ```
289
338
 
339
+ Wire `refreshSession` to a `CometChat.addConnectionListener(...)` `onDisconnected` handler, or simply re-mint and re-login whenever a CometChat operation returns an auth error.
340
+
290
341
  ---
291
342
 
292
343
  ## 6. User management CRUD
293
344
 
294
- When someone signs up in your app, create a matching CometChat user on your backend.
345
+ In production you keep CometChat users in sync with your app's users. There are two paths:
346
+
347
+ **The production path is the REST API** (server-side, REST API Key). Create the CometChat user the moment the app user signs up — otherwise `loginWithAuthToken` fails with *"user does not exist."*
295
348
 
296
- ### 6a. Create a user on signup
349
+ **The client helpers exist too** — `CometChatUIKit.createUser(user)` and `CometChatUIKit.updateUser(user)` are exported by the v5 kit (verified: both `(user: CometChat.User): Promise<CometChat.User>`). But they require the Auth Key on the UIKitSettings to authorize, which is exactly what you remove in production. **Treat them as a dev/admin-tool convenience, not the production user-provisioning mechanism.** Production provisioning belongs server-side via the REST API. (Note: the kit exposes `createUser`/`updateUser` only — there is no client-side `deleteUser`; deletion is REST-only.)
350
+
351
+ If you do use the client helper (e.g. a one-off admin screen running with the Auth Key), the shape is a `CometChat.User`:
352
+
353
+ ```typescript
354
+ import { CometChat } from "@cometchat/chat-sdk-javascript";
355
+ import { CometChatUIKit } from "@cometchat/chat-uikit-angular";
356
+
357
+ const user = new CometChat.User("user-uid-1");
358
+ user.setName("Alice");
359
+ await CometChatUIKit.createUser(user); // Promise<CometChat.User>
360
+ ```
361
+
362
+ ### 6a. Create a user on signup (REST — production path)
297
363
 
298
364
  ```typescript
299
365
  async function createCometChatUser(uid: string, name: string, avatarUrl?: string) {
300
- const r = await fetch(
301
- `https://${APP_ID}.api-${REGION}.cometchat.io/v3/users`,
302
- {
303
- method: "POST",
304
- headers: {
305
- "Content-Type": "application/json",
306
- appId: APP_ID,
307
- apiKey: REST_API_KEY,
308
- },
309
- body: JSON.stringify({ uid, name, avatar: avatarUrl }),
310
- }
311
- );
312
- if (!r.ok) throw new Error(`CometChat user create failed: ${await r.text()}`);
366
+ const r = await fetch(`https://${APP_ID}.api-${REGION}.cometchat.io/v3/users`, {
367
+ method: "POST",
368
+ headers: {
369
+ "Content-Type": "application/json",
370
+ appId: APP_ID,
371
+ apiKey: REST_API_KEY,
372
+ },
373
+ body: JSON.stringify({ uid, name, ...(avatarUrl ? { avatar: avatarUrl } : {}) }),
374
+ });
375
+ if (!r.ok) {
376
+ // 409 = user already exists — safe to ignore on re-signup.
377
+ if (r.status === 409) return;
378
+ throw new Error(`CometChat user create failed: ${await r.text()}`);
379
+ }
313
380
  return r.json();
314
381
  }
315
382
  ```
316
383
 
317
- ### 6b. Update a user on profile change
384
+ ### 6b. Update a user on profile change (REST)
318
385
 
319
386
  ```typescript
320
387
  async function updateCometChatUser(uid: string, updates: { name?: string; avatar?: string }) {
@@ -335,7 +402,7 @@ async function updateCometChatUser(uid: string, updates: { name?: string; avatar
335
402
  }
336
403
  ```
337
404
 
338
- ### 6c. Delete a user on account deletion
405
+ ### 6c. Delete a user on account deletion (REST only)
339
406
 
340
407
  ```typescript
341
408
  async function deleteCometChatUser(uid: string) {
@@ -355,48 +422,129 @@ async function deleteCometChatUser(uid: string) {
355
422
  }
356
423
  ```
357
424
 
425
+ ### 6d. Where to hook user CRUD into common auth providers
426
+
427
+ - **Firebase Auth** — `functions.auth.user().onCreate(...)` → `createCometChatUser`; `.onDelete(...)` → `deleteCometChatUser`. Firebase fires no event on profile change, so call `updateCometChatUser` from your profile-update endpoint.
428
+ - **Supabase** — a Database Webhook on `auth.users` (INSERT/UPDATE/DELETE) → the matching CRUD helper.
429
+ - **Clerk** — the `user.created` / `user.updated` / `user.deleted` webhook events (verify the svix signature first).
430
+ - **Auth0** — a post-registration Action / Log Stream webhook → `createCometChatUser`.
431
+
358
432
  ---
359
433
 
360
- ## 7. Environment variables split between client + server
434
+ ## 7. Environment files + production build
435
+
436
+ Angular has no `.env` / `process.env`. Config lives in `src/environments/`. The production build (`ng build --configuration production`) swaps `environment.ts` → `environment.prod.ts` via the `fileReplacements` in `angular.json`. **The split is your only lever** — anything in the active file ships to the client.
437
+
438
+ ### Dev environment (Auth Key — never built for production)
439
+
440
+ ```typescript
441
+ // src/environments/environment.ts (development)
442
+ export const environment = {
443
+ production: false,
444
+ cometchat: {
445
+ appId: "YOUR_APP_ID",
446
+ region: "us", // "us" | "eu" | "in"
447
+ authKey: "YOUR_AUTH_KEY", // dev only — must NOT exist in environment.prod.ts
448
+ },
449
+ };
450
+ ```
451
+
452
+ ### Production environment (no Auth Key, no REST API Key — just a token endpoint)
453
+
454
+ ```typescript
455
+ // src/environments/environment.prod.ts (production)
456
+ export const environment = {
457
+ production: true,
458
+ cometchat: {
459
+ appId: "YOUR_APP_ID",
460
+ region: "us",
461
+ // No authKey — mint auth tokens server-side and call loginWithAuthToken().
462
+ // No REST API Key — it lives on your backend only.
463
+ tokenEndpoint: "https://api.yourapp.com/cometchat-token",
464
+ },
465
+ };
466
+ ```
467
+
468
+ ### The build swap (already in angular.json for the standard schematic)
469
+
470
+ ```json
471
+ "configurations": {
472
+ "production": {
473
+ "fileReplacements": [
474
+ {
475
+ "replace": "src/environments/environment.ts",
476
+ "with": "src/environments/environment.prod.ts"
477
+ }
478
+ ]
479
+ }
480
+ }
481
+ ```
482
+
483
+ ### The init builder must drop setAuthKey() in production
484
+
485
+ Because `environment.prod.ts` has no `authKey`, the `UIKitSettingsBuilder` must not call `.setAuthKey()` in a production build. Guard it:
486
+
487
+ ```typescript
488
+ const builder = new UIKitSettingsBuilder()
489
+ .setAppId(environment.cometchat.appId)
490
+ .setRegion(environment.cometchat.region)
491
+ .subscribePresenceForAllUsers();
492
+
493
+ // Dev only — the prod environment has no authKey, so this branch is skipped.
494
+ if (!environment.production && "authKey" in environment.cometchat) {
495
+ builder.setAuthKey((environment.cometchat as any).authKey);
496
+ }
497
+
498
+ await CometChatUIKit.init(builder.build());
499
+ ```
500
+
501
+ ### Variable visibility summary
361
502
 
362
503
  | Variable | Location | Visibility |
363
504
  |---|---|---|
364
- | `COMETCHAT_APP_ID` | `environment.ts` + server | OK client-side |
365
- | `COMETCHAT_REGION` | `environment.ts` + server | OK client-side |
366
- | `COMETCHAT_AUTH_KEY` | **Dev `environment.ts` only.** Remove from `environment.prod.ts`. | Should NEVER ship in a production Angular build |
367
- | `COMETCHAT_REST_API_KEY` | **Server only.** Your backend's env. | Never in any Angular file, ever |
368
- | `COMETCHAT_TOKEN_ENDPOINT` | `environment.prod.ts` | Your backend URL safe in client bundle |
505
+ | `appId` | `environment.ts` + `environment.prod.ts` + backend | OK client-side |
506
+ | `region` | `environment.ts` + `environment.prod.ts` + backend | OK client-side |
507
+ | `authKey` | **Dev `environment.ts` only.** Absent from `environment.prod.ts`. | Must NEVER ship in a production Angular build |
508
+ | `tokenEndpoint` | `environment.prod.ts` | Your backend URL safe in client bundle |
509
+ | REST API Key | **Backend env only.** Never under `src/`. | Never in any Angular file, ever |
369
510
 
370
511
  ---
371
512
 
372
513
  ## 8. Security checklist
373
514
 
374
- Before releasing to production:
375
-
376
- - [ ] `authKey` removed from `environment.prod.ts`
377
- - [ ] Production init uses `UIKitSettingsBuilder` without `.setAuthKey()`
378
- - [ ] Production login uses `CometChatUIKit.login({ authToken })`, not `login({ uid })`
379
- - [ ] `COMETCHAT_REST_API_KEY` lives only on your backend (check with `grep -r REST_API_KEY src/`)
380
- - [ ] Token endpoint is behind auth — unauthenticated users can't mint a token for an arbitrary UID
381
- - [ ] UID derivation on the token endpoint comes from the authenticated session, NOT from the request body
382
- - [ ] Rate limit on the token endpoint (prevents abuse)
383
- - [ ] HTTPS-only no HTTP in production
384
- - [ ] User CRUD endpoints are authenticated (or called from webhooks with signature verification)
385
- - [ ] CometChat user deletion happens on account deletion (GDPR / privacy compliance)
515
+ Before releasing to production, verify every item:
516
+
517
+ - [ ] `authKey` removed from `environment.prod.ts`.
518
+ - [ ] Production init uses `UIKitSettingsBuilder` **without** `.setAuthKey()`.
519
+ - [ ] Production login uses `CometChatUIKit.loginWithAuthToken(authToken)` (bare string), **not** `login(uid)`.
520
+ - [ ] REST API Key lives only on your backend verify with `grep -rIE "REST_API_KEY|restApiKey" src/` (must return nothing).
521
+ - [ ] Token endpoint is behind auth — unauthenticated callers can't mint a token for an arbitrary UID.
522
+ - [ ] UID is derived from the authenticated session on the backend, **not** from the request body.
523
+ - [ ] Rate limit on the token endpoint (prevents abuse / token farming).
524
+ - [ ] CORS on the token endpoint allows only your Angular origin(s).
525
+ - [ ] HTTPS-only no HTTP in production.
526
+ - [ ] CometChat user is created (REST API) when the app user signs up — otherwise `loginWithAuthToken` fails with "user does not exist."
527
+ - [ ] User CRUD endpoints are authenticated (or invoked from webhooks with signature verification).
528
+ - [ ] CometChat user deletion runs on account deletion (GDPR / privacy compliance).
529
+ - [ ] Production build confirmed to swap `environment.ts` → `environment.prod.ts` (check `fileReplacements` in `angular.json`).
386
530
 
387
531
  ---
388
532
 
389
533
  ## 9. Anti-patterns
390
534
 
391
- 1. **NEVER put the REST API Key in any Angular file.** Not in `environment.ts`, `environment.prod.ts`, `assets/`, or any TypeScript file. Angular bundles everything in `src/` into the client JavaScript.
535
+ 1. **NEVER put the REST API Key in any Angular file.** Not in `environment.ts`, `environment.prod.ts`, `assets/`, or any TypeScript under `src/`. Angular bundles everything in `src/` into client JavaScript. There is no `process.env` split to save you.
536
+
537
+ 2. **NEVER let the client choose the UID to mint a token for.** The backend must derive UID from the authenticated session. A `POST /cometchat-token { uid: "..." }` that trusts the body is equivalent to no auth — any user can impersonate any other.
538
+
539
+ 3. **Don't pass an object to `loginWithAuthToken`.** v5 takes a bare string: `loginWithAuthToken(token)`, mirroring `login(uid)`. `loginWithAuthToken({ authToken })` is a v4-era shape and won't typecheck against v5.
392
540
 
393
- 2. **NEVER let the client specify the UID to mint a token for.** The server must derive UID from the authenticated session. A `POST /cometchat-token { uid: "..." }` that trusts the body is equivalent to no auth.
541
+ 4. **Don't use `login(uid)` in production.** `uid` login requires the Auth Key on the UIKitSettings. In production set neither `.setAuthKey()` on the builder nor call `login(uid)` use `loginWithAuthToken(token)`.
394
542
 
395
- 3. **Don't cache the auth token to localStorage forever.** It expires. Either re-mint on every cold start or store with a short TTL and refresh on 401.
543
+ 5. **Don't rely on `CometChatUIKit.createUser` / `updateUser` for production provisioning.** They authorize with the Auth Key (which you remove in production). Provision users server-side via the REST API; the kit helpers are a dev/admin convenience only. (And note: the kit has no client `deleteUser` — deletion is REST-only.)
396
544
 
397
- 4. **Don't use `login({ uid })` in production.** `uid` mode requires an Auth Key on the UIKitSettings. In production, set neither `authKey` on the builder nor call `login({ uid })`.
545
+ 6. **Don't cache the auth token in localStorage forever.** It expires. Re-mint on cold start, or store with a short TTL and refresh on disconnect/401 (§5).
398
546
 
399
- 5. **Don't forget user CRUD.** A user who signs up in your app but has no matching CometChat user will get "user does not exist" errors on `login({ authToken })`.
547
+ 7. **Don't forget user CRUD.** A user who signs up in your app but has no matching CometChat user gets "user does not exist" on `loginWithAuthToken`.
400
548
 
401
549
  ---
402
550
 
@@ -404,12 +552,13 @@ Before releasing to production:
404
552
 
405
553
  | Skill | When to route |
406
554
  |---|---|
407
- | `cometchat-angular-core` | Init / login / module setup — prerequisite |
408
- | `cometchat-angular-components` | The base component props |
555
+ | `cometchat-angular-core` | Init / login / standalone setup / environment — prerequisite |
556
+ | `cometchat-angular-components` | Base component props |
409
557
  | `cometchat-angular-placement` | Where your chat UI goes |
410
- | `cometchat-angular-patterns` | Angular-specific auth guard + APP_INITIALIZER |
411
- | `cometchat-angular-theming` | Theme customization |
558
+ | `cometchat-angular-patterns` | Standalone wiring, APP_INITIALIZER, auth guard |
559
+ | `cometchat-angular-theming` | CSS-variable theme customization |
412
560
  | `cometchat-angular-features` | Feature flags |
413
- | `cometchat-angular-customization` | If customization depends on server-side data |
561
+ | `cometchat-angular-calls` | Voice/video calling |
562
+ | `cometchat-angular-customization` | Customization tied to server-side data |
414
563
  | `cometchat-angular-production` | This skill — server tokens + user CRUD |
415
564
  | `cometchat-angular-troubleshooting` | 401 on token fetch, "user does not exist" on login |