Offer deduplication across offer attributes

Using the Unica Interact application programming interface (API), two API calls deliver offers: getOffers and getOffersForMultipleInteractionPoints. getOffersForMultipleInteractionPoints can prevent the return of duplicate offers at the OfferID level, but cannot deduplicate offers across offer category. So, for example, for Unica Interact to return only one offer from each offer category, a workaround was previously required. With the introduction of two parameters to the startSession API call, offer deduplication across offer attributes, such as category, is now possible.

This list summarizes the parameters that were added to the startSession API call. For more information about these parameters or any aspect of the Unica Interact API, see the Unica Interact Administrator's Guide, or the Javadoc files included with your Unica Interact installation in <Unica Interact_Home>/docs/apiJavaDoc.

  • UACIOfferDedupeAttribute. To create a startSession API call with offer deduplication, so that the subsequent getOffer calls return only one offer from each category, you must include the UACIOfferDedupeAttribute parameter as part of the API call. You can specify a parameter in the name,value,type format, as shown here:

    UACIOfferDedupeAttribute,<attributeName>,string

    In this example, you would replace <attributeName> with the name of the offer attribute you want to use as the criterion for deduplication, such as Category.

    Note: Unica Interact examines the offers that have the same attribute value you specify (such as Category) and deduplicate to remove all but the offer that has the highest score. If the offers that have the duplicate attribute also have identical scores, Unica Interact returns a random selection from among the matching offers.
  • UACINoAttributeDedupeIfFewerOffer. When you include the UACIOfferDedupeAttribute in the startSession call, you can also set this UACINoAttributeDedupeIfFewerOffer parameter to specify the behavior in cases where the offer list after deduplication no longer contains enough offers to satisfy the original request.

    For example, if you set UACIOfferDedupeAttribute to use the offer category to deduplicate offers, and your subsequent getOffers call requests that eight offers be returned, deduplication might result in fewer than eight eligible offers. In that case, setting UACINoAttributeDedupeIfFewerOffer parameter to true would result in adding some of the duplicated to the eligible list to satisfy the requested number of offers. In this example, if you set the parameter to false, the number of offers that are returned would be fewer than the requested number.

    UACINoAttributeDedupeIfFewerOffer is set to true by default.

For example, suppose you specified as a startSession parameter that the deduplication criterion is offer Category, as shown here:

UACIOfferDedupeAttribute,Category,string;

UACINoAttributeDedupeIfFewerOffer,1,string

By default, the UACIOfferDedupeAttribute will not deduplicate offers if fewer than the requested number is returned . However, to ensure that the deduplication happens when fewer than requested offers are returned, the UACINoAttributeDedupeIfFewerOffer parameter must be provided and must be set to 1.

These parameters together cause Unica Interact to deduplicate offers based on the offer attribute "Category," and to return only the deduplicated offers even if the resulting number of offers is fewer than requested (UACINoAttributeDedupeIfFewerOffer is false).

When you issue a getOffers API call, the original set of eligible offers might include these offers:

  • Category=Electronics: Offer A1 with a score of 100 and Offer A2 with a score of 50.
  • Category=Smartphones: Offer B1 with a score of 100, Offer B2 with a score of 80, and offer B3 with a score of 50.
  • Category=MP3Players: Offer C1 with a score of 100, Offer C2 with a score of 50.

In this case, there were two duplicate offers that match the first category, three duplicate offers that match the second category, and two duplicate offers that match the third category. The offers that are returned would be the highest scoring offers from each category, which are Offer A1, Offer B1, and Offer C1.

If the getOffers API call requested six offers, this example set UACINoAttributeDedupeIfFewerOffer to false, so only three offers would be returned.

If the getOffers API call requested six offers, and this example omitted the UACINoAttributeDedupeIfFewerOffer parameter, or specifically set it to true, some of the duplicate offers would be included in the result to satisfy the requested number.