Setup a Stripe Account
Let’s start by creating a free Stripe account. Head over to Stripe and register for an account.
Once signed in, click the Developers link on the left.
And hit API keys.
The first thing to note here is that we are working with a test version of API keys. To create the live version, you’d need to verify your email address and business details to activate your account. For the purpose of this guide we’ll continue working with our test version.
The second thing to note is that we need to generate the Publishable key and the Secret key. The Publishable key is what we are going to use in our frontend client with the Stripe SDK. And the Secret key is what we are going to use in our API when asking Stripe to charge our user. As denoted, the Publishable key is public while the Secret key needs to stay private.
Hit the Reveal test key token.
Make a note of both the Publishable key and the Secret key. We are going to be using these later.
Next let’s create our billing API.
For help and discussionComments on this chapter