我想将Firebase用作服务器,并将请求发送到付款请求以进行分条.我的服务器端经验为零,因此我正在寻找一种简单的方法来实现这一目标.这篇文章是否可以将Stripe与Firebase集成并使用iOS?接近我想要实现的目标,并且还列出了一些有趣的链接.有谁知道我在哪里可以找到一个很好而简单的教程来将Firebase设置为Stripe的服务器?
I would like to use firebase as a server and send request to payment request to stripe. I have zero experience server side so I am looking for a simple way to achieve this. This post Is it possible to integrate Stripe With Firebase and with iOS? is close to what I want to achieve and it also list some interesting link. Does anyone know where I can find a good but simple tutorial to set up firebase as a server for stripe?
推荐答案我通过以下2个步骤解决了此问题
I resolved this with the following 2 steps
func saveTokenInRealtimeDatabase(令牌:STPToken){
func saveTokenInRealtimeDatabase(token: STPToken) { let ref = Database.database().reference(withPath: "payments") ref.child(Auth.auth().currentUser!.uid).childByAutoId().setValue(["amount": valueToCharge, "token": token.allResponseFields]) }
更多推荐
如何将Firebase设置为服务器并执行条带支付
发布评论