Insights That Power Innovation | Praecipio

6 Things To Consider When Building Salesforce Apps

Written by Praecipio | Jul 18, 2022 5:00:00 AM

To keep up with the fast-paced digital landscape, businesses depend on software for carrying out day-to-day business operations, connecting teams, and simplifying workflows. This probably explains why the global application development software market is anticipated to reach $733.5 billion by 2028.

After helping some of the world’s leading brands drive business innovation with our custom software solutions, we've learned a thing or two (or six!) along the way about building custom software that keeps teams and their tools connected. Specifically with Salesforce, our applications and integrations (whether those be specific customer use cases or general ones via the Atlassian Marketplace) have brought systems together, increased productivity, and empowered sales teams to win more deals

Through our experience with developing custom solutions for the world's leading CRM platform, we've identified some key things to consider to help get you started when building Salesforce apps.

#1 – Hit the Trail(head)

Salesforce is a big, well-established environment. There’s a lot you need to know about the REST API, the development process, and packaging and distributing your applications. The Salesforce Developer Training available at https://trailhead.salesforce.com provides free training courses along with sandbox environments to do the exercises. It’s a great way to quickly come up to speed on the topics you need to know more about.

The courses are not limited to development topics. If you need to learn more about using Salesforce or just want to understand the ins and outs of the Partner program, the Trailhead is the place to go.

#2 – The REST API is nice

The Praecipio development team does a lot of integration work, helping our customers improve their workflows by connecting different systems together. We work with many platforms, and have seen many APIs that are REST in name only. Often these are thin wrappers over an older XML API, or they don’t handle relationships in a RESTful fashion. Salesforce gets it right. The API is clean, consistent, and easy to use.

The API also provides a lot of useful metadata, which can help you make your software exceptional. When working with any object, you can get a list of all of the object’s fields, the labels for those fields (which may have been customized or localized), each field’s type, and whether a field is required or not. For any field whose value is selected from a list, there is an API call to return the list of valid values for the field.

#3 – Leverage a library for your stack

While the API is well-designed, it is large and feature-rich. Starting from scratch can be daunting, and you might not even be aware of some of its features. Instead of rolling your own code, take advantage of open source projects that wrap the API in your language. To achieve this, we use the Restforce Ruby GemSimple Salesforce is a well-regarded Python customer, and jsforce is available for JavaScript developers.

#4 – Deploy with the force (CLI)

Books, tutorials, and Trailhead courses on Salesforce development typically have you developing in the Salesforce GUI. There are times when that is valuable. The Developer Console provides a REPL that is handy for testing out ideas and debugging problems.

However, if you are like most developers, you have invested a lot of time getting your development environment just the way you like it. Fortunately, it is possible to integrate the Salesforce development process into just about any workflow. The folks at Heroku, a Salesforce company, have developed a Command Line Interface called Force, that allows you to interact with Salesforce using an API, instead of the GUI. You can upload and download templates and code, test snippets, view logs, inspect and change settings, plus much more. You can do just about anything you could do in the Salesforce GUI and while doing it in a scriptable, repeatable way.

#5 – Not all Salesforce instances have API access

Salesforce offers a number of editions, each with different pricing and features. One of the features that is not available on the lower cost plans is API access. Trying to access the API of an organization with the Contact Edition, Group Edition, or Professional Edition will raise an error. It’s also possible for the administrator of other Editions to turn off API access. Full details can be found in this help article.

However, it is possible for a developer to get API access in these editions, which bring us to our final expert tip.

#6 – Managed packages and unmanaged packages. Choose wisely.

One of the topics that can be confusing for new Salesforce developers is Packages. It’s an important topic to understand because your choice can limit who can use your application and how.

Packages are ultimately bundles of customizations created by you that other Salesforce users can install into their organization. You customize a Salesforce instance and then, using a Salesforce-provided tool, you package up those customizations and publish them.

Once you have created a package, you can simply share a link to it. This is then considered an Unmanaged Package. Alternatively, you can submit that package to Salesforce for review, after which it will be published as a Managed Package, available in the Salesforce AppExchange.

Pros of Unmanaged Packages

  • Free to create.
  • Can be released at any time.
  • You can sell them directly to your customers.

Cons of Unmanaged Packages

  • Not in the AppExchange, you have to market directly to your potential customers.
  • Some companies will not install Unmanaged Packages, preferring only Salesforce approved applications from the AppExchange.
  • As noted above, API access is unavailable in some Salesforce Editions.
  • No automatic upgrades. If you make changes, your customers will have to manually install the new version.

Pros of Managed Packages

  • Customers can find you in the AppExchange.
  • Automatic upgrades are available.
  • Salesforce manages payments and licensing.
  • Full API access for all Editions. Editions of Salesforce that are not normally allowed to use the API are granted access for Managed Packages.

Cons of Managed Packages

  • Setup cost. The review process for a Managed Package includes a security review, which is expensive and time consuming. If your application will be free, this fee is waived, but you still must complete the security review.
  • Review time. The initial review process can take several months.
  • Salesforce takes a percentage of all sales through the AppExchange.

Ultimately, it’s a business decision. If you want to be in the AppExchange or have API access to all Editions of Salesforce, then you will need to have a Managed Package. However, if you want to move fast, sell directly, and avoid upfront costs, then an Unmanaged Package may be for you.

What's Next?

Still feel like you need some guidance on your custom development initiative? The award-winning team at Praecipio can bring our Salesforce expertise and software development best practices to your next project. Let us know how we can support your organization and help design innovative solutions that scale with speed of your business.