Billing agreement fails to attach plan.

ardev
Contributor
Contributor

Hi I am using paypal sdk. I got stuck and I think there is a problem with paypal.

I am trying set a plan in an agreement and I can't move on. Please help.

 

$plan = Plan::get('P-8S006071UD1304535TRTZZNI', $apiContext);
$agreement->setPlan($plan);

I get this error: Got Http response code 400 when accessing https://api.sandbox.paypal.com/v1/payments/billing-agreements/.

 

And when I try with anything like this:

$plan = Plan::get('Illputwhatever', $apiContext);
$agreement->setPlan($plan);

I get this error: Got Http response code 400 when accessing https://api.sandbox.paypal.com/v1/payments/billing-plans/Illputwhatever.

 

 

 

 

 

Login to Me Too
2 REPLIES 2

MTS_Justin
Moderator
Moderator
>> Moving to the REST forum

Was my post helpful? If so, please give me a kudos!
Login to Me Too

MTS_Andre
Moderator
Moderator

Hi, can you share the full response? There should also be a debug-id. This is the Billing Agreement documentation for reference.

Login to Me Too

Haven't Found your Answer?

It happens. Hit the "Login to Ask the community" button to create a question for the PayPal community.