I am using FuelSDK to send triggered emails using Salesforce Marketing Cloud (formerly ExactTarget). Here is an approximation of the code I'm using:
$triggeredsend = new ET_TriggeredSend();
$triggeredsend->authStub = $My_ET_Client;
$triggeredsend->props = array("CustomerKey" => 'MyTriggeredEmailID');
$triggeredsend->subscribers = array(
array(
"EmailAddress" => '[email protected]',
"SubscriberKey" => $subscriber_key,
"Attributes" => $some_attributes));
$results = $triggeredsend->send();
Amidst $some_attributes in my example is a Date type field (we'll call it My_Date) that contains a null value. However, I get this response from SFMC:
Error Code: 20 - Value provided for My_Date cannot be stored in a Date field.
I see that if I were using SoapClient, I "must explicitly state that null value using the NullAPIProperty type":
How do I send a NullAPIProperty type attribute using FuelSDK?
Thanks in advance,
Ben
EDIT: Here is a more complete dump of the query and results. To further address Mark's proposed answer: This code is meant to trigger a TriggeredSend and send the appropriate subscriber information. You'll see that one of the fields -- the one that is causing the error message -- needs to have a null value. The field itself is already nullable. This operation is distinct from updating the DataExtension field itself.
DEBUG - 2016-01-06 21:01:30 --> Preparing to send triggers...
DEBUG - 2016-01-06 21:01:31 --> ET_Post Object
(
[status] =>
[code] => 200
[message] =>
[results] => Array
(
[0] => stdClass Object
(
[StatusCode] => Error
[StatusMessage] => Unable to queue Triggered Send request. There are no valid subscribers.
[OrdinalID] => 0
[ErrorCode] => 180008
[NewID] => 0
[SubscriberFailures] => stdClass Object
(
[Subscriber] => stdClass Object
(
[PartnerKey] =>
[ObjectID] =>
[EmailAddress] => [email protected]
[Attributes] => Array
(
[0] => stdClass Object
(
[Name] => UserID
[Value] => 79
)
REDACTED
[22] => stdClass Object
(
[Name] => Purchase_Date
[Value] =>
)
REDACTED
)
[SubscriberKey] => dev_79
)
[ErrorCode] => TriggeredSendSubscriberProcessingError
[ErrorDescription] => Error Code: 20 - Value provided for Purchase_Date cannot be stored in a Date field.
)
)
)
[request_id] =>
[moreResults] =>
)