Skip to main content


         This documentation site is for previous versions. Visit our new documentation site for current releases.      
 

createPersonalization(listID, personalizationID, personalizedState)

Updated on July 20, 2021

Creates a new personalization instance for a list component.

Returns

The personalization ID as a Promise.

Parameters

NameTypeDescriptionRequired
listIDstringA unique ID referencing a list component. The length of the ID should be limited to 32 characters.
personalizationIDstringA temporary unique ID which will be replaced by the actual ID returned by this API.
personalizedStateobjectAn object containing information about the personalization state.

Usage example

In this example, the API creates a personalization instance and returns a personalization ID.

const listId = "443533r555";
const personalizationId = "L_343456";
const personalizedState = {
  "name" : "Open bugs",
  "markAsDefault" : true,
  "personalizationState" : "{ filter : 'pyStatusWork = Open'}"
};

PCore.getPersonalizationUtils(listId).createPersonalization(personalizationId, personalizedState).then((response)=>{
   const personalizationId = response;
});

Have a question? Get answers now.

Visit the Support Center to ask questions, engage in discussions, share ideas, and help others.

Did you find this content helpful?

Want to help us improve this content?

We'd prefer it if you saw us at our best.

Pega.com is not optimized for Internet Explorer. For the optimal experience, please use:

Close Deprecation Notice
Contact us