Customization

To add or update customer fields, please do the following, call the method passing a JSONArray containing a JSONObject:

Customer.assignOrUpdateValueToCustomerFields({
  fields: { "field1": "field1_value", "field2": "field2_value" }
  }, (customer) => {
		// Do something
}, (error) => {
  // Log error
})

Otherwise, if you want to eliminate a field, you have to do this with an array of strings containing the name of the fields:

Customer.deleteValuesFromCustomerFields(["field1", "field2"], (customer) => {
		// Do something
}, (error) => {
		// Log error
})