library_structure_controller = client.library_structure
LibraryStructureController
- Add Media Path
- Add Virtual Folder
- Get Virtual Folders
- Remove Media Path
- Remove Virtual Folder
- Rename Virtual Folder
- Update Library Options
- Update Media Path
Add a media path to a library.
def add_media_path(self,
body,
refresh_library=False)
Parameter | Type | Tags | Description |
---|---|---|---|
body |
MediaPathDto |
Body, Required | The media path dto. |
refresh_library |
bool |
Query, Optional | Whether to refresh the library. Default: False |
void
body = MediaPathDto()
body.name = 'Name6'
refresh_library = False
result = library_structure_controller.add_media_path(body, refresh_library)
HTTP Status Code | Error Description | Exception Class |
---|---|---|
401 | Unauthorized | APIException |
403 | Forbidden | APIException |
Adds a virtual folder.
def add_virtual_folder(self,
name=None,
collection_type=None,
paths=None,
refresh_library=False,
body=None)
Parameter | Type | Tags | Description |
---|---|---|---|
name |
string |
Query, Optional | The name of the virtual folder. |
collection_type |
CollectionTypeOptionsEnum |
Query, Optional | The type of the collection. |
paths |
List of string |
Query, Optional | The paths of the virtual folder. |
refresh_library |
bool |
Query, Optional | Whether to refresh the library. Default: False |
body |
AddVirtualFolderDto |
Body, Optional | The library options. |
void
refresh_library = False
result = library_structure_controller.add_virtual_folder(None, None, None, refresh_library)
HTTP Status Code | Error Description | Exception Class |
---|---|---|
401 | Unauthorized | APIException |
403 | Forbidden | APIException |
Gets all virtual folders.
def get_virtual_folders(self)
result = library_structure_controller.get_virtual_folders()
HTTP Status Code | Error Description | Exception Class |
---|---|---|
401 | Unauthorized | APIException |
403 | Forbidden | APIException |
Remove a media path.
def remove_media_path(self,
name=None,
path=None,
refresh_library=False)
Parameter | Type | Tags | Description |
---|---|---|---|
name |
string |
Query, Optional | The name of the library. |
path |
string |
Query, Optional | The path to remove. |
refresh_library |
bool |
Query, Optional | Whether to refresh the library. Default: False |
void
refresh_library = False
result = library_structure_controller.remove_media_path(None, None, refresh_library)
HTTP Status Code | Error Description | Exception Class |
---|---|---|
401 | Unauthorized | APIException |
403 | Forbidden | APIException |
Removes a virtual folder.
def remove_virtual_folder(self,
name=None,
refresh_library=False)
Parameter | Type | Tags | Description |
---|---|---|---|
name |
string |
Query, Optional | The name of the folder. |
refresh_library |
bool |
Query, Optional | Whether to refresh the library. Default: False |
void
refresh_library = False
result = library_structure_controller.remove_virtual_folder(None, refresh_library)
HTTP Status Code | Error Description | Exception Class |
---|---|---|
401 | Unauthorized | APIException |
403 | Forbidden | APIException |
Renames a virtual folder.
def rename_virtual_folder(self,
name=None,
new_name=None,
refresh_library=False)
Parameter | Type | Tags | Description |
---|---|---|---|
name |
string |
Query, Optional | The name of the virtual folder. |
new_name |
string |
Query, Optional | The new name. |
refresh_library |
bool |
Query, Optional | Whether to refresh the library. Default: False |
void
refresh_library = False
result = library_structure_controller.rename_virtual_folder(None, None, refresh_library)
HTTP Status Code | Error Description | Exception Class |
---|---|---|
401 | Unauthorized | APIException |
403 | Forbidden | APIException |
404 | Library doesn't exist. | ProblemDetailsException |
409 | Library already exists. | ProblemDetailsException |
Update library options.
def update_library_options(self,
body=None)
Parameter | Type | Tags | Description |
---|---|---|---|
body |
UpdateLibraryOptionsDto |
Body, Optional | The library name and options. |
void
result = library_structure_controller.update_library_options()
HTTP Status Code | Error Description | Exception Class |
---|---|---|
401 | Unauthorized | APIException |
403 | Forbidden | APIException |
Updates a media path.
def update_media_path(self,
body)
Parameter | Type | Tags | Description |
---|---|---|---|
body |
UpdateMediaPathRequestDto |
Body, Required | The name of the library and path infos. |
void
body = UpdateMediaPathRequestDto()
body.name = 'Name6'
body.path_info = MediaPathInfo()
result = library_structure_controller.update_media_path(body)
HTTP Status Code | Error Description | Exception Class |
---|---|---|
401 | Unauthorized | APIException |
403 | Forbidden | APIException |