diff --git a/source/includes/_account.md b/source/includes/_account.md index 367a95dd17b..f2437415e04 100644 --- a/source/includes/_account.md +++ b/source/includes/_account.md @@ -53,8 +53,8 @@ curl https://api.simplyprint.io/{id}/account/settings/groups/Create \ | Required permissions | -| --------------------- | -| `ORG_RANK_MANAGEMENT` | +|-----------------------| +| `org_rank_management` | This endpoint creates a new group in the company. @@ -63,7 +63,7 @@ This endpoint creates a new group in the company. `POST /{id}/account/settings/groups/Create` | Parameter | Type | Required | Description | -| --------------------- | ------- | -------- | --------------------------------------------------------------------------------------------------- | +|-----------------------|---------|----------|-----------------------------------------------------------------------------------------------------| | `ranks` | array | yes | Array of groups to create. | | `ranks[].title` | string | yes | The name of the group. | | `ranks[].description` | string | no | The description of the group. | @@ -73,7 +73,7 @@ This endpoint creates a new group in the company. ### Response | Parameter | Type | Description | -| --------- | ------- | ----------------------------------- | +|-----------|---------|-------------------------------------| | `status` | boolean | True if the request was successful. | | `message` | string | Error message if `status` is false. | | `data` | array | Array of the created groups. | @@ -97,7 +97,7 @@ curl https://api.simplyprint.io/{id}/account/settings/groups/Update \ "title": "TITLE", "description": "DESCRIPTION", "permissions": "{\"view_news\":true,\"org_admin\":true,\"panel_printing\":true,\"printer_restart\":true,\"printer_edit\":true,\"bed_leveling\":true,\"gcode_profiles\":true,\"printer_settings\":true,\"filament_settings\":true,\"change_filament\":true,\"create_filament\":true,\"see_filament_tab\":true,\"view_users\":true,\"change_user_rank\":true,\"manual_user_email_confirm\":true,\"invite_users\":true,\"delete_user\":true,\"org_user_registration_settings\":true,\"org_hub_settings\":true,\"org_rank_management\":true,\"org_view_statistics\":true,\"refill_quota\":true,\"custom_slicer_profiles\":true,\"org_profiles\":true,\"all_slicer_modes\":true,\"queue_remove_all\":true,\"org_api\":true,\"create_org_folder\":true,\"cancel_others\":true,\"see_who_printed\":true,\"max_print_size\":[],\"default_slicer_mode\":2}", - "sort_order": 3, + "sort_order": 3 } ] } @@ -129,8 +129,8 @@ curl https://api.simplyprint.io/{id}/account/settings/groups/Update \ | Required permissions | -| --------------------- | -| `ORG_RANK_MANAGEMENT` | +|-----------------------| +| `org_rank_management` | This endpoint updates the groups in the company. @@ -139,7 +139,7 @@ This endpoint updates the groups in the company. `POST /{id}/account/settings/groups/Update` | Parameter | Type | Required | Description | -| --------------------- | ------- | -------- | --------------------------------------------------------------------------------------------------- | +|-----------------------|---------|----------|-----------------------------------------------------------------------------------------------------| | `ranks` | array | yes | Array of groups to update. | | `ranks[].id` | integer | yes | The id of the group to update. | | `ranks[].title` | string | no | The name of the group. | @@ -150,7 +150,7 @@ This endpoint updates the groups in the company. ### Response | Parameter | Type | Description | -| --------------------- | ------- | --------------------------------------------------------------------------------------------------- | +|-----------------------|---------|-----------------------------------------------------------------------------------------------------| | `status` | boolean | True if the request was successful. | | `message` | string | Error message if `status` is false. | | `data` | array | Array of the updated groups. | @@ -199,8 +199,8 @@ curl https://api.simplyprint.io/{id}/account/GetGroups \ | Required permissions | -| --------------------- | -| `ORG_RANK_MANAGEMENT` | +|-----------------------| +| `org_rank_management` | This endpoint returns a list of groups that exist in the company. @@ -211,7 +211,7 @@ This endpoint returns a list of groups that exist in the company. ### Response | Parameter | Type | Description | -| --------------- | ------- | ----------------------------------- | +|-----------------|---------|-------------------------------------| | `status` | boolean | True if the request was successful. | | `message` | string | Error message if `status` is false. | | `groups` | array | Array of group objects. | @@ -241,7 +241,7 @@ curl https://api.simplyprint.io/{id}/account/settings/groups/Delete \ ```json { "status": true, - "message": null, + "message": null } ``` @@ -250,22 +250,22 @@ curl https://api.simplyprint.io/{id}/account/settings/groups/Delete \ | Required permissions | -| --------------------- | -| `ORG_RANK_MANAGEMENT` | +|-----------------------| +| `org_rank_management` | ### Request `POST /{id}/account/settings/groups/Delete` | Parameter | Type | Required | Description | -| ------------------- | ------- | -------- | ------------------------------------------------------------------------------------------------------- | +|---------------------|---------|----------|---------------------------------------------------------------------------------------------------------| | `id` | integer | yes | The id of the group to delete. | | `replacementRankId` | integer | maybe | The id of the group to replace the deleted group with.
This is only required if the group has users. | ### Response | Parameter | Type | Description | -| --------- | ------- | ----------------------------------- | +|-----------|---------|-------------------------------------| | `status` | boolean | True if the request was successful. | | `message` | string | Error message if `status` is false. | @@ -282,8 +282,16 @@ curl https://api.simplyprint.io/{id}/account/GetStatistics \ ```json { - "users": [1234, 1235, 1945], - "printers": [1234, 1235, 1945], + "users": [ + 1234, + 1235, + 1945 + ], + "printers": [ + 1234, + 1235, + 1945 + ], "start_date": "1677629786", "end_date": "1677629786" } @@ -293,46 +301,46 @@ curl https://api.simplyprint.io/{id}/account/GetStatistics \ ```json { - "status": true, - "message": null, - "data": { - "total_print_seconds": 1234, - "total_filament_usage_gram": 1241.1231231, - "print_job_count": 123, - "regretted_print_jobs": 123, - "failed_print_jobs": 123, - "printer_error_print_jobs": 123, - "done_print_jobs": 123, - "date_range": { - "from": "2023-02-22", - "to": "2023-03-02", - "general": false - }, - "printers": { - "3104": { - "name": "Printer 1", - "done": 0, - "failed": 0, - "printer_error": 0, - "regretted": 0, - "filament_usage_gram": 0 - }, - ... - }, - "print_jobs": [ - { - "date": "2023-02-27", - "started": "2023-02-27 11:39:34", - "ended": "2023-02-27 11:56:18", - "cancelled": 1, - "failed": 0, - "cancel_reason_type": 5, - "print_seconds": 1004, - "filament_usage_gram": 0.03758012402132279 - }, - ... - ] - } + "status": true, + "message": null, + "data": { + "total_print_seconds": 1234, + "total_filament_usage_gram": 1241.1231231, + "print_job_count": 123, + "regretted_print_jobs": 123, + "failed_print_jobs": 123, + "printer_error_print_jobs": 123, + "done_print_jobs": 123, + "date_range": { + "from": "2023-02-22", + "to": "2023-03-02", + "general": false + }, + "printers": { + "3104": { + "name": "Printer 1", + "done": 0, + "failed": 0, + "printer_error": 0, + "regretted": 0, + "filament_usage_gram": 0 + }, + ... + }, + "print_jobs": [ + { + "date": "2023-02-27", + "started": "2023-02-27 11:39:34", + "ended": "2023-02-27 11:56:18", + "cancelled": 1, + "failed": 0, + "cancel_reason_type": 5, + "print_seconds": 1004, + "filament_usage_gram": 0.03758012402132279 + }, + ... + ] + } } ``` @@ -347,7 +355,7 @@ This endpoint returns statistics for the user / company. `POST /{id}/account/GetStatistics` | Parameter | Type | Required | Description | -| ------------ | ------ | -------- | ------------------------------------------------------------------------------------------------------------ | +|--------------|--------|----------|--------------------------------------------------------------------------------------------------------------| | `users` | array | no | Array of user ids to get statistics for. Don't include this parameter to get statistics for all users. | | `printers` | array | no | Array of printer ids to get statistics for. Don't include this parameter to get statistics for all printers. | | `start_date` | string | no | The start date of the statistics. Provide a unix timestamp in seconds. | @@ -356,7 +364,7 @@ This endpoint returns statistics for the user / company. ### Response | Parameter | Type | Description | -| ---------------------------------------- | ------- | ---------------------------------------- | +|------------------------------------------|---------|------------------------------------------| | `status` | boolean | True if the request was successful. | | `message` | string | Error message if `status` is false. | | `data` | object | Statistics object. | diff --git a/source/includes/_custom_fields.md b/source/includes/_custom_fields.md index d63e5cbb066..0aa9524dadf 100644 --- a/source/includes/_custom_fields.md +++ b/source/includes/_custom_fields.md @@ -14,6 +14,10 @@ Custom Fields allow you to add your own data-fields inside SimplyPrint. This endpoint requires the Print Farm plan. +| Required permissions | +|------------------------| +| `custom_fields_manage` | + `POST /{id}/custom_fields/Get` > Example request @@ -95,6 +99,10 @@ curl -X POST https://api.simplyprint.io/{id}/custom_fields/Get \ This endpoint requires the Print Farm plan. +| Required permissions | +|------------------------| +| `custom_fields_manage` | + `POST /{id}/custom_fields/Save` > Example request @@ -151,6 +159,10 @@ curl -X POST https://api.simplyprint.io/{id}/custom_fields/Save \ This endpoint requires the Print Farm plan. +| Required permissions | +|------------------------| +| `custom_fields_manage` | + `POST /{id}/custom_fields/SetEnabled` > Example request @@ -192,6 +204,10 @@ curl -X POST https://api.simplyprint.io/{id}/custom_fields/SetEnabled \ This endpoint requires the Print Farm plan. +| Required permissions | +|------------------------| +| `custom_fields_manage` | + `GET /{id}/custom_fields/Delete` > Example request diff --git a/source/includes/_filament.md b/source/includes/_filament.md index b5656a53baa..9ae4c19b14e 100644 --- a/source/includes/_filament.md +++ b/source/includes/_filament.md @@ -176,7 +176,7 @@ want to update. | Required permissions | |----------------------| -| `CREATE_FILAMENT` | +| `create_filament` | ### Request @@ -250,7 +250,7 @@ This endpoint deletes a filament specified by the `fid` parameter. | Required permissions | |----------------------| -| `CREATE_FILAMENT` | +| `create_filament` | ### Request @@ -300,7 +300,7 @@ This endpoint assigns filament(s) to a printer. | Required permissions | |----------------------| -| `CHANGE_FILAMENT` | +| `change_filament` | ### Request @@ -350,7 +350,7 @@ This endpoint unassigns a filament from a printer by filament id. | Required permissions | |----------------------| -| `CHANGE_FILAMENT` | +| `change_filament` | ### Request diff --git a/source/includes/_files.md b/source/includes/_files.md index e72811c55ba..af659ae5521 100644 --- a/source/includes/_files.md +++ b/source/includes/_files.md @@ -8,20 +8,18 @@ `POST {id}/files/Upload?folder={folder}` - -| Parameter | Type | Required | Description | -| --------------- | ------- | -------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------- | -| `folder` (GET) | integer | no | Folder ID to get files for. **Defaults to 0 (root folder)** | -| `fileId` (POST) | string | yes | File ID from [API Files](#api-files) +| Parameter | Type | Required | Description | +|-----------------|---------|----------|-------------------------------------------------------------| +| `folder` (GET) | integer | no | Folder ID to get files for. **Defaults to 0 (root folder)** | +| `fileId` (POST) | string | yes | File ID from [API Files](#api-files) ### Response -| Parameter | Type | Description | -| ------------ | ------- | ---------------------------------------------------------- | -| `status` | boolean | True if the request was successful. | -| `message` | string | Error message if `status` is false. | -| `id` | string | User file ID of newly added file | - +| Parameter | Type | Description | +|-----------|---------|-------------------------------------| +| `status` | boolean | True if the request was successful. | +| `message` | string | Error message if `status` is false. | +| `id` | string | User file ID of newly added file | ```shell curl -X POST https://api.simplyprint.io/{id}/files/Upload?folder=5290 \ @@ -34,9 +32,9 @@ curl -X POST https://api.simplyprint.io/{id}/files/Upload?folder=5290 \ ```json { - "status":true, - "message":null, - "id":"6f7d79212f384c6b8eae2811c37d9338" + "status": true, + "message": null, + "id": "6f7d79212f384c6b8eae2811c37d9338" } ``` @@ -188,7 +186,7 @@ This endpoint returns a list of files and folders in a given folder. If no folde `GET /{id}/files/GetFiles` | Parameter | Type | Required | Description | -| --------------- | ------- | -------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------- | +|-----------------|---------|----------|---------------------------------------------------------------------------------------------------------------------------------------------------------------------| | `f` | integer | no | Folder ID to get files for. **Defaults to 0 (root folder)** | | `search` | string | no | Search string to filter files by. | | `global_search` | boolean | no | If true, search all files in the account, not just the folder specified by `f`. | @@ -197,7 +195,7 @@ This endpoint returns a list of files and folders in a given folder. If no folde ### Response | Parameter | Type | Description | -| ------------ | ------- | ---------------------------------------------------------- | +|--------------|---------|------------------------------------------------------------| | `status` | boolean | True if the request was successful. | | `message` | string | Error message if `status` is false. | | `files` | array | Array of file objects. | @@ -231,14 +229,14 @@ This endpoint moves one or more files to a given folder. `GET /{id}/files/MoveFiles` | Parameter | Type | Required | Description | -| --------- | ------- | -------- | -------------------------------------------------------------- | +|-----------|---------|----------|----------------------------------------------------------------| | `files` | array | yes | Array of file IDs to move. Separate multiple IDs with a comma. | | `folder` | integer | yes | Folder ID to move files to. | ### Response | Parameter | Type | Description | -| --------- | ------- | ------------------------------------------------------ | +|-----------|---------|--------------------------------------------------------| | `status` | boolean | True if the request was successful. | | `message` | string | Success message or error message if `status` is false. | @@ -283,13 +281,13 @@ This endpoint returns details about a given folder. `GET /{id}/files/GetFolder` | Parameter | Type | Required | Description | -| --------- | ------- | -------- | ----------------------------- | +|-----------|---------|----------|-------------------------------| | `id` | integer | yes | Folder ID to get details for. | ### Response | Parameter | Type | Description | -| --------------------------- | ----------- | ------------------------------------------------------------------------------ | +|-----------------------------|-------------|--------------------------------------------------------------------------------| | `status` | boolean | True if the request was successful. | | `message` | string | Error message if `status` is false. | | `folder` | object | Folder object. | @@ -328,13 +326,13 @@ Also, folders cannot be moved into themselves. `GET /{id}/files/MoveFolder` | Parameter | Type | Required | Description | -| --------- | ------- | -------- | --------------------- | +|-----------|---------|----------|-----------------------| | `folder` | integer | yes | Folder ID to move. | | `target` | integer | yes | Folder ID to move to. | ### Response | Parameter | Type | Description | -| --------- | ------- | ------------------------------------------------------ | +|-----------|---------|--------------------------------------------------------| | `status` | boolean | True if the request was successful. | | `message` | string | Success message or error message if `status` is false. | diff --git a/source/includes/_printer_groups.md b/source/includes/_printer_groups.md index b31de9c50a6..65d0afbf4c1 100644 --- a/source/includes/_printer_groups.md +++ b/source/includes/_printer_groups.md @@ -62,6 +62,10 @@ curl https://api.simplyprint.io/{id}/groups/Create \ `POST /{id}/groups/Create` +| Required permissions | +|----------------------| +| `printer_edit` | + ### Request Body | Parameter | Type | Description | @@ -98,6 +102,10 @@ curl https://api.simplyprint.io/{id}/groups/Update?group=123 \ `POST /{id}/groups/Update` +| Required permissions | +|----------------------| +| `printer_edit` | + ### Request Parameters | Parameter | Type | Description | @@ -137,6 +145,10 @@ curl https://api.simplyprint.io/{id}/groups/Delete?group=123 \ `POST /{id}/groups/Delete` +| Required permissions | +|----------------------| +| `printer_edit` | + ### Request Parameters | Parameter | Type | Description | diff --git a/source/includes/_printers.md b/source/includes/_printers.md index b2f07f30d9c..cb2fd369eb8 100644 --- a/source/includes/_printers.md +++ b/source/includes/_printers.md @@ -482,7 +482,7 @@ curl https://api.simplyprint.io/{id}/printers/actions/Cancel?pid=1234 \ | Required permission | Description | |------------------------|---------------------------------------------------------------------------------------------| -| `CANCEL_OTHERS_PRINTS` | Need permission to cancel other users' prints if the print job was started by another user. | +| `cancel_others_prints` | Need permission to cancel other users' prints if the print job was started by another user. | This endpoint can be used to cancel one or multiple print jobs. The printers have to be in the `PRINTING`, `PAUSED` or `PAUSING` state. @@ -583,7 +583,7 @@ curl https://api.simplyprint.io/{id}/printers/Delete?pid=1234&just_connection=1 | Required permissions | |----------------------| -| `PRINTER_EDIT` | +| `printer_edit` | This endpoint can be used to delete a printer from the database, or to disconnect a pi from a printer. This is useful if you want to change the printer that is connected to a pi. @@ -610,6 +610,10 @@ you want to change the printer that is connected to a pi. This endpoint requires the Pro plan. +| Required permission | +|---------------------| +| `print_queue` | + ```shell curl https://api.simplyprint.io/{id}/printers/OneClickPrint?pIds=1234,1235 \ -H 'accept: application/json' \ @@ -666,6 +670,10 @@ curl https://api.simplyprint.io/{id}/printers/OneClickPrint?pIds=1234,1235 \ This endpoint requires the Print Farm plan. +| Required permission | +|---------------------| +| `autoprint_manage` | + ```shell curl https://api.simplyprint.io/{id}/printers/autoprint/SetEnabled \ -X POST \ @@ -706,6 +714,10 @@ curl https://api.simplyprint.io/{id}/printers/autoprint/SetEnabled \ This endpoint requires the Print Farm plan. +| Required permission | +|---------------------| +| `autoprint_manage` | + ```shell curl https://api.simplyprint.io/{id}/printers/autoprint/CheckState \ -H 'accept: application/json' \ @@ -753,6 +765,10 @@ curl https://api.simplyprint.io/{id}/printers/autoprint/CheckState \ This endpoint requires the Print Farm plan. +| Required permission | +|---------------------| +| `autoprint_manage` | + ```shell curl https://api.simplyprint.io/{id}/printers/autoprint/GetAutoPrintSettings \ -H 'accept: application/json' \ @@ -803,6 +819,10 @@ curl https://api.simplyprint.io/{id}/printers/autoprint/GetAutoPrintSettings \ This endpoint requires the Print Farm plan. +| Required permission | +|---------------------| +| `autoprint_manage` | + ```shell curl https://api.simplyprint.io/{id}/printers/autoprint/SaveAutoPrintSettings \ -X POST \ @@ -852,6 +872,10 @@ curl https://api.simplyprint.io/{id}/printers/autoprint/SaveAutoPrintSettings \ ## AutoPrint get gcode templates +| Required permission | +|---------------------| +| `autoprint_manage` | + @@ -911,6 +935,10 @@ curl https://api.simplyprint.io/{id}/printers/autoprint/GetGcodeTemplates \ This endpoint requires the Print Farm plan. +| Required permission | +|---------------------| +| `autoprint_manage` | + ```shell curl https://api.simplyprint.io/{id}/printers/autoprint/SetClearedBedsAmount \ -X POST \ diff --git a/source/includes/_queue.md b/source/includes/_queue.md index dde915f24f6..54dbd64bfc2 100644 --- a/source/includes/_queue.md +++ b/source/includes/_queue.md @@ -300,6 +300,10 @@ curl https://api.simplyprint.io/{id}/queue/GetItem?id=1234 \ This endpoint requires the Pro plan. +| Required permissions | +|----------------------| +| `print_queue` | + This endpoint returns the queue item with the specified id. ### Request @@ -440,6 +444,10 @@ curl https://api.simplyprint.io/{id}/queue/GetItems?p=1234 \ This endpoint requires the Pro plan. +| Required permissions | +|----------------------| +| `print_queue` | + This endpoint returns the queue for the specified or all printers. ### Request @@ -540,6 +548,10 @@ curl https://api.simplyprint.io/{id}/queue/UpdateItem?job=1234 \ This endpoint requires the Print Farm plan. +| Required permissions | +|----------------------| +| `print_queue` | + This endpoint updates the queue item with the specified id. ### Request @@ -590,6 +602,10 @@ curl https://api.simplyprint.io/{id}/queue/DeleteItem?job=1234 \ This endpoint requires the Print Farm plan. +| Required permissions | +|----------------------| +| `print_queue` | + This endpoint deletes the queue item with the specified id. ### Request @@ -628,6 +644,12 @@ curl https://api.simplyprint.io/{id}/queue/SetOrder?job=1234&from=0&to=1 \ This endpoint requires the Print Farm plan. +| Required permissions | +|----------------------| +| `print_queue` | +| `reorder_queue` | +| `queue_see_others` | + This endpoint changes the order of the queue items by moving the queue item with the specified id. ### Request @@ -670,7 +692,8 @@ curl https://api.simplyprint.io/{id}/queue/EmptyQueue \ | Required Permissions | |--------------------------| -| `PRINT_QUEUE_REMOVE_ALL` | +| `print_queue` | +| `print_queue_remove_all` | This endpoint empties the queue. @@ -695,6 +718,11 @@ This endpoint empties the queue. This endpoint requires the Print Farm plan. +| Required permissions | +|---------------------------| +| `print_queue` | +| `queue_revive_done_items` | + ```shell curl https://api.simplyprint.io/{id}/queue/ReviveItem?job=1234 \ -H 'accept: application/json' \ @@ -731,6 +759,10 @@ curl https://api.simplyprint.io/{id}/queue/ReviveItem?job=1234 \ This endpoint requires the Pro plan. +| Required permissions | +|----------------------| +| `print_queue` | + ```shell curl https://api.simplyprint.io/{id}/queue/groups/Get \ -H 'accept: application/json' \ @@ -780,6 +812,11 @@ curl https://api.simplyprint.io/{id}/queue/groups/Get \ This endpoint requires the Pro plan. +| Required permissions | +|----------------------| +| `print_queue` | +| `queue_groups` | + ```shell curl https://api.simplyprint.io/{id}/queue/groups/Save \ -X POST \ @@ -832,6 +869,11 @@ curl https://api.simplyprint.io/{id}/queue/groups/Save \ This endpoint requires the Pro plan. +| Required permissions | +|----------------------| +| `print_queue` | +| `queue_groups` | + ```shell curl https://api.simplyprint.io/{id}/queue/groups/Delete?id=123 \ -X POST \ @@ -875,6 +917,11 @@ curl https://api.simplyprint.io/{id}/queue/groups/Delete?id=123 \ This endpoint requires the Pro plan. +| Required permissions | +|----------------------| +| `queue_groups` | +| `reorder_queue` | + ```shell curl https://api.simplyprint.io/{id}/queue/groups/SetOrder?queue_group=123 \ -X POST \ diff --git a/source/includes/_schools.md b/source/includes/_schools.md index 22103fa6d49..4dec8b8ed8e 100644 --- a/source/includes/_schools.md +++ b/source/includes/_schools.md @@ -83,6 +83,10 @@ curl https://api.simplyprint.io/{id}/account/settings/school/classes/GetClasses This endpoint is only available on the School plan. +| Required permissions | +|------------------------------| +| `org_school_settings_manage` | + `POST /{id}/account/settings/school/classes/SaveClass` > Example Request diff --git a/source/includes/_slicer.md b/source/includes/_slicer.md index e2c4276988f..7b5ad27d678 100644 --- a/source/includes/_slicer.md +++ b/source/includes/_slicer.md @@ -25,7 +25,8 @@ curl https://api.simplyprint.io/{id}/slicer/ListProfiles \ } ``` -This endpoint returns a list overview of slicer profiles that the user has access to. Includes personal and company profiles. +This endpoint returns a list overview of slicer profiles that the user has access to. Includes personal and company +profiles. ### Request @@ -34,7 +35,7 @@ This endpoint returns a list overview of slicer profiles that the user has acces ### Response | Field | Type | Description | -| ------------------------- | ------- | ------------------------------------------------------------------ | +|---------------------------|---------|--------------------------------------------------------------------| | `status` | boolean | True if the request was successful. | | `message` | string | Error message if `status` is false. | | `profiles` | array | An array of profile objects. | @@ -130,13 +131,13 @@ This endpoint can be used to get a slicer profile by its ID. This includes the s `GET /{id}/printers/Delete` | Parameter | Type | Required | Description | -| --------- | ------- | -------- | ------------------------------- | +|-----------|---------|----------|---------------------------------| | `id` | integer | yes | The id of the profile to fetch. | ### Response | Field | Type | Description | -| ---------------------- | ------- | ------------------------------------------------------------------ | +|------------------------|---------|--------------------------------------------------------------------| | `status` | boolean | True if the request was successful. | | `message` | string | Error message if `status` is false. | | `profile` | object | The profile object. | @@ -174,8 +175,8 @@ curl https://api.simplyprint.io/{id}/slicer/DeleteProfile?id=1234 \ ``` | Required permissions | Description | -| --------------------- | --------------------------------------- | -| `SLICER_ORG_PROFILES` | If the profile is owned by the company. | +|-----------------------|-----------------------------------------| +| `slicer_org_profiles` | If the profile is owned by the company. | This endpoint can be used to delete a slicer profile by its ID. @@ -184,12 +185,12 @@ This endpoint can be used to delete a slicer profile by its ID. `GET /{id}/printers/Delete` | Parameter | Type | Required | Description | -| --------- | ------- | -------- | -------------------------------- | +|-----------|---------|----------|----------------------------------| | `id` | integer | yes | The id of the profile to delete. | ### Response | Field | Type | Description | -| --------- | ------- | ----------------------------------- | +|-----------|---------|-------------------------------------| | `status` | boolean | True if the request was successful. | | `message` | string | Error message if `status` is false. | diff --git a/source/includes/_tags.md b/source/includes/_tags.md index 77bb82f90f9..484a2287225 100644 --- a/source/includes/_tags.md +++ b/source/includes/_tags.md @@ -51,7 +51,7 @@ curl -X POST https://api.simplyprint.io/{id}/tags/Create \ | Required permissions | |----------------------| -| `EDIT_TAGS` | +| `edit_tags` | This endpoint creates or updates a custom tag. @@ -205,7 +205,7 @@ curl https://api.simplyprint.io/{id}/tags/Delete?id=2 \ | Required permissions | |----------------------| -| `EDIT_TAGS` | +| `edit_tags` | This endpoint deletes a custom tag. diff --git a/source/includes/_users.md b/source/includes/_users.md index e259b0b7850..45cb97924cc 100644 --- a/source/includes/_users.md +++ b/source/includes/_users.md @@ -59,7 +59,7 @@ curl https://api.simplyprint.io/{id}/users/GetPaginatedUsers \ | Required permissions | |----------------------| -| `VIEW_USERS` | +| `view_users` | ### Request @@ -133,7 +133,7 @@ curl https://api.simplyprint.io/{id}/users/CreateInvitationLink \ | Required permissions | |----------------------| -| `INVITE_USERS` | +| `invite_users` | This endpoint creates an invitation link that can be used to invite new users to the company. Please note that links with unlimited uses expire at the end of the day. @@ -191,7 +191,7 @@ curl https://api.simplyprint.io/{id}/users/InviteSpecificUser \ | Required permissions | |----------------------| -| `INVITE_USERS` | +| `invite_users` | This endpoint invites one or more users to the company by email. @@ -245,7 +245,7 @@ curl https://api.simplyprint.io/{id}/users/SetPendingUserState \ | Required permissions | |----------------------| -| `INVITE_USERS` | +| `invite_users` | ### Request @@ -339,7 +339,7 @@ curl https://api.simplyprint.io/{id}/users/DeleteUser \ | Required permissions | |----------------------| -| `DELETE_USER` | +| `delete_user` | This endpoint deletes a user from the company. Use this endpoint with caution. diff --git a/source/includes/_webhooks.md b/source/includes/_webhooks.md index fca95a22908..bd38aec6f89 100644 --- a/source/includes/_webhooks.md +++ b/source/includes/_webhooks.md @@ -13,6 +13,10 @@ When one of those events is triggered, we'll send an HTTP POST payload to the we This endpoint is only available on the Print Farm plan. +| Required permissions | +|----------------------| +| `webhooks_manage` | + `GET /{id}/webhooks/Get` > Example request @@ -73,6 +77,10 @@ curl "https://api.simplyprint.io/{id}/webhooks/Get" \ This endpoint is only available on the Print Farm plan. +| Required permissions | +|----------------------| +| `webhooks_manage` | + `POST /{id}/webhooks/Create` > Example request @@ -135,6 +143,10 @@ https://api.simplyprint.io/{id}/webhooks/Create \ This endpoint is only available on the Print Farm plan. +| Required permissions | +|----------------------| +| `webhooks_manage` | + `POST /{id}/webhooks/Delete` > Example request @@ -176,6 +188,10 @@ https://api.simplyprint.io/{id}/webhooks/Delete \ This endpoint is only available on the Print Farm plan. +| Required permissions | +|----------------------| +| `webhooks_manage` | + `POST /{id}/webhooks/SetEnabled` > Example request diff --git a/source/includes/gcode_macros.md b/source/includes/gcode_macros.md index fd7cf6e2656..d7cf81e0400 100644 --- a/source/includes/gcode_macros.md +++ b/source/includes/gcode_macros.md @@ -297,6 +297,10 @@ curl -X POST https://api.simplyprint.io/gcode_macros/SaveMacro?type=private \ } ``` +| Required permission | Description | +|---------------------|-------------------------------------| +| `gcode_profiles` | Required if macro is of type `org`. | + `POST /gcode_macros/SaveMacro` ### Request Parameters