{"id":"76dd7a39-2d64-480a-9e00-aedcf4759819","shortId":"NkfCmx","kind":"skill","title":"cometchat-android-v6-builder-settings","tagline":"CometChat Android UIKit v6 UIKitSettings configuration — all builder options for SDK init, presence, calling, and host overrides","description":"> **Companion skills:** cometchat-android-v6-core (init/login), cometchat-android-v6-push (FCM/VoIP)\n\n## Purpose\n\nDetailed reference for `UIKitSettings.UIKitSettingsBuilder` — all configuration options for initializing the CometChat SDK, including presence subscriptions, calling features, and host overrides.\n\n## Use this skill when\n\n- Configuring presence subscription types (all users, roles, friends)\n- Enabling calling features and configuring `CallSettingsBuilder`\n- Overriding admin or client host URLs\n- Controlling socket connection behavior\n- Understanding the full `UIKitSettingsBuilder` API\n\n## Do not use this skill when\n\n- Just doing basic init/login (use `cometchat-android-v6-core` for quick setup)\n- Working with UI components or theming\n\n## 1. UIKitSettingsBuilder — Complete API\n\n```kotlin\nimport com.cometchat.uikit.core.UIKitSettings\n\nval settings = UIKitSettings.UIKitSettingsBuilder()\n\n    // Required\n    .setAppId(\"APP_ID\")                          // CometChat App ID\n    .setRegion(\"us\")                             // \"us\" or \"eu\"\n\n    // Authentication (dev only — use token auth in production)\n    .setAuthKey(\"AUTH_KEY\")                      // Auth key from dashboard\n\n    // Presence subscriptions\n    .subscribePresenceForAllUsers()              // Subscribe to all users' presence\n    .subscribePresenceForRoles(listOf(\"admin\"))  // Subscribe by roles\n    .subscribePresenceForFriends()               // Subscribe to friends' presence\n\n    // Socket connection\n    .setAutoEstablishSocketConnection(true)      // Auto-connect (default: true)\n\n    // Calling\n    .setEnableCalling(true)                      // Auto-init CometChatCalls SDK (default: false)\n    .setCallSettingsBuilder(callSettingsBuilder)  // Custom call config (optional)\n\n    // Host overrides (advanced — for on-premise deployments)\n    .overrideAdminHost(\"https://custom-admin.example.com\")\n    .overrideClientHost(\"https://custom-client.example.com\")\n\n    .build()\n```\n\n## 2. Presence Subscription Types\n\nOnly one subscription type is active at a time. The last one set wins.\n\n| Method | Subscription Type | Use Case |\n|---|---|---|\n| (none) | `\"NONE\"` | No presence updates (default) |\n| `subscribePresenceForAllUsers()` | `\"ALL_USERS\"` | Small apps where you want all online statuses |\n| `subscribePresenceForRoles(roles)` | `\"ROLES\"` | Subscribe to specific user roles |\n| `subscribePresenceForFriends()` | `\"FRIENDS\"` | Social apps with friend lists |\n\n## 3. Calling Configuration\n\nWhen `setEnableCalling(true)` is set, `CometChatUIKit.init()` automatically initializes the CometChatCalls SDK after the Chat SDK succeeds:\n\n```kotlin\n// Basic calling setup\nval settings = UIKitSettings.UIKitSettingsBuilder()\n    .setAppId(\"APP_ID\")\n    .setRegion(\"us\")\n    .setAuthKey(\"AUTH_KEY\")\n    .setEnableCalling(true)\n    .build()\n```\n\nFor custom call settings:\n\n```kotlin\nimport com.cometchat.calls.core.CometChatCalls\n\nval callSettingsBuilder = CometChatCalls.CallSettingsBuilder(context, null)\n    .setDefaultAudioMode(\"SPEAKER\")\n    .startWithVideoMuted(true)\n\nval settings = UIKitSettings.UIKitSettingsBuilder()\n    .setAppId(\"APP_ID\")\n    .setRegion(\"us\")\n    .setAuthKey(\"AUTH_KEY\")\n    .setEnableCalling(true)\n    .setCallSettingsBuilder(callSettingsBuilder)\n    .build()\n```\n\nAfter init, retrieve the stored builder:\n\n```kotlin\nval builder: CometChatCalls.CallSettingsBuilder? = CometChatUIKit.getCallSettingsBuilder()\n```\n\n## 4. Checking Initialization State\n\n```kotlin\n// Chat SDK initialized?\nCometChatUIKit.isSDKInitialized()\n\n// Calls SDK initialized? (only true if enableCalling was true AND init succeeded)\nCometChatUIKit.isCallsSDKInitialized()\n```\n\n## 5. Application-Level Init Pattern\n\nFrom `master-app-jetpack`, the recommended pattern separates SDK init from Calls SDK init:\n\n```kotlin\nclass MyApplication : Application() {\n    fun onSDKInitialized() {\n        // Called after CometChatUIKit.init() succeeds\n        // CometChatCalls is auto-initialized if enableCalling = true\n        // Register call listeners here\n        addCallListener()\n    }\n}\n```\n\n## Hard rules\n\n- NEVER set both `subscribePresenceForAllUsers()` and `subscribePresenceForRoles()` — only the last one takes effect\n- NEVER use `setAuthKey()` in production — use `loginWithAuthToken()` instead\n- `setEnableCalling(true)` requires the CometChatCalls SDK dependency in your Gradle file\n- If CometChatCalls init fails, the Chat SDK still reports success — check `isCallsSDKInitialized()` separately\n- `overrideAdminHost()` and `overrideClientHost()` are for on-premise deployments only — do not use with cloud-hosted CometChat","tags":["cometchat","android","builder","settings","skills","agent-skills","ai-agent","chat","claude-code","cursor","messaging","nextjs"],"capabilities":["skill","source-cometchat","skill-cometchat-android-v6-builder-settings","topic-agent-skills","topic-ai-agent","topic-chat","topic-claude-code","topic-cometchat","topic-cursor","topic-messaging","topic-nextjs","topic-react","topic-react-native","topic-ui-kit"],"categories":["cometchat-skills"],"synonyms":[],"warnings":[],"endpointUrl":"https://skills.sh/cometchat/cometchat-skills/cometchat-android-v6-builder-settings","protocol":"skill","transport":"skills-sh","auth":{"type":"none","details":{"cli":"npx skills add cometchat/cometchat-skills","source_repo":"https://github.com/cometchat/cometchat-skills","install_from":"skills.sh"}},"qualityScore":"0.463","qualityRationale":"deterministic score 0.46 from registry signals: · indexed on github topic:agent-skills · 27 github stars · SKILL.md body (4,618 chars)","verified":false,"liveness":"unknown","lastLivenessCheck":null,"agentReviews":{"count":0,"score_avg":null,"cost_usd_avg":null,"success_rate":null,"latency_p50_ms":null,"narrative_summary":null,"summary_updated_at":null},"enrichmentModel":"deterministic:skill-github:v1","enrichmentVersion":1,"enrichedAt":"2026-05-18T19:04:45.804Z","embedding":null,"createdAt":"2026-05-07T13:05:04.900Z","updatedAt":"2026-05-18T19:04:45.804Z","lastSeenAt":"2026-05-18T19:04:45.804Z","tsv":"'1':117 '2':211 '3':266 '4':346 '5':368 'activ':220 'addcalllisten':411 'admin':78,164 'advanc':200 'android':3,8,28,34,105 'api':91,120 'app':129,132,244,262,293,323,377 'applic':370,392 'application-level':369 'auth':144,148,150,298,328 'authent':139 'auto':178,186,402 'auto-connect':177 'auto-init':185 'auto-initi':401 'automat':275 'basic':100,286 'behavior':86 'build':210,302,334 'builder':5,14,340,343 'call':20,54,72,182,195,267,287,305,355,386,395,408 'callsettingsbuild':76,193,311,333 'case':233 'chat':282,351,450 'check':347,455 'class':390 'client':80 'cloud':473 'cloud-host':472 'com.cometchat.calls.core.cometchatcalls':309 'com.cometchat.uikit.core.uikitsettings':123 'cometchat':2,7,27,33,49,104,131,475 'cometchat-android-v6-builder-settings':1 'cometchat-android-v6-core':26,103 'cometchat-android-v6-push':32 'cometchatcal':188,278,399,438,446 'cometchatcalls.callsettingsbuilder':312,344 'cometchatuikit.getcallsettingsbuilder':345 'cometchatuikit.init':274,397 'cometchatuikit.iscallssdkinitialized':367 'cometchatuikit.issdkinitialized':354 'companion':24 'complet':119 'compon':114 'config':196 'configur':12,44,63,75,268 'connect':85,174,179 'context':313 'control':83 'core':30,107 'custom':194,304 'custom-admin.example.com':207 'custom-client.example.com':209 'dashboard':153 'default':180,190,239 'depend':440 'deploy':205,466 'detail':39 'dev':140 'effect':425 'enabl':71 'enablecal':361,405 'eu':138 'fail':448 'fals':191 'fcm/voip':37 'featur':55,73 'file':444 'friend':70,171,260,264 'full':89 'fun':393 'gradl':443 'hard':412 'host':22,57,81,198,474 'id':130,133,294,324 'import':122,308 'includ':51 'init':18,187,336,365,372,384,388,447 'init/login':31,101 'initi':47,276,348,353,357,403 'instead':433 'iscallssdkiniti':456 'jetpack':378 'key':149,151,299,329 'kotlin':121,285,307,341,350,389 'last':225,422 'level':371 'list':265 'listen':409 'listof':163 'loginwithauthtoken':432 'master':376 'master-app-jetpack':375 'method':229 'myapplic':391 'never':414,426 'none':234,235 'null':314 'on-premis':202,463 'one':216,226,423 'onlin':249 'onsdkiniti':394 'option':15,45,197 'overrid':23,58,77,199 'overrideadminhost':206,458 'overrideclienthost':208,460 'pattern':373,381 'premis':204,465 'presenc':19,52,64,154,161,172,212,237 'product':146,430 'purpos':38 'push':36 'quick':109 'recommend':380 'refer':40 'regist':407 'report':453 'requir':127,436 'retriev':337 'role':69,167,252,253,258 'rule':413 'sdk':17,50,189,279,283,352,356,383,387,439,451 'separ':382,457 'set':6,125,227,273,290,306,320,415 'setappid':128,292,322 'setauthkey':147,297,327,428 'setautoestablishsocketconnect':175 'setcallsettingsbuild':192,332 'setdefaultaudiomod':315 'setenablecal':183,270,300,330,434 'setregion':134,295,325 'setup':110,288 'skill':25,61,96 'skill-cometchat-android-v6-builder-settings' 'small':243 'social':261 'socket':84,173 'source-cometchat' 'speaker':316 'specif':256 'startwithvideomut':317 'state':349 'status':250 'still':452 'store':339 'subscrib':157,165,169,254 'subscribepresenceforallus':156,240,417 'subscribepresenceforfriend':168,259 'subscribepresenceforrol':162,251,419 'subscript':53,65,155,213,217,230 'succeed':284,366,398 'success':454 'take':424 'theme':116 'time':223 'token':143 'topic-agent-skills' 'topic-ai-agent' 'topic-chat' 'topic-claude-code' 'topic-cometchat' 'topic-cursor' 'topic-messaging' 'topic-nextjs' 'topic-react' 'topic-react-native' 'topic-ui-kit' 'true':176,181,184,271,301,318,331,359,363,406,435 'type':66,214,218,231 'ui':113 'uikit':9 'uikitset':11 'uikitsettings.uikitsettingsbuilder':42,126,291,321 'uikitsettingsbuild':90,118 'understand':87 'updat':238 'url':82 'us':135,136,296,326 'use':59,94,102,142,232,427,431,470 'user':68,160,242,257 'v6':4,10,29,35,106 'val':124,289,310,319,342 'want':247 'win':228 'work':111","prices":[{"id":"13a63905-c612-416b-8858-1d0c3bfe0efb","listingId":"76dd7a39-2d64-480a-9e00-aedcf4759819","amountUsd":"0","unit":"free","nativeCurrency":null,"nativeAmount":null,"chain":null,"payTo":null,"paymentMethod":"skill-free","isPrimary":true,"details":{"org":"cometchat","category":"cometchat-skills","install_from":"skills.sh"},"createdAt":"2026-05-07T13:05:04.900Z"}],"sources":[{"listingId":"76dd7a39-2d64-480a-9e00-aedcf4759819","source":"github","sourceId":"cometchat/cometchat-skills/cometchat-android-v6-builder-settings","sourceUrl":"https://github.com/cometchat/cometchat-skills/tree/main/skills/cometchat-android-v6-builder-settings","isPrimary":false,"firstSeenAt":"2026-05-07T13:05:04.900Z","lastSeenAt":"2026-05-18T19:04:45.804Z"}],"details":{"listingId":"76dd7a39-2d64-480a-9e00-aedcf4759819","quickStartSnippet":null,"exampleRequest":null,"exampleResponse":null,"schema":null,"openapiUrl":null,"agentsTxtUrl":null,"citations":[],"useCases":[],"bestFor":[],"notFor":[],"kindDetails":{"org":"cometchat","slug":"cometchat-android-v6-builder-settings","github":{"repo":"cometchat/cometchat-skills","stars":27,"topics":["agent-skills","ai-agent","chat","claude-code","cometchat","cursor","messaging","nextjs","react","react-native","ui-kit"],"license":null,"html_url":"https://github.com/cometchat/cometchat-skills","pushed_at":"2026-05-18T05:04:24Z","description":"Add CometChat chat to any React, Next.js, React Native, Angular, Android, iOS, or Flutter project through your AI coding agent. Works with Claude Code, Cursor, Codex, VS Code Copilot, Windsurf, Cline, Kiro, and 50+ more agents.","skill_md_sha":"4eb368a4fdbbb596847769de70d18bfc8b4e8c65","skill_md_path":"skills/cometchat-android-v6-builder-settings/SKILL.md","default_branch":"main","skill_tree_url":"https://github.com/cometchat/cometchat-skills/tree/main/skills/cometchat-android-v6-builder-settings"},"layout":"multi","source":"github","category":"cometchat-skills","frontmatter":{"name":"cometchat-android-v6-builder-settings","license":"MIT","description":"CometChat Android UIKit v6 UIKitSettings configuration — all builder options for SDK init, presence, calling, and host overrides","compatibility":"Android 9.0+ (API 28); Kotlin 1.9+; com.cometchat:chatuikit-core-android:6.x"},"skills_sh_url":"https://skills.sh/cometchat/cometchat-skills/cometchat-android-v6-builder-settings"},"updatedAt":"2026-05-18T19:04:45.804Z"}}