cancel
Showing results for 
Search instead for 
Did you mean: 

Accept Hosted Customer Email in Transaction Response

Hi All,

 

I'm currently implementing the Accept Hosted payment form and have enabled and required the customer email field (shows in billing info). However, I'm not able to view the email within the transaction response unlike the rest of the customer details I need. Does anyone know if I'm missing something, or if it's not included in the response? If the customer email isn't included in the response, why?

 

Best,

Jonathan Rasmussen

ITIL v3

Software Developer I

College of Southern Idaho

jrasmussen@csi.edu

208-732-6846

jrasmussen
Contributor
1 ACCEPTED SOLUTION

Accepted Solutions

Do you get that from an iframe? That may be why your response only has limited information. You can use a getTransactionDetails method call to get a complete response. Works like magic in conjunction with webhooks.

View solution in original post

7 REPLIES 7

@jrasmussen

I will look at this. I am pretty sure that the email is in the response for my transactions. What programming language do you use? And when you say that it isn’t in the response, you verify this by printing out the entire response?
Renaissance
All Star

By memory I think that you have to do is pass it in your api call under a different object. I think it gets returned from a different object than the billTo object, even though you can pass it in that object and that the customer can theoretically do the same when they enter it on the order form.

I'm using the Node.js SDK for getting the hosted form. Here's the response (parsed as a JSON object):

{ accountType: 'Visa',
accountNumber: 'XXXX1111',
transId: '60117528612',
responseCode: '1',
authorization: '98KUGL',
merchantName: 'College of Southern Idaho',
billTo:
{ phoneNumber: '2087326846',
firstName: 'J',
lastName: 'Rasmussen',
address: '315 Falls Ave. E',
city: 'Twin Falls',
state: 'ID',
zip: '83301',
country: 'USA' },
shipTo:
{ firstName: 'J',
lastName: 'Rasmussen',
address: '315 Falls Ave. E',
city: 'Twin Falls',
state: 'ID',
zip: '83301',
country: 'USA' },
totalAmount: '41.00',
dateTime: '3/5/2019 4:55:18 PM' }

 

I'm definitely filling out the email field in the hosted form and don't understand why that isn't coming back as part of the transaction response.

That is an incomplete transaction response. If you pull the complete response it will be in there. I looked earlier and the email is under 2 objects, the customer object and the billTo object. You can pass it in the billTo all day long. It won’t throw an error, but you won’t get it back either. The form field is tied to the
customer object. It can also be passed in the API call as a customer data type object. It will be prepopulated on the form.

Do you get that from an iframe? That may be why your response only has limited information. You can use a getTransactionDetails method call to get a complete response. Works like magic in conjunction with webhooks.

I did get that from an iframe. Thanks for the help, and I'm working on getting the getTransactionDetails working. I'll report back if that works for me.

I integrated hosted payment form in the iframe. On payment success, we are not getting the customer email id. I tried to get the transaction details using the getTransactionDetails method. but I am getting the error "The record cannot be found" with error code E00040. Currently, I am testing it in the sandbox environment.