Field MappingUpdated 30/04/2019


Map one field to another place, to build a set of unified attributes.


const { hubspot, clearbit } = user;
// First name detection
const first_name = user.first_name || hubspot.first_name || clearbit.person_name_given_name;
if (first_name) {
  hull.traits({ first_name });
}

// Last name detection
const last_name = user.last_name || hubspot.last_name || clearbit.person_name_family_name;
if (last_name) {
  hull.traits({ last_name });
}

//Company Name
const company = account.company_name || clearbit.company_name || hubspot.company;
if (company) {
  hull.traits({ "unified/company": company });
}