Method: users.spaces.updateSpaceReadState
คำขอ HTTP
PATCH https://chat.googleapis.com/v1/{spaceReadState.name=users/*/spaces/*/spaceReadState}
URL ใช้ไวยากรณ์การแปลง gRPC
พารามิเตอร์เส้นทาง
พารามิเตอร์ |
spaceReadState.name |
string
ชื่อทรัพยากรของสถานะการอ่านพื้นที่ทำงาน รูปแบบ: users/{user}/spaces/{space}/spaceReadState
|
พารามิเตอร์การค้นหา
พารามิเตอร์ |
updateMask |
string (FieldMask format)
ต้องระบุ เส้นทางฟิลด์ที่จะอัปเดต เส้นทางฟิลด์ที่รองรับในปัจจุบัน
เมื่อ lastReadTime อยู่ก่อนเวลาที่สร้างข้อความล่าสุด พื้นที่ทำงานจะแสดงเป็นยังไม่อ่านใน UI หากต้องการทําเครื่องหมายพื้นที่ทํางานว่าอ่านแล้ว ให้ตั้งค่า lastReadTime เป็นค่าที่หลังจาก (มากกว่า) เวลาสร้างข้อความล่าสุด ระบบจะบังคับให้ lastReadTime ตรงกับเวลาที่สร้างข้อความล่าสุด โปรดทราบว่าสถานะอ่านของพื้นที่ทำงานจะมีผลกับสถานะอ่านของข้อความที่ปรากฏในการสนทนาระดับบนสุดของพื้นที่ทำงานเท่านั้น การตอบกลับในชุดข้อความจะไม่ได้รับผลกระทบจากการประทับเวลานี้ และจะอาศัยสถานะการอ่านชุดข้อความแทน
|
เนื้อหาของคำขอ
เนื้อความของคำขอมีอินสแตนซ์ของ SpaceReadState
เนื้อหาการตอบกลับ
หากทำสำเร็จ เนื้อหาการตอบกลับจะมีอินสแตนซ์ SpaceReadState
ขอบเขตการให้สิทธิ์
ต้องใช้ขอบเขต OAuth ต่อไปนี้
https://www.googleapis.com/auth/chat.users.readstate
สำหรับข้อมูลเพิ่มเติม โปรดดูที่คู่มือการให้สิทธิ์
เนื้อหาของหน้าเว็บนี้ได้รับอนุญาตภายใต้ใบอนุญาตที่ต้องระบุที่มาของครีเอทีฟคอมมอนส์ 4.0 และตัวอย่างโค้ดได้รับอนุญาตภายใต้ใบอนุญาต Apache 2.0 เว้นแต่จะระบุไว้เป็นอย่างอื่น โปรดดูรายละเอียดที่นโยบายเว็บไซต์ Google Developers Java เป็นเครื่องหมายการค้าจดทะเบียนของ Oracle และ/หรือบริษัทในเครือ
อัปเดตล่าสุด 2024-10-23 UTC
[null,null,["อัปเดตล่าสุด 2024-10-23 UTC"],[[["This API updates a user's read state within a Google Chat space, marking messages as read or unread."],["It requires user authentication and the `chat.users.readstate` OAuth scope for authorization."],["The request uses the PATCH method and specifies the space read state resource name in the URL path."],["You can control which fields to update using the `updateMask` query parameter, such as setting the `lastReadTime` to mark a space as read."],["The request and response bodies utilize the `SpaceReadState` object to represent the user's read state information."]]],["This outlines updating a user's read state in a space using a PATCH request to `https://chat.googleapis.com/v1/{spaceReadState.name=users/*/spaces/*/spaceReadState}`. Key components include specifying the `spaceReadState.name` in the path, updating the `lastReadTime` via the `updateMask` query parameter, and providing a `SpaceReadState` instance in the request body. The response, if successful, returns a `SpaceReadState` instance. This operation requires user authentication and the `https://www.googleapis.com/auth/chat.users.readstate` authorization scope.\n"]]