Public init and proper doc
This commit is contained in:
parent
284ff11030
commit
46a7073a04
@ -10,4 +10,14 @@ public struct AdminRequest: Codable {
|
|||||||
|
|
||||||
/// The application id with which the request is associated
|
/// The application id with which the request is associated
|
||||||
public let application: ApplicationId
|
public let application: ApplicationId
|
||||||
|
|
||||||
|
/**
|
||||||
|
Create a new admin request.
|
||||||
|
- Parameter keyHash: The SHA256 hash of the admin key
|
||||||
|
- Parameter application: The application id for the request.
|
||||||
|
*/
|
||||||
|
public init(keyHash: Data, application: ApplicationId) {
|
||||||
|
self.keyHash = keyHash
|
||||||
|
self.application = application
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
@ -30,7 +30,7 @@ public enum Route: String {
|
|||||||
Get a list of unapproved devices for review.
|
Get a list of unapproved devices for review.
|
||||||
|
|
||||||
* HTTP Method: `POST`
|
* HTTP Method: `POST`
|
||||||
* HTTP Body: The binary SHA256 hash of the master key using the custom salt
|
* HTTP Body: An `AdminRequest` JSON object with the SHA256 hash of the admin key and the application id
|
||||||
* Response: An array of `DeviceRegistration` elements encoded in JSON. `401` if the master key is incorrect.
|
* Response: An array of `DeviceRegistration` elements encoded in JSON. `401` if the master key is incorrect.
|
||||||
*/
|
*/
|
||||||
case listUnapprovedDevices = "check"
|
case listUnapprovedDevices = "check"
|
||||||
|
Loading…
Reference in New Issue
Block a user