Technology Blogs by Members
Explore a vibrant mix of technical expertise, industry insights, and tech buzz in member blogs covering SAP products, technology, and events. Get in the mix!
Showing results for 
Search instead for 
Did you mean: 
Active Contributor

The aim of this document is to explain how automatic/initial Customer search works on Live Activity screen under an Inbound Call scenario. Also, the idea is to explain how to enhance this initial search.

A separate blog has been written here in order to provide detailed explanation on how to enhance and extend the manual search that can be carried on when an agent is searching through allowed objects.



When an incoming phone call occurs, call information is passed to C4C based on certain parameters.

After the user clicks on the incoming call display window, the solution displays the Live Activity Center window with associated information for that incoming phone number.

In C4C, an incoming call information is passed based on ANI (incoming phone number), and searches are performed over Business Partners such as Contacts, Accounts, and Individual Customers.

When a phone call is passed to C4C, two searches can take place:

a) An automatic search based on the ANI information (or even some additional fields) is used to display any matching caller information on the incoming call notification.

b) Default search when the Live Activity Center opens based on information passed by your interactive voice response (IVR) system. I will write about this on a separate Blog and explain how to extend it.



Solution search could identify a unique customer, multiple customers, or may not identify any customer at all.

If they are passed by the IVR system, the default search includes the following parameters:

  • Phone number: returns any contacts, accounts or individual customers containing a matching phone number.

  • Serial ID: returns any matching registered products.

  • Ticket ID: returns any matching tickets

This means that, if the IVR would send the Account ID, at least until release 1811, there is no search carried automatically for finding this account. If the agent would make a manual ID search with the Account ID, it will be returned as expected. (this could be a future improvement delivered by SAP ?)

For being more graphic, let me highlight which fields are being automatically searched by showing the CTI Client Adapter screen:

Additional information passed from the IVR system appears at the top right of the Live Activity Center.

The default search ignores this additional information. If wanted, the search parameters can be configured in order to exclude Serial ID and Ticket ID from search.


When configuring the Live Activity, the Administrator can determine which objects are allowed to be searched. Currently, there are not much:

This can be configured under Administrator workcenter (Service and Social > Communication Channels > Live Activity Configuration)

The selected business objects will be used to check for a matching phone number when the system receives an incoming telephone call. Cloud for Customer solution allows search for both: regular and mobile telephone numbers, which is the default behavior.

In my personnel experience, I am being requested to show Sales Orders which are not listed on the previous list. Therefore, I was required to introduce a custom development for showing them. Shortly, I will be providing  separate blog which shows how to handle this scenario.



In case a customer requires to have a specific logic to be executed for searching a customer when an incoming call is received, it is possible to implement a Search BAdI exit. However this has some cons:

  • If implementing the custom search, the standard search is not performed. So, if you were expecting to add custom logic just to refine standard search, this is not achievable, you will need to write the whole logic.

  • While standard search could return 0 or 1 or multiple possible callers, the custom search just allows to return a single caller. (Currently, I have an open incident for this)

  • Although a single caller can be returned by the BAdI, user still needs to confirm it.

  • When using custom search, no entries are returned on the left search pane.

As per official documentation, this is the process flow:

In order to create the custom search, the following Enhancement Implementaion needs to be created:

As per its documentation, it receives a structure called InputData and just returns a single business partner ID:

Just to give an example,  let’s think of a scenario where the IVR must send a custom field which represents a Booking ID and our customer needs to influence the Customer search based on this and the ANI, a possible logic could look similar to the following one:
import AP.Common.GDT;
import AP.CRM.Global;
import AP.FO.BusinessPartner.Global;
import AP.FO.Activity.Global;

var result : BusinessPartnerID = ""; // empty means no matched customers
var booking_id = InputData.CustomField1;
var from_phone_number = InputData.ANI;

// if inputData doesn't have BOOKING ID
if (booking_id.IsInitial()) {
// if inputData has PHONE number
// search customer by PHONE number
var query = Customer.QueryByCommunicationData;
var selectionParams = query.CreateSelectionParams();
selectionParams.Add(query.NormalisedPhoneNumberDescription, "I", "CP", from_phone_number);
var resultData = query.ExecuteDataOnly(selectionParams);

// if result set records more than one, get first
if(resultData.Count() > 0){
result = resultData.GetFirst().InternalID;

return result;


The supported input parameters when using a BAdI for custom search logic to retrieve CTI caller information are:

  • Activity UUID

  • Business Partner ID

  • ANI

  • DNIS

  • Serial ID

  • Ticket ID

  • External Reference ID

  • Custom Field 1 - 6

These fields are the ones present on the simulation screen of the CTI Client Adapter (already shown before).


Hope you find this blog useful for you. Feel free to leave comments and queries on it, they are very welcome!

Labels in this area