清单结构
使用集合让一切井井有条
根据您的偏好保存内容并对其进行分类。
本页面介绍了 Apps 脚本项目的清单文件 JSON 数据结构的顶层。
清单的子结构在单独的页面中定义:
清单
清单配置的顶层。
JSON 表示法 |
{
"addOns": {
object (AddOns)
},
"dependencies": {
object (Dependencies)
},
"exceptionLogging": string,
"executionApi": {
object (ExecutionApi)
},
"oauthScopes": [
string
],
"runtimeVersion": string,
"sheets": {
object (Sheets)
},
"timeZone": string,
"urlFetchWhitelist": [
string
],
"webapp": {
object (Webapp)
}
} |
字段 |
addOns |
object (AddOns)
项目的资源配置(如果部署为
Google Workspace 插件)。
|
dependencies |
object (Dependencies)
对脚本项目启用的
高级服务和库的配置。
|
exceptionLogging |
string
记录异常的位置。有效设置如下所示:
|
executionApi |
object (ExecutionApi)
脚本项目的 API 可执行配置。只有在为执行 API 而部署项目时,才需要使用此参数。
|
oauthScopes[] |
string
脚本项目使用的授权范围的定义。
|
runtimeVersion |
string
脚本使用的运行时版本。如果清单中没有此字段,脚本将使用默认运行时 (STABLE )。此字段的有效选项如下:
STABLE 指示默认运行时(目前为 Rhino)。
V8 表示采用 V8 的运行时。
DEPRECATED_ES5 指示 Rhino 运行时。设置此值还会阻止自动迁移到 V8。
|
sheets |
object (Sheets)
定义
Google 表格宏的资源配置。
|
timeZone |
string
采用某个可用的
ZoneId 值(例如“America/Denver”)的
脚本时区。
|
urlFetchWhitelist[] |
string
HTTPS 网址前缀列表。如果存在,提取的任何网址端点必须与此列表中的一个前缀匹配。这有助于保护用户数据。此字段对于测试部署是选填字段,但对于部署是必填字段。详细了解如何将网址列入许可名单。
|
webapp |
object (Webapp)
脚本项目的 Web 应用配置,只有在将项目部署为 Web 应用时才会使用。
|
如未另行说明,那么本页面中的内容已根据知识共享署名 4.0 许可获得了许可,并且代码示例已根据 Apache 2.0 许可获得了许可。有关详情,请参阅 Google 开发者网站政策。Java 是 Oracle 和/或其关联公司的注册商标。
最后更新时间 (UTC):2024-03-06。
[{
"type": "thumb-down",
"id": "missingTheInformationINeed",
"label":"没有我需要的信息"
},{
"type": "thumb-down",
"id": "tooComplicatedTooManySteps",
"label":"太复杂/步骤太多"
},{
"type": "thumb-down",
"id": "outOfDate",
"label":"内容需要更新"
},{
"type": "thumb-down",
"id": "translationIssue",
"label":"翻译问题"
},{
"type": "thumb-down",
"id": "samplesCodeIssue",
"label":"示例/代码问题"
},{
"type": "thumb-down",
"id": "otherDown",
"label":"其他"
}]
[{
"type": "thumb-up",
"id": "easyToUnderstand",
"label":"易于理解"
},{
"type": "thumb-up",
"id": "solvedMyProblem",
"label":"解决了我的问题"
},{
"type": "thumb-up",
"id": "otherUp",
"label":"其他"
}]