Upgrade to Pro — share decks privately, control downloads, hide ads and more …

Stripe Credit Card Flow

Stripe Credit Card Flow

What happens when you charge a credit card?

Avatar for Ross Boucher

Ross Boucher

April 03, 2014
Tweet

Other Decks in Programming

Transcript

  1. 1 2 3 4 5 6 7 8 Browser Stripe

    API Your Server Credit Card Network
  2. HTTP/1.1 200 OK ... { "id": "tok_1234", // this is

    how we will refer to the Stripe token "card": { "last4": "4242", "type": "Visa", ... } } STRIPE API RETURNS:
  3. Sending authorize request (conv fdc_1234): MTI:100 (Authorization Request) 002 Primary

    Account Number : "42xxxxxxxxxx42" 004 Amount of Transaction : 500 007 Transmission Date/Time : 2013-02-04 02:15:20 UTC 012 Time, Local Transmission : 2013-02-03 18:15:20 UTC 014 Card Expiration Date : "1503" 018 Merchant Category Code : "5399" 042 Merchant : "4451xxxxxxx" 049 Transaction Currency Code : 840 STRIPE REQUESTS: (binary wire protocol)
  4. Response: MTI:110 (Authorization Request Response) 004 Amount of Transaction :

    500 007 Transmission Date/Time : 2013-02-04T02:15:20+00:00 025 Point of Service (POS) Condition Code : 59 037 Retrieval Reference Number : "z8yYxxxxxxxx" 039 Response Code : "00" [Approved (for capture)] 044 Additional Response Data : "Y" [Address and 5-digit ZIP Match] CREDIT CARD NETWORK RESPONDS: (binary wire protocol)
  5. HTTP/1.1 200 OK { "id": "ch_1234", "paid": true, // the

    charge was successful "object": "charge", "amount": 500, ... } STRIPE RESPONDS
  6. 1 2 3 4 5 6 7 8 Browser Stripe

    API Your Server Credit Card Network