Skip to main content
RichRelevance

Registry Types

If your site has more than one kind of registry, your RichRelevance team will set up registry types, which identify the different registries and help deliver the best content for each of them.

For a list of valid registry type IDs that have been set up for your site, contact your RichRelevance team.

If shoppers typically create a registry the first time they visit your site from a particular device, you may need to explicitly pass the registry type ID in order to show registry recommendations.

JavaScript Integration

How To Make This Code Work For You

  1. Create the integration code on each of the pages on your site, following the HTML integration and JSON integration guides.
  2. Add this function to your integration code:
Function Requirement
R3_COMMON.setChannel('REGISTRY_TYPE'); Replace REGISTRY_TYPE with the registry type ID. For a list of valid registry type IDs that have been set up for your site, contact your RichRelevance team.

Sample Code

Call setRegistryType() in the Primary Code Block.

HTML

<!-- Place this code inside the <body> element as close to the top as possible -->
<script src="//media.richrelevance.com/rrserver/js/1.2/p13n.js"></script>
<script charset="utf-8" type="text/javascript">
  var R3_COMMON = new r3_common();
  R3_COMMON.setApiKey('abcd5432e1');
  R3_COMMON.setBaseUrl(window.location.protocol+'//integration.richrelevance.com/rrserver/');
  R3_COMMON.setClickthruServer(window.location.protocol+"//"+window.location.host);
  R3_COMMON.setSessionId('6B4D397B');
  R3_COMMON.setUserId('1');  // if exists, set it; if not, set it as session ID
  
  // here's an example requesting recommendations for 1 page area
  R3_COMMON.addPlacementType('home_page.rr1');
    
  var R3_HOME = new r3_home();
 
  R3_COMMON.setRegistryType('Baby');
 
  r3();
  
</script>

JSON

<!-- Place this code inside the <body> element as close to the top as possible -->
<script charset="utf-8" type="text/javascript">
  var R3_COMMON = new r3_common();
  R3_COMMON.setApiKey('abcd5432e1');
  R3_COMMON.setBaseUrl(window.location.protocol+'//integration.richrelevance.com/rrserver/');
  R3_COMMON.setClickthruServer(window.location.protocol+"//"+window.location.host);
  R3_COMMON.setSessionId('6B4D397B');
  R3_COMMON.setUserId('10987');  // if exists, set it; if not, set it as session ID
  
  // here's an example requesting recommendations for 1 page area
  R3_COMMON.addPlacementType('home_page.rr1');
 
  var R3_HOME = new r3_home();
 
  R3_COMMON.setRegistryType('Baby');
 
  rr_flush_onload();
  
  r3();
</script>

APIs

Set the registry type with the rg parameter in recsForPlacements.

Example: rg=Registry123454321