Skip to content

Commit

Permalink
Merge pull request #8667 from braze-inc/bd-3790
Browse files Browse the repository at this point in the history
BD-3790 Apply template standards to Custom Data
  • Loading branch information
lydia-xie authored Jan 6, 2025
2 parents 07bb054 + f72e662 commit 93eaa64
Show file tree
Hide file tree
Showing 8 changed files with 77 additions and 72 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -9,16 +9,16 @@ search_rank: 1

# [![Braze Learning course]({% image_buster /assets/img/bl_icon3.png %})](https://learning.braze.com/custom-events-and-attributes){: style="float:right;width:120px;border:0;" class="noimgborder"}Custom attributes

> Custom attributes are a collection of your users' unique traits. Custom attributes are best for storing attributes about your users, or information about low-value actions within your application.
> This page covers custom attributes, which are a collection of your users' unique traits. Custom attributes are best for storing attributes about your users, or information about low-value actions within your application.
When stored in Braze, these characteristics can be used to build out audience segments and personalize messaging using Liquid. You should keep in mind that we don't store time-series information for custom attributes, so you won't be able to get any graphs based upon them like you can for custom events.
When stored in Braze, custom attributes can be used to build out audience segments and personalize messaging using Liquid. Keep in mind that we don't store time-series information for custom attributes, so you won't be able to get any graphs based on them like you can for custom events.

## Managing custom attributes

To create and manage custom attributes in the dashboard, go to **Data Settings** > **Custom Attributes**.

{% alert note %}
If you are using the [older navigation]({{site.baseurl}}/navigation), you can find **Custom Attributes** under **Manage Settings**.
If you're using the [older navigation]({{site.baseurl}}/navigation), you can find **Custom Attributes** under **Manage Settings**.
{% endalert %}

![Four custom attributes that are booleans.]({% image_buster /assets/img/export_custom_attributes.png %})
Expand All @@ -29,11 +29,11 @@ From this page, you can view, manage, create, or blocklist existing custom attri

### Blocklisting

Custom attributes can be blocklisted individually via the actions menu, or up to 10 attributes can be selected and blocklisted in bulk. If you block a custom attribute, no data will be collected regarding that attribute, existing data will be unavailable unless reactivated, and blocklisted attributes will not show up in filters or graphs. In addition, if the attribute is currently being referenced by filters or triggers in other areas of the Braze dashboard, a warning modal will appear explaining that all instances of the filters or triggers that reference it will be removed and archived.
Custom attributes can be blocklisted individually in the actions menu, or up to 10 attributes can be selected and blocklisted in bulk. If you block a custom attribute, no data will be collected regarding that attribute, existing data will be unavailable unless reactivated, and blocklisted attributes will not show up in filters or graphs. Additionally, if the attribute is currently referenced by filters or triggers in other areas of the Braze dashboard, a warning modal will appear explaining that all instances of the filters or triggers that reference it will be removed and archived.

### Marking as PII
### Marking as personally identifiable information (PII)

Admins can also create custom attributes and mark them as PII from this page. These attributes will only be visible to admins and dashboard users with the “View Custom Attributes Marked as PII” permission.
Administrators can also create custom attributes and mark them as PII from this page. These attributes will only be visible to admins and dashboard users with the “View Custom Attributes Marked as PII” permission.

### Adding descriptions

Expand All @@ -56,7 +56,7 @@ There are two ways you can remove custom attributes from user profiles:

### Viewing usage reports

The usage report lists all the Canvases, campaigns, and segments using a specific custom attribute. This list does not include uses of Liquid.
The usage report lists all the Canvases, campaigns, and segments using a specific custom attribute. This list doesn't include uses of Liquid.

You can view up to 10 usage reports at a time by selecting the checkboxes next to the respective custom attributes and then selecting **View usage report**.

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -9,11 +9,11 @@ description: "This reference article covers using an array of objects as a data

# Array of objects

> Use an array of objects to group related attributes. For example, you may have a group of pet objects, song objects, and account objects that all belong to one user. These arrays of objects can be used to personalize your messaging with Liquid, or create audience segments if any element within an object matches the criteria.
> This page covers how to use an array of objects to group related attributes. For example, you may have a group of pet objects, song objects, and account objects that all belong to one user. These arrays of objects can be used to personalize your messaging with Liquid, or create audience segments if any element within an object matches the criteria.
## Limitations

- Arrays of objects are intended for custom attributes sent via the API. CSV uploads are not supported. This is because commas in the CSV file will be interpreted as a column separator, and commas in values will cause parsing errors.
- Arrays of objects are intended for custom attributes sent through the API. CSV uploads are not supported. This is because commas in the CSV file will be interpreted as a column separator, and commas in values will cause parsing errors.
- Arrays of objects have no limit on the number of items but do have a maximum size of 50 KB.
- Not all Braze Partners support arrays of objects. Refer to the [Partner documentation]({{site.baseurl}}/partners/home) to confirm if the integration supports this feature.

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -9,9 +9,9 @@ description: "This reference article covers using nested custom attributes as a

# Nested custom attributes

Nested custom attributes allow you to define a set of attributes as a property of another attribute. In other words, when you define a custom attribute object, you can define a set of additional attributes for that object.
> This page covers nested custom attributes, which allow you to define a set of attributes as a property of another attribute. In other words, when you define a custom attribute object, you can define a set of additional attributes for that object.
For example, let's say you want to define a custom attribute on the user profile called `favorite_book`. This custom attribute can be defined as an object that has the nested attributes `title`, `author`, and `publishing_date`, like so:
Let's say you want to define a custom attribute on the user profile called `favorite_book`. This custom attribute can be defined as an object that has the nested attributes `title`, `author`, and `publishing_date`, like so:

```json
"favorite_book": {
Expand All @@ -36,11 +36,11 @@ Custom attribute objects can contain [data types][1], such as:

## Limitations

- Nested custom attributes are intended for custom attributes sent via the Braze SDK or API.
- Nested custom attributes are intended for custom attributes sent through the Braze SDK or API.
- Objects have a maximum size of 50 KB.
- Key names and string values have a size limit of 255 characters.
- Key names cannot contain spaces.
- Not all Braze Partners support nested custom attributes. Refer to the [Partner documentation]({{site.baseurl}}/partners/home) to confirm if the integration supports this feature.
- Not all Braze Partners support nested custom attributes. Refer to the [Partner documentation]({{site.baseurl}}/partners/home) to confirm if specific partner integrations support this feature.
- Nested custom attributes cannot be used as a filter when making a Connected Audience API call.

## API example
Expand Down Expand Up @@ -261,7 +261,9 @@ If you haven't captured dates as object properties initially, we recommend resen
}
```

Note that for nested custom attributes, if the year is less than 0 or greater than 3000, Braze does not store these values on the user.
{% alert note %}
For nested custom attributes, if the year is less than 0 or greater than 3000, Braze doesn't store these values on the user.
{% endalert %}

## Liquid templating

Expand All @@ -281,15 +283,15 @@ Use the `custom_attribute` personalization tag and dot notation to access proper

You can build segments based on nested custom attributes to further target your users. To do so, filter your segment based on the custom attribute object, then specify the path to your property name and associated value you want to segment on. If you're not sure what that path looks like, you can [generate a schema](#generate-schema) and use the nested object explorer to have Braze populate that path for you.

After adding a path to your property, click **Validate** to verify that the value in the path field is valid.
After adding a path to your property, select **Validate** to verify that the value in the path field is valid.

![Filtering based on a most played song custom attribute where a listener has played a song over a specified number of times][6]

To segment with nested custom attributes, select the **Nested Custom Attributes** filter to expose a dropdown from which you can select a specific nested custom attribute.

![][17]{: style="max-width:70%;"}

When working with nested custom attributes segmentation, you'll have access to a new comparator grouped by data type. For example, since `play_analytics.count` is a number, you can select a comparator under the **Number** category.
When working with nested custom attributes segmentation, you'll have access to a new comparator grouped by data type. For example, because `play_analytics.count` is a number, you can select a comparator under the **Number** category.

![A user choosing an operator based on the data type for the nested custom attribute][7]

Expand Down Expand Up @@ -321,7 +323,7 @@ When you select **Copy Liquid for segment**, Braze will automatically generate L
{% endfor %}
```

From here, you can use `segmented_nested_objects` and personalize your message. In our use case, we want to take a goal from the first active taxable account and personalize it:
From here, you can use `segmented_nested_objects` and personalize your message. In this example, we want to take a goal from the first active taxable account and personalize it:

```
Get to your {{segmented_nested_objects[0].goal}} goal faster, make a deposit using our new fast deposit feature!
Expand Down Expand Up @@ -350,13 +352,13 @@ For this example, suppose we have an `accounts` object array that we've just sen
]
```

In the Braze dashboard, navigate to **Data Settings** > **Custom Attributes**.
In the Braze dashboard, go to **Data Settings** > **Custom Attributes**.

{% alert note %}
If you are using the [older navigation]({{site.baseurl}}/navigation), you can find **Custom Attributes** under **Manage Settings**.
If you're using the [older navigation]({{site.baseurl}}/navigation), you can find **Custom Attributes** under **Manage Settings**.
{% endalert %}

Search for your object or object array. In the **Attribute Name** column, click **Generate Schema**.
Search for your object or object array. In the **Attribute Name** column, select **Generate Schema**.

![][8]

Expand Down Expand Up @@ -386,19 +388,19 @@ Create a segment and add the filter `Nested Custom Attribute`, then search for a

![][11]

Click the <i class="fas fa-plus"></i> plus button in the path field. This will bring up a representation of your object or object array. You can select any of the listed items and Braze will insert them into the path field for you. For our use case, we need to get the balance. Select the balance and the path (in this case, `[].balance`) is automatically populated in the path field.
Select the <i class="fas fa-plus"></i> plus button in the path field. This will bring up a representation of your object or object array. You can select any of the listed items and Braze will insert them into the path field for you. In this example, we need to get the balance. Select the balance and the path (in this case, `[].balance`) is automatically populated in the path field.

![][12]{: style="max-width:70%" }

You can click **Validate** to verify that the contents of the path field is valid, then build the rest of the filter as needed. Here we've specified that the balance should be less than 100.
You can select **Validate** to verify that the contents of the path field is valid, then build the rest of the filter as needed. Here we've specified that the balance should be less than 100.

![][13]

That's it! You just created a segment using a nested custom attribute, all without needing to know how the data is structured. The nested object explorer in Braze generated a visual representation of your data and allowed you to explore and select exactly what you needed to create a segment.

### Trigger nested custom attribute changes

You can trigger when a nested custom attribute object changes. This option is not available for changes to object arrays. If you don't see an option to view the path explorer, check that you've generated a schema.
You can trigger when a nested custom attribute object changes. This option isn't available for changes to object arrays. If you don't see an option to view the path explorer, check that you've generated a schema.

![][16]

Expand Down Expand Up @@ -426,16 +428,16 @@ To regenerate the schema for your nested custom attribute:

1. Go to **Data Settings** > **Custom Attributes**.
2. Search for your nested custom attribute.
3. In the **Attribute Name** column for your attribute, click <i class="fas fa-plus"></i> to manage the schema.
4. A modal will appear. Click **Regenerate Schema**.
3. In the **Attribute Name** column for your attribute, select <i class="fas fa-plus"></i> to manage the schema.
4. A modal will appear. Select **Regenerate Schema**.

The option to regenerate schema will be disabled if it has been less than 24 hours since the schema was last regenerated. Regenerating the schema will only detect new objects and will not delete objects that currently exist in the schema.

{% alert important %}
If you want to reset the schema for an object array with an existing object, you need to create a new custom attribute. Schema regeneration does not delete existing objects.
To reset the schema for an object array with an existing object, you need to create a new custom attribute. Schema regeneration doesn't delete existing objects.
{% endalert %}

If data does not appear as expected after regenerating the schema, the attribute may not be ingested often enough. User data is sampled on previous data sent to Braze for the given nested attribute. If the attribute isn't ingested enough, it won't be picked up for the schema.
If data doesn't appear as expected after regenerating the schema, the attribute may not be ingested often enough. User data is sampled on previous data sent to Braze for the given nested attribute. If the attribute isn't ingested enough, it won't be picked up for the schema.

## Data points

Expand Down
Loading

0 comments on commit 93eaa64

Please sign in to comment.