0

Trying to make an Account lookup, looks like is not working. The code is pretty straight forward, but it looks like is not working. Any ideas what could be wrong with this lookup?

val accountEntity = ChatEntity.Builder()
                .showOnCreate(true)
                .linkToTranscriptField("Account")
                .linkToAnotherSalesforceObject(caseEntity, "AccountId")
                .addChatEntityField(
                        ChatEntityField.Builder()
                                .doFind(true)
                                .isExactMatch(true)
                                .doCreate(false)
                                .build("AccountNumber", erpCustomerNumber))
                .addChatEntityField(
                        ChatEntityField.Builder()
                                .doFind(true)
                                .isExactMatch(true)
                                .doCreate(false)
                                .build("ERP_Company_Code__c", erpCompanyCode))
                .build("Account") 
    

1 Answer 1

1

The issue here, I'm new with this sdk, just forgot to add the ChatUserData with ERP Number to the chatConfigurationBuilder instance.

the code will look like the following:

val accountEntity = ChatEntity.Builder()
                .showOnCreate(true)
                .linkToTranscriptField("Account")
                .linkToAnotherSalesforceObject(caseEntity, "AccountId")
                .addChatEntityField(
                        ChatEntityField.Builder()
                                .doFind(true)
                                .isExactMatch(true)
                                .doCreate(false)
                                .build("AccountNumber", erpCustomerNumber))
                .build("Account")

.......
chatConfigurationBuilder.chatUserData(firstName, lastName, email, subject, description, erpCustomerNumber)

You must log in to answer this question.

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