1
votes

I'm trying to add Google Checkout to my magento 1.7.0.0 shop. I've traced the issue and it seems to fail during posting to google's server because when I try to read the response it's false.

The error I get is: Google Checkout: Invalid response from Google Checkout server

I'm using magento 1.7, google sandbox with sandbox credentials, verified bank account, unchecked digitally signed carts, but am using a self-signed certificate on my development machine, and API version 2.2.

The issue is happening in app/code/core/Mage/GoogleCheckout/Model/Api/Xml/Abstract.php on lines 174, 175

$http = new Varien_Http_Adapter_Curl();
$http->write('POST', $url, '1.1', $headers, $xml);
$response = $http->read();
2
Tried turning SSL off on frontend and still have the same issue. Deleted cache/session for good measure. - Nate

2 Answers

0
votes

Not a PHP dev ~

Is this a sandbox server to server (Shopping Cart) POST? Check:

Note - unchecking "digital cart" only means your account will also accept HTML API cart POSTs, but it doesn't mean you can send XML without a digital signature if doing direct FORM post to Google - re: in XML API, you have 2 options to send XML data:

  1. Direct HTML FORM POST to Google (must include signature), or;
  2. Server to Server POST to Google (must use Basic Auth credentials)

You can also check your sandbox Integration Console for detailed error messages:

Tools -> Integration Console

Hth...

0
votes

There was a problem with it being a local environment. The issue was either with Google not being able to communicate or with my tld ending in .dev. Possibly Google rejected the request for that reason.