Fireship · @fireship

PayPal Checkout 2.0 - Monetize React, Angular, & Vue Quickly

Uploaded June 24, 2019 · Length 9:02

PayPal Checkout 2.0 - Monetize React, Angular, & Vue Quickly

Summary

Implement PayPal Checkout 2.0 in React, Angular, and Vue for easy payment processing.

  • paypal checkout 2.0
  • react payment integration
  • angular payment integration
  • vue payment integration
  • progressive web app payments
  • paypal api integration

Transcript preview

The first 2 minutes of the transcript. Select a timestamp to watch that moment on YouTube.

  1. 0:00

    version two of the paypal api was

  2. 0:01

    released earlier this year and it makes

  3. 0:03

    the extremely easy to start accepting

  4. 0:05

    payments from your progressive web app

  5. 0:06

    it's so easy in fact that I can show you

  6. 0:08

    how to integrate it into angular react

  7. 0:10

    and view in a single video dollar dollar

  8. 0:13

    bill y'all in today's video you'll learn

  9. 0:15

    the basics of the paypal version two API

  10. 0:17

    and how to start accepting and capturing

  11. 0:19

    real payments from your front-end

  12. 0:20

    JavaScript app and it's a lot easier

  13. 0:22

    than you might think if you're new here

  14. 0:23

    like and subscribe and you can find the

  15. 0:25

    full source code on fire ship io now

  16. 0:27

    just a few days ago I implemented

  17. 0:29

    PayPal payments on fire ship and also

  18. 0:31

    added the ability to purchase individual

  19. 0:33

    courses so ironically you can now use

  20. 0:35

    PayPal to pay for my strength payments

  21. 0:37

    course if you want now during this

  22. 0:38

    integration I learned that PayPal 2.0

  23. 0:40

    delivers a really nice developer

  24. 0:42

    experience they've completely revamped

  25. 0:43

    the documentation and the API in a way

  26. 0:46

    that resembles stripe payments now in my

  27. 0:48

    case I already have stripe implemented

  28. 0:49

    so I'm using PayPal alongside it as an

  29. 0:51

    additional option but you can actually

  30. 0:52

    use PayPal as a standalone payment

  31. 0:54

    solution to accept credit cards venmo

  32. 0:56

    crypto and more well we'll be looking at

  33. 0:58

    today as PayPal checkout which allows

  34. 1:00

    you to mount this payment button

  35. 1:01

    directly in your application and it will

  36. 1:03

    take care of collecting payment details

  37. 1:05

    from the user and can also capture and

  38. 1:07

    charge the payment entirely from the

  39. 1:08

    front end the first thing you'll need to

  40. 1:09

    get started is a PayPal business account

  41. 1:11

    from there you can go to the PayPal

  42. 1:13

    developers dashboard and the first thing

  43. 1:15

    you'll want to do is create an

  44. 1:16

    application when you create this

  45. 1:17

    application it will give you two sets of

  46. 1:19

    API keys these sandbox keys are used to

  47. 1:21

    make mock payments and to test your

  48. 1:23

    integration and live keys are used for

  49. 1:24

    actual payments in your production app

  50. 1:26

    now each of these environments contains

  51. 1:28

    two API keys the client ID and the

  52. 1:30

    secret the client ID is perfectly safe

  53. 1:32

    to expose in your front-end application

  54. 1:34

    and we'll use that client ID in the

  55. 1:36

    angular react and view apps the secret

  56. 1:38

    on the other hand should never be

  57. 1:39

    exposed in your front-end code or a

  58. 1:40

    public github repo a secret is used to

  59. 1:43

    identify your app to a back-end server

  60. 1:44

    like node or firebase cloud functions so

  61. 1:47

    you can use it to interact with the API

  62. 1:48

    from the backend but we actually don't

  63. 1:50

    even need to use it in this demo and

  64. 1:52

    that's because you can use PayPal

  65. 1:53

    checkout to do everything entirely from

  66. 1:54

    the front-end and we'll talk a little

  67. 1:56

    bit more about the trade-offs later in

  68. 1:57

    the video

  69. 1:57

    now we're going to implement the same

  70. 1:59

    basic payment spec in angular reactant