Creating Custom Metadata

Table of Contents

1. Overview

2. How to Get Started

3. Categories

4. Custom Fields

4.1 Custom SoQL expressions

4.2 Custom Metadata Field Types

4.3 Conditional Metadata

4.4 Custom Metadata Field Permissions

5. Metadata audit

 

Overview

Metadata templates are a collection of fieldsets and custom fields, similar to custom metadata but with additional features and a new interface. 

The addition is that fields have a SoQL expression associated with them which allows a site administrator to define custom validation. Before validation was limited to required fields or optional fields, now validation can take on any form you can express in a SoQL expression.

 

NOTE: Metadata templates do not change how metadata is stored, used, or rendered on the platform. Metadata templates will also not delete any existing metadata that has already been configured on a domain. Find more information on the new feature here Metadata Templates

 

How to Get Started

To access metadata templates, a roled user with the required permissions, e.g. an Administrator will navigate to the Metadata page within the Administration Panel on your domain.

 

met1.png

 

The new metadata templates page will have a different UI with three main sections including a new section labeled Audit Metadata as shown below:

metadata admin2.png

 

 

Categories

With Metadata Templates, site administrators can add, delete, and manage new and existing categories.

Admins will have the ability to hide/unhide them from the catalog and delete them if needed. 

 

To add a new Category... 

1. Enter the new category name

2. If adding a secondary category, select a parent category from the dropdown. 

3. Click on Save.

4. The new category will be hidden from the catalog by default. To unhide it, click on the checkbox for the category under Shown on the grid

 

NOTE: All category names have to be unique. Attempting to duplicate a category will result in the following error

 

213.png

 

Custom Fields

The UI for metadata templates re-uses the patterns from VQE (Exploration Canvas) to render certain SoQL expressions as easy-to-use UI components. Similarly, there are UI components that generate SoQL expressions without having to write SoQL. These pre-defined components and metadata field types are:

  • Text field
  • Select drop-down
  • Multi-select drop-down
  • Conditional metadata
  • Default Value

Custom Metadata Field Permissions:

  • Restricted metadata
  • Required metadata
  • Optional metadata field
  • Private metadata field
  • Public metadata filed

You can learn more about each of the above at the bottom of this page. Now, let's use an example scenario to go over the new features and workflow for adding and managing field sets and fields:

For example, to add a field set labeled 'Test Field Set' with a field labeled 'Test Field'

 

1. Click on the Add Field Set button, type in a fieldset label, and click on Save

2. Click on Add Field and type in the fields name. 

3. Once added, selecting the added field will show more options as shown below. 

 

4. By just adding a field a SoQL query is generated automatically. To view the query, click on the blue Test & Edit SoQL validation button.

 

Custom SoQL expressions

The SoQL expression editor associated with each field is accessible at the top right of the field manager. Admins are free to define whatever expression they see fit for the metadata field. The constraints are the same as data transformations, as in, it produces a single value. The "columns" available to reference are the metadata input fields they have defined.

It works in the same way as data transformations, with the same functions available. The documentation is available below the editor, just as it is in the dataset management interface. More information on metadata validation using SoQL can be found here. 

morn3.png

 

Custom Metadata Field Types

Text fields and default values

Text type metadata fields have free text options that will allow users to input free text into the metadata field when publishing assets.

An administrator can also define a default value for a text field which will auto-populate in a given metadata field when an asset is being published.

Note: Default values are only available for text-type metadata fields.

Administrators can make a field a drop-down of pre-defined value options. This drop-down can either be single-select or multi-select, depending on the metadata needs a program may have.

 

Conditional Metadata

Conditional metadata allows administrators to create relationships between metadata fields option is only available for drop-downs at this time. When configured,  the drop-down field will only render a subset of its options based on the value selected in another metadata field within the same fieldset.

To illustrate, we can see in the screenshot below that we have a 'select' metadata field titled “Test” with values based on the 'Dog' value in the 'Animal' metadata field(selected as the parent field). 

2024-03-20 15_09_34-Metadata _ Tyler Data & Insights.png

 

If a conditional metadata field is added, publishers will only see the parent, in this case “Animal” field, initially when publishing. Once a value is selected in the parent field, the child field will render with only the appropriate subset of options to choose from.

Custom Metadata Field Permissions

Custom metadata field permissions can be found on the right side of a metadata field card, and are set on a field-by-field basis.

 

field permission.png

Permission

Description

Restricted

Restricted metadata fields are only editable by a user who has the domain right to edit restricted metadata fields.

Required

Required metadata fields must be filled in before publishing the asset. If the field is not filled in on an asset, it cannot be published.

Optional

Optional metadata fields do not need to be filled in for an asset to be published.

Private

Private fields are only visible to roled users.

Public

Public fields are viewable by any user who can view the metadata for a particular asset.

 

Metadata audit

The metadata audit tool allows an admin to run metadata validation against existing assets. It uses the common catalog components to display and interact with the list of assets on the domain. 

audit.png

Clicking on the link in the Metadata Status column opens a modal that displays the error messages produced by the SoQL expression. 

morn_5.png

Was this article helpful?
0 out of 0 found this helpful
Have more questions? Submit a request

Comments

0 comments

Article is closed for comments.