Method: nodes.nodes.devices.createSigned
คำขอ HTTP
POST https://sasportal.googleapis.com/v1alpha1/{parent=nodes/*/nodes/*}/devices:createSigned
URL ใช้ไวยากรณ์ gRPC Transcoding
พารามิเตอร์เส้นทาง
พารามิเตอร์ |
parent |
string
ต้องระบุ ชื่อของทรัพยากรระดับบนสุด
|
เนื้อหาของคำขอ
เนื้อหาของคําขอมีข้อมูลที่มีโครงสร้างดังต่อไปนี้
การแสดง JSON |
{
"encodedDevice": string,
"installerId": string
} |
ช่อง |
encodedDevice |
string (bytes format)
ต้องระบุ โทเค็นเว็บ JSON ที่รับรองโดยใช้คีย์ส่วนตัว CPI เพย์โหลดต้องเป็นการเข้ารหัส JSON ของ device ต้องตั้งค่าช่อง userId สตริงที่เข้ารหัสฐาน 64
|
installerId |
string
ต้องระบุ รหัสโปรแกรมติดตั้งที่ไม่ซ้ํา (รหัส CPI) จากฐานข้อมูลโปรแกรมติดตั้งที่ได้รับการรับรอง
|
เนื้อหาการตอบกลับ
หากทำสำเร็จ เนื้อหาการตอบกลับจะมีอินสแตนซ์ Device
ขอบเขตการให้สิทธิ์
ต้องใช้ขอบเขต 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"],[[["Creates a signed device under a node or customer using an HTTP POST request."],["The request body requires a JSON Web Token and a unique installer ID."],["A successful response returns the device details."],["Requires `https://www.googleapis.com/auth/sasportal` authorization scope for access."]]],["This document details how to create a signed device under a node or customer using a `POST` request to the specified URL. The request requires a parent resource name in the URL path, and a request body containing a base64-encoded JSON Web Token (`encodedDevice`) and a unique installer ID (`installerId`). The `encodedDevice` must be signed with a CPI private key and the userId must be specified. A successful request returns a `Device` instance. OAuth scope `https://www.googleapis.com/auth/sasportal` is needed.\n"]]