paint-brush
How to Integrate Stripe Payments in Web Application?by@Eugeniya
21,326 reads
21,326 reads

How to Integrate Stripe Payments in Web Application?

by Yevheniia Korotia5mNovember 30th, 2016
Read on Terminal Reader
Read this story w/o Javascript
tldt arrow

Too Long; Didn't Read

How to build a web app that accepts online payments? How to choose best payment provider and where to start? These are the main issues that our customers face with. Whether it is a booking app, marketplace platform or eCommerce solution, you should be able to process payments for transactions.

People Mentioned

Mention Thumbnail

Companies Mentioned

Mention Thumbnail
Mention Thumbnail
featured image - How to Integrate Stripe Payments in Web Application?
Yevheniia Korotia HackerNoon profile picture

How to build a web app that accepts online payments? How to choose best payment provider and where to start? These are the main issues that our customers face with. Whether it is a booking app, marketplace platform or eCommerce solution, you should be able to process payments for transactions.

According to latest report by comScore and UPS, online shopping trend is constantly increasing: in 2016 shoppers bought 51% of stuff on the web, relative to 48% in 2015 and 47% in 2014. Moreover, these days mobile shopping is noted as a continuing upward trend with 44% in 2016 and 41% in 2015. In the light of above, it is essential that payment gateway integration runs without a hitch within both desktop and mobile versions.

At this point, how to choose the right credit card processing company? There are 5 common factors to consider, while choosing a payment processor:

  • Security
  • Cost (monthly/setup/minimum fees, etc.)
  • Signup duration
  • Payment types
  • Customer support

There are various options to choose from when it comes to accepting payments in your web app, though nowadays Stripe is among the most popular ones. Launched back in 2010, now it accepts all credit/debit cards, supports over 100 currencies and available for startup and business owners in in the United States, UK, Canada, Australia, and still gaining ground. Among the giants that use Stripe payment gateway you can find Twitter, Target, Adidas, BestBuy, Slack, HubSpot, Pinterest, Salesforce, Facebook and many others.

Read also: Marketplace App: Features for Users’ Needs

Top 5 Stripe advantages:

  • Comprehensive dashboard — provides you with full control over every customer, payment, subscription, transfer, and others from one place
  • Safety — with two-step authentication (password + unique code from mobile device) and fine-grained permissions Stripe keeps your account impenetrable for fraudsters
  • Clear policy — Stripe doesn’t have any hidden or card storage fees, fixed price: 2.9% and plus $0.30 per card change
  • Built for/by developers — extensive libraries support for various programming languages and mobile platforms; versioned API updates; in-depth documentation
  • Real-time risk evaluation — with responsive machine-learning system Stripe analyzes each payment risk level and indicates its’ fraudulence in real time

How to integrate Stripe payments in web app:

We’ve opted for stripe payment integration within a number of marketplace projects in such industries, as Engineering & Construction, Consumer Services, Travel & Tourism, and others. There are two key prerequisites to be able to handle credit card information: your web application should be hosted on https server and you need an SSL (Secure Sockets Layer) certificate.

Read also: Stripe vs Braintree: Which Is the Best Solution for Your Startup?

Ready to start? — Begin with creating a Stripe account and filling in several forms, like banking details and statement descriptor.

Install Node.js module for Stripe:

npm install stripe --save

Set your secret API key. Access Stripe Dashboard to retrive it:

const stripe = require('stripe')(' your stripe API key ');

Building a payment form:

To make it easier and faster Stripe offers Checkout: embedded payment tool that fully takes care of creating an HTML form, validating user data, and guarding your clients’ card details. This tool sends private card information directly to Stripe, without touching a server, and then Stripe returns a token representation of the credit card to your website, where this token can be employed for charge requests. Any doubts? — Look at stripe checkout example.

In the meanwhile, in those cases when you need to create a custom payment form, you can build it using Stripe.js library and HTML.

Stripe payment processing tips:

Testing:

For test mode of your newly-created payment form Stripe offers several card numbers that simulate particular responses and errors. The most common are:

  • Wrong card number: 4242424242424242
  • Declined card for fraudulent reason: 4100000000000019
  • Wrong CVC code: 4000000000000127
  • Successful charge: 4000000000000077
  • MasterCard accepted: 5555555555554444
  • Visa accepted: 4012888888881881
  • American Express accepted: 378282246310005

Though there are other numbers that enable testing invalid address line fails, risk levels, expired card messages, processing errors and much more. Moreover, there are test methods for Bitcoin and international credit cards, like Europe, Asia, Africa, and so on.

Read also: How to Create a Two-Sided Online Marketplace Platform?

Connectivity:

Stripe can be connected to a bunch of third-party apps that you use, including CRM software, analytics solutions, eCommerce systems, accounting and invoicing applications, email-marketing services, and others. Furthermore, it synchronizes all the sales data automatically.

Mobile app:

Now to accept payments with stripe and to track them you don’t need a computer. iPhone application allows you to track all the customers, payments and transactions, set up notifications for new payments or get daily summaries.

Think you know Stripe? — No, you don’t.

It’s just another payment system

Such statement is the main misrepresentation, since Stripe is not just a payment platform. The company offers a full set of business tools including, but not limited to:

  • Atlas makes it easier to start an international business and lessens the importance of your physical location. This tool allows entrepreneurs to incorporate a US business, open a US bank account and begin accepting online payment.
  • Connect is used to build up accounts and to enable online payments for your vendors, sellers, contractors or anyone else, who sells on marketplace. This solution facilitates complex flows, like automation of transfers to sellers, tuning of payment schedules, set the route for funds, and even much more.
  • Relay enables selling products within a growing number of mobile applications. With customizable “Buy Button” entrepreneurs can offer their goods across apps like Twitter or ShopStyle.
  • Subscriptions product is a smart engine that comprises best billing practices and ensures full control over the process. The system takes care of billing your subscribers monthly (weekly, daily, annually) and meanwhile does all the calculations regarding subscription changes and depts.

Stripe cooperates with governments worldwide

The company has recently signed up a framework agreement with British Government. Moreover it accompanied Barack Obama during his visit to Cuba. And it is Stripe Atlas that was offered to local entrepreneurs, removing one of the greatest barriers to Cubans involved in global financial sector.

Stripe is cut from the same cloth as PayPal

The majority of people believe that Stripe and PayPal are birds of a feather, though they take in different business niches. At a time when PayPal is largely focused upon consumers, Stripe is targeted at creating tools for programmers. The company lately acquired Runkit, unique platform that enables future development tools, like building a “developer OS” to facilitate writing and executing code.

The Wrap-Up:

Stripe is one of the most popular payment processors for ecommerce platforms. Apart from the facts that it is hassle-free for programmers, business owners and customers, it also eliminates the need for gateway and merchant account. With Stripe you can start online selling on a dime.

One of the core Stripe benefits among competitors is its’ world-class documentation. Stripe tutorial is full of guides and examples that can facilitate any building experience. If you need some advice on payment integration or still doubt about which system to choose for your web app, drop us a line — we’ll be glad to help you with the right choice.