Reputation: 789
Hello i've been having no problem submitting my custom cart form to the Paypal sandbox website before however a few days ago i've started getting an error which prevents me from going through the mock checkout process.
The code below demonstrates the form that is generated by my code before submitting, This seems like nothing has changed from previously and looks errors free.
<form id="BNForm" action="https://www.sandbox.paypal.com/cgi-bin/webscr" method="post">
<input type="hidden" name="cmd" value="_cart">
<input type="hidden" name="upload" value="1">
<input type="hidden" name="business" value="[email protected]">
<input type="hidden" name="currency_code" value="US">
<input type="hidden" name="handling_cart" value="8.79">
<input type="hidden" name="custom" value="123abc">
<input type="hidden" name="item_name_1" value="Bluetooth Controlled RC Car w/ Phone Control Center">
<input type="hidden" name="amount_1" value="18">
<input type="hidden" name="quantity_1" value="1">
<input type="hidden" name="item_name_2" value="MPU-6050 3-Axis Accel + Gyro Module">
<input type="hidden" name="amount_2" value="4.00">
<input type="hidden" name="quantity_2" value="1">
<input type="hidden" name="item_name_3" value="3.3V SD Card Module">
<input type="hidden" name="amount_3" value="2.50">
<input type="hidden" name="quantity_3" value="1">
</form>
The short error message given to me by the Paypal website is: UserException: message 'An id of zero was passed to PartyPostalAddressPBImpl::load_by_id'
The full error message given to me by the Paypal website is:
UserException: message 'An id of zero was passed to PartyPostalAddressPBImpl::load_by_id', return code: 3505 Backtrace: PPException::PPException(String const&) User::UserException::UserException(int, String const&) User::PartyPostalAddressPBImpl::load_by_id(unsigned long long) User::AddressPBImpl::load_by_id(unsigned long long, ForUpdate) User::ReputationALIImpl::processReputation(DeprecatedUserShim*, ReputationContainer*, char const*, int, MsgLog2*, DeprecatedUserShim const*) (anonymous namespace)::load_seller_details(PayPalCommonWebAppContext const&, PimpXClick&, unsigned long&, String&, ReputationContainer*) (anonymous namespace)::load_recipient_info(PayPalCommonWebAppContext const&, PimpXClick&, MerchantInfoUbiquityContainer&, CreditCardUbiquityContainer&, TransactionUbiquityContainer&, FlowInfoUbiquityContainer&, PassedParametersUbiquityContainer&, String&, ReputationContainer*, WalletInfoContainer*) Rapids::BusinessBlocks::HostedPayments::load_recipient(PayPalCommonWebAppContext const&, PimpXClick&, MerchantInfoUbiquityContainer&, CreditCardUbiquityContainer&, TransactionUbiquityContainer&, FlowInfoUbiquityContainer&, PassedParametersUbiquityContainer&, String&, WalletInfoContainer*) Rapids::Flows::Unity::DecoratorLoadRecipient::load_recipient_execute(Rapids::CGIVars const&) Rapids::Flows::Unity::DecoratorLoadRecipient::execute(Rapids::CGIVars const&) Rapids::DecoratedState::execute(Rapids::CGIVars const&) Riprap::RiprapRapidsGenericFlow::handle_execute(Riprap::WebAppContextOrnate const&, Rapids::TransitionRegistry const&, Rapids::State*, String const&, String const&, unsigned long long) Riprap::RiprapRapidsGenericFlow::process_states(Riprap::WebAppContextOrnate const&, Riprap::RiprapRapidsGenericFlow::ProcessStates, Riprap::DispatchInterceptorRegistry const&, Rapids::TransitionEdge const*) Riprap::RiprapRapidsGenericFlow::flow_call(Riprap::WebAppContextOrnate const&, Riprap::WebAppReturn const&, String const&, Riprap::DispatchInterceptorRegistry const&) Riprap::call_rapids(Riprap::WebAppContext const&, Riprap::RapidsFlowFactory const&, Riprap::DispatchAction const&, Riprap::WebAppReturn const&, String const&, Riprap::DispatchInterceptorRegistry const&) Riprap::dispatch_loop(Riprap::EPRegistry const&, Riprap::WebAppContext const&, Riprap::DispatchAction&, Riprap::WebAppReturn&, String const&, Riprap::DispatchInterceptorRegistry const&) Riprap::dispatch_wrapper(OutputStream&, Riprap::EPRegistry const&, Riprap::WebAppContext const&, Riprap::WebAppReturn const&, String const&, bool const&, Riprap::DispatchInterceptorRegistry const&) Riprap::entry_point(HTTPInterface&, Riprap::CGIVars&, OutputStream&, String const&, String const&) main
Blockquote
Any help leading to the solving of this problem would be greatly appreciated!
Upvotes: 0
Views: 276
Reputation: 155
Indeed I had the exact same issue : my paypal tests were working and suddenly this error shew up. In my case the email address used was containing an underscore.
So I created a new sandbox test account with no underscore in the email address and it solved the problem.
Upvotes: 1
Reputation: 789
So as it turns out that the problem is that an email address in the business field cannot have a "-" character.
Therefore this email address will not work:
<input type="hidden" name="business" value="[email protected]">
But this email address will work:
<input type="hidden" name="business" value="[email protected]">
This is strange because the first email address with the "-" was given to me by the Paypal sandbox website itself so be weary and consider changing it to a new test email as soon as possible.
Upvotes: 0