This request is used to upload an image which is used by the editor for the description. Supported formats are PNG, JPG, GIF, TIFF.
The upload API requires that the task has been created in advance before adding images to it.
The upload must be performed as a multipart/form-data post request.
| URL | https://api.telecomx.dk/tools/humantask/TASK_ID/image | |
|---|---|---|
| Method | POST | |
| Access level | RESELLER_ADMIN or ADMIN. | |
| Params | TASK_ID | Id of the task the image belongs to |
| Body | picture | Binary image data |
n/a
| Json object | ||
|---|---|---|
| url | String | URL to serve the image from |
{ "url": "https://image.telecomx.dk/12345678901234567890ABCD.png?token=token_for_current_user" }
| Error code | Message | Description |
|---|---|---|
| 400 | bad_request | Task id not found in request URI |
| 404 | id | Task not found |
| 404 | picture | The file was missing or invalid |
| 422 | picture | Filetype must be PNG or JPG |
| 403 | access_denied | Insufficient access level |
| 500 | internal_error | <unspecified> |