Engage SDK Travel: Third-party technical integration instructions

Boost app engagement by reaching your users where they are. Integrate Engage SDK to deliver personalized recommendations and continuation content directly to users across multiple on-device surfaces, like Collections, Entertainment Space, and the Play Store. The integration adds less than 50 KB (compressed) to the average APK and takes most apps about a week of developer time. Learn more at our business site.

This guide contains instructions for developer partners to deliver travel and events content to Engage content surfaces.

Integration detail

Terminology

This integration includes the following cluster types: Recommendation, Featured, Reservation and Continue Search.

  • Recommendation clusters show personalized travel & event suggestions from an individual developer partner. These recommendations can be personalized to the user or generalized (for example, trending items). Use these to surface articles, events, lodging, or places of interest recommendations.

    • A Recommendation cluster can be made of ArticleEntity, EventEntity, LodgingEntity, PointOfInterestEntity, or StoreEntity listings, but not a mix of different entity types.

    Your recommendations take the following structure:

    • Recommendation Cluster: A UI view that contains a group of recommendations from the same developer partner.

    • Entity: An object representing a single item in a cluster. This integration offers some entities that would be surfaced using the Recommendation Cluster:

      • ArticleEntity: ArticleEntity represents a recommendation for text-based content related to travel & events. It can be used for articles, blogposts, marketing content, news snippets, etc.

        Figure 1: UI showing a single ArticleEntity within Recommendations cluster.
      • EventEntity: EventEntity represents an event happening in the future. Event start time is a critical piece of information that needs to be conveyed to the users.

        Figure 2: UI showing a single EventEntity within Recommendations cluster.
      • LodgingEntity: LodgingEntity represents an accommodation, such as a hotel, apartment, vacation home for short term and long term rental.

        Figure 3: UI showing a single LodgingEntity within Recommendations cluster.
      • StoreEntity: StoreEntity represents a store, restaurant, cafe etc. It highlights content where a dining venue or store is the critical piece of information that needs to be conveyed to the users.

        Figure 4: UI showing a single StoreEntity within Recommendations cluster.
      • PointOfInterestEntity: PointOfInterestEntity represents a place of interest like, a gas station, event venue, theme park, museum, tourist attraction, hiking trail etc. It highlights content where location is a critical piece of information that needs to be conveyed to the users. It shouldn't be used for lodging, a store or a dining venue.

        Figure 5: UI showing a single PointOfInterestEntity within Recommendations cluster.
  • The Reservation cluster shows content recently engaged by users from multiple developer partners in a single UI grouping. Each developer partner will be allowed to broadcast a maximum of 10 entities in the Reservation cluster.

    Your reservation content can take the following structure:

    • RestaurantReservationEntity: RestaurantReservationEntity represents a reservation for a restaurant or cafe and helps users track upcoming or ongoing restaurant reservations.

      Figure 6. UI showing a single RestaurantReservationEntity within a Reservation cluster.
    • EventReservationEntity: EventReservationEntity represents a reservation for an event and helps users track upcoming or ongoing events reservations. Events could include, but not limited to the following:

      • Sports events like reservation for a football match
      • Gaming events like reservation for eSports
      • Entertainment events like reservation for movies in a cinema, concert, theater, book signing
      • Travel or point of interest reservations like guided tours, museum tickets
      • Social / Seminar / Conferences reservations
      • Education / Training sessions reservations
      Figure 7. UI showing a single EventReservationEntity within a Reservation cluster.
    • LodgingReservationEntity: LodgingEntityReservation represents a reservation for travel lodging and helps users track upcoming or ongoing hotel or vacation rental reservations.

      Figure 8. UI showing a single LodgingReservationEntity within a Reservation cluster.
    • TransportationReservationEntity: TransportationReservationEntity represents reservation for transportation by any mode and helps users track reservations for upcoming or ongoing flight, ferry, train, bus, ride-hailing, or cruise.

      Figure 9. UI showing a single TransportationReservationEntity within a Reservation cluster.
    • VehicleRentalReservationEntity: VehicleRentalReservationEntity represents vehicle rental reservation and helps users track upcoming or ongoing vehicle rental reservations.

      Figure 10. UI showing a single VehicleRentalReservationEntity within a Reservation cluster.
  • The Featured cluster showcases a selection of entities from multiple developer partners in one UI grouping. There will be a single Featured cluster, which is surfaced near the top of the UI with a priority placement above all Recommendation clusters. Each developer partner will be allowed to broadcast up to 10 entities in the Featured cluster.

    • GenericFeaturedEntity: GenericFeaturedEntity differs from Recommendation item in that Featured item should be used for a single top content from developers and should represent the single most important content that will be interesting and relevant to users.

      Figure 11: UI showing a FeaturedCluster with a list of GenericFeaturedEntity
  • The Continue Search cluster helps users resume their previous travel search journey by showcasing a list of search queries that the user has recently searched for across all their travel apps. The cluster will be pinned in second position, after reservations and before featured and recommendation clusters. Each developer partner will be allowed to broadcast up to 3 entities in the Continue Search cluster.

    • PointOfInterestEntity: PointOfInterestEntity represents a place of interest like, a gas station, event venue, theme park, museum, tourist attraction, hiking trail etc. It highlights content the user has previously searched for.

Pre-work

Minimum API level: 19

Add the com.google.android.engage:engage-core library to your app:

dependencies {
    // Make sure you also include that repository in your project's build.gradle file.
    implementation 'com.google.android.engage:engage-core:1.6.0'
}

Summary

The design is based on an implementation of a bound service.

The data a client can publish is subject to the following limits for different cluster types:

Cluster type Cluster limits Minimum entity limits in a cluster Maximum entity limits in a cluster
Recommendation Cluster(s) At most 7 At least 1 At most 50 (ArticleEntity, EventEntity, LodgingEntity, StoreEntity, or PointOfInterestEntity)
Reservation Cluster At most 1 At least 1 At most 20 (RestaurantReservationEntity, EventReservationEntity, LodgingReservationEntity, TransportationReservationEntity, or VehicleRentalReservationEntity)
Featured Cluster At most 1 At least 1 At most 20 (GenericFeaturedEntity)
Continue Search Cluster At most 1 At least 1 At most 3 (PointOfInterestEntity)

Step 1: Provide entity data

The SDK has defined different entities to represent each item type. We support the following entities for the Travel & Events category:

  1. GenericFeaturedEntity
  2. ArticleEntity
  3. EventEntity
  4. LodgingEntity
  5. StoreEntity
  6. PointOfInterestEntity
  7. RestaurantReservationEntity
  8. EventReservationEntity
  9. LodgingReservationEntity
  10. TransportationReservationEntity
  11. VehicleRentalReservationEntity

The charts below outline available attributes and requirements for each type.

GenericFeaturedEntity

Attribute Requirement Description Format
Action Uri Required

Deep Link to the entity in the provider app.

Note: You can use deep links for attribution. Refer to this FAQ

Uri
Poster images Required

We will show only 1 image when multiple images are provided. Recommended aspect ratio is 16:9

Note: If a badge is provided, ensure safe space of 24 dps at both the top and bottom of the image

See Image Specifications for guidance.
Title Optional Title of the entity.

Free text

Recommended text size: 50 chars

Description Optional

A single paragraph of text to describe the entity.

Note: Either description or subtitle list will be displayed to the user, not both.

Free text

Recommended text size: 180 chars

Subtitle list Optional

Up to 3 subtitles, with each subtitle a single line of text.

Note: Either description or subtitle list will be displayed to the user, not both.

Free text

Recommended text size for each subtitle: max 50 chars

Badges Optional

Each badge is either free text (max 15 chars) or small image.

Special UX treatment on top of image/video, For example, as badge overlay on the image

  • "Live update"
  • Article read duration
Badge - Text Optional

Title for the badge

Note: Either text or image is required for the badge

Free text

Recommended text size: max 15 chars

Badge - Image Optional

Small image

Special UX treatment, for example as badge overlay on the image/video thumbnail.

Note: Either text or image is required for the badge

See Image Specifications for guidance.
Content Categories Optional Describe the category of the content in the entity.

List of Enums

See the Content Category section for guidance.

DisplayTimeWindow (Optional) - Set a time window for a content to be shown on the surface
Start Timestamp Optional

The epoch timestamp after which the content should be shown on the surface.

If not set, content is eligible to be shown on the surface.

Epoch timestamp in milliseconds
End Timestamp Optional

The epoch timestamp after which the content is no longer shown on the surface.

If not set, content is eligible to be shown on the surface.

Epoch timestamp in milliseconds

ArticleEntity

Attribute Requirement Description Format
Action Uri Required

Deep Link to the entity in the provider app.

Note: You can use deep links for attribution. Refer to this FAQ

Uri
Title Required Title of the entity.

Free text

Recommended text size: Max 50 chars

Poster images Optional

We will show only 1 image when multiple images are provided. Recommended aspect ratio is 16:9

Note: Image is highly recommended. If a badge is provided, ensure safe space of 24 dps at both the top and bottom of the image

See Image Specifications for guidance.
Source - Title Optional The name of the author, organization, or reporter

Free text

Recommended text size: Under 25 chars

Source - Image Optional An image of the source like the author, the organization, reporter See Image Specifications for guidance.
Description Optional

A single paragraph of text to describe the entity.

Note: Either description or subtitle list will be displayed to the user, not both.

Free text

Recommended text size: 180 chars

Subtitle list Optional

Up to 3 subtitles, with each subtitle a single line of text.

Note: Either description or subtitle list will be displayed to the user, not both.

Free text

Recommended text size for each subtitle: max 50 chars

Badges Optional

Each badge is either free text (max 15 chars) or small image.

Special UX treatment on top of image/video, for example, as badge overlay on the image

  • "Live update"
  • Article read duration
Badge - Text Optional

Title for the badge

Note: Either text or image is required for the badge

Free text

Recommended text size: max 15 chars

Badge - Image Optional

Small image

Special UX treatment, for example as badge overlay on the image/video thumbnail.

Note: Either text or image is required for the badge

See Image Specifications for guidance.
Content Publish Time Optional This is the epoch timestamp in milliseconds on when the content was published / updated in the app. Epoch timestamp in milliseconds
Last Engagement Time Optional

The epoch timestamp in milliseconds when the user interacted with this entity last time.

Epoch timestamp in milliseconds
Progress Percentage Optional

The percentage of the full content consumed by the user to date.

An int value between 0~100 inclusive.
Content Categories Optional Describe the category of the content in the entity.

List of Enums

See the Content Category section for guidance.

DisplayTimeWindow (Optional) - Set a time window for a content to be shown on the surface
Start Timestamp Optional

The epoch timestamp after which the content should be shown on the surface.

If not set, content is eligible to be shown on the surface.

Epoch timestamp in milliseconds
End Timestamp Optional

The epoch timestamp after which the content is no longer shown on the surface.

If not set, content is eligible to be shown on the surface.

Epoch timestamp in milliseconds

EventEntity

Attribute Requirement Description Format
Action Uri Required

Deep Link to the entity in the provider app.

Note: You can use deep links for attribution. Refer to this FAQ

Uri
Title Required Title of the entity.

String

Recommended text size: Max 50 chars

Localized Start time - Timestamp Required

The epoch timestamp when the event is expected to start.

Joda-Time Instant
Localized Start time - Timezone Required

The timezone in which the event is expected to start.

Joda-Time DateTimeZone

See Timezone Specifications for guidance.

Event mode Required

A field to indicate whether the event will be virtual, in-person or both.

Enum: VIRTUAL, IN_PERSON, or HYBRID
Poster images Required

We will show only 1 image when multiple images are provided. Recommended aspect ratio is 16:9

Note: Image is highly recommended. If a badge is provided, ensure safe space of 24 dps at both the top and bottom of the image

See Image Specifications for guidance.
Location - Country Conditionally required

The country in which the event is happening.

Note: This is required for events which are IN_PERSON or HYBRID

Free text

Recommended text size: max ~20 chars

Location - City Conditionally required

The city in which the event is happening.

Note: This is required for events which are IN_PERSON or HYBRID

Free text

Recommended text size: max ~20 chars

Location - Display Address Conditionally required

The address or venue name where the event will take place that should be displayed to the user.

Note: This is required for events which are IN_PERSON or HYBRID

Free text

Recommended text size: max ~20 chars

Location - Street Address Optional The street address (if applicable) of the location at which event is being hosted.

Free text

Recommended text size: max ~20 chars

Location - State Optional The state or province (if applicable) in which the event is being hosted.

Free text

Recommended text size: max ~20 chars

Location - Zip code Optional The zip code (if applicable) of the location in which the event is being hosted.

Free text

Recommended text size: max ~20 chars

Location - Neighborhood Optional The neighborhood (if applicable) in which the event is being hosted.

Free text

Recommended text size: max ~20 chars

End time Optional

The epoch timestamp when the event is expected to end.

Note:This will be represented in milliseconds.

Epoch timestamp in milliseconds
Description Optional

A single paragraph of text to describe the entity.

Note: Either description or subtitle list will be displayed to the user, not both.

Free text

Recommended text size: 180 chars

Subtitle list Optional

Up to 3 subtitles, with each subtitle a single line of text.

Note: Either description or subtitle list will be displayed to the user, not both.

Free text

Recommended text size for each subtitle: max 50 chars

Badges Optional

Each badge is either free text (max 15 chars) or small image.

Badge - Text Optional

Title for the badge

Note: Either text or image is required for the badge

Free text

Recommended text size: max 15 chars

Badge - Image Optional

Small image

Special UX treatment, for example as badge overlay on the image/video thumbnail.

Note: Either text or image is required for the badge

See Image Specifications for guidance.
Price - CurrentPrice Conditionally required

The current price of the ticket/pass for the event.

Must be provided if strikethrough price is provided.

Free text
Price - StrikethroughPrice Optional The original price of the ticket/pass for the event. Free text
Price Callout Optional Price callout to feature a promo, event, member discount, if available.

Free text

Recommended text size: under 45 chars (Text that is too long may show ellipses)

Content Categories Optional Describe the category of the content in the entity.

List of Eligible Enums

  • TYPE_MOVIES_AND_TV_SHOWS (Example - Cinema)
  • TYPE_DIGITAL_GAMES (Example - eSports)
  • TYPE_MUSIC (Example - Concert)
  • TYPE_TRAVEL_AND_LOCAL (Example - Tour, festival)
  • TYPE_HEALTH_AND_FITENESS (Example - Yoga class)
  • TYPE_EDUCATION (Example - Class)
  • TYPE_SPORTS (Example - Football game)
  • TYPE_DATING (Example - meetup)

See the Content Category section for guidance.

DisplayTimeWindow (Optional) - Set a time window for a content to be shown on the surface
Start Timestamp Optional

The epoch timestamp after which the content should be shown on the surface.

If not set, content is eligible to be shown on the surface.

Epoch timestamp in milliseconds
End Timestamp Optional

The epoch timestamp after which the content is no longer shown on the surface.

If not set, content is eligible to be shown on the surface.

Epoch timestamp in milliseconds

LodgingEntity

Attribute Requirement Description Format
Action Uri Required

Deep Link to the entity in the provider app.

Note: You can use deep links for attribution. Refer to this FAQ

Uri
Title Required Title of the entity.

String

Recommended text size: Max 50 chars

Poster images Required

We will show only 1 image when multiple images are provided. Recommended aspect ratio is 16:9

Note: If a badge is provided, ensure safe space of 24 dps at both the top and bottom of the image

See Image Specifications for guidance.
Location - Country Required The country in which the lodging is happening.

Free text

Recommended text size: max ~20 chars

Location - City Required The city in which the lodging is happening.

Free text

Recommended text size: max ~20 chars

Location - Display Address Required The address that will be displayed to the user. We recommend including the city name and possibly state or country for most use cases. Only include the street address or neighborhood if the user is near the location, the user is familiar with the location, or the city is included in the cluster title. If you include the street address, provide a succinct address, using abbreviations where possible (for example, "St" for "Street", "Ave" for "Avenue").

Free text

Recommended text size: max ~20 chars

Location - Street Address Optional The street address (if applicable) of the lodging.

Free text

Recommended text size: max ~20 chars

Location - State Optional The state or province (if applicable) in which the lodging is located.

Free text

Recommended text size: max ~20 chars

Location - Zip code Optional The zip code (if applicable) of the lodging.

Free text

Recommended text size: max ~20 chars

Location - Neighborhood Optional The neighborhood (if applicable) of the lodging.

Free text

Recommended text size: max ~20 chars

Badges Optional

Each badge is either free text (max 15 chars) or small image.

Badge - Text Optional

Title for the badge

Note: Either text or image is required for the badge

Free text

Recommended text size: max 15 chars

Badge - Image Optional

Small image

Special UX treatment, for example as badge overlay on the image/video thumbnail.

Note: Either text or image is required for the badge

See Image Specifications for guidance.
Description Optional

A single paragraph of text to describe the entity.

Note: Either description or subtitle list will be displayed to the user, not both.

Free text

Recommended text size: 180 chars

Subtitle list Optional

Up to 3 subtitles, with each subtitle a single line of text.

Note: Either description or subtitle list will be displayed to the user, not both.

Free text

Recommended text size for each subtitle: max 50 chars

AvailabilityTimeWindow - Localized Start Time - Timestamp Optional The epoch timestamp when the lodging is expected to be open/available. Joda-Time Instant
AvailabilityTimeWindow - Localized Start Time - Timezone Optional The timezone in which the lodging is expected to be open/available.

Joda-Time DateTimeZone

See Timezone Specifications for guidance.

AvailabilityTimeWindow - Localized End Time - Timestamp Optional The epoch timestamp until which the lodging is expected to be open/available. Joda-Time Instant
AvailabilityTimeWindow - Localized End Time - Timezone Optional The timezone in which the lodging is expected to be open/available.

Joda-Time DateTimeZone

See Timezone Specifications for guidance.

Rating - Max value Optional

The maximum value of the rating scale.

Must be provided if current value of rating is also provided.

Number >= 0.0
Rating - Current value Optional

The current value of the rating scale.

Must be provided if maximum value of rating is also provided.

Number >= 0.0
Rating - Count Optional

The count of the ratings for the lodging.

Note: Provide this field if your app wants to control how this is displayed to the users. Provide the concise string that can be displayed to the user. For example, if the count is 1,000,000, consider using abbreviations like 1M, so that it won't be truncated on smaller display sizes.

String
Rating - Count Value Optional

The count of the ratings for the lodging.

Note: Provide this field if you don't want to handle the display abbreviation logic yourself. If both Count and Count Value are present, we will use the Count to display to users

Long
Price - CurrentPrice Conditionally required

The current price of the lodging.

Must be provided if strikethrough price is provided.

Free text
Price - StrikethroughPrice Optional The original price of the lodging, which is be struck-through in the UI. Free text
Price Callout Optional Price callout to feature a promo, event, member discount, if available.

Free text

Recommended text size: under 45 chars (Text that is too long may show ellipses)

DisplayTimeWindow (Optional) - Set a time window for a content to be shown on the surface
Start Timestamp Optional

The epoch timestamp after which the content should be shown on the surface.

If not set, content is eligible to be shown on the surface.

Epoch timestamp in milliseconds
End Timestamp Optional

The epoch timestamp after which the content is no longer shown on the surface.

If not set, content is eligible to be shown on the surface.

Epoch timestamp in milliseconds

StoreEntity

The StoreEntity object represents an individual store that developer partners want to publish, such as a popular dining place or eatery that are relevant to one's travel experience.

Attribute Requirement Description Format
Poster images Required At least one image must be provided. See Image Specifications for guidance.
Action Uri Required

Deep Link to the entity in the provider app.

Note: You can use deep links for attribution. Refer to this FAQ

Uri
Title Optional The name of the store.

Free text

Recommended text size: under 45 chars (Text that is too long may show ellipses)

Location Optional The location of the store.

Free text

Recommended text size: under 45 chars (Text that is too long may show ellipses)

Callout Optional Callout to feature a promo, event, or update for the store, if available.

Free text

Recommended text size: under 45 chars (Text that is too long may show ellipses)

Callout fine print Optional Fine print text for the callout.

Free text

Recommended text size: under 45 chars (Text that is too long may show ellipses)

Description Optional A description of the store.

Free text

Recommended text size: under 90 chars (Text that is too long may show ellipses)

Category Optional

Category of a store, in the context of dining places, it can be cuisine like "french", "new american", "ramen", "fine dining".

Free text

Recommended text size: under 45 chars (Text that is too long may show ellipses)

Rating - Max value Optional

The maximum value of the rating scale.

Must be provided if current value of rating is also provided.

Number >= 0.0
Rating - Current value Optional

The current value of the rating scale.

Must be provided if maximum value of rating is also provided.

Number >= 0.0
Rating - Count Optional

The count of the ratings for the lodging.

Note: Provide this field if your app wants to control how this is displayed to the users. Provide the concise string that can be displayed to the user. For example, if the count is 1,000,000, consider using abbreviations like 1M, so that it won't be truncated on smaller display sizes.

String
Rating - Count Value Optional

The count of the ratings for the lodging.

Note: Provide this field if you don't want to handle the display abbreviation logic yourself. If both Count and Count Value are present, we will use the Count to display to users

Long
DisplayTimeWindow (Optional) - Set a time window for a content to be shown on the surface
Start Timestamp Optional

The epoch timestamp after which the content should be shown on the surface.

If not set, content is eligible to be shown on the surface.

Epoch timestamp in milliseconds
End Timestamp Optional

The epoch timestamp after which the content is no longer shown on the surface.

If not set, content is eligible to be shown on the surface.

Epoch timestamp in milliseconds

PointOfInterestEntity

Attribute Requirement Description Format
Action Uri Required

Deep Link to the entity in the provider app.

Note: You can use deep links for attribution. Refer to this FAQ

Uri
Title Required Title of the entity.

String

Recommended text size: Max 50 chars

Poster images Conditionally required

We will show only 1 image when multiple images are provided. Recommended aspect ratio is 16:9

Note: Image is required if the entity is part of recommendation cluster. If a badge is provided, ensure safe space of 24 dps at both the top and bottom of the image

See Image Specifications for guidance.
Last Engagement Time Conditionally required

The epoch timestamp when the user last interacted with this entity.

Note: This field is required if the entity is part of continue search cluster.

Joda-Time Instant
Location - Country Conditionally required

The country in which the point of interest is happening.

Note: This field is required if the entity is part of recommendation cluster.

Free text

Recommended text size: max ~20 chars

Location - City Conditionally required

The city in which the point of interest is happening.

Note: This field is required if the entity is part of recommendation cluster.

Free text

Recommended text size: max ~20 chars

Location - Display Address Conditionally required

The address that will be displayed to the user. Provide a succinct address, using abbreviations where possible (for example, "St" for "Street", "Ave" for "Avenue"). This string may be truncated depending on the user's device and settings. Include the city name for clear identification.

Note: This field is required if the entity is part of recommendation cluster.

Free text

Recommended text size: max ~35 chars

Location - Street Address Optional The street address (if applicable) of the point of interest.

Free text

Recommended text size: max ~20 chars

Location - State Optional The state or province (if applicable) in which the point of interest is located.

Free text

Recommended text size: max ~20 chars

Location - Zip code Optional The zip code (if applicable) of the point of interest.

Free text

Recommended text size: max ~20 chars

Location - Neighborhood Optional The neighborhood (if applicable) of the point of interest.

Free text

Recommended text size: max ~20 chars

AvailabilityTimeWindow - Localized Start Time - Timestamp Optional The epoch timestamp when the point of interest is expected to be open/available. Joda-Time Instant
AvailabilityTimeWindow - Localized Start Time - Timezone Optional The timezone in which the point of interest is expected to be open/available.

Joda-Time DateTimeZone

See Timezone Specifications for guidance.

AvailabilityTimeWindow - Localized End Time - Timestamp Optional The epoch timestamp until which the point of interest is expected to be open/available. Joda-Time Instant
AvailabilityTimeWindow - Localized End Time - Timezone Optional The timezone in which the point of interest is expected to be open/available.

Joda-Time DateTimeZone

See Timezone Specifications for guidance.

Badges Optional

Each badge is either free text (max 15 chars) or small image.

Badge - Text Optional

Title for the badge

Note: Either text or image is required for the badge

Free text

Recommended text size: max 15 chars

Badge - Image Optional

Small image

Special UX treatment, for example as badge overlay on the image/video thumbnail.

Note: Either text or image is required for the badge

See Image Specifications for guidance.
Description Optional

A single paragraph of text to describe the entity.

Note: Either description or subtitle list will be displayed to the user, not both.

Free text

Recommended text size: 180 chars

Subtitle list Optional

Up to 3 subtitles, with each subtitle a single line of text.

Note: Either description or subtitle list will be displayed to the user, not both.

Free text

Recommended text size for each subtitle: max 50 chars

Rating - Max value Optional

The maximum value of the rating scale.

Must be provided if current value of rating is also provided.

Number >= 0.0
Rating - Current value Optional

The current value of the rating scale.

Must be provided if maximum value of rating is also provided.

Number >= 0.0
Rating - Count Optional

The count of the ratings for the point of interest.

Note: Provide this field if your app wants to control how this is displayed to the users. Provide the concise string that can be displayed to the user. For example, if the count is 1,000,000, consider using abbreviations like 1M, so that it won't be truncated on smaller display sizes.

String
Rating - Count Value Optional

The count of the ratings for the point of interest.

Note: Provide this field if you don't want to handle the display abbreviation logic yourself. If both Count and Count Value are present, we will use the Count to display to users

Long
Price - CurrentPrice Conditionally required

The current price of the tickets/entry pass for the point of interest.

Must be provided if strikethrough price is provided.

Free text
Price - StrikethroughPrice Optional The original price of the tickets/entry pass for the point of interest. Free text
Price Callout Optional Price callout to feature a promo, event, member discount, if available.

Free text

Recommended text size: under 45 chars (Text that is too long may show ellipses)

Content Categories Optional Describe the category of the content in the entity.

List of Eligible Enums

  • TYPE_TRAVEL_AND_LOCAL
  • TYPE_MOVIES_AND_TV_SHOWS (Example - theater)
  • TYPE_MEDICAL (Example - hospital)
  • TYPE_EDUCATION (Example - school)
  • TYPE_SPORTS (Example - stadium)

See the Content Category section for guidance.

DisplayTimeWindow (Optional) - Set a time window for a content to be shown on the surface
Start Timestamp Optional

The epoch timestamp after which the content should be shown on the surface.

If not set, content is eligible to be shown on the surface.

Epoch timestamp in milliseconds
End Timestamp Optional

The epoch timestamp after which the content is no longer shown on the surface.

If not set, content is eligible to be shown on the surface.

Epoch timestamp in milliseconds

RestaurantReservationEntity

Attribute Requirement Description Format
Action Uri Required

Deep Link to the entity in the provider app.

Note: You can use deep links for attribution. Refer to this FAQ

Uri
Title Required Title of the entity.

String

Recommended text size: Max 50 chars

Localized Reservation Start Time - Timestamp Required The epoch timestamp when the reservation is expected to start. Joda-Time Instant
Localized Reservation Start Time - Timezone Required The timezone in which the reservation is expected to start.

Joda-Time DateTimeZone

See Timezone Specifications for guidance.

Location - Country Required The country in which the restaurant is happening.

Free text

Recommended text size: max ~20 chars

Location - City Required The city in which the restaurant is happening.

Free text

Recommended text size: max ~20 chars

Location - Display Address Required The address of the prestaurant that will be displayed to the user.

Free text

Recommended text size: max ~20 chars

Location - Street Address Optional The street address (if applicable) of the restaurant.

Free text

Recommended text size: max ~20 chars

Location - State Optional The state or province (if applicable) in which the restaurant is located.

Free text

Recommended text size: max ~20 chars

Location - Zip code Optional The zip code (if applicable) of the restaurant.

Free text

Recommended text size: max ~20 chars

Location - Neighborhood Optional The neighborhood (if applicable) of the restaurant.

Free text

Recommended text size: max ~20 chars

Poster images Optional We will show only 1 image when multiple images are provided. Recommended aspect ratio is 16:9 See Image Specifications for guidance.
Description Optional

A single paragraph of text to describe the entity.

Note: Either description or subtitle list will be displayed to the user, not both.

Free text

Recommended text size: 180 chars

Subtitle list Optional

Up to 3 subtitles, with each subtitle a single line of text.

Note: Either description or subtitle list will be displayed to the user, not both.

Free text

Recommended text size for each subtitle: max 50 chars

Table Size Optional The number of people in the reservation group Integer > 0
DisplayTimeWindow (Optional) - Set a time window for a content to be shown on the surface
Start Timestamp Optional

The epoch timestamp after which the content should be shown on the surface.

If not set, content is eligible to be shown on the surface.

Epoch timestamp in milliseconds
End Timestamp Optional

The epoch timestamp after which the content is no longer shown on the surface.

If not set, content is eligible to be shown on the surface.

Epoch timestamp in milliseconds

EventReservationEntity

Attribute Requirement Description Format
Action Uri Required

Deep Link to the entity in the provider app.

Note: You can use deep links for attribution. Refer to this FAQ

Uri
Title Required Title of the entity.

String

Recommended text size: Max 50 chars

Localized Start time - Timestamp Required

The epoch timestamp when the event is expected to start.

Joda-Time Instant
Localized Start time - Timezone Required

The timezone in which the event is expected to start.

Joda-Time DateTimeZone

See Timezone Specifications for guidance.

Event mode Required

A field to indicate whether the event will be virtual, in-person or both.

Enum: VIRTUAL, IN_PERSON, or HYBRID
Location - Country Conditionally required

The country in which the event is happening.

Note: This is required for events which are IN_PERSON or HYBRID

Free text

Recommended text size: max ~20 chars

Location - City Conditionally required

The city in which the event is happening.

Note: This is required for events which are IN_PERSON or HYBRID

Free text

Recommended text size: max ~20 chars

Location - Display Address Conditionally required

The address or venue name where the event will take place that should be displayed to the user.

Note: This is required for events which are IN_PERSON or HYBRID

Free text

Recommended text size: max ~20 chars

Location - Street Address Optional The street address (if applicable) of the location at which event is being hosted.

Free text

Recommended text size: max ~20 chars

Location - State Optional The state or province (if applicable) in which the event is being hosted.

Free text

Recommended text size: max ~20 chars

Location - Zip code Optional The zip code (if applicable) of the location in which the event is being hosted.

Free text

Recommended text size: max ~20 chars

Location - Neighborhood Optional The neighborhood (if applicable) in which the event is being hosted.

Free text

Recommended text size: max ~20 chars

Poster images Optional

We will show only 1 image when multiple images are provided. Recommended aspect ratio is 16:9

Note: Image is highly recommended. If a badge is provided, ensure safe space of 24 dps at both the top and bottom of the image

See Image Specifications for guidance.
Localized End time - Timestamp Optional

The epoch timestamp when the event is expected to end.

Joda-Time Instant
Localized End time - Timezone Optional

The timezone in which the event is expected to end.

Joda-Time DateTimeZone

See Timezone Specifications for guidance.

Service Provider - Name Optional

The name of the service provider.

Note:Either text or image is required for the service provider.

Free text. For example, name of the event organizer/tour
Service Provider - Image Optional

The logo/image of the service provider.

Note:Either text or image is required for the service provider.

See Image Specifications for guidance.
Description Optional

A single paragraph of text to describe the entity.

Note: Either description or subtitle list will be displayed to the user, not both.

Free text

Recommended text size: 180 chars

Subtitle list Optional

Up to 3 subtitles, with each subtitle a single line of text.

Note: Either description or subtitle list will be displayed to the user, not both.

Free text

Recommended text size for each subtitle: max 50 chars

Badges Optional

Each badge is either free text (max 15 chars) or small image.

Badge - Text Optional

Title for the badge

Note: Either text or image is required for the badge

Free text

Recommended text size: max 15 chars

Badge - Image Optional

Small image

Special UX treatment, for example as badge overlay on the image/video thumbnail.

Note: Either text or image is required for the badge

See Image Specifications for guidance.
Reservation ID Optional The reservation ID for the event reservation. Free text
Price - CurrentPrice Conditionally required

The current price of the ticket/pass for the event.

Must be provided if strikethrough price is provided.

Free text
Price - StrikethroughPrice Optional The original price of the ticket/pass for the event. Free text
Price Callout Optional Price callout to feature a promo, event, member discount, if available.

Free text

Recommended text size: under 45 chars (Text that is too long may show ellipses)

Rating - Max value Optional

The maximum value of the rating scale.

Must be provided if current value of rating is also provided.

Number >= 0.0
Rating - Current value Optional

The current value of the rating scale.

Must be provided if maximum value of rating is also provided.

Number >= 0.0
Rating - Count Optional

The count of the ratings for the event.

Note: Provide this field if your app wants to control how this is displayed to the users. Provide the concise string that can be displayed to the user. For example, if the count is 1,000,000, consider using abbreviations like 1M, so that it won't be truncated on smaller display sizes.

String
Rating - Count Value Optional

The count of the ratings for the event.

Note: Provide this field if you don't want to handle the display abbreviation logic yourself. If both Count and Count Value are present, we will use the Count to display to users

Long
Content Categories Optional Describe the category of the content in the entity.

List of Eligible Enums

  • TYPE_MOVIES_AND_TV_SHOWS (Example - Cinema)
  • TYPE_DIGITAL_GAMES (Example - eSports)
  • TYPE_MUSIC (Example - Concert)
  • TYPE_TRAVEL_AND_LOCAL (Example - Tour, festival)
  • TYPE_HEALTH_AND_FITENESS (Example - Yoga class)
  • TYPE_EDUCATION (Example - Class)
  • TYPE_SPORTS (Example - Football game)
  • TYPE_DATING (Example - meetup)

See the Content Category section for guidance.

DisplayTimeWindow (Optional) - Set a time window for a content to be shown on the surface
Start Timestamp Optional

The epoch timestamp after which the content should be shown on the surface.

If not set, content is eligible to be shown on the surface.

Epoch timestamp in milliseconds
End Timestamp Optional

The epoch timestamp after which the content is no longer shown on the surface.

If not set, content is eligible to be shown on the surface.

Epoch timestamp in milliseconds

LodgingReservationEntity

Attribute Requirement Description Format
Action Uri Required

Deep Link to the entity in the provider app.

Note: You can use deep links for attribution. Refer to this FAQ

Uri
Title Required Title of the entity.

Free text. For example, "Your Stay from Dec 12th"

Recommended text size: Max 50 chars

Localized Check-in Time - Timestamp Required The epoch timestamp that represents the check in time for the reservation. Joda-Time Instant
Localized Check-in Time - Timezone Required The timezone in which the check in time exists for the reservation.

Joda-Time DateTimeZone

See Timezone Specifications for guidance.

Localized Check-out Time - Timestamp Required The epoch timestamp that represents the check out time for the reservation. Joda-Time Instant
Localized Check-out Time - Timezone Required The timezone in which the check out time exists for the reservation.

Joda-Time DateTimeZone

See Timezone Specifications for guidance.

Location - Country Required The country in which the lodging is located.

Free text

Recommended text size: max ~20 chars

Location - City Required The city in which the lodging is located.

Free text

Recommended text size: max ~20 chars

Location - Display Address Required The address that will be displayed to the user. Provide a succinct address, using abbreviations where possible (for example, "St" for "Street", "Ave" for "Avenue"). This string may be truncated depending on the user's device and settings. Include the city name for clear identification.

Free text

Recommended text size: max ~35 chars

Location - Street Address Optional The street address (if applicable) of the lodging.

Free text

Recommended text size: max ~20 chars

Location - State Optional The state or province (if applicable) in which the lodging is located.

Free text

Recommended text size: max ~20 chars

Location - Zip code Optional The zip code (if applicable) of the lodging.

Free text

Recommended text size: max ~20 chars

Location - Neighborhood Optional The neighborhood (if applicable) of the lodging.

Free text

Recommended text size: max ~20 chars

Poster images Optional

We will show only 1 image when multiple images are provided. Recommended aspect ratio is 16:9

Note: If a badge is provided, ensure safe space of 24 dps at both the top and bottom of the image

See Image Specifications for guidance.
Description Optional

A single paragraph of text to describe the entity.

Note: Either description or subtitle list will be displayed to the user, not both.

Free text

Recommended text size: 180 chars

Subtitle list Optional

Up to 3 subtitles, with each subtitle a single line of text.

Note: Either description or subtitle list will be displayed to the user, not both.

Free text

Recommended text size for each subtitle: max 50 chars

Reservation ID Optional The reservation ID for the lodging reservation. Free text
Rating - Max value Optional

The maximum value of the rating scale.

Must be provided if current value of rating is also provided.

Number >= 0.0
Rating - Current value Optional

The current value of the rating scale.

Must be provided if maximum value of rating is also provided.

Number >= 0.0
Rating - Count Optional

The count of the ratings for the lodging.

Note: Provide this field if your app wants to control how this is displayed to the users. Provide the concise string that can be displayed to the user. For example, if the count is 1,000,000, consider using abbreviations like 1M, so that it won't be truncated on smaller display sizes.

String
Rating - Count Value Optional

The count of the ratings for the lodging.

Note: Provide this field if you don't want to handle the display abbreviation logic yourself. If both Count and Count Value are present, we will use the Count to display to users

Long
Price - CurrentPrice Conditionally required

The current price of the lodging.

Must be provided if strikethrough price is provided.

Free text
Price - StrikethroughPrice Optional The original price of the lodging, which is be struck-through in the UI. Free text
Price Callout Optional Price callout to feature a promo, event, member discount, if available.

Free text

Recommended text size: under 45 chars (Text that is too long may show ellipses)

DisplayTimeWindow (Optional) - Set a time window for a content to be shown on the surface
Start Timestamp Optional

The epoch timestamp after which the content should be shown on the surface.

If not set, content is eligible to be shown on the surface.

Epoch timestamp in milliseconds
End Timestamp Optional

The epoch timestamp after which the content is no longer shown on the surface.

If not set, content is eligible to be shown on the surface.

Epoch timestamp in milliseconds

TransportationReservationEntity

Attribute Requirement Description Format
Action Uri Required

Deep Link to the entity in the provider app.

Note: You can use deep links for attribution. Refer to this FAQ

Uri
Title Required Title of the entity.

Free text. For example, "SFO to SAN"

Recommended text size: Max 50 chars

Transportation Type Required The mode/type of transportation for the reservation. Enum: FLIGHT, TRAIN, BUS, or FERRY
Localized Departure Time - Timestamp Required The epoch timestamp that represents the departure time. Joda-Time Instant
Localized Departure Time - Timezone Required The timezone of the departure time.

Joda-Time DateTimeZone

See Timezone Specifications for guidance.

Localized Arrival Time - Timestamp Required The epoch timestamp that represents the arrival time. Joda-Time Instant
Localized Arrival Time - Timezone Required The timezone of the arrival time.

Joda-Time DateTimeZone

See Timezone Specifications for guidance.

Transportation Number Required The flight number, bus number, train number, or ferry/cruise number. Free text
Localized Boarding Time - Timestamp Required The epoch timestamp that represents the boarding time for the reservation (if applicable) Joda-Time Instant
Localized Boarding Time - Timezone Required The timezone of the boarding time for the reservation (if applicable)

Joda-Time DateTimeZone

See Timezone Specifications for guidance.

Departure Location - Country Optional The country of departure.

Free text

Recommended text size: max ~20 chars

Departure Location - City Optional The city of departure.

Free text

Recommended text size: max ~20 chars

Departure Location - Display Address Optional The location of departure that will be displayed to the user.

Free text

Recommended text size: max ~20 chars

Departure Location - Street Address Optional The street address (if applicable) of the departure location.

Free text

Recommended text size: max ~20 chars

Departure Location - State Optional The state or province (if applicable) of the departure location.

Free text

Recommended text size: max ~20 chars

Departure Location - Zip code Optional The zip code (if applicable) of the departure location.

Free text

Recommended text size: max ~20 chars

Departure Location - Neighborhood Optional The neighborhood (if applicable) of the departure location.

Free text

Recommended text size: max ~20 chars

Arrival Location - Country Optional The country of arrival.

Free text

Recommended text size: max ~20 chars

Arrival Location - City Optional The city of arrival.

Free text

Recommended text size: max ~20 chars

Arrival Location - Display Address Optional The location of arrival that will be displayed to the user.

Free text

Recommended text size: max ~20 chars

Arrival Location - Street Address Optional The street address (if applicable) of the arrival location.

Free text

Recommended text size: max ~20 chars

Arrival Location - State Optional The state or province (if applicable) of the arrival location.

Free text

Recommended text size: max ~20 chars

Arrival Location - Zip code Optional The zip code (if applicable) of the arrival location.

Free text

Recommended text size: max ~20 chars

Arrival Location - Neighborhood Optional The neighborhood (if applicable) of the arrival location.

Free text

Recommended text size: max ~20 chars

Service Provider - Name Optional

The name of the service provider.

Note:Either text or image is required for the service provider.

Free text. For example, Airline name
Service Provider - Image Optional

The logo/image of the service provider.

Note:Either text or image is required for the service provider.

See Image Specifications for guidance.
Poster images Optional

We will show only 1 image when multiple images are provided. Recommended aspect ratio is 16:9

See Image Specifications for guidance.
Description Optional

A single paragraph of text to describe the entity.

Note: Either description or subtitle list will be displayed to the user, not both.

Free text

Recommended text size: 180 chars

Subtitle list Optional

Up to 3 subtitles, with each subtitle a single line of text.

Note: Either description or subtitle list will be displayed to the user, not both.

Free text

Recommended text size for each subtitle: max 50 chars

Reservation ID Optional The reservation ID for the transportation reservation. Free text
Price - CurrentPrice Conditionally required

The current price of the reservation.

Must be provided if strikethrough price is provided.

Free text
Price - StrikethroughPrice Optional The original price of the reservation, which is be struck-through in the UI. Free text
Price Callout Optional Price callout to feature a promo, event, member discount, if available.

Free text

Recommended text size: under 45 chars (Text that is too long may show ellipses)

DisplayTimeWindow (Optional) - Set a time window for a content to be shown on the surface
Start Timestamp Optional

The epoch timestamp after which the content should be shown on the surface.

If not set, content is eligible to be shown on the surface.

Epoch timestamp in milliseconds
End Timestamp Optional

The epoch timestamp after which the content is no longer shown on the surface.

If not set, content is eligible to be shown on the surface.

Epoch timestamp in milliseconds

VehicleRentalReservationEntity

Attribute Requirement Description Format
Action Uri Required

Deep Link to the entity in the provider app.

Note: You can use deep links for attribution. Refer to this FAQ

Uri
Title Required Title of the entity.

Free text. For example, "Avis Union Square SF"

Recommended text size: Max 50 chars

Localized Pickup Time - Timestamp Required The epoch timestamp that represents the pick up time for the reservation. Joda-Time Instant
Localized Pickup Time - Timezone Required The timezone of the pick up time for the reservation.

Joda-Time DateTimeZone

See Timezone Specifications for guidance.

Localized Return Time - Timestamp Optional The epoch timestamp that represents the check out time for the reservation. Joda-Time Instant
Localized Return Time - Timezone Optional The timezone of the check out time for the reservation.

Joda-Time DateTimeZone

See Timezone Specifications for guidance.

Pickup Address - Country Optional The country of the pickup location.

Free text

Recommended text size: max ~20 chars

Pickup Address - City Optional The city of the pickup location.

Free text

Recommended text size: max ~20 chars

Pickup Address - Display Address Optional The pickup location that will be displayed to the user.

Free text

Recommended text size: max ~20 chars

Pickup Address - Street Address Optional The street address (if applicable) of the pickup location.

Free text

Recommended text size: max ~20 chars

Pickup Address - State Optional The state or province (if applicable) of the pickup location.

Free text

Recommended text size: max ~20 chars

Pickup Address - Zip code Optional The zip code (if applicable) of the pickup location.

Free text

Recommended text size: max ~20 chars

Pickup Address - Neighborhood Optional The neighborhood (if applicable) of the pickup location.

Free text

Recommended text size: max ~20 chars

Return Address - Country Optional The country of return location.

Free text

Recommended text size: max ~20 chars

Return Address - City Optional The city of return location.

Free text

Recommended text size: max ~20 chars

Return Address - Display Address Optional The return location that will be displayed to the user.

Free text

Recommended text size: max ~20 chars

Return Address - Street Address Optional The street address (if applicable) of the return location.

Free text

Recommended text size: max ~20 chars

Return Address - State Optional The state or province (if applicable) of the return location.

Free text

Recommended text size: max ~20 chars

Return Address - Zip code Optional The zip code (if applicable) of the return location.

Free text

Recommended text size: max ~20 chars

Return Address - Neighborhood Optional The neighborhood (if applicable) of the return location.

Free text

Recommended text size: max ~20 chars

Service Provider - Name Optional

The name of the service provider.

Note:Either text or image is required for the service provider.

Free text. For example, "Avis Car Rental"
Service Provider - Image Optional

The logo/image of the service provider.

Note:Either text or image is required for the service provider.

See Image Specifications for guidance.
Poster images Optional

We will show only 1 image when multiple images are provided. Recommended aspect ratio is 16:9

See Image Specifications for guidance.
Description Optional

A single paragraph of text to describe the entity.

Note: Either description or subtitle list will be displayed to the user, not both.

Free text

Recommended text size: 180 chars

Subtitle list Optional

Up to 3 subtitles, with each subtitle a single line of text.

Note: Either description or subtitle list will be displayed to the user, not both.

Free text

Recommended text size for each subtitle: max 50 chars

Confirmation ID Optional The confirmation ID for the vehicle rental reservation. Free text
Price - CurrentPrice Conditionally required

The current price of the reservation.

Must be provided if strikethrough price is provided.

Free text
Price - StrikethroughPrice Optional The original price of the reservation, which is be struck-through in the UI. Free text
Price Callout Optional Price callout to feature a promo, event, member discount, if available.

Free text

Recommended text size: under 45 chars (Text that is too long may show ellipses)

DisplayTimeWindow (Optional) - Set a time window for a content to be shown on the surface
Start Timestamp Optional

The epoch timestamp after which the content should be shown on the surface.

If not set, content is eligible to be shown on the surface.

Epoch timestamp in milliseconds
End Timestamp Optional

The epoch timestamp after which the content is no longer shown on the surface.

If not set, content is eligible to be shown on the surface.

Epoch timestamp in milliseconds

Image specifications

Required specifications for image assets are listed in this table:

Aspect ratio Minimum pixels Recommended pixels

Square (1x1)

Preferred

300x300 1200x1200
Landscape (1.91x1) 600x314 1200x628
Portrait (4x5) 480x600 960x1200

The images are required to be hosted on public CDNs so that Google can access them.

File formats

PNG, JPG, static GIF, WebP

Maximum file size

5120 KB

Additional recommendations

  • Image safe area: Put your important content in the center 80% of the image.
  • Use a transparent background so that the image can be properly displayed in Dark and Light theme settings.

Timezone specifications

Prefer ID (for example, "America/Los_Angeles") over offset (for example, "-07:00").

Sample usage: DateTimeZone.forID("America/Los_Angeles")

Content Category

The content category allows apps to publish content belonging to multiple categories. This maps the content with some of the predefined categories namely:

  • TYPE_EDUCATION
  • TYPE_SPORTS
  • TYPE_MOVIES_AND_TV_SHOWS
  • TYPE_BOOKS
  • TYPE_AUDIOBOOKS
  • TYPE_MUSIC
  • TYPE_DIGITAL_GAMES
  • TYPE_TRAVEL_AND_LOCAL
  • TYPE_HOME_AND_AUTO
  • TYPE_BUSINESS
  • TYPE_NEWS
  • TYPE_FOOD_AND_DRINK
  • TYPE_SHOPPING
  • TYPE_HEALTH_AND_FITENESS
  • TYPE_MEDICAL
  • TYPE_PARENTING
  • TYPE_DATING

The images are required to be hosted on public CDNs so that Google can access them.

Guidelines to use the content categories

  1. Some entities like ArticleEntity and GenericFeaturedEntity are eligible to use any of the content categories. For other entities like EventEntity, EventReservationEntity, PointOfInterestEntity, only a subset of these categories are eligible. Check the list of categories eligible for an entity type before populating the list.
  2. Use the specific entity type for some content categories over a combination of the Generic entities and the ContentCategory:

    • TYPE_MOVIES_AND_TV_SHOWS - Check out the entities from Watch integration guide before using the generic entities.
    • TYPE_BOOKS - Check out the EbookEntity before using the generic entities.
    • TYPE_AUDIOBOOKS - Check out AudiobookEntity before using the generic entities.
    • TYPE_SHOPPING - Check out ShoppingEntity before using the generic entities.
    • TYPE_FOOD_AND_DRINK - Check out entities from Food Integration guide before using the generic entities.
  3. The ContentCategory field is optional and should be left blank if the content doesn't belong to any of the categories mentioned earlier.

  4. In case multiple content categories are provided, provide them in the order of relevance to the content with the most relevant content category placed first in the list.

Step 2: Provide Cluster data

It is recommended to have the content publish job executed in the background (for example, using WorkManager) and scheduled on a regular basis or on an event basis (for example, every time the user opens the app or when the user just added something to their cart).

AppEngageTravelClient is responsible for publishing clusters.

There are following APIs to publish clusters in the client:

  • isServiceAvailable
  • publishRecommendationClusters
  • publishFeaturedCluster
  • publishReservationCluster
  • publishContinueSearchCluster
  • publishUserAccountManagementRequest
  • updatePublishStatus
  • deleteRecommendationsClusters
  • deleteFeaturedCluster
  • deleteReservationCluster
  • deleteContinueSearchCluster
  • deleteUserManagementCluster
  • deleteClusters

isServiceAvailable

This API is used to check if the service is available for integration and whether the content can be presented on the device.

You can check the service availability for every cluster type that you intend to publish. The isServiceAvailable API accepts a request object, ServiceAvailabilityRequest, which contains the cluster types for which service availability needs to be checked. You can find the ClusterType enum values required for ServiceAvailabilityRequest from the following table.

Cluster Type Cluster Type Constant Integer Value
Unknown TYPE_UNKNOWN 0
Recommendation Cluster TYPE_RECOMMENDATION 1
Featured Cluster TYPE_FEATURED 2
Continuation Cluster TYPE_CONTINUATION 3
User Management Cluster TYPE_ENGAGEMENT 8
Subscription Cluster TYPE_SUBSCRIPTION 12
Continue Search Cluster TYPE_CONTINUE_SEARCH 13
Reservation Cluster TYPE_RESERVATION 14

Kotlin

val request = ServiceAvailabilityRequest.Builder()
    .addIntendedClusterType(ClusterType.TYPE_CONTINUATION)
    .addIntendedClusterType(ClusterType.TYPE_RECOMMENDATION)
    .build()

client.isServiceAvailable(request).addOnCompleteListener { task ->
    if (task.isSuccessful) {
        val availabilityMap = task.result
        if (availabilityMap[ClusterType.TYPE_CONTINUATION] ==