Reply
Highlighted
Member
Posts: 1
Registered: ‎02-15-2019

CIM, getCustomerProfileRequest, and duplicate records

I need to know if a payment profile exists for a customer, and create one if it does not.  I do not know ahead of time if the customer profile exists.

 

Documentation on Duplicate Profile Verification states that a CIM customer profile is unique based on these fields:

merchantCustomerId
description
email

 

Unfortunately, it doesn't appear that the getCustomerProfileRequest API call accepts a description parameter, so if we somehow ended up with multiple profiles for the same merchantCustomerId & email (with a different description), a call to getCustomerProfileRequest returns "Multiple records found. Please refine search options."  This leaves me unable to find the proper customerProfileId.

 

I can call createCustomerProfileRequest with the assumption that no profile exists, but if the customer profile already exists it will give me the profileId in an error message.  While I could extract this profileId and use it to add a new payment profile, I just used the nonce in the call to createCustomerProfileRequest, so it is no longer valid and I no longer have the payment information.

- Is there a way to call getCustomerProfileRequest using the description to ensure I get a result?

- If not, would a best practice be to call createCustomerProfileRequest without the opaqueData nonce, saving it for the subsequent call to createCustomerPaymentProfileRequest?

 

Any insight is appreciated.  Thank you!

Highlighted
Contributor
Posts: 21
Registered: ‎08-17-2012

Re: CIM, getCustomerProfileRequest, and duplicate records

Same issue for me.

 

getCustomerProfileRequest should return the duplicates as list to let us or the user choose the correct one or add away for us to filter results.