It’s easier than you think!

Shopping Carts and Payment Gateways

Posted on Jul 01, 2008 by Linda - E-Commerce

Introduction

Retail shopping has evolved dramatically over the years. In the earlier days of shopping, a shopkeeper would sit behind a counter and respond to requests from a customer, selecting a product from the shelf and handing it to the customer for her consideration. The customer would then indicate whether she was interested in buying it. If so, the product would be set aside, the shopkeeper would respond to the customer’s next request, and after the customer was satisfied with all the items set aside, the shopkeeper would prepare the final bill and accept payment. If the customer didn’t like a product, the shopkeeper would naturally reshelve it.

Today, most stores allow customers to do their own shopping. A customer may ask for assistance from one of the attendants, but on the whole, products are displayed in ways that make shopping easy. Thus stores can cater to many customers, each going about his shopping individually. The entire shopping experience has been made easy for the customer. Factors such as product layout, arrangement of displays, location and width of aisles, location of check out counters, and the availability of human assistance all play a key role in the overall shopping experience.

Another innovation in the shopping experience was the advent of “catalog shopping.” Here the entire storefront was replaced with a printed catalog of products and a precise method of placing orders via phone or mail. This new approach allowed businesses to operate in an entire region or an entire nation without maintaining retail stores. Catalog shopping offered competitive prices, as there was no overhead for maintaining retail stores, inventory, staff, and stocking logistics; few central warehouses and a well-established delivery system were used to fill orders. From the customer’s viewpoint, the entire shopping experience was now available from home.

Electronic shopping is an attempt to combine the shopping experience of both in-store shopping and catalog shopping. Web-based applications offer more interactivity than a printed catalog. They also have the ability to provide more media forms, such as audio, video clips, and animation, in addition to static text and pictures—all in an effort to enhance the shopping experience and, in the end, sell more merchandise. In fact, the success of the online shopping experience depends almost entirely on ease of shopping coupled with factors such as richer media.

Customers have their own shopping styles and sets of needs when they go shopping. A storefront and its contents look different and more or less appealing when viewed through the eyes of different customers. Thus the greatest challenge facing electronic storefronts is to cater to diverse customer needs and desires over a Web-based interface. The set of customer choices also varies. For example, one customer may like to pile up all potential purchases while shopping but delay the final decision of which item(s) to purchase until the very end. Another customer may like to make a single selection at a time. Customers have different payment habits too. Although the majority use credit cards to pay for retail purchases, customers still like to pay cash or by check in some cases. Even with credit cards, customers may prefer one credit card company to another. Shopping systems have to anticipate and take care of all these needs and preferences.

As Web shopping applications have matured, some technologies and components became standard for every electronic storefront implementation. In this chapter we focus on the two most important aspects of an electronic storefront—shopping carts and payment gateways. The purpose of this chapter is to familiarize you with a few key concepts and issues related to security.

Evolution of the Storefront

By taking a look at how retail businesses evolved over time, you can understand better the roles of various components of an electronic shopping framework. Let’s begin with the traditional model of retail shopping. Figure 3-1 shows various entities and interrelationships of traditional retail shopping.

Figure 3-1. Traditional retail business

In a traditional retail business, customers interact with the merchant via a storefront. The purpose of the storefront is to display and generally to stock enough merchandise for customers to purchase on a day-to-day basis. The storefront has ways to accept payments from customers for their purchases and if some orders can’t be filled directly on the store’s premises, the merchant is responsible for taking the order and payment information. The order is then passed along to the company owning the store for further processing.

The entire purchase and delivery process works something like this. First, the company validates the order in terms of accuracy of information and availability of requested merchandise. When it finds everything in order, the company processes the payment instructions with the help of its financial institution. Upon proper processing of the payment, the company interacts with its suppliers and its clearinghouse (distribution center or warehouse) to initiate shipment of the purchased goods against the order.

In addition to selling goods, a retail business has many other peripheral functions and activities. For example, it is also responsible for marketing the company’s merchandise, which is what draws customers to its storefront in the first place.

As the scale of operations, volumes, and need for efficiency increased, retail businesses began using software applications that captured the business logic of transactions and inventory control and carried out various business processes automatically. As they continued to prosper, businesses used more and more automation in their processes. Figure 3-2 shows how businesses increased their use of automation via computerization.

Figure 3-2. Automation via computerization

Computer systems capture and process transactions efficiently at the storefront. At the end of the day, all orders are transferred electronically to the company’s corporate computer systems. These systems are updated with data from suppliers and the clearinghouse, which help track inventory. The company’s systems, in turn, typically communicate with the bank’s computers to process payments in bulk. Once the payments are processed, the orders are sent to suppliers and the clearinghouse to be filled. However, the evolution doesn’t end here. As more users were connected to the Internet—and as Web application servers matured—electronic retail business (e-business or e-commerce) came into being. Instead of businesses making use of automation, businesses themselves became automated. Application servers were now capable of hosting entire business processes on the Internet and interfacing with business processes of other entities, such as financial institutions and suppliers. The Internet also provided the means for providing ancillary services such as marketing. The physical storefront began to be replaced by an electronic storefront. People began hosting storefronts on the Internet and selling directly to customers, who interacted with the electronic storefront through a Web browser.

It is now possible to capture orders, process payments, update inventories, and initiate order fulfillment in a matter of minutes. The entire system requires little human intervention. Figure 3-3 depicts the e-commerce model.

Figure 3-3. E-commerce model

Electronic Shopping

With the electronic retail business model in mind, let’s now follow the process of electronic shopping in an electronic storefront. Companies host their storefronts as Web applications on Web servers. The Web site becomes the store’s electronic identity. Customers “step into” stores by browsing the store’s Web site. The electronic storefront provides customers with a virtual shopping experience, as they browse the merchandise and decide what they want to buy. The electronic storefront also interfaces with a payment processing system or a payment gateway provided by the company’s financial institution for accepting payments on the merchant’s behalf. The electronic storefront also interfaces with the company’s corporate systems and the suppliers’ and clearinghouse’s systems for order processing and fulfillment.

When the customer visits the electronic storefront, or Web site, he browses the different products that the store sells. The customer then reads the description of the products, looks at product prices, and decides whether to buy one or more product. Once a customer has arrived at a decision to buy a particular product, he needs to set the product aside until the shopping “trip” completed. In a regular storefront, the customer uses a shopping cart to hold his selections until he is ready to check out. Today’s electronic shopping cart is analogous to the metal or plastic shopping cart familiar to every shopper. An electronic shopping cart holds the customer’s selections and when all the selections are made, the shopping cart helps the customer check out and pay for his purchases. Electronic storefronts handle customer payments via payment gateways provided by the storefront’s financial institution where it has its bank accounts. This application provides some sort of customization to serve customers’ varying needs. The payment gateway verifies the validity of the payment instrument used by the customer and takes the necessary actions to process the payment instrument and credit the merchant’s account with the appropriate funds. Figure 3-4 depicts a customer’s interaction with an electronic retail business.

Figure 3-4. Use of electronic shopping cart and payment gateway

Shopping Cart Systems

Shopping carts in storefronts are provided for the customer’s convenience. A customer picks up a shopping cart from the row of carts in the parking lot or at the storefront entrance. The customer pushes the cart around the store’s floor during the shopping session, filling it as she goes, until she is ready to check out. The customer then (sometimes) returns the cart to the store when she has finished transferring her purchases to her vehicle. Similarly, when a customer visits an electronic retail storefront, the shopping cart’s purpose is to make shopping easy for the customer. To understand the technologies that govern an electronic shopping cart, you need to understand how the technology works.

Scope and Lifetime of an Electronic Shopping Cart
When a customer first enters an electronic retail storefront, the shopping cart application provides him with a virtual shopping cart. It remains with the customer until he places an order and exits the storefront’s Web site. Once the order is placed, the virtual shopping cart’s contents are cleared and the resources used by the virtual shopping cart are freed. In essence, without further need, the virtual shopping cart is destroyed by the shopping cart application.

Collecting, Analyzing, and Comparing Selected Components
As with a conventional shopping cart, another important aspect of an electronic shopping cart is that the customer can select items after analyzing them thoroughly—including comparing different brands—and place them in the cart. The ability to hold items and carry them along electronically saves shopping time. Otherwise, the customer would have to pay for each item immediately upon selection and then continue with his shopping. Also, at any time during the shopping process, the customer can view the selected items and compare them with other items.

Keeping Track of the Total Cost
One advantage that an electronic shopping cart has over a conventional shopping cart is that is displays the running total of the items as they’re added to the shopping cart. In this way, the customer can keep track of the cost of his selections and compare it to his budget.

Change of Mind
A customer often changes her mind after deciding to buy an item. If the customer notices a better or cheaper item than the one being carried, she can replace the previous selection with the new one. If she overshoots her budget, she may decide not to buy some items or reduce the quantities of the items selected. Electronic shopping carts allow the customer to change the quantities and remove items previously selected.

Processing the Purchase
The electronic shopping cart also helps the merchant do the final billing at the checkout counter. By carrying the total cost of the selected items, the shopping cart saves the checkout system the trouble of adding up the costs. The system simply applies any taxes and surcharges and generates the final bill. Payment is accepted against this final bill.

Figure 3-5. Shopping cart integrated with product catalog

Hence the shopping cart application forms the heart of the electronic storefront. The shopping cart application binds the customer, the catalog, the inventory system, and the payment system closely. Certain electronic shopping cart systems provide the customer with product recommendations and price comparisons with equivalent products on the fly. Most shopping cart systems are implemented with server-side code. When maintaining shopping cart instances on the server side, some applications allow the user to resume shopping where she left off, if for some reason the shopping session is terminated abruptly. Incidentally, if shopping cart applications aren’t implemented with server-side code, they become candidates for electronic shoplifting!

Figure 3-6. Shopping cart contents

Figures 3-5 and 3-6 show how the shopping cart is integrated with the product catalog and how a customer can keep track of selections during the shopping session.