snix/website/sandbox/learnpianochords/src/server
William Carroll 81aa32fe71 Support POST /create-payment-intent
Interact with Stripe's payment_intents API endpoint.

I'm not committing the index.html that contains client-side code that interacts
with the /create-payment-intent endpoint, but it contains sensitive information,
so I'm omitting it for now.

TL;DR:
- Define POST /create-payment-intent endpoint
- Include envStripeAPIKey in Context record
- Define a top-level Stripe module for making API calls
- Define types and instances that align with Stripes request and response types
- Depend on the Req library: a higher-level library than http-client
2020-08-20 11:26:30 +01:00
..
.ghci Add common language extensions to .ghci 2020-08-09 10:18:46 +01:00
API.hs Support POST /create-payment-intent 2020-08-20 11:26:30 +01:00
App.hs Support POST /create-payment-intent 2020-08-20 11:26:30 +01:00
default.nix Support POST /create-payment-intent 2020-08-20 11:26:30 +01:00
Fixtures.hs Replace Prelude with RIO 2020-08-09 22:17:19 +01:00
GoogleSignIn.hs Replace Prelude with RIO 2020-08-09 22:17:19 +01:00
index.html Support echo server to test POST /verify 2020-08-06 22:23:06 +01:00
init.sql Sketch database schema 2020-08-09 10:22:12 +01:00
Main.hs Support POST /create-payment-intent 2020-08-20 11:26:30 +01:00
shell.nix Support POST /create-payment-intent 2020-08-20 11:26:30 +01:00
Spec.hs Replace Prelude with RIO 2020-08-09 22:17:19 +01:00
Stripe.hs Support POST /create-payment-intent 2020-08-20 11:26:30 +01:00
TestUtils.hs Replace Prelude with RIO 2020-08-09 22:17:19 +01:00
Types.hs Support POST /create-payment-intent 2020-08-20 11:26:30 +01:00
Utils.hs Define Utils module 2020-08-08 11:06:53 +01:00