Catalog field values MAY contain variables that are substituted at delivery time. This mechanism enables a single cached catalog to be customized for each viewer, supporting use cases such as personalized advertising, A/B watermarking, QoE reporting endpoints, and logging identifiers.
5.4.1. Variable Syntax
Variables are denoted by enclosing the variable name in percent characters (%).
Variable names MUST consist of alphanumeric characters, hyphens, and underscores.
Variable names are case-sensitive.
The percent character (%) MUST NOT appear in catalog field values except as
part of a variable reference. Literal percent characters are not permitted.
Variable values MUST consist only of alphanumeric characters, hyphens, underscores,
and the at sign (@). Special characters including commas, semicolons, quotes,
ampersands, and other punctuation MUST NOT appear in variable values. This
restriction prevents injection attacks and ensures safe substitution into
catalog field values.
5.4.2. Variable Resolution
Variables are resolved from the fragment identifier of the URI used to access
the catalog. The fragment identifier is the portion following the # character
and is processed entirely client-side, making it suitable for per-viewer
customization without affecting server-side caching.
Query parameters (following the ? character) are reserved for server-side
processing and MUST NOT be used for variable substitution.
When a subscriber requests a catalog using a URI containing a fragment identifier,
the fragment is parsed as key-value pairs (using & as delimiter and = as
separator). Each key becomes available as a variable name, and the variable
is replaced with the corresponding value.