I'm planning to develop a native iOS app using Swift on Salesforce1. Any sample code/ guidance which shows how to fire the Salesforce REST API and render the response on UI will be helpful.

2 Answers 2


As a starting point, you can refer to this tutorial from Raja Rao (Salesforce Developer Relations Team) which explains how to integrate Swift in your existing Salesforce native iOS app. The source code is available here


Please checkout the post at http://4loopers.io/developing-ios-apps-using-swift/ for the steps involved in building an iOS app using Swift from scratch.

The basic steps are: - Create a Swift Project in XCode

  • Download and set up your XCode project as outlined in https://github.com/forcedotcom/SalesforceMobileSDK-iOS-Distribution

  • In the Build Settings—>Header search paths add the paths for the Salesforce Mobile SDK

  • Add an Objective C file. It’ll ask if you want to configure a objective C bridging header. Click Yes and delete the Objective C file and just keep the birding header

  • Import the relevant headers from the Salesforce Mobile SDK

  • Set up Remote App in Salesforce and get the clientid and callback URL to be added to SFDCSettings.swift

  • That seems relevant, but stackexchange discourages answers that are just links to other sites. Can you edit your answer to summarize some key points? Sep 24, 2014 at 2:45
  • It's very relevant and it's an improvement on the tutorial mentioned in the post above. The link has the technical details on building iOS apps for Force.com using Apple's new language named Swift. Oct 1, 2014 at 16:10
  • @HariKolasani, what ca_peterson was trying to say is that you should post relative content (or at least a summary) from the linked page to your answer. Links can break over time which risks making the answer worthless later down the road! I've edited your answer as an example.
    – Matt Lacey
    Oct 1, 2014 at 23:53

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.