REST Resource: channels
จัดทุกอย่างให้เป็นระเบียบอยู่เสมอด้วยคอลเล็กชัน
บันทึกและจัดหมวดหมู่เนื้อหาตามค่ากำหนดของคุณ
แหล่งข้อมูล: ช่อง
แชแนลการแจ้งเตือนที่ใช้เพื่อดูการเปลี่ยนแปลงทรัพยากร
การแสดง JSON |
{
"params": {
string: string,
...
},
"payload": boolean,
"id": string,
"resourceId": string,
"resourceUri": string,
"token": string,
"expiration": string,
"type": string,
"address": string,
"kind": string
} |
ช่อง |
params |
map (key: string, value: string)
พารามิเตอร์เพิ่มเติมที่ควบคุมลักษณะการทำงานของช่องทางการนำส่ง ไม่บังคับ ออบเจ็กต์ที่มีรายการคู่ "key": value ตัวอย่าง: { "name": "wrench", "mass": "1.3kg", "count": "3" }
|
payload |
boolean
ค่าบูลีนเพื่อระบุว่าต้องการเพย์โหลดหรือไม่ ไม่บังคับ
|
id |
string
UUID หรือสตริงที่ไม่ซ้ำกันที่คล้ายกันซึ่งระบุช่องนี้
|
resourceId |
string
รหัสที่ไม่โปร่งใสซึ่งระบุแหล่งข้อมูลที่กำลังรับชมในช่องนี้ เสถียรใน API เวอร์ชันต่างๆ
|
resourceUri |
string
ตัวระบุเฉพาะเวอร์ชันสำหรับทรัพยากรที่ดู
|
token |
string
สตริงที่กำหนดเองซึ่งส่งไปยังที่อยู่เป้าหมายพร้อมกับการแจ้งเตือนแต่ละรายการที่ส่งผ่านช่องทางนี้ ไม่บังคับ
|
expiration |
string (int64 format)
วันที่และเวลาที่ช่องทางการแจ้งเตือนหมดอายุ ซึ่งแสดงเป็นการประทับเวลา Unix ในหน่วยมิลลิวินาที ไม่บังคับ
|
type |
string
ประเภทของกลไกการนำส่งที่ใช้สำหรับช่องนี้ ค่าที่ใช้ได้คือ "web_hook" หรือ "webhook"
|
address |
string
ที่อยู่ที่ใช้ส่งการแจ้งเตือนสำหรับช่องนี้
|
kind |
string
ระบุว่านี่คือช่องทางการแจ้งเตือนที่ใช้เพื่อดูการเปลี่ยนแปลงทรัพยากร ซึ่งก็คือ api#channel
|
เมธอด |
|
หยุดดูแหล่งข้อมูลผ่านช่องนี้ |
เนื้อหาของหน้าเว็บนี้ได้รับอนุญาตภายใต้ใบอนุญาตที่ต้องระบุที่มาของครีเอทีฟคอมมอนส์ 4.0 และตัวอย่างโค้ดได้รับอนุญาตภายใต้ใบอนุญาต Apache 2.0 เว้นแต่จะระบุไว้เป็นอย่างอื่น โปรดดูรายละเอียดที่นโยบายเว็บไซต์ Google Developers Java เป็นเครื่องหมายการค้าจดทะเบียนของ Oracle และ/หรือบริษัทในเครือ
อัปเดตล่าสุด 2025-07-25 UTC
[null,null,["อัปเดตล่าสุด 2025-07-25 UTC"],[],[],null,["# REST Resource: channels\n\n- [Resource: Channel](#Channel)\n - [JSON representation](#Channel.SCHEMA_REPRESENTATION)\n- [Methods](#METHODS_SUMMARY)\n\nResource: Channel\n-----------------\n\nA notification channel used to watch for resource changes.\n\n| JSON representation |\n|------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|\n| ``` { \"params\": { string: string, ... }, \"payload\": boolean, \"id\": string, \"resourceId\": string, \"resourceUri\": string, \"token\": string, \"expiration\": string, \"type\": string, \"address\": string, \"kind\": string } ``` |\n\n| Fields ||\n|---------------|--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|\n| `params` | `map (key: string, value: string)` Additional parameters controlling delivery channel behavior. Optional. An object containing a list of `\"key\": value` pairs. Example: `{ \"name\": \"wrench\", \"mass\": \"1.3kg\", \"count\": \"3\" }`. |\n| `payload` | `boolean` A Boolean value to indicate whether payload is wanted. Optional. |\n| `id` | `string` A UUID or similar unique string that identifies this channel. |\n| `resourceId` | `string` An opaque ID that identifies the resource being watched on this channel. Stable across different API versions. |\n| `resourceUri` | `string` A version-specific identifier for the watched resource. |\n| `token` | `string` An arbitrary string delivered to the target address with each notification delivered over this channel. Optional. |\n| `expiration` | `string (`[int64](https://developers.google.com/discovery/v1/type-format)` format)` Date and time of notification channel expiration, expressed as a Unix timestamp, in milliseconds. Optional. |\n| `type` | `string` The type of delivery mechanism used for this channel. Valid values are \"web_hook\" or \"webhook\". |\n| `address` | `string` The address where notifications are delivered for this channel. |\n| `kind` | `string` Identifies this as a notification channel used to watch for changes to a resource, which is `api#channel`. |\n\n| Methods ------- ||\n|------------------------------------------------------------------|------------------------------------------------|\n| ### [stop](/workspace/drive/api/reference/rest/v2/channels/stop) | Stops watching resources through this channel. |"]]