Chapter 1. Getting Started with Shopify
Shopify is a Software as a Service (SaaS) e-commerce platform built to meet the needs of the typical storeowner. It offers hosting, shopping cart, payment processing, order management, product catalogs, blogging, and much more. A storeowner can sign up for Shopify, pick out a design, create a product catalog, set up a payment gateway, and make a sale on the same day—all without any programming or technical expertise.
Shopify gives you the ability to completely modify the HTML, CSS, and JavaScript of the storefront theme. Designers are able to add features such as visual effects, responsive designs, bundled products, shipping estimators, and social plugins that can accomplish almost everything that is expected of a modern e-commerce site.
For features such as inventory management, accounting, drop shipping, mailing lists, and, reporting, an application that communicates with Shopify's API and/or handles Shopify's XML notifications (called webhooks) is needed. In this book, we'll focus on building such an app. You should have an understanding of web development using a server-side language such as Ruby, PHP, or ASP.NET. Basic HTML, CSS, and JavaScript skills are also required because we'll be building a simple UI. Finally, familiarity with Shopify's features will be extremely helpful. If you've not used Shopify before, I encourage you to go through this excellent primer on the Shopify blog at http://www.shopify.com/technology/3671962-developing-shopify-apps-part-1-the-setup.
Throughout the course of this book, we will be building a web application that allows the storeowners to run contests by randomly picking a customer who has placed an order in the shop. Our app will be built using Ruby on Rails (http://rubyonrails.org), which is an open source web development framework that is relatively simple to learn. It is the same language that Shopify has been written in. A few popular Ruby libraries (for example, Active Merchant and Liquid) are extractions of the Shopify source code that have been released as open source. Rails is based on the Model-View-Controller (MVC) enterprise architecture pattern, so if you aren't familiar with this paradigm, I encourage you to head over to Wikipedia for a general overview (http://en.wikipedia.org/wiki/Model–view–controller).
This chapter will cover the following topics:
An overview of the Shopify platform
App development options
The Shopify API
The Shopify Webhook system
Tips on how to get started