Method: policies.set
ตั้งค่านโยบายการควบคุมการเข้าถึงสําหรับทรัพยากรที่ระบุ แทนที่นโยบายที่มีอยู่
คำขอ HTTP
POST https://sasportal.googleapis.com/v1alpha1/policies:set
URL ใช้ไวยากรณ์ gRPC Transcoding
เนื้อหาของคำขอ
เนื้อหาของคําขอมีข้อมูลที่มีโครงสร้างดังต่อไปนี้
การแสดง JSON |
{
"resource": string,
"policy": {
object (Policy )
},
"disableNotification": boolean
} |
ช่อง |
resource |
string
ต้องระบุ ทรัพยากรที่มีการระบุนโยบาย นโยบายนี้จะแทนที่นโยบายที่มีอยู่
|
policy |
object (Policy )
ต้องระบุ นโยบายที่จะนําไปใช้กับ resource
|
disableNotification |
boolean
ไม่บังคับ ตั้งค่าช่องเป็น true เพื่อปิดใช้การแจ้งเตือนการเริ่มต้นใช้งาน
|
เนื้อหาการตอบกลับ
หากทำสำเร็จ เนื้อหาการตอบกลับจะมีอินสแตนซ์ Policy
ขอบเขตการให้สิทธิ์
ต้องใช้ขอบเขต OAuth ต่อไปนี้
https://www.googleapis.com/auth/sasportal
เนื้อหาของหน้าเว็บนี้ได้รับอนุญาตภายใต้ใบอนุญาตที่ต้องระบุที่มาของครีเอทีฟคอมมอนส์ 4.0 และตัวอย่างโค้ดได้รับอนุญาตภายใต้ใบอนุญาต Apache 2.0 เว้นแต่จะระบุไว้เป็นอย่างอื่น โปรดดูรายละเอียดที่นโยบายเว็บไซต์ Google Developers Java เป็นเครื่องหมายการค้าจดทะเบียนของ Oracle และ/หรือบริษัทในเครือ
อัปเดตล่าสุด 2022-11-02 UTC
[null,null,["อัปเดตล่าสุด 2022-11-02 UTC"],[[["Sets the access control policy on a specified resource, replacing any existing policy."],["The request body requires the resource, the policy to be applied, and optionally allows disabling onboarding notifications."],["A successful response returns the applied policy."],["Utilizes the `https://www.googleapis.com/auth/sasportal` OAuth scope for authorization."]]],["The core function is to set an access control policy on a resource via a `POST` HTTP request to `https://sasportal.googleapis.com/v1alpha1/policies:set`. The request body, in JSON format, requires a `resource` string and a `policy` object. Optionally, `disableNotification` can be set to `true`. A successful request returns a `Policy` instance. This process requires the `https://www.googleapis.com/auth/sasportal` OAuth scope. Existing policies are replaced.\n"]]