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

Requesting autorization code when charging with card #29

Open
Oluwatemilorun opened this issue Aug 20, 2018 · 7 comments
Open

Requesting autorization code when charging with card #29

Oluwatemilorun opened this issue Aug 20, 2018 · 7 comments

Comments

@Oluwatemilorun
Copy link

Hi
I get this error when i try to charge with card Required Parameters Ommited - authorization_code

But according to paystack doc for charge, its not a required param when charging with card - https://developers.paystack.co/reference#charge

screen shot 2018-08-20 at 15 09 38

I'm i doing this wrong? Please help out.

@Oluwatemilorun
Copy link
Author

Just went through your code and disabled the default params check so i can proceed and i got another error { status: false, message: 'Invalid transaction reference' }

I discovered that the method Paystack.transaction.charge() has an endpoint of https://api.paystack.co/transaction/charge_authorization which is different from that on paystack docs https://api.paystack.co/charge

@subomi
Copy link
Collaborator

subomi commented Aug 26, 2018

@Oluwatemilorun Thanks for this issue! Please can you send in a PR to this effect?

@Oluwatemilorun
Copy link
Author

#30

@subomi just did... check it out.

@subomi
Copy link
Collaborator

subomi commented Aug 30, 2018

@Oluwatemilorun There seems to be so much incompatibility with current code. Can you take some time to read current code so you can follow whats already avaliable. So we can test and merge this .

@Oluwatemilorun
Copy link
Author

@subomi i just wrote a different module and attached it to the core paystack. Same implementation with all other resource. But can you please point out where the compatibility failed?

@gray-adeyi
Copy link

Hi! try out this package. It's not yet a major release but it supports typescript and other JavaScript runtime like bun and Deno https://www.npmjs.com/package/@gray-adeyi/paystack-sdk

@gray-adeyi
Copy link

@gray-adeyi/paystack-sdk 0.2.4 release is now available with even better type support 🔥 https://www.npmjs.com/package/@gray-adeyi/paystack-sdk

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

3 participants