1

I'm SDK php. It looks like it is connect to my app. Alas in the end it gives me an error

ET_Post Object ( [status] => [code] => 200 [message] => [results] => Array ( [0] => stdClass Object ( [StatusCode] => Error [StatusMessage] => The Subscriber Key / Customer Key was not specified in the request. [OrdinalID] => 0 [ErrorCode] => 12015 [NewID] => 0 [Object] => stdClass Object ( [PartnerKey] => [ObjectID] => [EmailAddress] => [email protected] [Lists] => stdClass Object ( [PartnerKey] => [ID] => xxxx [ObjectID] => ) ) ) ) [request_id] => [moreResults] => )

Here is my code. It is simple

<?php
require('SDK/ET_Client.php');
$myclient = new ET_Client();
$authStub = $myclient;
$objType = "Subscriber";
$props = array("EmailAddress" =>"[email protected]","Lists" => array("ID"=>1111));
$response = new ET_Post($authStub,$objType,$props);
print_r($response);
?>

Any suggestion? Thank you

1

1 Answer 1

3

You should be able to declare the SubscriberKey as well...something like this maybe:

<?php
require('SDK/ET_Client.php');
$myclient = new ET_Client();
$authStub = $myclient;
$objType = "Subscriber";
$props = array("SubscriberKey" => "XXXXXXX","EmailAddress" =>"[email protected]","Lists" => array("ID"=>1111));
$response = new ET_Post($authStub,$objType,$props);
print_r($response);
?>
2
  • Yes thank you I had figured out it worked beautifully. Thank you Rob
    – Einstein
    Commented Feb 5, 2015 at 4:34
  • Hey @adlan, welcome to SFSE! Please mark this answer as accepted if it solved your issue :)
    – Matt Lacey
    Commented Feb 5, 2015 at 5:05

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .