Method: tasks.pushNotificationConfigs.create

為工作建立推播通知設定。

HTTP 要求

POST https://ces.googleapis.com/tasks/{taskId}/pushNotificationConfigs

這個網址使用 gRPC 轉碼語法。

路徑參數

參數
taskId

string

與這項設定相關聯的工作 ID。

要求主體

要求主體包含下列結構的資料:

JSON 表示法
{
  "tenant": string,
  "id": string,
  "url": string,
  "token": string,
  "authentication": {
    object (AuthenticationInfo)
  }
}
欄位
tenant

string

選用。不透明的路由 ID。如果設定該欄位,則必須與所選代理資訊卡中的 AgentInterface 值相符。tenant

id

string

推播通知設定詳細資料。這項推播通知設定的專屬 ID (例如 UUID)。

url

string

這是必要旗標,應傳送通知的網址。

token

string

這項工作或工作階段的專屬權杖。

authentication

object (AuthenticationInfo)

必須提供驗證資訊才能傳送通知。

回應主體

如果成功,回應主體會包含新建立的 TaskPushNotificationConfig 執行個體。

授權範圍

需要下列其中一種 OAuth 範圍:

  • https://www.googleapis.com/auth/cloud-platform
  • https://www.googleapis.com/auth/ces

詳情請參閱Authentication Overview