API call to make payments

Can you be more clear? You can’t get a response, or wait action is not seeing the response?

The responce I was waiting for is a URL that the user would click on to pay. It does come through

However the Wait action, doesn’t match it to that Row?

I think I know what the problem is, but it will require sharing my top-secret tricks :wink:
Would you mind connecting over Zoom?

I spoke too soon, I figured it out, I should rather open a new. window and make the payment link to that window!!!

Almost there!!!

1 Like

I see you fighting for the solution for a long time… that makes me think if my templates might be a way too cheap LOL

1 Like

Yeh, I’m doing this in my spare time. I’m sure your Templates would have helped stax, however I really want this to be a learning exercise for me and hoping I can help the broader community too

1 Like

Have you figured this out? Let me know if you need any further help.

New Stripe checkout for Apps (Pages), with simplified options, no cart, no stack adjustment:

Hi Uzo!
This version dl/d0a5f4 returned error, but pro version works normally.

Almost there

This is where I am stuck

I made a video, as I thought it would be a lot easier!

This is what I am doing:

  1. The user clicks a button in the app √
  2. I generate a link for them and bring that back to the app. √
  3. The user pays through that link ??? ← I get stuck on this part as I don’t know how to wait for the call back to the API and open that specific URL
  4. You get the payment info and bring that back to the app… I think I cracked this!

My thought is:

  • Webhook call
  • Wait for condition, set it to like 60 seconds to give you a high enough time, that anything beyond it can be considered a failure. Set the condition to something like “payment URL” is not empty. How you get that payment URL to the same row you’re building your tab on is another story, we’re willing to discuss that more.
  • Open the URL.

Then, on a successful payment, it would be ideal if PayStack can send a payload to a webhook URL. You can set that up in Make, and then update an existing row/add a new payment details row inside Glide using the API.

2 Likes

Almost there, now I am stuck on getting “payment URL to the same row”

  1. I am in the “Gallery View” where all the image are showing
  2. User Clicks on Purchase which “Adds Row” to “PayStackPayments” table with all the NB details (Email, Title, Amount, etc) with a value payment URL = “pending”
  3. I managed to trigger a webhook and send all the relevant details and get a response back. However I don’t know how to send a unique value of the Row I created in “PayStackPayments”, so I can amend that with a reference of Row with the URL that was created

Maybe you can adjust this a bit, I assume you are building on top of a row that has no relations to the payment rows?

Remove the add row function in the app, do everything on the Make side. Webhook > Call to PayStack > Create a new row with the Payment info and Payment URL after you get the info from PayStack.

Show that new payment row, with a button to pay, in Glide.

2 Likes

This is brilliant!

Any idea on how to ensure that button reflects the latest row’s info?

Do you mean the button to pay? I would use a collection to do that, and you can use a sheet order > descending sort, limit to 1 item to only show the last “payment”.

However, you might want to show the full list of payment history to the user.

1 Like

Almost finished this behemoth :crossed_fingers:

1 Like

This is a nice solution…
Pity you are using stripe as the payment service in your set up…

Why not try and setup a solution for Paystack or any other service provider that Glide is not currently easy to set up with and you can sell that solution…
At the moment you are solving a problem that is not really a pain for most people or companies. People in emerging economies or third world countries e.g. in Africa cannot use Stripe at all.
So what do you say @Uzo. Go and check out the Paystack documentation and come up with a way on how that would work with Glide seamlessly and then you will surely have paying clients for your solution. I will even be your “affiliate marketer” for that solution…

Hey Luther, not sure if you have noticed, I am NOT using Stripe, but using PayStack which works well in Africa.

I def think that I will document this process and share it

1 Like

I have noticed and I think it’s quite inspiring how you are “building in public” so to speak and in the process documenting your struggles for all to follow and pitch in to help where they can. My text was more in reference to @Uzo who is trying to offer an alternative solution which does not really solve your issue.
I am also in South Africa and have not used Paystack as I am not sure how reliable they are in terms of Payouts. I normally use payment links from Yoco or Payfast for my solutions. I am following your post though as it might help at some point. :hugs:

Thanks for the kind words.

I agree, Uzo has been really helpful in the past, however it’s mainly for Stripe

Yeh I have used Stripe for my international startups, however I didn’t feel like paying the expensive Atlas fees to incorporate. Paystack is highly reliable as it got bought out by Stripe. It has paylinks etc.

1 Like