You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: source/includes/_printers.md
+86-66Lines changed: 86 additions & 66 deletions
Original file line number
Diff line number
Diff line change
@@ -30,7 +30,7 @@ This endpoint can be used to delete a printer from the database, or to disconnec
30
30
| Parameter | Type | Required | Description |
31
31
| --------- | ---- | -------- | ----------- |
32
32
|`pid`| integer | yes | The ID of the printer to delete. |
33
-
|`just_connection`| integer | no | If set to 1, the Pi connection will be deleted. If set to 0, the printer and connection will be permanently deleted.<br>**Default: 0**|
33
+
|`just_connection`| integer | no | If set to 1, only the Pi connection will be deleted. Otherwise, the printer will be permanently deleted.<br>**Default: 0**|
34
34
35
35
### Response
36
36
@@ -226,38 +226,33 @@ To start a print job you must either specify a `filesystem` ID, a `queue_file` I
226
226
|`message`| string | Error message if `status` is false. |
227
227
|`files`| array | Array of started print job objects. |
228
228
|`files[].name`| string | The name of the file. |
229
-
|`files[].analysis`| object | The analysis of the file. This has been documented in the [Save autoqueue defaults endpoint.](#save-autoqueue-defaults). |
229
+
|`files[].analysis`| object | The analysis of the file. This has been documented in the [Get queue items endpoint](#get-queue-items). |
230
230
|`files[].printers`| integer[]| The IDs of the printers that the print job was started on. |
231
-
|`files[].queued`| boolean | True if the print job was queued. |
231
+
|`files[].queued`| boolean | TODO |
232
+
|`jobIds`| integer[]| The IDs of the print jobs that were started. |
This endpoint can be used to pause one or multiple print jobs. The printers have to be in the `PRINTING` state.
270
+
273
271
### Request
274
272
275
-
`? /{id}/printers/actions/Pause`
273
+
`POST /{id}/printers/actions/Pause`
274
+
275
+
#### Query parameters
276
276
277
-
TODO
277
+
| Parameter | Type | Required | Description |
278
+
| --------- | ---- | -------- | ----------- |
279
+
|`pid`| integer or integer[]| yes | The ID(s) of the printer to pause. Pause multiple printers by comma separating printer ids.<br>**Printer must be in `PRINTER_PRINTING` state**|
278
280
279
-
## actions/Get
281
+
#### Response
282
+
283
+
| Field | Type | Description |
284
+
| ----- | ---- | ----------- |
285
+
|`status`| boolean | True if the request was successful. |
286
+
|`message`| string | Error message if `status` is false. |
|`pid`| integer or integer[]| yes | The ID(s) of the printer to resume. Resume multiple printers by comma separating printer ids.<br>**Printer must be in `PRINTER_PAUSED` state**|
315
+
316
+
#### Response
299
317
300
-
TODO
318
+
| Field | Type | Description |
319
+
| ----- | ---- | ----------- |
320
+
|`status`| boolean | True if the request was successful. |
321
+
|`message`| string | Error message if `status` is false. |
|`CANCEL_OTHERS_PRINTS`| Need permission to cancel other users' prints if the print job was started by another user. |
353
+
354
+
This endpoint can be used to cancel one or multiple print jobs. The printers have to be in the `PRINTING`, `PAUSED` or `PAUSING` state.
355
+
342
356
### Request
343
357
344
-
`? /{id}/printers/logs/ReadLog`
358
+
`POST /{id}/printers/actions/Cancel`
345
359
346
-
TODO
360
+
#### Query parameters
347
361
348
-
## logs/DeleteLog
362
+
| Parameter | Type | Required | Description |
363
+
| --------- | ---- | -------- | ----------- |
364
+
|`pid`| integer or integer[]| yes | The ID(s) of the printer to cancel. Cancel multiple printers by comma separating printer ids.<br>**Printer must be in `PRINTER_PRINTING`, `PRINTER_PAUSED` or `PRINTER_PAUSING` state**|
|`reason`| integer | no | The reason for cancelling the print job. See [Cancel reasons](#cancel-reasons). Depending on the `require_cancel_reason` organization setting, this field may be required. |
371
+
|`comment`| string | no | A comment for the cancel reason. Depending on the `require_comment` organization setting, this field may be required.<br>**Max length: 500 characters**|
358
372
359
-
```json
360
-
{
361
-
"TODO": "TODO"
362
-
}
363
-
```
373
+
### Response
364
374
365
-
### Request
375
+
| Field | Type | Description |
376
+
| ----- | ---- | ----------- |
377
+
|`status`| boolean | True if the request was successful. |
378
+
|`message`| string | Error message if `status` is false. |
Copy file name to clipboardExpand all lines: source/includes/_queue.md
+17-17Lines changed: 17 additions & 17 deletions
Original file line number
Diff line number
Diff line change
@@ -43,7 +43,7 @@ You must specify either a filesystem id or a file to upload.
43
43
| Parameter | Type | Required | Description |
44
44
| --------- | ---- | -------- | ----------- |
45
45
|`filesystem`| string | no | The filesystem id of the file to add to the queue. |
46
-
|`amount`|int| no | The amount of prints to add to the queue.<br>**Default: 1**|
46
+
|`amount`|integer| no | The amount of prints to add to the queue.<br>**Default: 1**|
47
47
48
48
#### File upload
49
49
@@ -146,7 +146,7 @@ This endpoint returns the queue for the specified or all printers.
146
146
147
147
| Parameter | Type | Required | Description |
148
148
| --------- | ---- | -------- | ----------- |
149
-
|`p`|int| no | The printer id to get the queue for. If not specified, the queue for all printers will be returned. |
149
+
|`p`|integer| no | The printer id to get the queue for. If not specified, the queue for all printers will be returned. |
150
150
151
151
### Response
152
152
@@ -157,31 +157,31 @@ This endpoint returns the queue for the specified or all printers.
157
157
|`queue`| object | The queue object. |
158
158
|`queue.fits`| boolean | TODO |
159
159
|`queue.items`| array | An array of queue item objects. |
160
-
|`queue.items[].id`|int| The queue item id. |
161
-
|`queue.items[].index`|int| The queue item index. |
160
+
|`queue.items[].id`|integer| The queue item id. |
161
+
|`queue.items[].index`|integer| The queue item index. |
162
162
|`queue.items[].filename`| string | The queue item filename. |
163
163
|`queue.items[].model`| boolean | True if the queue item is a model. |
164
-
|`queue.items[].left`|int| The amount of prints left to print. |
165
-
|`queue.items[].printed`|int| The amount of prints that have been printed. |
164
+
|`queue.items[].left`|integer| The amount of prints left to print. |
165
+
|`queue.items[].printed`|integer| The amount of prints that have been printed. |
166
166
|`queue.items[].for`| object | For which printers, models and groups this queue item is for. |
167
167
|`queue.items[].for.printers`| array | An array of printer ids. |
168
168
|`queue.items[].for.models`| array | An array of printer model ids. |
169
169
|`queue.items[].for.groups`| array | An array of group ids. |
170
170
|`queue.items[].analysis`| object | The analysis object. |
171
171
|`queue.items[].analysis.slicer`| string | The slicer used to slice the file. |
172
172
|`queue.items[].analysis.filament`| array | An array of filament lengths. |
173
-
|`queue.items[].analysis.estimate`|int| The estimated print time in seconds. |
173
+
|`queue.items[].analysis.estimate`|integer| The estimated print time in seconds. |
174
174
|`queue.items[].analysis.movement`| object | The movement object. |
175
175
|`queue.items[].analysis.temps`| object | The temperatures object. |
176
176
|`queue.items[].analysis.temps.tool`| object | Temperature for each tool (extruder). |
177
-
|`queue.items[].analysis.temps.bed`|int| Temperature for the bed. |
178
-
|`queue.items[].analysis.temps.pset`|int| TODO |
177
+
|`queue.items[].analysis.temps.bed`|integer| Temperature for the bed. |
178
+
|`queue.items[].analysis.temps.pset`|integer| TODO |
179
179
|`queue.items[].analysis.modelSize`| object | The model size object. Represented as `x`, `y` and `z` values in millimeters. |
180
180
|`queue.items[].analysis.printArea`| object | The print area object. Represented as `maxX`, `minX`, `maxY`, `minY`, `maxZ` and `minZ` values in millimeters. |
181
181
|`queue.items[].analysis.minDeltaRadius`| float | Minimum radius for delta printers. |
182
-
|`queue.items[].analysis.v`|int| The analysis version. |
182
+
|`queue.items[].analysis.v`|integer| The analysis version. |
183
183
|`queue.items[].user`| string | The user name of who added the queue item. |
184
-
|`queue.items[].user_id`|int| The user id of who added the queue item. |
184
+
|`queue.items[].user_id`|integer| The user id of who added the queue item. |
185
185
186
186
## Update queue item
187
187
@@ -231,7 +231,7 @@ This endpoint updates the queue item with the specified id.
231
231
232
232
| Parameter | Type | Required | Description |
233
233
| --------- | ---- | -------- | ----------- |
234
-
|`job`|int| yes | The queue item id to update. |
234
+
|`job`|integer| yes | The queue item id to update. |
235
235
236
236
#### Request body
237
237
@@ -240,7 +240,7 @@ This endpoint updates the queue item with the specified id.
240
240
|`for_groups`| array | no | An array of group ids to assign the queue item to. |
241
241
|`for_models`| array | no | An array of printer model ids to assign the queue item to. |
242
242
|`for_printers`| array | no | An array of printer ids to assign the queue item to. |
243
-
|`amount`|int| no | The new amount to set. |
243
+
|`amount`|integer| no | The new amount to set. |
244
244
245
245
### Response
246
246
@@ -278,7 +278,7 @@ This endpoint deletes the queue item with the specified id.
278
278
279
279
| Parameter | Type | Required | Description |
280
280
| --------- | ---- | -------- | ----------- |
281
-
|`job`|int| yes | The queue item id to delete. |
281
+
|`job`|integer| yes | The queue item id to delete. |
282
282
283
283
### Response
284
284
@@ -316,9 +316,9 @@ This endpoint changes the order of the queue items by moving the queue item with
316
316
317
317
| Parameter | Type | Required | Description |
318
318
| --------- | ---- | -------- | ----------- |
319
-
|`job`|int| yes | The queue item id to move. |
320
-
|`from`|int| yes | The current position of the queue item. |
321
-
|`to`|int| yes | The new position of the queue item. |
319
+
|`job`|integer| yes | The queue item id to move. |
320
+
|`from`|integer| yes | The current position of the queue item. |
321
+
|`to`|integer| yes | The new position of the queue item. |
0 commit comments