Troubleshoot the Mobile Development Plugin
Resolve common installation, native app, and LWC issues with the Salesforce Mobile Development plugin.
- The plugin isn’t in the marketplace: Confirm that you registered the marketplace with
/plugin marketplace add forcedotcom/sf-skills, and that you install the plugin with the marketplace name,mobile-development@salesforce. If you registered the marketplace earlier, update it from the/pluginmenu to get the latest plugin list. - The skills don’t appear after installation: Run
/pluginto confirm thatmobile-developmentis installed. If it’s installed, restart Claude Code. In other environments, confirm thatnpx skills addcompleted without errors, and then restart your AI assistant. - The agent doesn’t load a skill for your prompt: Make your prompt more specific. Name the platform, such as iOS or Android, the component, or the capability, and use terms from the skill’s trigger phrases. In Claude Code, invoke the skill directly, for example,
/mobile-development:mobile-platform-offline-validate.
- The agent asks to install a skill that you didn’t request: The
mobile-apps-createskill hands off work to a platform skill, such asios-mobile-sdk, from the Mobile SDK or Agentforce SDK repository. Approve the install to continue. If you decline, the workflow stops because the platform skill owns the SDK setup steps. See Mobile Development Plugin Dependencies. - The agent asks which SDK or platform to use: Your prompt matches more than one SDK family or platform. Say whether you’re building a data-driven app, a chat-first agent app, or both, and whether you’re targeting iOS, Android, or both.
- Generated Agentforce code doesn’t compile: Upgrade to version 0.2.1 or later of the plugin. In earlier versions,
mobile-apps-createsometimes wrote the Agentforce integration by hand instead of loading the Agentforce SDK skill for your platform. - An iOS build fails with “file not found” errors: If you add files to the generated project manually, also add them to the
.xcodeprojfile. - The login screen doesn’t appear when the app launches: On iOS, confirm that
bootconfig.plist, which contains the connected app’s consumer key and callback URI, is in the target’s Copy Bundle Resources build phase, and thatInfo.plistsetsSFDCOAuthLoginHost. On Android, confirm thatAndroidManifest.xmlregistersMainApplicationand thatinitNative()runs inonCreate(). - Login completes, but the iOS app doesn’t advance or loses the session on relaunch: Mobile SDK can’t store OAuth tokens because the keychain entitlement is missing or stripped. Confirm that the app’s entitlements file includes
keychain-access-groups, and don’t build withCODE_SIGNING_ALLOWED=NO. For simulator builds, use ad-hoc signing withCODE_SIGN_IDENTITY=-.
For more login, build, and sync issues, see the troubleshooting references for the ios-mobile-sdk and android-mobile-sdk skills.
isAvailable()returnsfalseon a real device: Not every capability is supported in every Salesforce mobile app. Check the Mobile Capabilities Compatibility Summary for the app that runs your component. If the app supports the capability, an org-level setting can turn off the service. Fix the org configuration, not the code.- TypeScript can’t find the
lightning/mobileCapabilitiesimport: The module is declared globally inside Salesforce mobile apps. In your local project, install the@salesforce/lightning-typespackage withnpm install @salesforce/lightning-types. Then import the package once from a declaration file, such astypes/salesforce.d.ts, and include that file in yourtsconfig.json. - Sample code uses deprecated barcode methods: The deprecated
beginCapture(),resumeCapture(), andendCapture()methods still work, but new code usesscan()anddismiss(). Ask the skill to refactor the code. npx eslintcan’t find the Komaci plugin: Install@salesforce/eslint-plugin-lwc-graph-analyzerin your project. See Validate Lightning Web Components for Offline Use.- The analyzer reports
bundleAnalyzererrors: Keep the recommended configuration, which enables thebundleAnalyzerprocessor, and keep the component’s HTML templates next to its JavaScript file. - The review reports no findings for a component that you expect to fail: Confirm that the recommended ruleset is applied, not only the
bundleAnalyzerprocessor with no rules. Some rules also require the HTML templates to be present alongside the JavaScript file.
Generated code ownership
The code that the skills generate is yours. The skills generate standard Swift, Kotlin, and JavaScript source files that you can read, refactor, and commit to your own repository.