Skip to main content

Broadcast a Google Apps Script web app

Display a page generated by a Google Apps Script web app on your Comeen Play screens.

The Apps Script web app content lets you broadcast a web page generated by a Google Apps Script project on your Comeen Play displays. You add it to a playlist like any other content, simply by pasting your web app's deployment URL.

Typical use cases:

  • a dashboard fed by a Google Sheet (quality, production or sales KPIs);

  • internal information computed on the fly (schedules, queues, counters);

  • a custom page built by your teams, with no external hosting required.

This content sits under Collaboration suites > Google Workspace, alongside Google Slides, Google Sheets, Google Docs and Data Studio.

Prerequisites

  • A Google Workspace auth provider configured in Comeen Play (see Google Integration). It appears in the Google Workspace drop-down of the content.

  • A Google Apps Script project deployed as a web app, with a deployment URL ending in /exec.

  • Web app access settings that allow the Google account selected in Comeen Play.

  • Permission to edit the target playlist in Comeen Play.

Step 1 – Deploy the web app in Google Apps Script

Your script must expose a doGet() function that returns the page to display. To let Comeen Play show the page, allow it to be embedded in an iframe:

function doGet() {
  return HtmlService.createHtmlOutputFromFile('Index')
    .setTitle('My display')
    .setXFrameOptionsMode(HtmlService.XFrameOptionsMode.ALLOWALL);
}
  1. In the Apps Script editor, click Deploy > New deployment.

  2. Select the Web app type.

  3. Enter a description, then set Execute as and Who has access (see Best practices).

  4. Click Deploy and authorize the requested access.

  5. Copy the Web app URL, formatted as https://script.google.com/macros/s/<ID>/exec.

Do not use the test URL ending in /dev: only the script's editors can open it.

Step 2 – Add the web app to a playlist

  1. In Playlists, open the playlist you want and go to the Content tab.

  2. Click Add content.

  3. Under Collaboration suites, select Google Workspace, then Apps Script web app, and click Next.

  4. Set the display duration and check that Visibility is on.

  5. In the Google Workspace block, choose the Google account to use.

  6. Paste the deployment URL into Web app URL.

  7. If needed, turn on Automatically refresh the page and Force fullscreen.

  8. Click Save, then check the result in the Preview tab.

The content then appears in the playlist and is broadcast on the targeted displays.

Settings

Setting

Description

Default

Duration (s)

How long the content is shown in the playlist. If the content has several pages, this is the duration of each page.

5

Visibility

Enables or disables the item in the playlist without deleting it.

On

Google Workspace

Google auth provider used to access the web app.

–

Web app URL

Deployment URL of the web app, ending in /exec. Required.

–

Automatically refresh the page

Reloads the page at regular intervals to show up-to-date data.

Off

Force fullscreen

Displays the web app across the whole screen.

Off

Best practices and edge cases

  • Web app access: the account selected in Comeen Play must be among the users allowed in Who has access. Prefer "Anyone within your domain" over "Anyone" if the page shows internal data.

  • Script updates: a new deployment creates a new URL. To keep the same URL, use Manage deployments > Edit and select a new version.

  • Screen format: design the page for the resolution and orientation of the target displays (e.g. 1920 × 1080 landscape), with no scrolling or interaction.

  • Google quotas: every load runs the script. On a large fleet with frequent refreshes, monitor Apps Script quotas and cache data (CacheService).

FAQ and troubleshooting

Symptom

Likely cause

Fix

The Save button stays greyed out

URL missing or in the wrong format

Paste the full URL ending in /exec.

Blank page or "refused to connect"

The page does not allow iframe embedding

Add setXFrameOptionsMode(ALLOWALL) in doGet() and redeploy.

Google sign-in page or access error

The selected account has no access to the web app

Adjust Who has access or select another Google Workspace account. See also Why do I get a 403 error while trying to add a Google content to my playlist?

Script changes don't show up

The deployment still points to the old version

Edit the existing deployment and select "New version".

Data doesn't update

Automatic refresh is off

Turn on Automatically refresh the page.

Related articles

Did this answer your question?