Skip to content

Invalid plan Sent #125

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

Closed
PromiseShedrach opened this issue Nov 18, 2020 · 5 comments
Closed

Invalid plan Sent #125

PromiseShedrach opened this issue Nov 18, 2020 · 5 comments

Comments

@PromiseShedrach
Copy link

PromiseShedrach commented Nov 18, 2020

When I try to initialize a transaction. I get this error:

GuzzleHttp\Exception\ClientException
Client error: POST https://api.paystack.co/transaction/initialize resulted in a 400 Bad Request response: { "status": false, "message": "Invalid plan Sent" }

@Raymoneto
Copy link

I encountered same issue. The payment was working seamlessly hours ago, and stopped with Invalid plan Sent. I had to do a quick fix by tampering with the library code.

Goto: vendor/unicodeveloper/src/Paystack.php, and comment the line below:

// "plan" => request()->plan,

NB: This is a quick fix, and shouldn't be used when implementing plans/subscriptions.

@unicodeveloper
Copy link
Owner

unicodeveloper commented Nov 19, 2020

@PromiseShedrach @Raymoneto I have fixed the issue. Please upgrade to the latest version of the package.

@Raymoneto
Copy link

@PromiseShedrach @Raymoneto I have fixed the issue. Please upgrade to the latest version of the package.

Bravo! Thank you.

@blazefluz
Copy link

You don't need to comment it.

Go to the vendor folder vendor\unicodeveloper\laravel-paystack\src\Paystack.php
Change "plan" => request()->plan,
to
"plan_code" => request()->plan,

paystack did an update that is why you have an error.

@devclassik
Copy link

"plan_code" => request()->plan,
or
//"plan" => request()->plan,

nothing works

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

5 participants