I'm working on an app that starts a Google Hangout On Air. We do this programmatically using Javascript and the Google+ Hangouts API.
We've successfully created the button and when you click it, it properly starts a Hangout On Air.
We'd like to not have to pre-invite all the viewers but would rather share the hangout link. Once the hangout is started, it says in the upper right "Anyone with this link" should be able to join in. But it does not work. If I share the link with folks outside of the domain user that launched the hangout, they get bumped out with the message "This party is over..." and "Error: HJR: 2-RNF". I've checked my app domain settings and talked with Google support for Hangouts and no one seems to know how to fix this.
Even stranger, I've tried this with two different Google App domains. Under one domain (call this workingdomain.com
), we can share the link to anyone (with no invites) and everyone can join in. Under the other domain (call it notworking.com
), the hangout starts up fine, but if I share the link to folks who are not on the invite list, they cannot join in. It appears that workingdomain.com
has been grandfathered into Google Apps (not Google Apps for Work), and notworking.com
is paying for the Google Apps for Work subscription. That seems to be the main difference but I'm surprised that the paid version seems more restrictive than the free (grandfathered) service.
I wonder if anyone has a good way to programmatically start a public Hangout On Air - or what settings need to be set on the domain to make that work.
The button is initialized like this:
var startData = {
sectionId: "an id for tracking",
courseId: "an id for tracking",
sectionGuid: "a guid tracking it",
sectionTitle: "the hangout title"
};
var initial_apps = [
{ 'app_id': "our google hangout app id",
'start_data' : JSON.stringify(startData),
'app_type' : 'LOCAL_APP'
}
]
gapi.hangout.render('hangout-button-placeholder', {
render: 'createhangout',
hangout_type: 'onair',
topic: 'The Topic Title',
initial_apps: initial_apps,
widget_size: 72
});