REST Resource: projects.deployments

資源:部署作業

代表單一指令碼部署。

JSON 表示法
{
  "deploymentId": string,
  "deploymentConfig": {
    object (DeploymentConfig)
  },
  "updateTime": string,
  "entryPoints": [
    {
      object (EntryPoint)
    }
  ]
}
欄位
deploymentId

string

這項部署作業的部署作業 ID。

deploymentConfig

object (DeploymentConfig)

部署設定。

updateTime

string (Timestamp format)

上次修改日期時間戳記。

RFC3339 世界標準時間「Zulu」格式的時間戳記,採用奈秒解析度,且最多 9 個小數位數。範例:"2014-10-02T15:01:23Z""2014-10-02T15:01:23.045123456Z"

entryPoints[]

object (EntryPoint)

Deployment 的進入點。

DeploymentConfig

中繼資料可定義 Deployment 的設定方式。

JSON 表示法
{
  "scriptId": string,
  "versionNumber": integer,
  "manifestFileName": string,
  "description": string
}
欄位
scriptId

string

指令碼專案的雲端硬碟 ID。

versionNumber

integer

這項部署作業的版本號碼。

manifestFileName

string

這項部署作業的資訊清單檔案名稱。

description

string

這項部署作業的說明。

EntryPoint

定義 Deployment 如何存取外部的設定。

JSON 表示法
{
  "entryPointType": enum (EntryPointType),

  // Union field properties can be only one of the following:
  "webApp": {
    object (WebAppEntryPoint)
  },
  "executionApi": {
    object (ExecutionApiEntryPoint)
  },
  "addOn": {
    object (AddOnEntryPoint)
  }
  // End of list of possible types for union field properties.
}
欄位
entryPointType

enum (EntryPointType)

進入點的類型。

聯集欄位 properties。每個進入點類型的進入點屬性properties 只能是下列其中一項:
webApp

object (WebAppEntryPoint)

網頁應用程式的進入點規格。

executionApi

object (ExecutionApiEntryPoint)

Apps Script API 執行呼叫的進入點規格。

addOn

object (AddOnEntryPoint)

外掛程式屬性。

EntryPointType

進入點的類型。

列舉
ENTRY_POINT_TYPE_UNSPECIFIED 未指定的進入點。
WEB_APP 網頁應用程式進入點。
EXECUTION_API API 可執行的進入點。
ADD_ON 外掛程式進入點。

WebAppEntryPoint

網頁應用程式進入點。

JSON 表示法
{
  "url": string,
  "entryPointConfig": {
    object (WebAppConfig)
  }
}
欄位
url

string

網頁應用程式的網址。

entryPointConfig

object (WebAppConfig)

進入點的設定。

WebAppConfig

網頁應用程式進入點設定。

JSON 表示法
{
  "access": enum (Access),
  "executeAs": enum (ExecuteAs)
}
欄位
access

enum (Access)

誰有權執行網頁應用程式。

executeAs

enum (ExecuteAs)

負責執行網頁應用程式的人員。

存取權

存取權設定。

列舉
UNKNOWN_ACCESS 請勿使用預設值。
MYSELF 只有部署網頁應用程式或執行檔的使用者才能存取該應用程式。請注意,這不一定是指令碼專案的擁有者。
DOMAIN 只有部署網頁應用程式或執行檔的使用者位於相同網域的使用者才能存取該應用程式。
ANYONE 任何登入使用者都可以存取網頁應用程式或執行檔。
ANYONE_ANONYMOUS 任何使用者 (無論登入與否) 都可以存取網頁應用程式或執行檔。

ExecuteAs

這項設定會指定網頁應用程式要在哪個使用者的身分下執行。

列舉
UNKNOWN_EXECUTE_AS 請勿使用預設值。
USER_ACCESSING 指令碼會以存取網頁應用程式的使用者的身分執行。
USER_DEPLOYING 指令碼會以部署網頁應用程式的使用者的身分執行。請注意,這不一定是指令碼專案的擁有者。

ExecutionApiEntryPoint

API 可執行的進入點。

JSON 表示法
{
  "entryPointConfig": {
    object (ExecutionApiConfig)
  }
}
欄位
entryPointConfig

object (ExecutionApiConfig)

進入點的設定。

ExecutionApiConfig

API 可執行的進入點設定。

JSON 表示法
{
  "access": enum (Access)
}
欄位
access

enum (Access)

誰有權執行 API 執行檔。

AddOnEntryPoint

外掛程式進入點。

JSON 表示法
{
  "addOnType": enum (AddOnType),
  "title": string,
  "description": string,
  "helpUrl": string,
  "reportIssueUrl": string,
  "postInstallTipUrl": string
}
欄位
addOnType

enum (AddOnType)

外掛程式的支援的容器類型清單。

title

string

外掛程式的必要標題。

description

string

外掛程式的說明 (選填)。

helpUrl

string

外掛程式的選填說明網址。

reportIssueUrl

string

外掛程式的選填回報問題網址。

postInstallTipUrl

string

外掛程式的安裝後提示網址。

AddOnType

AddType 會定義主機應用程式處理的外掛程式類別。每個外掛程式類型都有指令碼資訊清單區段,在部署或執行指定類型的外掛程式時會使用。

列舉
UNKNOWN_ADDON_TYPE 預設值,外掛程式類型不明。
GMAIL Gmail 的外掛程式類型。
DATA_STUDIO 數據分析外掛程式類型。

方法

create

建立 Apps Script 專案的部署作業。

delete

刪除 Apps Script 專案的部署作業。

get

取得 Apps Script 專案的部署作業。

list

可列出 Apps Script 專案的部署作業。

update

更新 Apps Script 專案的部署作業。