Пользователи предпочитают смотреть или слушать контент, к которому у них уже есть доступ, например, контент по существующей подписке. Если Google знает, к какому контенту пользователь может получить доступ в вашем приложении или на вашей платформе, то Google может обеспечить более релевантный опыт на всех платформах Google и направить пользователя именно к этому контенту.

Определите требования к доступу к контенту.
Необходимо определить требования к доступу для каждого пакета контента в вашем каталоге. При этом следует рассмотреть следующие вопросы:
- Нужно ли пользователям входить в ваше приложение или на вашу платформу, чтобы получить доступ к контенту?
Нужна ли пользователям подписка?
Смотрите только действия:
- Нужна ли пользователям подписка от стороннего поставщика услуг?
- Предлагаете ли вы многоуровневые, пакетные или дополнительные подписки?
Только для просмотра действий: Нужно ли пользователям арендовать или покупать контент?
Меняются ли требования к доступу со временем?
Зависят ли требования к доступу от местоположения устройства?
типы ограничений доступа
Существует два вида ограничений доступа:
тип платного доступа
Вы можете ограничить доступ к контенту, указав тип платного доступа. В таблице ниже подробно описаны различные типы платного доступа:
| тип платного доступа | Пример | Категория |
|---|---|---|
| Покупка или регистрация не требуются. | Треск | nologinrequired |
| Пользователь должен быть авторизован, но платная подписка не требуется. | Vudu (AVOD) | free |
| У пользователя должна быть активная подписка. Доступ не зависит от уровня подписки. | Netflix | |
| У пользователя должна быть активная подписка. Доступ зависит от выбранного уровня подписки. | Hulu (дополнения) | |
| Контент доступен в течение ограниченного времени после покупки. | Вуду | rental |
| Контент доступен неограниченное время после покупки. | Вуду | purchase |
| Данный контент доступен по кабельной подписке. | HBO Go | externalSubscription |
Тип платного доступа для действий просмотра
Чтобы указать тип платного доступа к контенту для действий просмотра, используйте свойство category в спецификации доступа к действию :
"potentialAction": {
"@type":"WatchAction",
"target": { … },
"actionAccessibilityRequirement": {
"@type": "ActionAccessSpecification",
"category": "subscription",
"availabilityStarts": "2018-06-01T10:35:29Z",
"availabilityEnds": "2019-05-31T10:35:29Z",
"eligibleRegion": {
"@type": "Country",
"name": "US"
}
},
...
}
Тип платного доступа для действий прослушивания
Чтобы указать тип платного доступа к контенту для действий прослушивания, используйте свойство category в объекте предложения :
"potentialAction": {
"@type":"ListenAction",
"target": { … },
"expectsAcceptanceOf":{
"@type":"Offer",
"category":"subscription",
"availabilityStarts": "2018-06-01T10:35:29Z",
"availabilityEnds": "2019-05-31T10:35:29Z",
"eligibleRegion": {
"@type":"Country",
"name":"US"
}
},
...
}
Географическая область
Необходимо указать географические регионы, где доступен контент. Используйте одно или оба из следующих свойств:
- Свойство
eligibleRegionобъекта спецификации доступа к действию . Это свойство обязательно для использования. - Свойство
ineligibleRegionобъекта спецификации доступа к действию .
Пользователь может получить доступ к контенту, если местоположение устройства находится в пределах любого региона, указанного в eligibleRegion , и не находится в пределах любого региона, указанного в ineligibleRegion .
Свойства eligibleRegion и ineligibleRegion допускают следующие значения:
- Список
Country,CityиState. - Объект
GeoShape. Подробные требования см. в разделе « СвойстваGeoShape. - Список объектов
GeoShape.
Если контент доступен во всем мире, используйте следующее специальное значение для eligibleRegion :
"eligibleRegion": "EARTH",
Варианты использования подходящего региона
Ниже приведены примеры использования свойства eligibleRegion :
- Пример 1:
eligibleRegionсо списком стран. - Пример 2:
eligibleRegionс объектомGeoShape, содержащим список почтовых индексов. - Пример 3:
eligibleRegionс объектомGeoShape, содержащим список кодов зон сортировки (FSA). - Пример 4:
eligibleRegionс объектомGeoShape, содержащим идентификатор DMA. - Пример 5:
eligibleRegionсо списком объектовGeoShape. Каждый объект содержит идентификатор DMA. - Пример 6:
ineligibleRegionс заблокированными почтовыми индексами.
Пример 1
eligibleRegion со списком стран:
"actionAccessibilityRequirement": { "@type": "ActionAccessSpecification", "category": "subscription", "requiresSubscription": { "@type": "MediaSubscription", "@id": "http://www.example.com/north_america_network/subscription", "name": "Example Subscription", "commonTier": true }, "eligibleRegion": [ { "@type": "Country", "name": "US" }, { "@type": "Country", "name": "CA" } ] }
Пример 2
eligibleRegion с объектом GeoShape , содержащим список почтовых индексов:
"actionAccessibilityRequirement": { "@type": "ActionAccessSpecification", "category": "subscription", "requiresSubscription": { "@type": "MediaSubscription", "@id": "http://www.example.com/local_tv_network/subscription", "name": "Example Subscription", "commonTier": true }, "eligibleRegion": { "@type": "GeoShape", "@id": "http://example.com/area1", "addressCountry": "US", "postalCode": [ "94118", "94119" ] } }
Пример 3
eligibleRegion с объектом GeoShape , содержащим список кодов зон сортировки (FSA):
"actionAccessibilityRequirement": { "@type": "ActionAccessSpecification", "category": "subscription", "requiresSubscription": { "@type": "MediaSubscription", "@id": "http://www.example.com/local_tv_network/subscription", "name": "Example Subscription", "commonTier": true }, "additionalProperty": { "@type": "PropertyValue", "name": "DisplaySubscriptionIdentifier", "value": "http://www.example.com/local_tv_network/subscription" }, "eligibleRegion":{ "@type": "GeoShape", "@id": "http://example.com/area2", "addressCountry": "CA", "postalCode": [ "1A1", "K1A" ] } }
Пример 4
eligibleRegion с объектом GeoShape , содержащим идентификатор DMA:
"actionAccessibilityRequirement": { "@type": "ActionAccessSpecification", "category": "subscription", "requiresSubscription": { "@type": "MediaSubscription", "@id": "http://www.example.com/abcd/subscription", "name": "Example Subscription", "commonTier": true }, "additionalProperty": { "@type": "PropertyValue", "name": "DisplaySubscriptionIdentifier", "value": "http://www.example.com/abcd/subscription" }, "eligibleRegion":{ "@type": "GeoShape", "@id": "http://example.com/area3", "addressCountry": "US", "identifier": [ { "@type": "PropertyValue", "propertyID": "DMA_ID", "value": "501" } ] } }
Пример 5
eligibleRegion содержит список объектов GeoShape . Каждый объект имеет идентификатор DMA:
"actionAccessibilityRequirement" : { "@type" : "ActionAccessSpecification", "eligibleRegion" : [ { "@id" : "http://example.com/dma/601", "@type" : "GeoShape", "addressCountry" : "US", "identifier" : { "@type" : "PropertyValue", "propertyID" : "DMA_ID", "value" : "601" } }, { "@id" : "http://example.com/dma/602", "@type" : "GeoShape", "addressCountry" : "US", "identifier" : { "@type" : "PropertyValue", "propertyID" : "DMA_ID", "value" : "602" } } ] }
Пример 6
ineligibleRegion с заблокированными почтовыми индексами:
"actionAccessibilityRequirement": { "@type": "ActionAccessSpecification", "category": "subscription", "requiresSubscription": { "@type": "MediaSubscription", "@id": "http://www.example.com/local_tv_network/subscription", "name": "Example Subscription", "commonTier": true }, "additionalProperty": { "@type": "PropertyValue", "name": "DisplaySubscriptionIdentifier", "value": "http://www.example.com/local_tv_network/subscription" }, "eligibleRegion": { "@type": "Country", "name": "US" }, "ineligibleRegion": { "@type": "GeoShape", "@id": "http://example.com/area1", "addressCountry": "US", "postalCode": [ "94118", "94119" ] } }
Идентификатор права доступа
Идентификатор права доступа, entitlementId , представляет собой строку, обозначающую доступ к группе контента в вашем медиакаталоге. Чтобы определить, имеет ли пользователь доступ к вашему контенту, Google выполняет следующие действия:
- Мы выполняем вызов API к вашей конечной точке Entitlements , чтобы получить идентификаторы прав пользователя.
- Мы получаем необходимые идентификаторы прав доступа к контенту из вашего фида Media Actions.
- Мы сопоставляем
entitlementIdпользователя со свойствомidentifierобъекта подписки на медиаконтент в вашем ленте. Если совпадает хотя бы одинentitlementId, мы определяем, что пользователь может получить доступ к контенту.

Google рекомендует использовать следующий синтаксис для entitlementId :
<domain name> + colon (:) + <access level to content>
Примеры синтаксиса:
-
example.com:basic -
example.com:premium -
example.com:sports
Пример идентификатора права доступа
В ленте MediaExampleCompany указано, что Movie XYZ требуется entitlementId example.com:basic , как показано ниже:
{ "@context": ["http://schema.org", {"@language": "en"}], "@type": "Movie", "@id": "www.example.com/movie_xyz", "url": "www.example.com/movie_xyz", "name": "Movie XYZ", "potentialAction": { "@type": "WatchAction", "target": [ … ], "actionAccessibilityRequirement": { "@type": "ActionAccessSpecification", "category": "subscription", "requiresSubscription": { "@type": "MediaSubscription", "@id": "http://www.example.com/basic_subscription", "name": "Basic subscription", "commonTier": true ... }, "additionalProperty": { "@type": "PropertyValue", "name": "DisplaySubscriptionIdentifier", "value": "http://www.example.com/basic_subscription" }, ... } }, ... }
Типичные сценарии использования доступа
Ниже приведены типичные сценарии использования доступа:
- Бесплатно (регистрация не требуется): контент доступен без регистрации, подписки или покупки.
- Бесплатно (требуется авторизация): Для доступа к контенту требуется авторизация, но подписка не требуется.
- Одноуровневая подписка: Для доступа к контенту требуется подписка. Все подписчики могут получить доступ к одному и тому же контенту, будь то фильмы или эпизоды, независимо от выбранного ими пакета подписки.
- Многоуровневая подписка: Для доступа к контенту требуется подписка. Подписчики могут получать доступ к различному контенту, будь то фильмы или эпизоды, в зависимости от выбранного уровня подписки. Например, Silver против Gold .
- Дополнительная подписка: Для доступа к контенту требуется подписка. Подписчики могут добавить премиум-контент к своей обычной подписке.
- Единовременная покупка: контент можно приобрести, после чего пользователь может получить к нему неограниченный доступ.
- Прямая трансляция: Подписка включает доступ к местным, национальным и премиум-каналам.
- Подписка от стороннего поставщика: для доступа к контенту пользователю необходимо войти в систему через своего кабельного провайдера.
Бесплатно (регистрация не требуется)
Вход в систему не требуется.
Контент доступен без регистрации и подписки.
{ "actionAccessibilityRequirement": { "@type": "ActionAccessSpecification", "category": "nologinrequired", "availabilityStarts": "2015-01-01T00:00Z", "availabilityEnds": "2015-12-31T00:00Z", "eligibleRegion": { "@type": "Country", "name": "US" } } }
- Установите
categorynologinrequired. - Не включайте
expectAcceptanceOf.
Бесплатно (требуется вход в систему)
Требуется вход в систему.
Для доступа к контенту требуется авторизация, но подписка не требуется.
{ "actionAccessibilityRequirement": { "@type": "ActionAccessSpecification", "category": "free", "availabilityStarts": "2015-01-01T00:00Z", "availabilityEnds": "2015-12-31T00:00Z", "eligibleRegion": { "@type": "Country", "name": "US" } } }
- Установите
category«free. - Не включайте
expectAcceptanceOf.
Одноуровневая подписка
В модели подписки с одним уровнем тарифа у поставщика услуг есть один уровень подписки. Все подписчики могут получить доступ к одному и тому же контенту, будь то фильмы или сериалы, независимо от выбранного ими пакета подписки.
{ "actionAccessibilityRequirement": { "@type": "ActionAccessSpecification", "category": "subscription", "availabilityStarts": "2015-01-01T00:00Z", "availabilityEnds": "2015-12-31T00:00Z", "requiresSubscription": { "@type": "MediaSubscription", "name": "Example Package", "commonTier": true, "@id": "http://www.example.com/example_package" }, "additionalProperty": { "@type": "PropertyValue", "name": "DisplaySubscriptionIdentifier", "value": "http://www.example.com/example_package" }, "eligibleRegion": { "@type": "Country", "name": "US" } } }
Многоуровневая подписка
В многоуровневой модели подписки у поставщика услуг есть несколько уровней подписки, таких как Gold , Silver и Bronze . Пользователи с подпиской более высокого уровня имеют доступ ко всему контенту более низкого уровня. Однако пользователи с подпиской более низкого уровня не имеют доступа к контенту более высокого уровня.

Рассмотрим следующий сценарий:
- Джейн подписана на тарифный план Gold . Ваша конечная точка для управления правами доступа возвращает следующие идентификаторы
entitlementId:-
example.com:bronze -
example.com:silver -
example.com:gold
-
- Джон подписан на тарифный план Bronze . Ваша конечная точка для управления правами доступа возвращает следующий
entitlementId:-
example.com:bronze
-
- В вашем ленте Media Actions должны быть соблюдены следующие требования:
- Для просмотра фильма A требуется
example.com:bronze. - Для просмотра фильма B требуется
example.com:silver.
- Для просмотра фильма A требуется
В этом сценарии Google определяет следующие уровни доступа для Джейн и Джона:
- И Джейн, и Джон имеют доступ к фильму А.
- У Джейн есть доступ к фильму B , а у Джона — нет.
{ "actionAccessibilityRequirement": { "@type": "ActionAccessSpecification", "category": "subscription", "requiresSubscription": { "@type": "MediaSubscription", "@id": "http://www.example.com/basic_subscription", "name": "Bronze", "commonTier": true ... }, "additionalProperty": { "@type": "PropertyValue", "name": "DisplaySubscriptionIdentifier", "value": "http://www.example.com/basic_subscription" }, ... } }
Дополнительная подписка
В модели подписки с дополнительными услугами поставщик услуг позволяет пользователям расширять свои права и добавлять каналы к базовой подписке. Пользователи могут добавить столько каналов, сколько захотят.

Рассмотрим следующий сценарий:
- Помимо базовой подписки, у Джейн есть PRO и Sportz . Ваша конечная точка для получения прав доступа возвращает следующие идентификаторы
entitlementId:-
example.com:basic -
example.com:pro -
example.com:sportz
-
- У Джона только базовая подписка. Ваша конечная точка для управления правами доступа возвращает следующий
entitlementId:-
example.com:basic
-
- В вашем ленте Media Actions должны быть соблюдены следующие требования:
- Для просмотра фильма A требуется
example.com:basic. - Для просмотра фильма B требуется
example.com:pro.
- Для просмотра фильма A требуется
В этом сценарии Google определяет следующие уровни доступа для Джейн и Джона:
- И Джейн, и Джон имеют доступ к фильму А.
- У Джейн есть доступ к фильму B , а у Джона — нет.
{ "actionAccessibilityRequirement": { "@type": "ActionAccessSpecification", "category": "subscription", "availabilityStarts": "2015-01-01T00:00Z", "availabilityEnds": "2015-12-31T00:00Z", "eligibleRegion": { "@type": "Country", "name": "US" } "requiresSubscription": [ { "@type": "MediaSubscription", "@id": "https://www.example.com/package/basic", "name": "Basic", "sameAs": "https://www.example.com/package/basic", "commonTier": true }, { "@type": "MediaSubscription", "@id": "https://www.example.com/packages/basic/pro", "name": "PRO", "sameAs": "https://www.example.com/package/pro", "identifier": "example.com:pro", "commonTier": false }, { "@type": "MediaSubscription", "@id": "https://www.example.com/package/sportz", "name": "Sportz", "sameAs": "https://www.example.com/package/sports", "identifier": "example.com:sportz", "commonTier": false } ], "additionalProperty": { "@type": "PropertyValue", "name": "DisplaySubscriptionIdentifier", "value": "http://www.example.com/package/basic" }, } } }
Единоразовая покупка
Покупка
Контент доступен неограниченное время после покупки.
{ "actionAccessibilityRequirement": { "@type": "ActionAccessSpecification", "category": "purchase", "availabilityStarts": "2015-01-01T00:00Z", "availabilityEnds": "2015-12-31T00:00Z", "eligibleRegion": { "@type": "Country", "name": "US" }, "expectsAcceptanceOf": { "@type": "Offer", "price": 7.99, "priceCurrency": "USD", "seller": { "@type": "Organization", "name": "Example", "sameAs": "http://www.example.com/" } } } }
- Выберите
categoryдляpurchase. - Включите
expectAcceptanceOfвactionAccessibilityRequirement, чтобы указать цену покупки.
Аренда
Контент доступен в течение ограниченного времени после покупки.
{ "actionAccessibilityRequirement": { "@type": "ActionAccessSpecification", "category": "rental", "availabilityStarts": "2015-01-01T00:00Z", "availabilityEnds": "2015-12-31T00:00Z", "eligibleRegion": { "@type": "Country", "name": "US" }, "expectsAcceptanceOf": { "@type": "Offer", "price": 7.99, "priceCurrency": "USD", "seller": { "@type": "Organization", "name": "Example", "sameAs": "http://www.example.com/" } } } }
- Установите
category«rental. - Включите
expectAcceptanceOfвactionAccessibilityRequirement, чтобы указать цену аренды.
Прямая трансляция ТВ
В ленте «Действия с медиаконтентом» можно ограничить доступ к телеканалу или событию в прямом эфире на основе следующих двух условий пользователя:
- Местоположение устройства пользователя
Чтобы ограничить доступ к телеканалу, укажите регион, где пользователи имеют к нему доступ. Это условие обычно применяется к местным телеканалам.
- Статус учетной записи пользователя
Если доступ к телеканалу зависит от настроек учетной записи пользователя, используйте идентификаторы прав доступа для обозначения ограничения.
Это условие обычно применяется в следующих случаях:
- Пакетные предложения: Национальные каналы часто входят в пакеты, и пользователи сами выбирают, на какой пакет они хотят подписаться.
- Дополнительно: Для некоторых платных каналов пользователям необходимо выборочно добавлять дополнительные каналы к своей подписке.
- Региональные спортивные сети (РСН): РСН обычно связаны с местоположением «дома» пользователя. Пользователи могут смотреть контент РСН, даже находясь за пределами своего «дома».
Подписка от стороннего поставщика
Подписка от стороннего поставщика
Подписчикам этот контент доступен через другой сервис.
{ "actionAccessibilityRequirement": { "@type": "ActionAccessSpecification", "category": "externalsubscription" "availabilityStarts": "2015-01-01T00:00Z", "availabilityEnds": "2015-12-31T00:00Z", "requiresSubscription":{ "@type": "MediaSubscription", "@id": "https://www.example.com/faq", "name": "Example", "sameAs": "https://www.example.com/faq", "authenticator": { "@type": "Organization", "name": "TVE" } }, "additionalProperty": { "@type": "PropertyValue", "name": "DisplaySubscriptionIdentifier", "value": "http://www.example.com/faq" }, "eligibleRegion": { "@type": "Country", "name": "US" } } }
- Добавьте
authenticator, чтобы указать, что аутентификацию подписчиков выполняет другой сервис. Например, для HBO GO требуется подписка от кабельного провайдера.
Пакеты стандартного уровня
Контент общего уровня доступен всем подписчикам независимо от выбранного ими тарифного плана. Общий уровень применяется ко всему контенту, относящемуся к category subscription . Для получения дополнительной информации о category см. раздел «Тип платного доступа» .
Почему требуется пакет услуг стандартного уровня?
На нескольких платформах Google пользователям предлагаются рекомендации по телепередачам и фильмам. Чтобы сформировать у пользователей представление о стоимости, Google должен понимать, какой контент доступен всем подписчикам, использующим общий тарифный план. Google также должен понимать, какой контент доступен подписчикам с определенными пакетами подписки.
Google рекомендует контент, доступный на общем уровне подписки, если вы не поддерживаете API управления правами доступа . Этот API позволяет Google понять, к каким контентам, не входящим в общий уровень подписки, может получить доступ каждый конкретный пользователь.
Когда следует создавать пакет общего уровня?
Единый тарифный план необходим, если ваш сервис предлагает контент, доступный всем подписчикам. Это включает в себя как сервисы, предлагающие только один пакет, так и сервисы, предлагающие несколько пакетов или дополнительных услуг.
Провайдерам, у которых контент недоступен всем абонентам, не нужно создавать единый тарифный план. Примером могут служить провайдеры, предоставляющие взаимоисключающий контент во всех своих пакетах.
Примеры общего уровня
Ниже приведены примеры распространенного уровня.
Многоуровневая подписка
В многоуровневой модели подписки поставщик услуг предлагает несколько уровней подписки, таких как Gold , Silver и Bronze . Пользователи с подпиской более высокого уровня имеют доступ ко всему контенту более низких уровней. Пользователи с подпиской более низкого уровня не имеют доступа к контенту более высокого уровня. На следующем изображении представлен пример структуры пакета.

В приведенном ниже примере кода пакет «бронза» является общим уровнем, поскольку все пользователи имеют доступ ко всему контенту этого уровня.
"requiresSubscription": [ { "@type": "MediaSubscription", "@id": "https://www.example.com/package/bronze", "name": "Bronze", "sameAs": "https://www.example.com/package/bronze", "commonTier": true }, { "@type": "MediaSubscription", "@id": "https://www.example.com/package/silver", "name": "Silver", "sameAs": "https://www.example.com/package/silver", "identifier": "example.com:silver", "commonTier": false }, { "@type": "MediaSubscription", "@id": "https://www.example.com/package/gold", "name": "Gold", "sameAs": "https://www.example.com/package/gold", "identifier": "example.com:gold", "commonTier": false } ],
Дополнительные опции
В модели подписки с дополнительными услугами поставщик услуг позволяет пользователям расширять свои права и добавлять каналы к базовой подписке. Пользователи могут добавить столько каналов, сколько захотят. На следующем изображении представлен пример структуры пакета.

Если у вас есть канал, доступный всем пользователям, и его использование бесплатно, вы можете объединить этот пакет с обычным пакетом услуг.
В приведенном ниже примере кода базовый пакет является общим уровнем, поскольку все пользователи имеют доступ ко всему содержимому этого пакета.
"requiresSubscription": [ { "@type": "MediaSubscription", "@id": "https://www.example.com/package/basic", "name": "Basic", "sameAs": "https://www.example.com/package/basic", "commonTier": true }, { "@type": "MediaSubscription", "@id": "https://www.example.com/packages/basic/pro", "name": "PRO", "sameAs": "https://www.example.com/package/pro", "identifier": "example.com:pro", "commonTier": false }, { "@type": "MediaSubscription", "@id": "https://www.example.com/package/sportz", "name": "Sportz", "sameAs": "https://www.example.com/package/sports", "identifier": "example.com:sportz", "commonTier": false }, { "@type": "MediaSubscription", "@id": "https://www.example.com/package/moviemax", "name": "Moviemax", "sameAs": "https://www.example.com/package/moviemax", "identifier": "example.com:moviemax", "commonTier": false } ],
Пакеты с содержимым, которое пересекается
В контентной модели, где содержимое пакетов пересекается, поставщик услуг продает пакеты, которые включают в себя часть содержимого других пакетов. На следующем изображении представлен пример структуры пакета.

В приведенном ниже примере кода провайдер предлагает три пакета, контент которых пересекается во всех трех пакетах. В этом случае требуется четвертый пакет, представляющий собой общий уровень. Он должен включать весь контент, доступный во всех трех пакетах.
"requiresSubscription": [ { "@type": "MediaSubscription", "@id": "https://www.example.com/package/1", "name": "Package 1", "sameAs": "https://www.example.com/package/1", "identifier": "example.com:package1", "commonTier": false }, { "@type": "MediaSubscription", "@id": "https://www.example.com/package/2", "name": "Package 2", "sameAs": "https://www.example.com/package/2", "identifier": "example.com:package2", "commonTier": false }, { "@type": "MediaSubscription", "@id": "https://www.example.com/package/3", "name": "Package 3", "sameAs": "https://www.example.com/package/3", "identifier": "example.com:package3", "commonTier": false }, { "@type": "MediaSubscription", "@id": "https://www.example.com/package/common", "name": "Common Tier Package", "sameAs": "https://www.example.com/package/common", "commonTier": true } ],
Пакеты, содержимое которых не пересекается
В контентной модели, где все контентные пакеты не пересекаются, поставщик услуг продает пакеты, которые не содержат контента из других пакетов. На следующем изображении показан пример структуры пакета.

В следующем примере провайдер предлагает три пакета услуг, контент которых не пересекается ни в одном из них. Общий тарифный план не требуется.
"requiresSubscription": [ { "@type": "MediaSubscription", "@id": "https://www.example.com/package/1", "name": "Package 1", "sameAs": "https://www.example.com/package/1", "identifier": "example.com:package1", "commonTier": false }, { "@type": "MediaSubscription", "@id": "https://www.example.com/package/2", "name": "Package 2", "sameAs": "https://www.example.com/package/2", "identifier": "example.com:package2", "commonTier": false }, { "@type": "MediaSubscription", "@id": "https://www.example.com/package/3", "name": "Package 3", "sameAs": "https://www.example.com/package/3", "identifier": "example.com:package3", "commonTier": false } ],
Конечная точка прав доступа
Используйте информацию из этого раздела для размещения HTTPS-конечной точки, которая возвращает права доступа, связанные с пользователем.
Предварительное условие
Прежде чем начать, убедитесь, что ваш сервис поддерживает протокол OAuth 2.0 от Google.
Запрос
Для получения прав пользователя Google отправляет запрос, содержащий токен OAuth пользователя. Ваша конечная точка должна идентифицировать пользователя на основе этого токена OAuth. См. следующий пример:
GET /resource HTTP/1.1
Host: server.example.com
Authorization: Bearer <OAuthToken>
Ответ
Ваш конечный пункт должен возвращать ответ со следующими свойствами:
| Свойство | |
|---|---|
subscription | Необходимый Это поле находится внутри корневого ответа. |
subscription.type | Необходимый Это свойство может принимать следующие значения:
|
subscription.expiration_date | Необязательный Срок действия данного права, указанный в формате ISO 8601 , включая часовой пояс. Для получения более подробной информации см. раздел «Сроки действия» . |
entitlements | Необязательный Это корневое свойство содержит значения |
entitlements.entitlement | Требуется , если доступ к вашему каталогу потокового контента зависит от типа подписки. Это свойство содержит идентификатор |
entitlements.expiration_date | Необязательный Дата истечения срока действия данной подписки в формате ISO 8601 , включая часовой пояс. Для получения более подробной информации см. раздел «Даты истечения срока действия» . |
Сроки годности
В ответе конечной точки есть два свойства, отвечающие за даты истечения срока действия: subscription.expiration_date и entitlements.expiration_date . Вы можете указать одно из них или ни одно, но не оба. Какой из них использовать, зависит от вашей модели подписки.
| Модель подписки | |
|---|---|
| Доступ к вашему каталогу потокового контента одинаков для всех подписчиков. | Поскольку указывать свойство entitlements не требуется, укажите subscription.expiration_date . |
Доступ к вашему каталогу потокового контента зависит от условий подписки пользователя. | Если ваша модель подписки включает несколько уровней или дополнительных услуг, срок действия которых истекает через некоторое время, выполните одно из следующих действий:
|
Примеры ответов
Ниже приведены примеры ответов в зависимости от состояния подписки:
- Активная подписка
- Активная подписка со сроком действия.
- Без подписки
- Активные подписки на несколько уровней или дополнительных пакетов.
Активная подписка
Активная подписка
У пользователя есть активная подписка на example.com . В этом случае все подписчики имеют доступ ко всему вашему каталогу потокового контента независимо от типа их подписки.
{ "subscription" : { "type": "ActiveSubscription", } }
Активная подписка со сроком действия.
Активная подписка со сроком действия.
У пользователя есть активная подписка на example.com , и у этой подписки есть срок действия. В этом случае все подписчики имеют доступ ко всему вашему каталогу потокового контента независимо от типа их подписки.
{ "subscription" : { "type": "ActiveSubscription", "expiration_date": "2019-11-10T10:00:00Z" } }
Без подписки
Без подписки
У пользователя нет подписки на example.com .
{ "subscription" : { "type": "InactiveSubscription" } }
Активные подписки на несколько уровней или дополнительных пакетов.
Активные подписки на несколько уровней или дополнительных пакетов.
У пользователя есть подписка на example.com:premium до определенной даты.
{ "subscription" : { "type": "ActiveSubscription", } "entitlements": [ { "entitlement": "example.com:premium", "expiration": "2019-11-10T10:00:00Z" } ] }
Лимит скорости
Google обновляет информацию о правах пользователя каждые шесть часов. Для сглаживания максимального количества запросов в секунду (QPS) Google равномерно распределяет запросы к вашей конечной точке во времени. Таким образом, вы можете оценить ожидаемое среднее количество запросов в секунду для вашей конечной точки по следующей формуле:
Ожидаемое среднее время отклика в секунду (QPS) = <общее количество пользователей> / 21 600 секунд (6 часов x 60 минут x 60 секунд)
Если вы обслуживаете большое количество пользователей, Google может скорректировать 6-часовой интервал. При необходимости свяжитесь с Google для обсуждения настроек.
Связаться с Google
Когда ваша конечная точка будет готова, свяжитесь с Google, чтобы сообщить URL-адрес конечной точки.
Свойства спецификации доступа к действию
Для получения справочной информации см. раздел « Свойства спецификации доступа к действию» .
,Пользователи предпочитают смотреть или слушать контент, к которому у них уже есть доступ, например, контент по существующей подписке. Если Google знает, к какому контенту пользователь может получить доступ в вашем приложении или на вашей платформе, то Google может обеспечить более релевантный опыт на всех платформах Google и направить пользователя именно к этому контенту.

Определите требования к доступу к контенту.
Необходимо определить требования к доступу для каждого пакета контента в вашем каталоге. При этом следует рассмотреть следующие вопросы:
- Нужно ли пользователям входить в ваше приложение или на вашу платформу, чтобы получить доступ к контенту?
Нужна ли пользователям подписка?
Смотрите только действия:
- Нужна ли пользователям подписка от стороннего поставщика услуг?
- Предлагаете ли вы многоуровневые, пакетные или дополнительные подписки?
Только для просмотра действий: Нужно ли пользователям арендовать или покупать контент?
Меняются ли требования к доступу со временем?
Зависят ли требования к доступу от местоположения устройства?
типы ограничений доступа
Существует два вида ограничений доступа:
тип платного доступа
Вы можете ограничить доступ к контенту, указав тип платного доступа. В таблице ниже подробно описаны различные типы платного доступа:
| тип платного доступа | Пример | Категория |
|---|---|---|
| Покупка или регистрация не требуются. | Треск | nologinrequired |
| Пользователь должен быть авторизован, но платная подписка не требуется. | Vudu (AVOD) | free |
| У пользователя должна быть активная подписка. Доступ не зависит от уровня подписки. | Netflix | |
| У пользователя должна быть активная подписка. Доступ зависит от выбранного уровня подписки. | Hulu (дополнения) | |
| Контент доступен в течение ограниченного времени после покупки. | Вуду | rental |
| Контент доступен неограниченное время после покупки. | Вуду | purchase |
| Данный контент доступен по кабельной подписке. | HBO Go | externalSubscription |
Тип платного доступа для действий просмотра
Чтобы указать тип платного доступа к контенту для действий просмотра, используйте свойство category в спецификации доступа к действию :
"potentialAction": {
"@type":"WatchAction",
"target": { … },
"actionAccessibilityRequirement": {
"@type": "ActionAccessSpecification",
"category": "subscription",
"availabilityStarts": "2018-06-01T10:35:29Z",
"availabilityEnds": "2019-05-31T10:35:29Z",
"eligibleRegion": {
"@type": "Country",
"name": "US"
}
},
...
}
Тип платного доступа для действий прослушивания
Чтобы указать тип платного доступа к контенту для действий прослушивания, используйте свойство category в объекте предложения :
"potentialAction": {
"@type":"ListenAction",
"target": { … },
"expectsAcceptanceOf":{
"@type":"Offer",
"category":"subscription",
"availabilityStarts": "2018-06-01T10:35:29Z",
"availabilityEnds": "2019-05-31T10:35:29Z",
"eligibleRegion": {
"@type":"Country",
"name":"US"
}
},
...
}
Географическая область
Необходимо указать географические регионы, где доступен контент. Используйте одно или оба из следующих свойств:
- Свойство
eligibleRegionобъекта спецификации доступа к действию . Это свойство обязательно для использования. - Свойство
ineligibleRegionобъекта спецификации доступа к действию .
Пользователь может получить доступ к контенту, если местоположение устройства находится в пределах любого региона, указанного в eligibleRegion , и не находится в пределах любого региона, указанного в ineligibleRegion .
Свойства eligibleRegion и ineligibleRegion допускают следующие значения:
- Список
Country,CityиState. - Объект
GeoShape. Подробные требования см. в разделе « СвойстваGeoShape. - Список объектов
GeoShape.
Если контент доступен во всем мире, используйте следующее специальное значение для eligibleRegion :
"eligibleRegion": "EARTH",
Варианты использования подходящего региона
Ниже приведены примеры использования свойства eligibleRegion :
- Пример 1:
eligibleRegionсо списком стран. - Пример 2:
eligibleRegionс объектомGeoShape, содержащим список почтовых индексов. - Пример 3:
eligibleRegionс объектомGeoShape, содержащим список кодов зон сортировки (FSA). - Пример 4:
eligibleRegionс объектомGeoShape, содержащим идентификатор DMA. - Пример 5:
eligibleRegionсо списком объектовGeoShape. Каждый объект содержит идентификатор DMA. - Пример 6:
ineligibleRegionс заблокированными почтовыми индексами.
Пример 1
eligibleRegion со списком стран:
"actionAccessibilityRequirement": { "@type": "ActionAccessSpecification", "category": "subscription", "requiresSubscription": { "@type": "MediaSubscription", "@id": "http://www.example.com/north_america_network/subscription", "name": "Example Subscription", "commonTier": true }, "eligibleRegion": [ { "@type": "Country", "name": "US" }, { "@type": "Country", "name": "CA" } ] }
Пример 2
eligibleRegion с объектом GeoShape , содержащим список почтовых индексов:
"actionAccessibilityRequirement": { "@type": "ActionAccessSpecification", "category": "subscription", "requiresSubscription": { "@type": "MediaSubscription", "@id": "http://www.example.com/local_tv_network/subscription", "name": "Example Subscription", "commonTier": true }, "eligibleRegion": { "@type": "GeoShape", "@id": "http://example.com/area1", "addressCountry": "US", "postalCode": [ "94118", "94119" ] } }
Пример 3
eligibleRegion с объектом GeoShape , содержащим список кодов зон сортировки (FSA):
"actionAccessibilityRequirement": { "@type": "ActionAccessSpecification", "category": "subscription", "requiresSubscription": { "@type": "MediaSubscription", "@id": "http://www.example.com/local_tv_network/subscription", "name": "Example Subscription", "commonTier": true }, "additionalProperty": { "@type": "PropertyValue", "name": "DisplaySubscriptionIdentifier", "value": "http://www.example.com/local_tv_network/subscription" }, "eligibleRegion":{ "@type": "GeoShape", "@id": "http://example.com/area2", "addressCountry": "CA", "postalCode": [ "1A1", "K1A" ] } }
Пример 4
eligibleRegion с объектом GeoShape , содержащим идентификатор DMA:
"actionAccessibilityRequirement": { "@type": "ActionAccessSpecification", "category": "subscription", "requiresSubscription": { "@type": "MediaSubscription", "@id": "http://www.example.com/abcd/subscription", "name": "Example Subscription", "commonTier": true }, "additionalProperty": { "@type": "PropertyValue", "name": "DisplaySubscriptionIdentifier", "value": "http://www.example.com/abcd/subscription" }, "eligibleRegion":{ "@type": "GeoShape", "@id": "http://example.com/area3", "addressCountry": "US", "identifier": [ { "@type": "PropertyValue", "propertyID": "DMA_ID", "value": "501" } ] } }
Пример 5
eligibleRegion содержит список объектов GeoShape . Каждый объект имеет идентификатор DMA:
"actionAccessibilityRequirement" : { "@type" : "ActionAccessSpecification", "eligibleRegion" : [ { "@id" : "http://example.com/dma/601", "@type" : "GeoShape", "addressCountry" : "US", "identifier" : { "@type" : "PropertyValue", "propertyID" : "DMA_ID", "value" : "601" } }, { "@id" : "http://example.com/dma/602", "@type" : "GeoShape", "addressCountry" : "US", "identifier" : { "@type" : "PropertyValue", "propertyID" : "DMA_ID", "value" : "602" } } ] }
Пример 6
ineligibleRegion с заблокированными почтовыми индексами:
"actionAccessibilityRequirement": { "@type": "ActionAccessSpecification", "category": "subscription", "requiresSubscription": { "@type": "MediaSubscription", "@id": "http://www.example.com/local_tv_network/subscription", "name": "Example Subscription", "commonTier": true }, "additionalProperty": { "@type": "PropertyValue", "name": "DisplaySubscriptionIdentifier", "value": "http://www.example.com/local_tv_network/subscription" }, "eligibleRegion": { "@type": "Country", "name": "US" }, "ineligibleRegion": { "@type": "GeoShape", "@id": "http://example.com/area1", "addressCountry": "US", "postalCode": [ "94118", "94119" ] } }
Идентификатор права доступа
Идентификатор права доступа, entitlementId , представляет собой строку, обозначающую доступ к группе контента в вашем медиакаталоге. Чтобы определить, имеет ли пользователь доступ к вашему контенту, Google выполняет следующие действия:
- Мы выполняем вызов API к вашей конечной точке Entitlements , чтобы получить идентификаторы прав пользователя.
- Мы получаем необходимые идентификаторы прав доступа к контенту из вашего фида Media Actions.
- Мы сопоставляем
entitlementIdпользователя со свойствомidentifierобъекта подписки на медиаконтент в вашем ленте. Если совпадает хотя бы одинentitlementId, мы определяем, что пользователь может получить доступ к контенту.

Google рекомендует использовать следующий синтаксис для entitlementId :
<domain name> + colon (:) + <access level to content>
Примеры синтаксиса:
-
example.com:basic -
example.com:premium -
example.com:sports
Пример идентификатора права доступа
В ленте MediaExampleCompany указано, что Movie XYZ требуется entitlementId example.com:basic , как показано ниже:
{ "@context": ["http://schema.org", {"@language": "en"}], "@type": "Movie", "@id": "www.example.com/movie_xyz", "url": "www.example.com/movie_xyz", "name": "Movie XYZ", "potentialAction": { "@type": "WatchAction", "target": [ … ], "actionAccessibilityRequirement": { "@type": "ActionAccessSpecification", "category": "subscription", "requiresSubscription": { "@type": "MediaSubscription", "@id": "http://www.example.com/basic_subscription", "name": "Basic subscription", "commonTier": true ... }, "additionalProperty": { "@type": "PropertyValue", "name": "DisplaySubscriptionIdentifier", "value": "http://www.example.com/basic_subscription" }, ... } }, ... }
Типичные сценарии использования доступа
Ниже приведены типичные сценарии использования доступа:
- Бесплатно (регистрация не требуется): контент доступен без регистрации, подписки или покупки.
- Бесплатно (требуется авторизация): Для доступа к контенту требуется авторизация, но подписка не требуется.
- Одноуровневая подписка: Для доступа к контенту требуется подписка. Все подписчики могут получить доступ к одному и тому же контенту, будь то фильмы или эпизоды, независимо от выбранного ими пакета подписки.
- Многоуровневая подписка: Для доступа к контенту требуется подписка. Подписчики могут получать доступ к различному контенту, будь то фильмы или эпизоды, в зависимости от выбранного уровня подписки. Например, Silver против Gold .
- Дополнительная подписка: Для доступа к контенту требуется подписка. Подписчики могут добавить премиум-контент к своей обычной подписке.
- Единовременная покупка: контент можно приобрести, после чего пользователь может получить к нему неограниченный доступ.
- Прямая трансляция: Подписка включает доступ к местным, национальным и премиум-каналам.
- Подписка от стороннего поставщика: для доступа к контенту пользователю необходимо войти в систему через своего кабельного провайдера.
Бесплатно (регистрация не требуется)
Вход в систему не требуется.
Контент доступен без регистрации и подписки.
{ "actionAccessibilityRequirement": { "@type": "ActionAccessSpecification", "category": "nologinrequired", "availabilityStarts": "2015-01-01T00:00Z", "availabilityEnds": "2015-12-31T00:00Z", "eligibleRegion": { "@type": "Country", "name": "US" } } }
- Установите
categorynologinrequired. - Не включайте
expectAcceptanceOf.
Бесплатно (требуется вход в систему)
Требуется вход в систему.
Для доступа к контенту требуется авторизация, но подписка не требуется.
{ "actionAccessibilityRequirement": { "@type": "ActionAccessSpecification", "category": "free", "availabilityStarts": "2015-01-01T00:00Z", "availabilityEnds": "2015-12-31T00:00Z", "eligibleRegion": { "@type": "Country", "name": "US" } } }
- Установите
category«free. - Не включайте
expectAcceptanceOf.
Одноуровневая подписка
В модели подписки с одним уровнем тарифа у поставщика услуг есть один уровень подписки. Все подписчики могут получить доступ к одному и тому же контенту, будь то фильмы или сериалы, независимо от выбранного ими пакета подписки.
{ "actionAccessibilityRequirement": { "@type": "ActionAccessSpecification", "category": "subscription", "availabilityStarts": "2015-01-01T00:00Z", "availabilityEnds": "2015-12-31T00:00Z", "requiresSubscription": { "@type": "MediaSubscription", "name": "Example Package", "commonTier": true, "@id": "http://www.example.com/example_package" }, "additionalProperty": { "@type": "PropertyValue", "name": "DisplaySubscriptionIdentifier", "value": "http://www.example.com/example_package" }, "eligibleRegion": { "@type": "Country", "name": "US" } } }
Многоуровневая подписка
В многоуровневой модели подписки у поставщика услуг есть несколько уровней подписки, таких как Gold , Silver и Bronze . Пользователи с подпиской более высокого уровня имеют доступ ко всему контенту более низкого уровня. Однако пользователи с подпиской более низкого уровня не имеют доступа к контенту более высокого уровня.

Рассмотрим следующий сценарий:
- Джейн подписана на тарифный план Gold . Ваша конечная точка для управления правами доступа возвращает следующие идентификаторы
entitlementId:-
example.com:bronze -
example.com:silver -
example.com:gold
-
- Джон подписан на тарифный план Bronze . Ваша конечная точка для управления правами доступа возвращает следующий
entitlementId:-
example.com:bronze
-
- В вашем ленте Media Actions должны быть соблюдены следующие требования:
- Для просмотра фильма A требуется
example.com:bronze. - Для просмотра фильма B требуется
example.com:silver.
- Для просмотра фильма A требуется
В этом сценарии Google определяет следующие уровни доступа для Джейн и Джона:
- И Джейн, и Джон имеют доступ к фильму А.
- У Джейн есть доступ к фильму B , а у Джона — нет.
{ "actionAccessibilityRequirement": { "@type": "ActionAccessSpecification", "category": "subscription", "requiresSubscription": { "@type": "MediaSubscription", "@id": "http://www.example.com/basic_subscription", "name": "Bronze", "commonTier": true ... }, "additionalProperty": { "@type": "PropertyValue", "name": "DisplaySubscriptionIdentifier", "value": "http://www.example.com/basic_subscription" }, ... } }
Дополнительная подписка
В модели подписки с дополнительными услугами поставщик услуг позволяет пользователям расширять свои права и добавлять каналы к базовой подписке. Пользователи могут добавить столько каналов, сколько захотят.

Рассмотрим следующий сценарий:
- Помимо базовой подписки, у Джейн есть PRO и Sportz . Ваша конечная точка для получения прав доступа возвращает следующие идентификаторы
entitlementId:-
example.com:basic -
example.com:pro -
example.com:sportz
-
- У Джона только базовая подписка. Ваша конечная точка для управления правами доступа возвращает следующий
entitlementId:-
example.com:basic
-
- В вашем ленте Media Actions должны быть соблюдены следующие требования:
- Для просмотра фильма A требуется
example.com:basic. - Для просмотра фильма B требуется
example.com:pro.
- Для просмотра фильма A требуется
В этом сценарии Google определяет следующие уровни доступа для Джейн и Джона:
- И Джейн, и Джон имеют доступ к фильму А.
- У Джейн есть доступ к фильму B , а у Джона — нет.
{ "actionAccessibilityRequirement": { "@type": "ActionAccessSpecification", "category": "subscription", "availabilityStarts": "2015-01-01T00:00Z", "availabilityEnds": "2015-12-31T00:00Z", "eligibleRegion": { "@type": "Country", "name": "US" } "requiresSubscription": [ { "@type": "MediaSubscription", "@id": "https://www.example.com/package/basic", "name": "Basic", "sameAs": "https://www.example.com/package/basic", "commonTier": true }, { "@type": "MediaSubscription", "@id": "https://www.example.com/packages/basic/pro", "name": "PRO", "sameAs": "https://www.example.com/package/pro", "identifier": "example.com:pro", "commonTier": false }, { "@type": "MediaSubscription", "@id": "https://www.example.com/package/sportz", "name": "Sportz", "sameAs": "https://www.example.com/package/sports", "identifier": "example.com:sportz", "commonTier": false } ], "additionalProperty": { "@type": "PropertyValue", "name": "DisplaySubscriptionIdentifier", "value": "http://www.example.com/package/basic" }, } } }
Единоразовая покупка
Покупка
Контент доступен неограниченное время после покупки.
{ "actionAccessibilityRequirement": { "@type": "ActionAccessSpecification", "category": "purchase", "availabilityStarts": "2015-01-01T00:00Z", "availabilityEnds": "2015-12-31T00:00Z", "eligibleRegion": { "@type": "Country", "name": "US" }, "expectsAcceptanceOf": { "@type": "Offer", "price": 7.99, "priceCurrency": "USD", "seller": { "@type": "Organization", "name": "Example", "sameAs": "http://www.example.com/" } } } }
- Выберите
categoryдляpurchase. - Включите
expectAcceptanceOfвactionAccessibilityRequirement, чтобы указать цену покупки.
Аренда
Контент доступен в течение ограниченного времени после покупки.
{ "actionAccessibilityRequirement": { "@type": "ActionAccessSpecification", "category": "rental", "availabilityStarts": "2015-01-01T00:00Z", "availabilityEnds": "2015-12-31T00:00Z", "eligibleRegion": { "@type": "Country", "name": "US" }, "expectsAcceptanceOf": { "@type": "Offer", "price": 7.99, "priceCurrency": "USD", "seller": { "@type": "Organization", "name": "Example", "sameAs": "http://www.example.com/" } } } }
- Установите
category«rental. - Включите
expectAcceptanceOfвactionAccessibilityRequirement, чтобы указать цену аренды.
Прямая трансляция ТВ
В ленте «Действия с медиаконтентом» можно ограничить доступ к телеканалу или событию в прямом эфире на основе следующих двух условий пользователя:
- Местоположение устройства пользователя
Чтобы ограничить доступ к телеканалу, укажите регион, где пользователи имеют к нему доступ. Это условие обычно применяется к местным телеканалам.
- Статус учетной записи пользователя
Если доступ к телеканалу зависит от настроек учетной записи пользователя, используйте идентификаторы прав доступа для обозначения ограничения.
Это условие обычно применяется в следующих случаях:
- Пакетные предложения: Национальные каналы часто входят в пакеты, и пользователи сами выбирают, на какой пакет они хотят подписаться.
- Дополнительно: Для некоторых платных каналов пользователям необходимо выборочно добавлять дополнительные каналы к своей подписке.
- Региональные спортивные сети (РСН): РСН обычно связаны с местоположением «дома» пользователя. Пользователи могут смотреть контент РСН, даже находясь за пределами своего «дома».
Подписка от стороннего поставщика
Подписка от стороннего поставщика
Подписчикам этот контент доступен через другой сервис.
{ "actionAccessibilityRequirement": { "@type": "ActionAccessSpecification", "category": "externalsubscription" "availabilityStarts": "2015-01-01T00:00Z", "availabilityEnds": "2015-12-31T00:00Z", "requiresSubscription":{ "@type": "MediaSubscription", "@id": "https://www.example.com/faq", "name": "Example", "sameAs": "https://www.example.com/faq", "authenticator": { "@type": "Organization", "name": "TVE" } }, "additionalProperty": { "@type": "PropertyValue", "name": "DisplaySubscriptionIdentifier", "value": "http://www.example.com/faq" }, "eligibleRegion": { "@type": "Country", "name": "US" } } }
- Добавьте
authenticator, чтобы указать, что аутентификацию подписчиков выполняет другой сервис. Например, для HBO GO требуется подписка от кабельного провайдера.
Пакеты стандартного уровня
Контент общего уровня доступен всем подписчикам независимо от выбранного ими тарифного плана. Общий уровень применяется ко всему контенту, относящемуся к category subscription . Для получения дополнительной информации о category см. раздел «Тип платного доступа» .
Почему требуется пакет услуг стандартного уровня?
На нескольких платформах Google пользователям предлагаются рекомендации по телепередачам и фильмам. Чтобы сформировать у пользователей представление о стоимости, Google должен понимать, какой контент доступен всем подписчикам, использующим общий тарифный план. Google также должен понимать, какой контент доступен подписчикам с определенными пакетами подписки.
Google рекомендует контент, доступный на общем уровне подписки, если вы не поддерживаете API управления правами доступа . Этот API позволяет Google понять, к каким контентам, не входящим в общий уровень подписки, может получить доступ каждый конкретный пользователь.
Когда следует создавать пакет общего уровня?
Единый тарифный план необходим, если ваш сервис предлагает контент, доступный всем подписчикам. Это включает в себя как сервисы, предлагающие только один пакет, так и сервисы, предлагающие несколько пакетов или дополнительных услуг.
Провайдерам, у которых контент недоступен всем абонентам, не нужно создавать единый тарифный план. Примером могут служить провайдеры, предоставляющие взаимоисключающий контент во всех своих пакетах.
Примеры общего уровня
Ниже приведены примеры распространенного уровня.
Многоуровневая подписка
В многоуровневой модели подписки поставщик услуг предлагает несколько уровней подписки, таких как Gold , Silver и Bronze . Пользователи с подпиской более высокого уровня имеют доступ ко всему контенту более низких уровней. Пользователи с подпиской более низкого уровня не имеют доступа к контенту более высокого уровня. На следующем изображении представлен пример структуры пакета.

В приведенном ниже примере кода пакет «бронза» является общим уровнем, поскольку все пользователи имеют доступ ко всему контенту этого уровня.
"requiresSubscription": [ { "@type": "MediaSubscription", "@id": "https://www.example.com/package/bronze", "name": "Bronze", "sameAs": "https://www.example.com/package/bronze", "commonTier": true }, { "@type": "MediaSubscription", "@id": "https://www.example.com/package/silver", "name": "Silver", "sameAs": "https://www.example.com/package/silver", "identifier": "example.com:silver", "commonTier": false }, { "@type": "MediaSubscription", "@id": "https://www.example.com/package/gold", "name": "Gold", "sameAs": "https://www.example.com/package/gold", "identifier": "example.com:gold", "commonTier": false } ],
Дополнительные опции
В модели подписки с дополнительными услугами поставщик услуг позволяет пользователям расширять свои права и добавлять каналы к базовой подписке. Пользователи могут добавить столько каналов, сколько захотят. На следующем изображении представлен пример структуры пакета.

Если у вас есть канал, доступный всем пользователям, и его использование бесплатно, вы можете объединить этот пакет с обычным пакетом услуг.
В приведенном ниже примере кода базовый пакет является общим уровнем, поскольку все пользователи имеют доступ ко всему содержимому этого пакета.
"requiresSubscription": [ { "@type": "MediaSubscription", "@id": "https://www.example.com/package/basic", "name": "Basic", "sameAs": "https://www.example.com/package/basic", "commonTier": true }, { "@type": "MediaSubscription", "@id": "https://www.example.com/packages/basic/pro", "name": "PRO", "sameAs": "https://www.example.com/package/pro", "identifier": "example.com:pro", "commonTier": false }, { "@type": "MediaSubscription", "@id": "https://www.example.com/package/sportz", "name": "Sportz", "sameAs": "https://www.example.com/package/sports", "identifier": "example.com:sportz", "commonTier": false }, { "@type": "MediaSubscription", "@id": "https://www.example.com/package/moviemax", "name": "Moviemax", "sameAs": "https://www.example.com/package/moviemax", "identifier": "example.com:moviemax", "commonTier": false } ],
Пакеты с содержимым, которое пересекается
В контентной модели, где содержимое пакетов пересекается, поставщик услуг продает пакеты, которые включают в себя часть содержимого других пакетов. На следующем изображении представлен пример структуры пакета.

In the following code example, the provider offers three packages where some content intersects across all of the packages. In this case, a fourth package that represents the common tier is required. It must include all content available across all three packages.
"requiresSubscription": [ { "@type": "MediaSubscription", "@id": "https://www.example.com/package/1", "name": "Package 1", "sameAs": "https://www.example.com/package/1", "identifier": "example.com:package1", "commonTier": false }, { "@type": "MediaSubscription", "@id": "https://www.example.com/package/2", "name": "Package 2", "sameAs": "https://www.example.com/package/2", "identifier": "example.com:package2", "commonTier": false }, { "@type": "MediaSubscription", "@id": "https://www.example.com/package/3", "name": "Package 3", "sameAs": "https://www.example.com/package/3", "identifier": "example.com:package3", "commonTier": false }, { "@type": "MediaSubscription", "@id": "https://www.example.com/package/common", "name": "Common Tier Package", "sameAs": "https://www.example.com/package/common", "commonTier": true } ],
Packages without content that intersects
In a content model where all of the content packages don't intersect, a service provider sells packages that include no content from other packages. The following image is an example of the package structure.

In the following example, the provider offers three packages with no content intersecting across all of the packages. No common tier package is required.
"requiresSubscription": [ { "@type": "MediaSubscription", "@id": "https://www.example.com/package/1", "name": "Package 1", "sameAs": "https://www.example.com/package/1", "identifier": "example.com:package1", "commonTier": false }, { "@type": "MediaSubscription", "@id": "https://www.example.com/package/2", "name": "Package 2", "sameAs": "https://www.example.com/package/2", "identifier": "example.com:package2", "commonTier": false }, { "@type": "MediaSubscription", "@id": "https://www.example.com/package/3", "name": "Package 3", "sameAs": "https://www.example.com/package/3", "identifier": "example.com:package3", "commonTier": false } ],
Entitlements endpoint
Use the information from this section to host an HTTPS endpoint that returns the entitlements associated with a user.
Предварительное условие
Before you begin, verify that your service supports the OAuth 2.0 flow with Google.
Запрос
To receive a user's entitlements, Google sends a request that contains the user's OAuth token. Your endpoint needs to identify the user based on that OAuth token. See the following example:
GET /resource HTTP/1.1
Host: server.example.com
Authorization: Bearer <OAuthToken>
Ответ
Your endpoint needs to return a response with the following properties:
| Свойство | |
|---|---|
subscription | Необходимый This is a field inside the root response. |
subscription.type | Необходимый This property can have the following values:
|
subscription.expiration_date | Необязательный The expiration date of this entitlement, in ISO 8601 format , which includes the timezone. For more details, see Expiration dates . |
entitlements | Необязательный This a root property contains the |
entitlements.entitlement | Required if access to your streaming catalog varies based on the type of subscription. This property contains the |
entitlements.expiration_date | Необязательный The expiration date of this subscription, in ISO 8601 format , which includes the timezone. For more details, see Expiration dates . |
Сроки годности
There are two properties in an endpoint response that deal with expiration dates: subscription.expiration_date and entitlements.expiration_date . You can include one of them or neither, but not both. Which one you use depends on your subscription model.
| Модель подписки | |
|---|---|
| Access to your streaming catalog is the same for all subscribers. | Because you don't need to specify the entitlements property, specify subscription.expiration_date . |
Access to your streaming catalog varies based on the details of a user's subscription. | If your subscription model has multiple tiers or add-ons that expire over time, do one of the following:
|
Example responses
The following are example responses of different subscription states:
- Активная подписка
- Active subscription with an expiration date
- Без подписки
- Active subscriptions to multiple tiers or add-ons
Активная подписка
Активная подписка
A user has an active subscription to example.com . In this case, all subscribers have access to your entire streaming catalog regardless of their subscription type.
{ "subscription" : { "type": "ActiveSubscription", } }
Active subscription with an expiration date
Active subscription with an expiration date
A user has an active subscription to example.com , and the subscription has an expiration date. In this case, all subscribers have access to your entire streaming catalog regardless of their subscription type.
{ "subscription" : { "type": "ActiveSubscription", "expiration_date": "2019-11-10T10:00:00Z" } }
Без подписки
Без подписки
A user has no subscription to example.com .
{ "subscription" : { "type": "InactiveSubscription" } }
Active subscriptions to multiple tiers or add-ons
Active subscriptions to multiple tiers or add-ons
A user has a subscription to example.com:premium until a certain date.
{ "subscription" : { "type": "ActiveSubscription", } "entitlements": [ { "entitlement": "example.com:premium", "expiration": "2019-11-10T10:00:00Z" } ] }
Лимит скорости
Google refreshes a user's entitlements information up to every six hours. To smooth out the maximum queries per second (QPS), Google distributes the queries to your endpoint evenly over time. Thus, you can estimate the expected average QPS for your endpoint with the following formula:
Expected average QPS = <total number of users> / 21,600 seconds (6 hours x 60 minutes x 60 seconds)
If you support a large number of users, Google can adjust the 6-hour interval. If necessary, contact Google to discuss the configuration.
Связаться с Google
When your endpoint is ready, contact Google to inform the endpoint's URL.
Action access specification properties
See the action access specification properties section for reference information.
,Users prefer to watch or listen to content that they can already access, such as their existing subscription content. If Google knows what content a user can access on your app or platform, then Google can deliver a more relevant experience across Google surfaces and direct the user to that content.

Identify content access requirements
You must identify the access requirement for each content package in your catalog. When you do so, consider the following questions:
- Do users need to log in to your app or platform to access the content?
Do users need a subscription?
Watch Actions only:
- Do users need a subscription from an external service provider?
- Do you offer a tiered, multi-package, or add-on subscription?
Watch Actions only: Do users need to rent or purchase the content?
Does the access requirement change over time?
Does the access requirement depend on the device location?
Access restriction types
There are two kinds of access restrictions:
Paywall type
You can restrict access to content by its paywall type. The following table details the different paywall types:
| Paywall type | Пример | Категория |
|---|---|---|
| No purchase or login is required. | Треск | nologinrequired |
| The user must be logged in, but doesn't need a paid subscription. | Vudu (AVOD) | free |
| The user must have an active subscription. Access is independent of the subscription tier. | Netflix | |
| The user must have an active subscription. Access is dependent on the subscription tier. | Hulu (add-ons) | |
| The content is available for a finite amount of time after the purchase. | Вуду | rental |
| The content is available for an indefinite amount of time after the purchase. | Вуду | purchase |
| The content is available by cable subscription. | HBO Go | externalSubscription |
Paywall type for Watch Actions
To specify the content paywall type for Watch Actions, use the category property in the Action access specification :
"potentialAction": {
"@type":"WatchAction",
"target": { … },
"actionAccessibilityRequirement": {
"@type": "ActionAccessSpecification",
"category": "subscription",
"availabilityStarts": "2018-06-01T10:35:29Z",
"availabilityEnds": "2019-05-31T10:35:29Z",
"eligibleRegion": {
"@type": "Country",
"name": "US"
}
},
...
}
Paywall type for Listen Actions
To specify the content paywall type for Listen Actions, use the category property in the offer object :
"potentialAction": {
"@type":"ListenAction",
"target": { … },
"expectsAcceptanceOf":{
"@type":"Offer",
"category":"subscription",
"availabilityStarts": "2018-06-01T10:35:29Z",
"availabilityEnds": "2019-05-31T10:35:29Z",
"eligibleRegion": {
"@type":"Country",
"name":"US"
}
},
...
}
Географическая область
You must specify the geographic areas where the content is available. Use one or both of the following properties:
- The
eligibleRegionproperty of an Action access specification object. This property is required. - The
ineligibleRegionproperty of an Action access specification object.
A user can access content if the device location is within any region that's specified in eligibleRegion and isn't within any region that's specified in ineligibleRegion .
The eligibleRegion and ineligibleRegion properties allow the following values:
- A list of
Country,City, andState. - A
GeoShapeobject. See theGeoShapeproperties section for detailed requirements. - A list of
GeoShapeobjects.
If the content is available globally, use the following special value for eligibleRegion :
"eligibleRegion": "EARTH",
eligibleRegion use cases
The following are use-case examples of the eligibleRegion property:
- Example 1:
eligibleRegionwith a list of countries. - Example 2:
eligibleRegionwith aGeoShapeobject that contains a list of ZIP codes. - Example 3:
eligibleRegionwith aGeoShapeobject that contains a list of Forward Sortation Area (FSA) codes. - Example 4:
eligibleRegionwith aGeoShapeobject that contains a DMA ID. - Example 5:
eligibleRegionwith a list ofGeoShapeobjects. Each contains a DMA ID. - Example 6:
ineligibleRegionwith blocked-out ZIP codes.
Пример 1
eligibleRegion with a list of countries:
"actionAccessibilityRequirement": { "@type": "ActionAccessSpecification", "category": "subscription", "requiresSubscription": { "@type": "MediaSubscription", "@id": "http://www.example.com/north_america_network/subscription", "name": "Example Subscription", "commonTier": true }, "eligibleRegion": [ { "@type": "Country", "name": "US" }, { "@type": "Country", "name": "CA" } ] }
Пример 2
eligibleRegion with a GeoShape object that contains a list of ZIP codes:
"actionAccessibilityRequirement": { "@type": "ActionAccessSpecification", "category": "subscription", "requiresSubscription": { "@type": "MediaSubscription", "@id": "http://www.example.com/local_tv_network/subscription", "name": "Example Subscription", "commonTier": true }, "eligibleRegion": { "@type": "GeoShape", "@id": "http://example.com/area1", "addressCountry": "US", "postalCode": [ "94118", "94119" ] } }
Пример 3
eligibleRegion with a GeoShape object that contains a list of Forward Sortation Area (FSA) codes:
"actionAccessibilityRequirement": { "@type": "ActionAccessSpecification", "category": "subscription", "requiresSubscription": { "@type": "MediaSubscription", "@id": "http://www.example.com/local_tv_network/subscription", "name": "Example Subscription", "commonTier": true }, "additionalProperty": { "@type": "PropertyValue", "name": "DisplaySubscriptionIdentifier", "value": "http://www.example.com/local_tv_network/subscription" }, "eligibleRegion":{ "@type": "GeoShape", "@id": "http://example.com/area2", "addressCountry": "CA", "postalCode": [ "1A1", "K1A" ] } }
Example 4
eligibleRegion with a GeoShape object that contains a DMA ID:
"actionAccessibilityRequirement": { "@type": "ActionAccessSpecification", "category": "subscription", "requiresSubscription": { "@type": "MediaSubscription", "@id": "http://www.example.com/abcd/subscription", "name": "Example Subscription", "commonTier": true }, "additionalProperty": { "@type": "PropertyValue", "name": "DisplaySubscriptionIdentifier", "value": "http://www.example.com/abcd/subscription" }, "eligibleRegion":{ "@type": "GeoShape", "@id": "http://example.com/area3", "addressCountry": "US", "identifier": [ { "@type": "PropertyValue", "propertyID": "DMA_ID", "value": "501" } ] } }
Example 5
eligibleRegion with a list of GeoShape objects. Each contains a DMA ID:
"actionAccessibilityRequirement" : { "@type" : "ActionAccessSpecification", "eligibleRegion" : [ { "@id" : "http://example.com/dma/601", "@type" : "GeoShape", "addressCountry" : "US", "identifier" : { "@type" : "PropertyValue", "propertyID" : "DMA_ID", "value" : "601" } }, { "@id" : "http://example.com/dma/602", "@type" : "GeoShape", "addressCountry" : "US", "identifier" : { "@type" : "PropertyValue", "propertyID" : "DMA_ID", "value" : "602" } } ] }
Example 6
ineligibleRegion with blocked-out ZIP codes:
"actionAccessibilityRequirement": { "@type": "ActionAccessSpecification", "category": "subscription", "requiresSubscription": { "@type": "MediaSubscription", "@id": "http://www.example.com/local_tv_network/subscription", "name": "Example Subscription", "commonTier": true }, "additionalProperty": { "@type": "PropertyValue", "name": "DisplaySubscriptionIdentifier", "value": "http://www.example.com/local_tv_network/subscription" }, "eligibleRegion": { "@type": "Country", "name": "US" }, "ineligibleRegion": { "@type": "GeoShape", "@id": "http://example.com/area1", "addressCountry": "US", "postalCode": [ "94118", "94119" ] } }
Entitlement identifier
The entitlement identifier, entitlementId , refers to a string that represents access to a group of content in your media catalog. To determine whether a user has access to your content, Google takes the following steps:
- We make an API call to your Entitlements endpoint to receive the user's entitlement identifiers.
- We look up the content's required entitlement identifiers from your Media Actions feed.
- We match a user's
entitlementIdto theidentifierproperty of the media subscription object in your feed. If at least oneentitlementIdmatches, we determine that the user can access the content.

Google recommends that you use the following syntax for entitlementId :
<domain name> + colon (:) + <access level to content>
Примеры синтаксиса:
-
example.com:basic -
example.com:premium -
example.com:sports
Entitlement identifier example
MediaExampleCompany 's feed specifies that Movie XYZ requires the example.com:basic entitlementId , as shown:
{ "@context": ["http://schema.org", {"@language": "en"}], "@type": "Movie", "@id": "www.example.com/movie_xyz", "url": "www.example.com/movie_xyz", "name": "Movie XYZ", "potentialAction": { "@type": "WatchAction", "target": [ … ], "actionAccessibilityRequirement": { "@type": "ActionAccessSpecification", "category": "subscription", "requiresSubscription": { "@type": "MediaSubscription", "@id": "http://www.example.com/basic_subscription", "name": "Basic subscription", "commonTier": true ... }, "additionalProperty": { "@type": "PropertyValue", "name": "DisplaySubscriptionIdentifier", "value": "http://www.example.com/basic_subscription" }, ... } }, ... }
Common access use cases
The following are common access use cases:
- Free (no login required): The content is available without login, subscription, or purchase.
- Free (login required): The content requires users to be logged in but doesn't require a subscription.
- Single-tier subscription: The content requires a subscription. All subscribers can access the same content, whether movies or episodes, regardless of their subscription package.
- Multi-tier subscription: The content requires a subscription. Subscribers can access different content, whether movies or episodes, based on their subscription tier. For example, Silver versus Gold .
- Add-on subscription: The content requires a subscription. Subscribers can add premium content on top of their regular subscription.
- One-time purchase: The content can be purchased, after which the user can access it indefinitely.
- Live TV: A subscription includes access to local, national, and premium channels.
- Third-party subscription: The content requires the user to log in with their cable provider.
Free (no login required)
Вход в систему не требуется.
The content is available without login or subscription.
{ "actionAccessibilityRequirement": { "@type": "ActionAccessSpecification", "category": "nologinrequired", "availabilityStarts": "2015-01-01T00:00Z", "availabilityEnds": "2015-12-31T00:00Z", "eligibleRegion": { "@type": "Country", "name": "US" } } }
- Set
categorytonologinrequired. - Do not include
expectAcceptanceOf.
Free (login required)
Требуется вход в систему.
The content requires users to be logged in but doesn't require a subscription.
{ "actionAccessibilityRequirement": { "@type": "ActionAccessSpecification", "category": "free", "availabilityStarts": "2015-01-01T00:00Z", "availabilityEnds": "2015-12-31T00:00Z", "eligibleRegion": { "@type": "Country", "name": "US" } } }
- Set
categorytofree. - Do not include
expectAcceptanceOf.
Single-tier subscription
In a single-tiered subscription model, a service provider has one subscription tier. All subscribers can access the same content, whether movies or episodes, regardless of their subscription package.
{ "actionAccessibilityRequirement": { "@type": "ActionAccessSpecification", "category": "subscription", "availabilityStarts": "2015-01-01T00:00Z", "availabilityEnds": "2015-12-31T00:00Z", "requiresSubscription": { "@type": "MediaSubscription", "name": "Example Package", "commonTier": true, "@id": "http://www.example.com/example_package" }, "additionalProperty": { "@type": "PropertyValue", "name": "DisplaySubscriptionIdentifier", "value": "http://www.example.com/example_package" }, "eligibleRegion": { "@type": "Country", "name": "US" } } }
Multi-tier subscription
In a tiered subscription model, a service provider has multiple subscription tiers, such as Gold , Silver , and Bronze . Users who have the upper tier subscription can access all the lower tier content. However, users who have the lower tier subscription can't access the upper tier content.

Рассмотрим следующий сценарий:
- Jane subscribes to the Gold tier. Your entitlements endpoint returns the following
entitlementIdidentifiers:-
example.com:bronze -
example.com:silver -
example.com:gold
-
- John subscribes to the Bronze tier. Your entitlements endpoint returns the following
entitlementId:-
example.com:bronze
-
- Your Media Actions feed describes the following requirements:
- Movie A requires
example.com:bronze. - Movie B requires
example.com:silver.
- Movie A requires
In this scenario, Google determines the following access levels for Jane and John:
- Both Jane and John have access to Movie A .
- Jane has access to Movie B , but John doesn't.
{ "actionAccessibilityRequirement": { "@type": "ActionAccessSpecification", "category": "subscription", "requiresSubscription": { "@type": "MediaSubscription", "@id": "http://www.example.com/basic_subscription", "name": "Bronze", "commonTier": true ... }, "additionalProperty": { "@type": "PropertyValue", "name": "DisplaySubscriptionIdentifier", "value": "http://www.example.com/basic_subscription" }, ... } }
Add-on subscription
In an add-ons subscription model, a service provider allows users to expand their entitlements and add channels to a base subscription. Users can add as many channels as they want to.

Рассмотрим следующий сценарий:
- Jane has PRO and Sportz in addition to the Basic subscription. Your entitlements endpoint returns the following
entitlementIdidentifiers:-
example.com:basic -
example.com:pro -
example.com:sportz
-
- John only has the Basic subscription. Your entitlements endpoint returns the following
entitlementId:-
example.com:basic
-
- Your Media Actions feed describes the following requirements:
- Movie A requires
example.com:basic. - Movie B requires
example.com:pro.
- Movie A requires
In this scenario, Google determines the following access levels for Jane and John:
- Both Jane and John have access to Movie A .
- Jane has access to Movie B , but John doesn't.
{ "actionAccessibilityRequirement": { "@type": "ActionAccessSpecification", "category": "subscription", "availabilityStarts": "2015-01-01T00:00Z", "availabilityEnds": "2015-12-31T00:00Z", "eligibleRegion": { "@type": "Country", "name": "US" } "requiresSubscription": [ { "@type": "MediaSubscription", "@id": "https://www.example.com/package/basic", "name": "Basic", "sameAs": "https://www.example.com/package/basic", "commonTier": true }, { "@type": "MediaSubscription", "@id": "https://www.example.com/packages/basic/pro", "name": "PRO", "sameAs": "https://www.example.com/package/pro", "identifier": "example.com:pro", "commonTier": false }, { "@type": "MediaSubscription", "@id": "https://www.example.com/package/sportz", "name": "Sportz", "sameAs": "https://www.example.com/package/sports", "identifier": "example.com:sportz", "commonTier": false } ], "additionalProperty": { "@type": "PropertyValue", "name": "DisplaySubscriptionIdentifier", "value": "http://www.example.com/package/basic" }, } } }
Единоразовая покупка
Покупка
The content is available for an indefinite amount of time after the purchase.
{ "actionAccessibilityRequirement": { "@type": "ActionAccessSpecification", "category": "purchase", "availabilityStarts": "2015-01-01T00:00Z", "availabilityEnds": "2015-12-31T00:00Z", "eligibleRegion": { "@type": "Country", "name": "US" }, "expectsAcceptanceOf": { "@type": "Offer", "price": 7.99, "priceCurrency": "USD", "seller": { "@type": "Organization", "name": "Example", "sameAs": "http://www.example.com/" } } } }
- Set
categorytopurchase. - Include
expectAcceptanceOfinactionAccessibilityRequirementto indicate the price of the purchase.
Аренда
The content is available for a finite amount of time after the purchase.
{ "actionAccessibilityRequirement": { "@type": "ActionAccessSpecification", "category": "rental", "availabilityStarts": "2015-01-01T00:00Z", "availabilityEnds": "2015-12-31T00:00Z", "eligibleRegion": { "@type": "Country", "name": "US" }, "expectsAcceptanceOf": { "@type": "Offer", "price": 7.99, "priceCurrency": "USD", "seller": { "@type": "Organization", "name": "Example", "sameAs": "http://www.example.com/" } } } }
- Set
categorytorental. - Include
expectAcceptanceOfinactionAccessibilityRequirementto indicate the price of the rental.
Прямая трансляция ТВ
In a Media Actions feed, you can restrict access to a Live TV channel or event based on the following two user conditions:
- The user's device location
To restrict access to the TV channel, specify the area where users have access to it. This condition usually applies to local broadcast TV channels.
- The user's account status
If access to a TV channel depends on a user's account-level setting, use entitlement identifiers to represent the restriction.
This condition usually applies to the following use-cases:
- Bundle: National channels are often included in bundles, and users choose which bundle they want to subscribe to.
- Add-on: Some premium channels require users to selectively add extra channels to their subscription.
- Regional Sports Network (RSN): RSNs are usually associated with a user's "home" location. Users can watch content on the RSN even when they travel outside of their "home" location.
Third-party subscription
Third-party subscription
The content is available to the subscribers from a different service.
{ "actionAccessibilityRequirement": { "@type": "ActionAccessSpecification", "category": "externalsubscription" "availabilityStarts": "2015-01-01T00:00Z", "availabilityEnds": "2015-12-31T00:00Z", "requiresSubscription":{ "@type": "MediaSubscription", "@id": "https://www.example.com/faq", "name": "Example", "sameAs": "https://www.example.com/faq", "authenticator": { "@type": "Organization", "name": "TVE" } }, "additionalProperty": { "@type": "PropertyValue", "name": "DisplaySubscriptionIdentifier", "value": "http://www.example.com/faq" }, "eligibleRegion": { "@type": "Country", "name": "US" } } }
- Add
authenticatorto indicate that a different service authenticates the subscribers. For example, HBO GO requires a subscription from the cable provider.
Common tier packages
Common tier content is available to all subscribers regardless of their subscription package. The common tier applies to all content with the category of subscription . For more information on the category property, check the Paywall type section.
Why is a common tier package required?
Multiple Google surfaces provide TV & movie recommendations to users. To set user expectations about cost, Google must understand what content is available to all subscribers through use of the common tier. Google must also understand what content is available to subscribers with specific subscription packages.
Google recommends titles available on the common tier unless you support the entitlement API . The API lets Google understand the non-common-tier titles each specific user can access.
When should I create a common tier package?
A common tier package is required when your service offers content that's available to all subscribers. This includes services that offer only one package and services that offer multiple packages or add-ons.
Providers that have no content available to all subscribers don't need to create a common tier package. An example is service providers that provide mutually exclusive content across all of their packages.
Common tier examples
The following are examples of the common tier.
Tiered Subscription
In a tiered subscription model, a service provider has multiple subscription tiers, such as Gold , Silver , and Bronze tiers. Users with the upper-tier subscription have access to all the content in the lower tiers. Users with the lower-tier subscription don't have access to the content in the upper tier. The following image is an example of the package structure.

In the following code example, the bronze package is the common tier because all users have access to all content in that tier.
"requiresSubscription": [ { "@type": "MediaSubscription", "@id": "https://www.example.com/package/bronze", "name": "Bronze", "sameAs": "https://www.example.com/package/bronze", "commonTier": true }, { "@type": "MediaSubscription", "@id": "https://www.example.com/package/silver", "name": "Silver", "sameAs": "https://www.example.com/package/silver", "identifier": "example.com:silver", "commonTier": false }, { "@type": "MediaSubscription", "@id": "https://www.example.com/package/gold", "name": "Gold", "sameAs": "https://www.example.com/package/gold", "identifier": "example.com:gold", "commonTier": false } ],
Дополнительные опции
In an add-ons subscription model, a service provider allows users to expand their entitlements and add channels to a basic subscription. Users can add as many channels as they want. The following image is an example of the package structure.

If you have a channel available to all users and there's no cost for the channel, you can merge the package with the common tier package.
In the following code example, the basic package is the common tier because all users have access to all content in this package.
"requiresSubscription": [ { "@type": "MediaSubscription", "@id": "https://www.example.com/package/basic", "name": "Basic", "sameAs": "https://www.example.com/package/basic", "commonTier": true }, { "@type": "MediaSubscription", "@id": "https://www.example.com/packages/basic/pro", "name": "PRO", "sameAs": "https://www.example.com/package/pro", "identifier": "example.com:pro", "commonTier": false }, { "@type": "MediaSubscription", "@id": "https://www.example.com/package/sportz", "name": "Sportz", "sameAs": "https://www.example.com/package/sports", "identifier": "example.com:sportz", "commonTier": false }, { "@type": "MediaSubscription", "@id": "https://www.example.com/package/moviemax", "name": "Moviemax", "sameAs": "https://www.example.com/package/moviemax", "identifier": "example.com:moviemax", "commonTier": false } ],
Packages with content that intersects
In a content model where packages have content that intersects, a service provider sells packages that include some content from other packages. The following image is an example of the package structure.

In the following code example, the provider offers three packages where some content intersects across all of the packages. In this case, a fourth package that represents the common tier is required. It must include all content available across all three packages.
"requiresSubscription": [ { "@type": "MediaSubscription", "@id": "https://www.example.com/package/1", "name": "Package 1", "sameAs": "https://www.example.com/package/1", "identifier": "example.com:package1", "commonTier": false }, { "@type": "MediaSubscription", "@id": "https://www.example.com/package/2", "name": "Package 2", "sameAs": "https://www.example.com/package/2", "identifier": "example.com:package2", "commonTier": false }, { "@type": "MediaSubscription", "@id": "https://www.example.com/package/3", "name": "Package 3", "sameAs": "https://www.example.com/package/3", "identifier": "example.com:package3", "commonTier": false }, { "@type": "MediaSubscription", "@id": "https://www.example.com/package/common", "name": "Common Tier Package", "sameAs": "https://www.example.com/package/common", "commonTier": true } ],
Packages without content that intersects
In a content model where all of the content packages don't intersect, a service provider sells packages that include no content from other packages. The following image is an example of the package structure.

In the following example, the provider offers three packages with no content intersecting across all of the packages. No common tier package is required.
"requiresSubscription": [ { "@type": "MediaSubscription", "@id": "https://www.example.com/package/1", "name": "Package 1", "sameAs": "https://www.example.com/package/1", "identifier": "example.com:package1", "commonTier": false }, { "@type": "MediaSubscription", "@id": "https://www.example.com/package/2", "name": "Package 2", "sameAs": "https://www.example.com/package/2", "identifier": "example.com:package2", "commonTier": false }, { "@type": "MediaSubscription", "@id": "https://www.example.com/package/3", "name": "Package 3", "sameAs": "https://www.example.com/package/3", "identifier": "example.com:package3", "commonTier": false } ],
Entitlements endpoint
Use the information from this section to host an HTTPS endpoint that returns the entitlements associated with a user.
Предварительное условие
Before you begin, verify that your service supports the OAuth 2.0 flow with Google.
Запрос
To receive a user's entitlements, Google sends a request that contains the user's OAuth token. Your endpoint needs to identify the user based on that OAuth token. See the following example:
GET /resource HTTP/1.1
Host: server.example.com
Authorization: Bearer <OAuthToken>
Ответ
Your endpoint needs to return a response with the following properties:
| Свойство | |
|---|---|
subscription | Необходимый This is a field inside the root response. |
subscription.type | Необходимый This property can have the following values:
|
subscription.expiration_date | Необязательный The expiration date of this entitlement, in ISO 8601 format , which includes the timezone. For more details, see Expiration dates . |
entitlements | Необязательный This a root property contains the |
entitlements.entitlement | Required if access to your streaming catalog varies based on the type of subscription. This property contains the |
entitlements.expiration_date | Необязательный The expiration date of this subscription, in ISO 8601 format , which includes the timezone. For more details, see Expiration dates . |
Сроки годности
There are two properties in an endpoint response that deal with expiration dates: subscription.expiration_date and entitlements.expiration_date . You can include one of them or neither, but not both. Which one you use depends on your subscription model.
| Модель подписки | |
|---|---|
| Access to your streaming catalog is the same for all subscribers. | Because you don't need to specify the entitlements property, specify subscription.expiration_date . |
Access to your streaming catalog varies based on the details of a user's subscription. | If your subscription model has multiple tiers or add-ons that expire over time, do one of the following:
|
Example responses
The following are example responses of different subscription states:
- Активная подписка
- Active subscription with an expiration date
- Без подписки
- Active subscriptions to multiple tiers or add-ons
Активная подписка
Активная подписка
A user has an active subscription to example.com . In this case, all subscribers have access to your entire streaming catalog regardless of their subscription type.
{ "subscription" : { "type": "ActiveSubscription", } }
Active subscription with an expiration date
Active subscription with an expiration date
A user has an active subscription to example.com , and the subscription has an expiration date. In this case, all subscribers have access to your entire streaming catalog regardless of their subscription type.
{ "subscription" : { "type": "ActiveSubscription", "expiration_date": "2019-11-10T10:00:00Z" } }
Без подписки
Без подписки
A user has no subscription to example.com .
{ "subscription" : { "type": "InactiveSubscription" } }
Active subscriptions to multiple tiers or add-ons
Active subscriptions to multiple tiers or add-ons
A user has a subscription to example.com:premium until a certain date.
{ "subscription" : { "type": "ActiveSubscription", } "entitlements": [ { "entitlement": "example.com:premium", "expiration": "2019-11-10T10:00:00Z" } ] }
Лимит скорости
Google refreshes a user's entitlements information up to every six hours. To smooth out the maximum queries per second (QPS), Google distributes the queries to your endpoint evenly over time. Thus, you can estimate the expected average QPS for your endpoint with the following formula:
Expected average QPS = <total number of users> / 21,600 seconds (6 hours x 60 minutes x 60 seconds)
If you support a large number of users, Google can adjust the 6-hour interval. If necessary, contact Google to discuss the configuration.
Связаться с Google
When your endpoint is ready, contact Google to inform the endpoint's URL.
Action access specification properties
See the action access specification properties section for reference information.
,Users prefer to watch or listen to content that they can already access, such as their existing subscription content. If Google knows what content a user can access on your app or platform, then Google can deliver a more relevant experience across Google surfaces and direct the user to that content.

Identify content access requirements
You must identify the access requirement for each content package in your catalog. When you do so, consider the following questions:
- Do users need to log in to your app or platform to access the content?
Do users need a subscription?
Watch Actions only:
- Do users need a subscription from an external service provider?
- Do you offer a tiered, multi-package, or add-on subscription?
Watch Actions only: Do users need to rent or purchase the content?
Does the access requirement change over time?
Does the access requirement depend on the device location?
Access restriction types
There are two kinds of access restrictions:
Paywall type
You can restrict access to content by its paywall type. The following table details the different paywall types:
| Paywall type | Пример | Категория |
|---|---|---|
| No purchase or login is required. | Треск | nologinrequired |
| The user must be logged in, but doesn't need a paid subscription. | Vudu (AVOD) | free |
| The user must have an active subscription. Access is independent of the subscription tier. | Netflix | |
| The user must have an active subscription. Access is dependent on the subscription tier. | Hulu (add-ons) | |
| The content is available for a finite amount of time after the purchase. | Вуду | rental |
| The content is available for an indefinite amount of time after the purchase. | Вуду | purchase |
| The content is available by cable subscription. | HBO Go | externalSubscription |
Paywall type for Watch Actions
To specify the content paywall type for Watch Actions, use the category property in the Action access specification :
"potentialAction": {
"@type":"WatchAction",
"target": { … },
"actionAccessibilityRequirement": {
"@type": "ActionAccessSpecification",
"category": "subscription",
"availabilityStarts": "2018-06-01T10:35:29Z",
"availabilityEnds": "2019-05-31T10:35:29Z",
"eligibleRegion": {
"@type": "Country",
"name": "US"
}
},
...
}
Paywall type for Listen Actions
To specify the content paywall type for Listen Actions, use the category property in the offer object :
"potentialAction": {
"@type":"ListenAction",
"target": { … },
"expectsAcceptanceOf":{
"@type":"Offer",
"category":"subscription",
"availabilityStarts": "2018-06-01T10:35:29Z",
"availabilityEnds": "2019-05-31T10:35:29Z",
"eligibleRegion": {
"@type":"Country",
"name":"US"
}
},
...
}
Географическая область
You must specify the geographic areas where the content is available. Use one or both of the following properties:
- The
eligibleRegionproperty of an Action access specification object. This property is required. - The
ineligibleRegionproperty of an Action access specification object.
A user can access content if the device location is within any region that's specified in eligibleRegion and isn't within any region that's specified in ineligibleRegion .
The eligibleRegion and ineligibleRegion properties allow the following values:
- A list of
Country,City, andState. - A
GeoShapeobject. See theGeoShapeproperties section for detailed requirements. - A list of
GeoShapeobjects.
If the content is available globally, use the following special value for eligibleRegion :
"eligibleRegion": "EARTH",
eligibleRegion use cases
The following are use-case examples of the eligibleRegion property:
- Example 1:
eligibleRegionwith a list of countries. - Example 2:
eligibleRegionwith aGeoShapeobject that contains a list of ZIP codes. - Example 3:
eligibleRegionwith aGeoShapeobject that contains a list of Forward Sortation Area (FSA) codes. - Example 4:
eligibleRegionwith aGeoShapeobject that contains a DMA ID. - Example 5:
eligibleRegionwith a list ofGeoShapeobjects. Each contains a DMA ID. - Example 6:
ineligibleRegionwith blocked-out ZIP codes.
Пример 1
eligibleRegion with a list of countries:
"actionAccessibilityRequirement": { "@type": "ActionAccessSpecification", "category": "subscription", "requiresSubscription": { "@type": "MediaSubscription", "@id": "http://www.example.com/north_america_network/subscription", "name": "Example Subscription", "commonTier": true }, "eligibleRegion": [ { "@type": "Country", "name": "US" }, { "@type": "Country", "name": "CA" } ] }
Пример 2
eligibleRegion with a GeoShape object that contains a list of ZIP codes:
"actionAccessibilityRequirement": { "@type": "ActionAccessSpecification", "category": "subscription", "requiresSubscription": { "@type": "MediaSubscription", "@id": "http://www.example.com/local_tv_network/subscription", "name": "Example Subscription", "commonTier": true }, "eligibleRegion": { "@type": "GeoShape", "@id": "http://example.com/area1", "addressCountry": "US", "postalCode": [ "94118", "94119" ] } }
Пример 3
eligibleRegion with a GeoShape object that contains a list of Forward Sortation Area (FSA) codes:
"actionAccessibilityRequirement": { "@type": "ActionAccessSpecification", "category": "subscription", "requiresSubscription": { "@type": "MediaSubscription", "@id": "http://www.example.com/local_tv_network/subscription", "name": "Example Subscription", "commonTier": true }, "additionalProperty": { "@type": "PropertyValue", "name": "DisplaySubscriptionIdentifier", "value": "http://www.example.com/local_tv_network/subscription" }, "eligibleRegion":{ "@type": "GeoShape", "@id": "http://example.com/area2", "addressCountry": "CA", "postalCode": [ "1A1", "K1A" ] } }
Example 4
eligibleRegion with a GeoShape object that contains a DMA ID:
"actionAccessibilityRequirement": { "@type": "ActionAccessSpecification", "category": "subscription", "requiresSubscription": { "@type": "MediaSubscription", "@id": "http://www.example.com/abcd/subscription", "name": "Example Subscription", "commonTier": true }, "additionalProperty": { "@type": "PropertyValue", "name": "DisplaySubscriptionIdentifier", "value": "http://www.example.com/abcd/subscription" }, "eligibleRegion":{ "@type": "GeoShape", "@id": "http://example.com/area3", "addressCountry": "US", "identifier": [ { "@type": "PropertyValue", "propertyID": "DMA_ID", "value": "501" } ] } }
Example 5
eligibleRegion with a list of GeoShape objects. Each contains a DMA ID:
"actionAccessibilityRequirement" : { "@type" : "ActionAccessSpecification", "eligibleRegion" : [ { "@id" : "http://example.com/dma/601", "@type" : "GeoShape", "addressCountry" : "US", "identifier" : { "@type" : "PropertyValue", "propertyID" : "DMA_ID", "value" : "601" } }, { "@id" : "http://example.com/dma/602", "@type" : "GeoShape", "addressCountry" : "US", "identifier" : { "@type" : "PropertyValue", "propertyID" : "DMA_ID", "value" : "602" } } ] }
Example 6
ineligibleRegion with blocked-out ZIP codes:
"actionAccessibilityRequirement": { "@type": "ActionAccessSpecification", "category": "subscription", "requiresSubscription": { "@type": "MediaSubscription", "@id": "http://www.example.com/local_tv_network/subscription", "name": "Example Subscription", "commonTier": true }, "additionalProperty": { "@type": "PropertyValue", "name": "DisplaySubscriptionIdentifier", "value": "http://www.example.com/local_tv_network/subscription" }, "eligibleRegion": { "@type": "Country", "name": "US" }, "ineligibleRegion": { "@type": "GeoShape", "@id": "http://example.com/area1", "addressCountry": "US", "postalCode": [ "94118", "94119" ] } }
Entitlement identifier
The entitlement identifier, entitlementId , refers to a string that represents access to a group of content in your media catalog. To determine whether a user has access to your content, Google takes the following steps:
- We make an API call to your Entitlements endpoint to receive the user's entitlement identifiers.
- We look up the content's required entitlement identifiers from your Media Actions feed.
- We match a user's
entitlementIdto theidentifierproperty of the media subscription object in your feed. If at least oneentitlementIdmatches, we determine that the user can access the content.

Google recommends that you use the following syntax for entitlementId :
<domain name> + colon (:) + <access level to content>
Примеры синтаксиса:
-
example.com:basic -
example.com:premium -
example.com:sports
Entitlement identifier example
MediaExampleCompany 's feed specifies that Movie XYZ requires the example.com:basic entitlementId , as shown:
{ "@context": ["http://schema.org", {"@language": "en"}], "@type": "Movie", "@id": "www.example.com/movie_xyz", "url": "www.example.com/movie_xyz", "name": "Movie XYZ", "potentialAction": { "@type": "WatchAction", "target": [ … ], "actionAccessibilityRequirement": { "@type": "ActionAccessSpecification", "category": "subscription", "requiresSubscription": { "@type": "MediaSubscription", "@id": "http://www.example.com/basic_subscription", "name": "Basic subscription", "commonTier": true ... }, "additionalProperty": { "@type": "PropertyValue", "name": "DisplaySubscriptionIdentifier", "value": "http://www.example.com/basic_subscription" }, ... } }, ... }
Common access use cases
The following are common access use cases:
- Free (no login required): The content is available without login, subscription, or purchase.
- Free (login required): The content requires users to be logged in but doesn't require a subscription.
- Single-tier subscription: The content requires a subscription. All subscribers can access the same content, whether movies or episodes, regardless of their subscription package.
- Multi-tier subscription: The content requires a subscription. Subscribers can access different content, whether movies or episodes, based on their subscription tier. For example, Silver versus Gold .
- Add-on subscription: The content requires a subscription. Subscribers can add premium content on top of their regular subscription.
- One-time purchase: The content can be purchased, after which the user can access it indefinitely.
- Live TV: A subscription includes access to local, national, and premium channels.
- Third-party subscription: The content requires the user to log in with their cable provider.
Free (no login required)
Вход в систему не требуется.
The content is available without login or subscription.
{ "actionAccessibilityRequirement": { "@type": "ActionAccessSpecification", "category": "nologinrequired", "availabilityStarts": "2015-01-01T00:00Z", "availabilityEnds": "2015-12-31T00:00Z", "eligibleRegion": { "@type": "Country", "name": "US" } } }
- Set
categorytonologinrequired. - Do not include
expectAcceptanceOf.
Free (login required)
Требуется вход в систему.
The content requires users to be logged in but doesn't require a subscription.
{ "actionAccessibilityRequirement": { "@type": "ActionAccessSpecification", "category": "free", "availabilityStarts": "2015-01-01T00:00Z", "availabilityEnds": "2015-12-31T00:00Z", "eligibleRegion": { "@type": "Country", "name": "US" } } }
- Set
categorytofree. - Do not include
expectAcceptanceOf.
Single-tier subscription
In a single-tiered subscription model, a service provider has one subscription tier. All subscribers can access the same content, whether movies or episodes, regardless of their subscription package.
{ "actionAccessibilityRequirement": { "@type": "ActionAccessSpecification", "category": "subscription", "availabilityStarts": "2015-01-01T00:00Z", "availabilityEnds": "2015-12-31T00:00Z", "requiresSubscription": { "@type": "MediaSubscription", "name": "Example Package", "commonTier": true, "@id": "http://www.example.com/example_package" }, "additionalProperty": { "@type": "PropertyValue", "name": "DisplaySubscriptionIdentifier", "value": "http://www.example.com/example_package" }, "eligibleRegion": { "@type": "Country", "name": "US" } } }
Multi-tier subscription
In a tiered subscription model, a service provider has multiple subscription tiers, such as Gold , Silver , and Bronze . Users who have the upper tier subscription can access all the lower tier content. However, users who have the lower tier subscription can't access the upper tier content.

Рассмотрим следующий сценарий:
- Jane subscribes to the Gold tier. Your entitlements endpoint returns the following
entitlementIdidentifiers:-
example.com:bronze -
example.com:silver -
example.com:gold
-
- John subscribes to the Bronze tier. Your entitlements endpoint returns the following
entitlementId:-
example.com:bronze
-
- Your Media Actions feed describes the following requirements:
- Movie A requires
example.com:bronze. - Movie B requires
example.com:silver.
- Movie A requires
In this scenario, Google determines the following access levels for Jane and John:
- Both Jane and John have access to Movie A .
- Jane has access to Movie B , but John doesn't.
{ "actionAccessibilityRequirement": { "@type": "ActionAccessSpecification", "category": "subscription", "requiresSubscription": { "@type": "MediaSubscription", "@id": "http://www.example.com/basic_subscription", "name": "Bronze", "commonTier": true ... }, "additionalProperty": { "@type": "PropertyValue", "name": "DisplaySubscriptionIdentifier", "value": "http://www.example.com/basic_subscription" }, ... } }
Add-on subscription
In an add-ons subscription model, a service provider allows users to expand their entitlements and add channels to a base subscription. Users can add as many channels as they want to.

Рассмотрим следующий сценарий:
- Jane has PRO and Sportz in addition to the Basic subscription. Your entitlements endpoint returns the following
entitlementIdidentifiers:-
example.com:basic -
example.com:pro -
example.com:sportz
-
- John only has the Basic subscription. Your entitlements endpoint returns the following
entitlementId:-
example.com:basic
-
- Your Media Actions feed describes the following requirements:
- Movie A requires
example.com:basic. - Movie B requires
example.com:pro.
- Movie A requires
In this scenario, Google determines the following access levels for Jane and John:
- Both Jane and John have access to Movie A .
- Jane has access to Movie B , but John doesn't.
{ "actionAccessibilityRequirement": { "@type": "ActionAccessSpecification", "category": "subscription", "availabilityStarts": "2015-01-01T00:00Z", "availabilityEnds": "2015-12-31T00:00Z", "eligibleRegion": { "@type": "Country", "name": "US" } "requiresSubscription": [ { "@type": "MediaSubscription", "@id": "https://www.example.com/package/basic", "name": "Basic", "sameAs": "https://www.example.com/package/basic", "commonTier": true }, { "@type": "MediaSubscription", "@id": "https://www.example.com/packages/basic/pro", "name": "PRO", "sameAs": "https://www.example.com/package/pro", "identifier": "example.com:pro", "commonTier": false }, { "@type": "MediaSubscription", "@id": "https://www.example.com/package/sportz", "name": "Sportz", "sameAs": "https://www.example.com/package/sports", "identifier": "example.com:sportz", "commonTier": false } ], "additionalProperty": { "@type": "PropertyValue", "name": "DisplaySubscriptionIdentifier", "value": "http://www.example.com/package/basic" }, } } }
Единоразовая покупка
Покупка
The content is available for an indefinite amount of time after the purchase.
{ "actionAccessibilityRequirement": { "@type": "ActionAccessSpecification", "category": "purchase", "availabilityStarts": "2015-01-01T00:00Z", "availabilityEnds": "2015-12-31T00:00Z", "eligibleRegion": { "@type": "Country", "name": "US" }, "expectsAcceptanceOf": { "@type": "Offer", "price": 7.99, "priceCurrency": "USD", "seller": { "@type": "Organization", "name": "Example", "sameAs": "http://www.example.com/" } } } }
- Set
categorytopurchase. - Include
expectAcceptanceOfinactionAccessibilityRequirementto indicate the price of the purchase.
Аренда
The content is available for a finite amount of time after the purchase.
{ "actionAccessibilityRequirement": { "@type": "ActionAccessSpecification", "category": "rental", "availabilityStarts": "2015-01-01T00:00Z", "availabilityEnds": "2015-12-31T00:00Z", "eligibleRegion": { "@type": "Country", "name": "US" }, "expectsAcceptanceOf": { "@type": "Offer", "price": 7.99, "priceCurrency": "USD", "seller": { "@type": "Organization", "name": "Example", "sameAs": "http://www.example.com/" } } } }
- Set
categorytorental. - Include
expectAcceptanceOfinactionAccessibilityRequirementto indicate the price of the rental.
Прямая трансляция ТВ
In a Media Actions feed, you can restrict access to a Live TV channel or event based on the following two user conditions:
- The user's device location
To restrict access to the TV channel, specify the area where users have access to it. This condition usually applies to local broadcast TV channels.
- The user's account status
If access to a TV channel depends on a user's account-level setting, use entitlement identifiers to represent the restriction.
This condition usually applies to the following use-cases:
- Bundle: National channels are often included in bundles, and users choose which bundle they want to subscribe to.
- Add-on: Some premium channels require users to selectively add extra channels to their subscription.
- Regional Sports Network (RSN): RSNs are usually associated with a user's "home" location. Users can watch content on the RSN even when they travel outside of their "home" location.
Third-party subscription
Third-party subscription
The content is available to the subscribers from a different service.
{ "actionAccessibilityRequirement": { "@type": "ActionAccessSpecification", "category": "externalsubscription" "availabilityStarts": "2015-01-01T00:00Z", "availabilityEnds": "2015-12-31T00:00Z", "requiresSubscription":{ "@type": "MediaSubscription", "@id": "https://www.example.com/faq", "name": "Example", "sameAs": "https://www.example.com/faq", "authenticator": { "@type": "Organization", "name": "TVE" } }, "additionalProperty": { "@type": "PropertyValue", "name": "DisplaySubscriptionIdentifier", "value": "http://www.example.com/faq" }, "eligibleRegion": { "@type": "Country", "name": "US" } } }
- Add
authenticatorto indicate that a different service authenticates the subscribers. For example, HBO GO requires a subscription from the cable provider.
Common tier packages
Common tier content is available to all subscribers regardless of their subscription package. The common tier applies to all content with the category of subscription . For more information on the category property, check the Paywall type section.
Why is a common tier package required?
Multiple Google surfaces provide TV & movie recommendations to users. To set user expectations about cost, Google must understand what content is available to all subscribers through use of the common tier. Google must also understand what content is available to subscribers with specific subscription packages.
Google recommends titles available on the common tier unless you support the entitlement API . The API lets Google understand the non-common-tier titles each specific user can access.
When should I create a common tier package?
A common tier package is required when your service offers content that's available to all subscribers. This includes services that offer only one package and services that offer multiple packages or add-ons.
Providers that have no content available to all subscribers don't need to create a common tier package. An example is service providers that provide mutually exclusive content across all of their packages.
Common tier examples
The following are examples of the common tier.
Tiered Subscription
In a tiered subscription model, a service provider has multiple subscription tiers, such as Gold , Silver , and Bronze tiers. Users with the upper-tier subscription have access to all the content in the lower tiers. Users with the lower-tier subscription don't have access to the content in the upper tier. The following image is an example of the package structure.

In the following code example, the bronze package is the common tier because all users have access to all content in that tier.
"requiresSubscription": [ { "@type": "MediaSubscription", "@id": "https://www.example.com/package/bronze", "name": "Bronze", "sameAs": "https://www.example.com/package/bronze", "commonTier": true }, { "@type": "MediaSubscription", "@id": "https://www.example.com/package/silver", "name": "Silver", "sameAs": "https://www.example.com/package/silver", "identifier": "example.com:silver", "commonTier": false }, { "@type": "MediaSubscription", "@id": "https://www.example.com/package/gold", "name": "Gold", "sameAs": "https://www.example.com/package/gold", "identifier": "example.com:gold", "commonTier": false } ],
Дополнительные опции
In an add-ons subscription model, a service provider allows users to expand their entitlements and add channels to a basic subscription. Users can add as many channels as they want. The following image is an example of the package structure.

If you have a channel available to all users and there's no cost for the channel, you can merge the package with the common tier package.
In the following code example, the basic package is the common tier because all users have access to all content in this package.
"requiresSubscription": [ { "@type": "MediaSubscription", "@id": "https://www.example.com/package/basic", "name": "Basic", "sameAs": "https://www.example.com/package/basic", "commonTier": true }, { "@type": "MediaSubscription", "@id": "https://www.example.com/packages/basic/pro", "name": "PRO", "sameAs": "https://www.example.com/package/pro", "identifier": "example.com:pro", "commonTier": false }, { "@type": "MediaSubscription", "@id": "https://www.example.com/package/sportz", "name": "Sportz", "sameAs": "https://www.example.com/package/sports", "identifier": "example.com:sportz", "commonTier": false }, { "@type": "MediaSubscription", "@id": "https://www.example.com/package/moviemax", "name": "Moviemax", "sameAs": "https://www.example.com/package/moviemax", "identifier": "example.com:moviemax", "commonTier": false } ],
Packages with content that intersects
In a content model where packages have content that intersects, a service provider sells packages that include some content from other packages. The following image is an example of the package structure.

In the following code example, the provider offers three packages where some content intersects across all of the packages. In this case, a fourth package that represents the common tier is required. It must include all content available across all three packages.
"requiresSubscription": [ { "@type": "MediaSubscription", "@id": "https://www.example.com/package/1", "name": "Package 1", "sameAs": "https://www.example.com/package/1", "identifier": "example.com:package1", "commonTier": false }, { "@type": "MediaSubscription", "@id": "https://www.example.com/package/2", "name": "Package 2", "sameAs": "https://www.example.com/package/2", "identifier": "example.com:package2", "commonTier": false }, { "@type": "MediaSubscription", "@id": "https://www.example.com/package/3", "name": "Package 3", "sameAs": "https://www.example.com/package/3", "identifier": "example.com:package3", "commonTier": false }, { "@type": "MediaSubscription", "@id": "https://www.example.com/package/common", "name": "Common Tier Package", "sameAs": "https://www.example.com/package/common", "commonTier": true } ],
Packages without content that intersects
In a content model where all of the content packages don't intersect, a service provider sells packages that include no content from other packages. The following image is an example of the package structure.

In the following example, the provider offers three packages with no content intersecting across all of the packages. No common tier package is required.
"requiresSubscription": [ { "@type": "MediaSubscription", "@id": "https://www.example.com/package/1", "name": "Package 1", "sameAs": "https://www.example.com/package/1", "identifier": "example.com:package1", "commonTier": false }, { "@type": "MediaSubscription", "@id": "https://www.example.com/package/2", "name": "Package 2", "sameAs": "https://www.example.com/package/2", "identifier": "example.com:package2", "commonTier": false }, { "@type": "MediaSubscription", "@id": "https://www.example.com/package/3", "name": "Package 3", "sameAs": "https://www.example.com/package/3", "identifier": "example.com:package3", "commonTier": false } ],
Entitlements endpoint
Use the information from this section to host an HTTPS endpoint that returns the entitlements associated with a user.
Предварительное условие
Before you begin, verify that your service supports the OAuth 2.0 flow with Google.
Запрос
To receive a user's entitlements, Google sends a request that contains the user's OAuth token. Your endpoint needs to identify the user based on that OAuth token. See the following example:
GET /resource HTTP/1.1
Host: server.example.com
Authorization: Bearer <OAuthToken>
Ответ
Your endpoint needs to return a response with the following properties:
| Свойство | |
|---|---|
subscription | Необходимый This is a field inside the root response. |
subscription.type | Необходимый This property can have the following values:
|
subscription.expiration_date | Необязательный The expiration date of this entitlement, in ISO 8601 format , which includes the timezone. For more details, see Expiration dates . |
entitlements | Необязательный This a root property contains the |
entitlements.entitlement | Required if access to your streaming catalog varies based on the type of subscription. This property contains the |
entitlements.expiration_date | Необязательный The expiration date of this subscription, in ISO 8601 format , which includes the timezone. For more details, see Expiration dates . |
Сроки годности
There are two properties in an endpoint response that deal with expiration dates: subscription.expiration_date and entitlements.expiration_date . You can include one of them or neither, but not both. Which one you use depends on your subscription model.
| Модель подписки | |
|---|---|
| Access to your streaming catalog is the same for all subscribers. | Because you don't need to specify the entitlements property, specify subscription.expiration_date . |
Access to your streaming catalog varies based on the details of a user's subscription. | If your subscription model has multiple tiers or add-ons that expire over time, do one of the following:
|
Example responses
The following are example responses of different subscription states:
- Активная подписка
- Active subscription with an expiration date
- Без подписки
- Active subscriptions to multiple tiers or add-ons
Активная подписка
Активная подписка
A user has an active subscription to example.com . In this case, all subscribers have access to your entire streaming catalog regardless of their subscription type.
{ "subscription" : { "type": "ActiveSubscription", } }
Active subscription with an expiration date
Active subscription with an expiration date
A user has an active subscription to example.com , and the subscription has an expiration date. In this case, all subscribers have access to your entire streaming catalog regardless of their subscription type.
{ "subscription" : { "type": "ActiveSubscription", "expiration_date": "2019-11-10T10:00:00Z" } }
Без подписки
Без подписки
A user has no subscription to example.com .
{ "subscription" : { "type": "InactiveSubscription" } }
Active subscriptions to multiple tiers or add-ons
Active subscriptions to multiple tiers or add-ons
A user has a subscription to example.com:premium until a certain date.
{ "subscription" : { "type": "ActiveSubscription", } "entitlements": [ { "entitlement": "example.com:premium", "expiration": "2019-11-10T10:00:00Z" } ] }
Лимит скорости
Google refreshes a user's entitlements information up to every six hours. To smooth out the maximum queries per second (QPS), Google distributes the queries to your endpoint evenly over time. Thus, you can estimate the expected average QPS for your endpoint with the following formula:
Expected average QPS = <total number of users> / 21,600 seconds (6 hours x 60 minutes x 60 seconds)
If you support a large number of users, Google can adjust the 6-hour interval. If necessary, contact Google to discuss the configuration.
Связаться с Google
When your endpoint is ready, contact Google to inform the endpoint's URL.
Action access specification properties
See the action access specification properties section for reference information.