The API documentation suggests that when charging a credit card, one can create a CIM profile by setting transactionRequest.profile = new customerProfilePaymentType { createProfile = true }
When testing that in the Sanbox, the response.profileResponse field is null.
Thanks in advance for any insights!
03-25-2016 12:30 PM
Hello @rsuliteanu
It's hard to tell without more informatin. Was the transaction successful or were any errors returned? What is the transaction ID?
Richard
03-25-2016 12:42 PM
The transactions go through without any errors. I tried it with an email that was new to CIM and also one that had pre-existing customer and payment profiles. In all cases, the responseResult field was null and no errors were reported. Is this functionality actually supported in the ChargeCreditCard call or do I need to take the successful transaction id and subsequently call the CreateCustomerProfileFromTransaction method?
Many Thanks,
Ron
03-27-2016 07:01 PM
Sorry, I meant profileResponse field of the createTransactionResponse object.
03-27-2016 07:05 PM
03-28-2016 11:49 AM
ASP.NET C#
Code excerpt:
var transactionRequest = new transactionRequestType
{
transactionType = transactionTypeEnum.authCaptureTransaction.ToString(), // Charge the card
amount = order.GrandTotal,
payment = paymentType,
billTo = billingAddress,
lineItems = lineItems,
profile = new customerProfilePaymentType
{
createProfile = true
},
order = new orderType
{
invoiceNumber = order.OrderNumber,
description = order.Partner.PartnerName
},
and then
var controller = new createTransactionController(request);
controller.Execute();
var response = controller.GetApiResponse();
And here, response.profileResponse is always null
Thanks!
Ron
03-28-2016 12:00 PM