-
Notifications
You must be signed in to change notification settings - Fork 1
[Device] Add new device
Gledson Afonso edited this page Aug 16, 2022
·
5 revisions
Method | Action | Header | Request | Response |
---|---|---|---|---|
POST | add new device | ["Content-Type: application/json"] | # | # |
{
"name": "string",
"type": "string"
}
-
type
can be eitherwindows
ormac
{
"id": 1234,
"name": "string",
"type": "string",
"services": []
}
-
services
will always start as an empty array, since it's a new device that has been added
Keep in mind that:
- In the case of success, an HTTP status code of
201
should be expected with the above response body - In the case of incorrect use of
type
, or trying to add duplicates (samename
andtype
between devices), an HTTP status code of400
should be expected, with a common Spring error message body as a response