Editor’s note: This is a guest by Eric Davis who helps entrepreneurs build apps for Shopify.

With over 200,000 online stores Shopify has become an online e-commerce platform for many new entrepreneurs.

One downside to using any platform is that your store is stuck if it needs something outside the ordinary.

Except it’s not.

You may have already seen the Shopify App Store where 3rd parties build free and paid apps that integrate with Shopify. What you might not know is that Shopify provides a mechanism that lets you build your own app for your store.

These are called private apps.

A private Shopify app can access most of the APIs and data that public App Store apps can, but you can tailor it to work exactly how you want it.

Isn’t app development difficult

One fear you might have about building a new private app is that it must be difficult and time-consuming. I mean, it is software development after all.

I’m going to show you the process I used to build and launch a small, but moderately complex Shopify app in under a week. I don’t have a team of 20 developers and designers, it’s just myself doing all of the development and relying on tools and processes to get everything done.

The app I built is called Dripify. At its core, it only does three things:

  1. It connects to Shopify
  2. It connects to the Drip email marketing service
  3. It copies the snippet of JavaScript code from Drip into the Shopify theme

Simple and small, but each step involved some tricky process.

1. Planning

The first thing I did before I even wrote a line of code was to plan out what I was doing and, more importantly, what I wasn’t doing.

I knew going into it that I wanted to limit my time investment to one week while still running my consulting business. That means I had a little less than 30 hours of actual development available.

The quickest way to start planning is to create a software roadmap. This is basically a document that lists all of the features, what they do, what Shopify APIs they might use, and a rough estimate of how long it will take to do.

Normally in my roadmaps I like to get into business risks, task dependencies (e.g. X before Y and Z), and other more advanced planning but for this app I kept it simple.

After going through the three main features Dripify had and thinking about what other supporting features they’d need, my estimates came out at 3.75 to 4.75 days – a bit close to my total budget but with enough room to adapt.

2. Connecting to Shopify

Since I develop all of my apps in Ruby on Rails I’m able to take advantage of the official Shopify App library Shopify maintains. This library acts as a skeleton and includes most of the components you need to authenticate with Shopify and start making API calls.

Since Dripify is intended to be used by multiple stores and to be offered in the App Store, I used Shopify’s OAuth flow to let each store authenticate with the app securely. OAuth is tricky to setup because there are many options and steps involved but using the Shopify App library made it much easier.

Now if I wanted to keep Dripify private and integrate it with only one store as a private app, I could have skipped OAuth completely and got connected to Shopify in only a few minutes. So if you’re considering building an app just for your store, make sure to look into private Shopify apps first. They’re a bit different than regular, public apps.

3. Connecting to Drip

Once Dripify was connected to Shopify it was easy to build up a simple user-interface inside of Shopify. The next hurdle was to connect to the Drip email marketing service.

dripify-complete

 

At the time, Drip had just launched their own version of OAuth to allow apps to integrate with Drip. While it’s similar to Shopify, the details of it were a bit different.

This was a major risk with the project. Since Drip’s OAuth was new, there was a risk of running into problems with the service that would have been out of my control. I addressed this with a workaround, just in case:

If the Drip connection is unable to work automatically, Dripify could ask the user to copy and paste the Drip snippet into Dripify’s control panel manually.

Naturally this would be a poor user experience but having a workaround option just in case things went wrong is a great idea with the risky parts of any development project.

It ended up that the OAuth connection to Drip worked fine. There were some complicated parts because both Shopify and Drip were using OAuth but they were able to coexist peacefully.

4. Copying the JavaScript snippet to the Shopify theme

With connections to both Shopify and Drip, the last piece needed was to take the Drip snippet and save it to the Shopify theme.

At the first glance, this appears easy. Shopify has APIs to modify theme files. The Drip snippet is just a short piece of JavaScript.

Behind that simple appearance though was one major risk: Dripify would have to modify the template used on every page of a live store.

Screw it up and the store could break.

The actual logic to add the snippet was simple, but I put that logic through dozens of different test cases to make sure it worked as expected, from things like non-standard themes, a store that already has the snippet installed, to what to do when a user overwrites the theme file on accident.

I will admit, it was fun to brainstorm all of the different ways the snippet install could fail and then figure out how to work around it. The end result was simple but it took quite a bit of time to complete.

5. Launch

Once all the features were complete, I was ready to launch Dripify to the public Shopify App Store. I allowed this to take longer than the week of development so I could write the marketing copy, record a demo video, and submit everything to Shopify for review.

creating shopify app dripify

All said and done, the entire development process took 28.50 hours with another 6 hours to get it into the App Store.

So don’t be afraid about building a Shopify app, either a private one for your store or a public one to be sold in the App Store. They’re powerful and with just a little bit of code you can really automate and integrate Shopify deeper into your business.

You can download the roadmap I used to plan Dripify’s development here.

About the author
Eric Davis helps e-commerce entrepreneurs build apps for Shopify. He has helped teams with all aspects of development. Ranging from initial concept, through launching, and into growing pains that are bundled so often with success.

PAYMILL

ACCEPT ONLINE PAYMENTS

The easiest way to accept credit and debit card payments on your website

Sign Up

 

Guest Blogger

This is a guest post written by one of our contributors.