BlazeDataSourceType
A data source tells a Web SDK widget or player which content to fetch. Build one with BlazeSDK.DataSourceBuilder(), then pass it as options.dataSource to a widget method or to playContent.
Pages in this section
- DataSourceBuilder: the
labels,ids,text,recommendations, andcompositebuilder methods. - LabelBuilder: build single-label, AND, and OR label expressions.
- VideoFiltersBuilder: filter video content by content type and stream state.
For the concepts behind data sources, see Data sources and Content recommendations. For the widget methods that consume a data source, see BlazeSDK class.
BlazeDataSourceType
BlazeDataSourceType is the object every DataSourceBuilder method returns.
| Property | Type | Required | Description | ||
|---|---|---|---|---|---|
| sourceType | 'labels' | 'ids' | 'text' | 'recommendations' | Yes | The type of data source: 'labels', 'ids', 'text', or 'recommendations'. | ||
| labels | string | string [ ] | BlazeWidgetLabel ` ` ` | No | A string, array of strings, or BlazeWidgetLabel representing the labels. |
| labelsPriority | string | string [ ] | BlazeWidgetLabel [ ] | No | A string, array of strings, or array of BlazeWidgetLabel for priority. | ||
| ids | string [ ] | No | An array of strings representing the IDs. | ||
| text | string | No | Search term for text-based content search (case-insensitive). Searches across video catalog metadata. | ||
| orderType | OrderType | No | The order type | ||
| maxItems | number | No | The maximum number of items. | ||
| advancedOrdering | AdvancedOrdering | No | Advanced ordering config | Currently supports only 'LiveFirst' | |
| recommendations | BlazeRecommendations | No | Object representing the recommendations. | ||
| personalized | BlazePersonalized (see below) | No | Optional BlazePersonalized filter when sourceType is labels (see above). For Concepts vs this API name, see Content recommendations. |
type BlazePersonalizedIds = {
type: 'ids';
teams?: Array<string>;
players?: Array<string>;
};
type BlazePersonalizedLabels = {
type: 'labels';
labelsFilterExpression: string | string[] | BlazeWidgetLabel;
labelsPriority: string | string[] | BlazeWidgetLabel[];
};
type BlazePersonalized = BlazePersonalizedIds | BlazePersonalizedLabels;Updated 16 days ago
Did this page help you?
