Skip to main content

Managing attributes

important

Admin feature

Attributes are the key to customizing your Rules as much as you want. Use attributes to represent any information about the following entities:

  • Application
  • Campaign
  • Cart Item
  • Coupons
  • Customer profile
  • Customer session
  • Event
  • Giveaway
  • Referral

Attributes are Application-specific and used inside rules, usually inside conditions. They are described by:

  • Their type (number, string, list...).
  • Their name.
  • The entity they belong to in the above list.

Some attributes are provided by default, such as the name of a customer, the value of a coupon, the name of a Campaign, and many more. These are called built-in attributes. You can see them in the attribute library and find them in the Rule Builder palette.

Not all built-in attributes are available by default, but Admin users can enable them.

When the built-in attributes do not represent the data of your business activity, you can create your own attributes. These are called custom attributes.

Example

Let's imagine you own a bike-rental business. Users can get free minutes if they return their rental bikes to certain locations.

An obvious rule for this would be:

  • Condition: if the bike location at the end of the rental is one of the special locations then...
  • Effect: Award X minutes to the customer profile.

Talon.One does not provide a minutes attribute for customer profiles, so we can create a custom attribute to represent this data. We can call it minutes, it is a number, and it is associated to the customer profile entity.

Creating custom attributes

To send specific data to Talon.One, create custom attributes, set a value for them via the Integration API or via the Campaign Manager and use them in your Rules.

note

Only Admin users can create attributes.

  1. Click Account in the left-most menu.

  2. Click Dev Tools > Attributes.

  3. Click Create attribute at the top-right of the page.

  4. In Associated entity, choose the entity that will own the attribute.

  5. In Attribute type, choose the type of value assigned to the attribute:

    • String
    • Number
    • Boolean
    • Time
    • Location
    • List of strings
    • List of numbers
    • List of dates
    • List of locations
  6. In API name, type the name of the attribute as you will use it in the integration layer. See the Developer docs.

  7. In Rule Builder name, type the name of the attribute as it will appear in the Rule Builder palette.

  8. In Rule Builder description, type a description of what the attribute represents. It will appear in the Rule Builder palette.

  9. (Optional) In Picklist Values:

    • In Enter picklist values, enter a list of values for the attribute.
    • If you have to enter more than 20 values, upload a CSV file with up to 500.000 values in Import picklist values. Imports override previous ones and any manually entered values.
    • (Optional) Tick the checkbox above Enter picklist values to allow users to enter their own values when using the attribute in the Rule Builder. By default, users are only able to use picklist values once you import or manually enter some.
    note

    See Picklist values to learn more.

  10. In Available in applications, select the Applications where you want to use the attribute. If you choose none, it will be available everywhere.

  11. Click Create Attribute.

A notification pops up, indicating that the attribute has been successfully created.

This attribute is ready to be used but has no value yet.

Picklist values

Use this feature to select predefined values from a drop-down menu when using custom attributes in the Rule Builder. Picklist values are available for conditions and cart item filters. This is useful to prevent mistakes when setting up campaigns involving many items.

For example, if your business is a supermarket and you want to create campaigns based on items in the cart, you can create a cart item custom attribute called pizza and add values such as pizza carbonara, pizza salami and pizza veggie, or a list of SKUs.

When creating custom attributes, you can decide whether users creating rules can add their own values or just pick predefined values from a list.

note

Picklist values are not available for boolean and location attributes.

Setting the value of an attribute

Once you have created an attribute, you can set its value. The way you can set its value depends on the associated entity.

EntityHow to set the attribute values
ApplicationIn the Application settings.
CampaignIn the settings of the campaign.
Cart itemProgrammatically, using the Update Customer Session endpoint. See an example in the Developer docs.
CouponWhen you create a coupon via the Campaign Manager. Programmatically during import or using the Update Customer Session endpoint.
Customer profileProgrammatically, using the Update Customer Profile endpoint.
Customer sessionProgrammatically, using the Update Customer Session endpoint.
EventProgrammatically, using the Track Event endpoint.
GiveawayWhen you import a giveaway. Programmatically, during import or using the Update Customer Session endpoint.
ReferralWhen you generate a referral as an effect. Programmatically, during creation or using the Update Customer Session endpoint.

Also see an example in the Developer docs.

Filtering attributes

You can use different criteria to filter your attributes and find specific ones. For example, you can filter by the entity associated with the attribute.

  1. Click Account in the left-most menu.

  2. Click Dev tools > Attributes.

  3. Click Filter at the top of the page to display the filtering options:

    • You can use Entity to find all the attributes associated with the same type of entity.
    • You can use Type to find attributes corresponding to a certain type of value.
    • You can use Hide/Show attributes to only display built-in attributes or custom ones.
    note

    You can use more than one filter at the same time. The filters used appear at the top of the page, and you can edit them by clicking on the box with their name. You can also remove them individually by clicking the X to the right of their name.

You see the table rows containing the attributes that match the filters you have set.

tip

Click Clear Filters at the top of the page to see again all the available attributes once you have found those you were looking for.

Editing custom attributes

You can modify some characteristics of a coupon after it has been created. For example, you can modify the description or edit picklist values.

  1. Click Account in the left-most menu.

  2. Click Dev tools > Attributes.

  3. Use the search bar and the filters at the top to search for the attribute you wish to edit.

  4. Click the title of the attribute.

  5. Edit the required information (Rule Builder name, Rule Builder description, picklist values, connected Applications).

    note

    If you imported a CSV file with picklist values, you can download it to check the values it contains. If you import a new CSV file, it overrides any manually entered values and previous imports.

  6. Click Update attribute.

A notification pops up, indicating that the attribute has been successfully updated.

Deleting custom attributes

You can delete your custom attributes, but not the built-in ones.

important

You cannot delete a custom attribute if you are using it.

  1. Click Account in the left-most menu.
  2. Click Dev tools > Attributes.
  3. Use the search bar and the filters at the top to search for the attribute you wish to edit.
  4. Click the title of the attribute.
  5. Click Delete <attribute name> on the pop-up confirmation window that appears.

A notification pops up, indicating that the attribute has been deleted.