---
title: "Use Case Guide: Tagging Through Playbooks"
url: "https://atlan.com/demos/tagging-through-playbooks/"
description: "Automate tagging of assets in Atlan with Playbooks"
format: "Video"
video: "https://videos.ctfassets.net/nwa1c00rtgxb/2qguoD4ScUvHovGCcWzma6/14b7184456788630be93bdfe02f29133/Tagging_through_playbooks.mp4"
content_purpose: ["Product Overview"]
target_persona: ["Data Engineer", "Data Steward"]
journey_stage: ["C1 - Onboarding", "C2 - First Value", "C3 - Adoption", "S2 - Discovery"]
use_case_context: ["Training"]
product: ["Context For AI - Automation"]
content_type: "video transcript"
transcript_source: "contentful"
---

# Use Case Guide: Tagging Through Playbooks

Transcript of the video at https://atlan.com/demos/tagging-through-playbooks/

<!-- Body: machine transcript stored on the Contentful entry (field contentBody), timestamps kept, product names corrected. Not yet edited by a person. -->

Tagging through playbooks

Steven Hloros: [00:00] While tagging assets from the asset profile allows a lot of flexibility, we decide that we want to apply a P I I Level 3 tag to any column that is named mobile_phone, regardless of what database they reside in. This is where playbooks become a perfect way to mass update these assets and apply tags to them. As we are administrators, we click on the Governance icon on the left-hand navigation and then select Playbooks. We are taken to the playbooks overview page, where we can view all previous playbooks that have been run in our Atlan instance. We create a new playbook by clicking on the create new button. The playbook creation popup will appear and we enter the name of the playbook. We call it Tag P I I Level 3 columns. Since playbooks are flexible, while we may start out with only a single column name, we could always extend to include other column names, such as social security or home phone, so we won't specify the column name in the playbook name. We then click create to create the new playbook.

Playbooks are composed of two parts, filters, which allow you to create a selection of assets, and actions, which define the updates to apply to the assets selected in the rules.

For the first filter, [01:00] we click on the attribute dropdown and choose asset type. Then on the right-hand side, we click on the values and select column, meaning that we only include column asset types. Next, we click the add filter, and select name as the filter. We click on contains and change this to equals, so that what we type in as the matching value for the name must be an exact match of the entire name of the column. For the name, we put mobile phone with an underscore, as it is a column name. Once entered, we can see at the number of assets that match this rule has been updated. Clicking on view all opens up the preview assets sidebar, where we can review all assets selected from our rule. Here, we see that all the assets included are columns and have the exact name of mobile phone, adhering to the filters that we set.

Next, we need to create our action. Clicking on search in actions gives us the options available to apply to our selected assets. In this case, we are looking to apply the tag of P I I Level 3 to these assets, so we first select tags, keep the value of add, and select P I I Level 3. By default, propagation is turned off when applying a tag through playbooks. Clicking on the edit button [02:00] allows us to change this to propagate through hierarchy and lineage, or hierarchy only. In this case, we specifically identified the assets that we want the tag to be applied to, so we leave this as none.

Prior to running the playbook, a best practice is to add an additional filter to exclude assets that have already been updated by the action specified. We click on the add filter and select tag, we update the selection value to is not, and then select P I I Level 3. This way we do not attempt to add a tag on an asset where it already has been applied.

Our playbook is completed, so we click on the next button. This takes us to the run options for the playbook. We will choose run once for this walkthrough, however when creating playbooks to apply tags to assets, setting a schedule is usually the correct option, as scheduling the playbook to run on a repeated basis allows for tagging of newly created assets that fit the rule, ensuring that you keep up with your data estate as it changes. We click complete to run our playbook.

As the playbook has finished running, we can now go validate the application on our assets. Back at the asset discovery, we bring up the mobile_phone columns. Clicking [03:00] on the asset name, we can see the overview and see the tag applied to the asset.

With just a few filters we have been able to tag all of our assets with our specific column name and ensure they are correctly tagged. We can build out more playbooks and more complex filters to reduce a lot of the manual work that we would have to do if tagging through the UI.
