api:networkmanagement:devicemodel:pictureupload
Table of Contents
API : Network Device Model : Upload picture
Introduction
This request is used to upload a picture of the device model, e.g. PNG or JPG. The image should be square. Any existing picture is replaced.
The upload must be performed as a multipart/form-data post request.
Request
| URL | https://api.telecomx.dk/network/device/model/MODEL_ID/picture | |
|---|---|---|
| Method | POST | |
| Access level | RESELLER_ADMIN or ADMIN. | |
| Params | MODEL_ID | Id of the network device model to upload the picture for. |
| Body | file | Binary image data |
Request example
https://api.telecomx.dk/network/device/model/1234567890ABCDEF12345678/picture
Response
| JSON object | ||
|---|---|---|
| success | Boolean | True on success. |
| picture | Id | Id of the uploaded picture. |
Example
{ "success": true, "picture": "12345678901234567890ABCD" }
Errors
| Error code | Message | Description |
|---|---|---|
| 403 | access_denied | Insufficient access level |
| 404 | not_found | Network device model not found |
| 422 | id | Id is not a valid model id. |
| 422 | picture | No file uploaded, or the file is not a valid image. |
| 500 | internal_error | <Unspecified> |
api/networkmanagement/devicemodel/pictureupload.txt · Last modified: by Mikkel Meerwaldt Jørgensen