我正在研究Google日历会议附加组件的实现,发现了一些问题。我按照文档执行示例代码,但它没有按预期工作。
从我的角度来看,我的清单文件是完整的,但是当我尝试从"从清单部署"链接发布日历会议加载项时,它会打开我的谷歌日历,但它没有显示我的会议,因为它显示了环聊和优步会议例如。
我期待在 Stackdriver 中的入口点函数上出现一些日志消息,但即使这样也不起作用。你有什么线索应该从哪里开始调查吗?下面是我的清单文件,也是我的创建会议函数定义。
{
"dependencies": {
"enabledAdvancedServices": [{
"userSymbol": "Calendar",
"serviceId": "calendar",
"version": "v3"
}],
"libraries": [{
"userSymbol": "OAuth2",
"libraryId": "1B7FSrk5Zi6L1rSxxTDgDEUsPzlukDsiaserTMogajsHhGBzBkMun4iDF",
"version": "21"
}]
},
"webapp": {
"access": "ANYONE",
"executeAs": "USER_ACCESSING"
},
"exceptionLogging": "STACKDRIVER",
"oauthScopes": [
"https://www.googleapis.com/auth/calendar.addons.execute",
"https://www.googleapis.com/auth/calendar.events.readonly",
"https://www.googleapis.com/auth/calendar.settings.readonly",
"https://www.googleapis.com/auth/script.external_request",
"https://www.googleapis.com/auth/script.scriptapp",
"https://www.googleapis.com/auth/userinfo.email",
"https://www.googleapis.com/auth/script.external_request"
],
"urlFetchWhitelist": [
"https://circuitsandbox.net/"
],
"calendar": {
"name": "My Web Conferencing",
"logoUrl": "https://dl.dropboxusercontent.com/s/sgkt743sv30rid1/logo-circuit-100x100.png?dl=0",
"createSettingsUrlFunction": "createSettingsUrl",
"conferenceSolution": [{
"id": 1,
"name": "My Web Conference",
"logoUrl": "https://dl.dropboxusercontent.com/s/sgkt743sv30rid1/logo-circuit-100x100.png?dl=0",
"onCreateFunction": "createConference"
},
{
"id": 2,
"name": "My Recorded Web Conference",
"logoUrl": "https://dl.dropboxusercontent.com/s/sgkt743sv30rid1/logo-circuit-100x100.png?dl=0",
"onCreateFunction": "createConference"
}
]
}
function createConference(arg) {
var dataBuilder = ConferenceDataService.newConferenceDataBuilder();
var authenticationUrl = 'https://adfs01.circuitsandbox.net/';
var error = ConferenceDataService.newConferenceError()
.setConferenceErrorType(
ConferenceDataService.ConferenceErrorType.AUTHENTICATION)
.setAuthenticationUrl(authenticationUrl);
dataBuilder.setError(error);
return dataBuilder.build();
}
您需要
被列入白名单才能开发和调试谷歌日历插件。
编辑:在那个时间点,你需要在谷歌内有一个联系人将你列入白名单,不确定是否仍然如此。很久没有解决这个问题了。不知道如何与他们取得联系,我自己从未直接联系过。