Skip to main content

Spike - Review Cloudinary Structured Metadata and Collections for use in approvals and Hybris sync

Overview

Results from a spike looking into Cloudinary structured metadata and collections, and how these features might fit into or simplify our approvals and asset sync process. Structured metadata fields can be added by developers via API, and their values can be configured by either developer teams or media library users. Structured metadata values can be used when searching for assets via API. Collections are a way of organising our assets in a non-hierarchical or fixed way, that could be used to group assets that are yet to be approved.

Metadata

Metadata is data that decsribes and summarises other data. In Cloudinary, metadata are key-value pairs that contain details about our assets which they are stored alongside - in other words a custom, typed field (key) for storing user defined data (value) with a media asset. There are 3 types of metadata:

  • Tags: individual text values that can assigned to specific assets.
  • Contextual metadata: custom key-value pairs that you can assign to individual assets.
  • Structured metadata: custom fields are defined, along with data types and validations, by an account administrator at a global level, and are added to all assets in the account. You assign their values per asset.

We will be focusing on structured metadata to integrate approval workflows into our sync with Hybris. We can use structured metadata to search assets based on a field value, or field value pair in order to refine data that we process and therefore sync with Hybris. Structured metadata allows us to define typed fields for media assets, populate them with values programmatically or via the Media Library, and perform searches on them. We can also add validation rules, set default values, and define fields as mandatory. It's possible to set up dependencies and hierarchical relationships between structured metadata fields and field options using the conditional metadata rules API.

Folders and Collections

There are two ways of organising assets in Cloudinary - Folders and Collections.

  • Folders are asset containers and are an integral part of the asset path (public ID).
  • Collections are a dynamic way to create conceptual groupings of assets, regardless of their folder structure.

We will benefit from the use of Folders when organising assets in Cloudinary in a hierarchical manner e.g. a Folder for a base product SKU could contain sub-Folders that organise the Gallery sets and Product sets for that base SKU.

Collections however, are non-hierarchical way of grouping assets for internal use that is unrelated to which Folder they are in. A single asset can be in stored in a folder path and can also be included in one or more collections e.g. a new asset could be uploaded to a Folder path of SKU123XX/Gallery/xxx.jpg and also belong to a Collection named "Awaiting approval". Adding or deleting assets to collections will have no impact on their Folder location. It's worth bearing in mind that users with a Media Library user role must be given explicit permissions to create collections by an account administrator. If Media Library users aren't able to use this feature independently, it could reduce its value to us.

How could we use these features?

Some examples of possible uses of Folders, Structured Metadata and Collections to visualise these features.

Replicating our Amplience asset organisation with Folders

  • Organise assets by product SKU, with separate sub-folders for gallery assets and product assets

Example Folder structure organisation

Streamlining the approvals workflow using Structured Metadata and Collections

  • All assets would have a structured metadata field "isApproved" value of "awaiting approval" added on asset upload
  • Assets would organised as suggested above, and uploaded to the relevant Folder
  • Media Library user would be responsible for creating a new "Awaiting Approval" Collection made up of on newly uploaded assets that therefore need approving
  • Once approved, assets would be deleted from the "Awaiting Approval" Collection but their Folder location would not change

Workflow using structured metadata and collections

Streamlining the approvals workflow using Structured Metadata and Advanced Search UI

  • All assets would have a structured metadata field "isApproved" value of "awaiting approval" added on asset upload
  • Assets would organised as suggested above, and uploaded to the relevant Folder
  • No Collections would be created, but instead the Media Library user that is responsible for approvals would use the Advanced Search API to search for any assets with the structured metadata field value of "awaiting approval"

Workflow using structured metadata and search functionality

Resources

https://cloudinary.com/documentation/metadata_api https://cloudinary.com/documentation/dam_manage_individual_assets#custom_metadata_comparison_table https://cloudinary.com/documentation/dam_manage_individual_assets#bulk_updating_metadata_values https://cloudinary.com/documentation/dam_folders_collections_sharing#comparison_chart https://cloudinary.com/documentation/dam_advanced_search