I have been able to successfully, Add, Modify, but cannot delete a contact. This is my request, but I continue to receive this error, and i'm not sure the issue, it has to be with my 'content', but i'm not sure what is missing. Any light shed upon this would be greatly appreciated!
URL REQUEST:
https://www.google.com/m8/feeds/contacts/{userEmail}/full/{contactId}
METHOD: DELETE
XML CONTENT:
<entry etag='*'><id>https://www.google.com/m8/feeds/contacts/{userEmail}/full/54934b770f18de29</id>
</entry>
ERROR: 400 That's an error. Your client has issued a malformed or illegal request. That's all we know.
NOTE: I am trying out, Manuel Lemos Class: http://www.phpclasses.org/package/7700-PHP-Authorize-and-access-APIs-using-OAuth.html
I received an answer from Manuel on his forum.
Here is the response.
api_url = 'https://www.googleapis.com/some-google-api-url';
$options = array(
'RequestHeaders'=>array(
'If-Match'=>'if match value here',
'FailOnAccessError'=>true
);
$success = $client->CallAPI($api_url, 'DELETE', array(), $options, $results);