Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Cannot understand 3. Handle charge.success Event #13

Open
shirshak55 opened this issue Jan 27, 2018 · 6 comments
Open

Cannot understand 3. Handle charge.success Event #13

shirshak55 opened this issue Jan 27, 2018 · 6 comments

Comments

@shirshak55
Copy link

What is it and where should i use it?

@shirshak55
Copy link
Author

And what should we do lets say for 100naira things customer only paid 10naira. Can we check before having transaction?

@ibrahimlawal
Copy link
Member

@shirshak55
Copy link
Author

shirshak55 commented Jan 29, 2018

@ibrahimlawal I read it. But i guess the documentation is actually not clear.

In stripe i used to have flow like this

Customer will fill the form. They will order the item and pay it in credit card. And they will get token in form element. But stripe will not charge it .

When they post in server. I verify if items are correct and fetching money from database i charge them using the token that stripe gave it to me which works like credit card on server side.

And the main problem is lets say user changed amount from 100naira to 10 naira using inspect element. I know i can check if they paid 100 naira or not using transaction key etc.. but i don't want them charge 10 also just because they change from 100 to 10 naira because they may claim refund etc.. which will be probelmatic right? How do i make such flow possible.

I guess documentation of api should have been clear :(

I hope you understand my problem thank you.

@ibrahimlawal
Copy link
Member

To be clear, you only need to be sure they pay the amount you want, right?

Use Transaction/Initialize to start the transaction on your server. Then use same email, amount and reference to start inline and we will resume the already initialized transaction.

@shirshak55
Copy link
Author

@ibrahimlawal i want them not to pay the amount that i don't want like. I don't want to specifiy amount on input

Because if user change it to 10 by using console it will only creates problem. I want to charge them from server side once they have filled the form.

Regarding transaction initialize it has two problem.

  1. I need to redirect them to another page.
  2. After completion they come to my server with get request with token like . Website.com/?transaction_id=xx &&...............

Thanks . I hope you are understanding what i want to say.

And there are two webhook url in settings in paystack what is that for?

@ibrahimlawal
Copy link
Member

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants