immichpy 1.6.5__py3-none-any.whl → 1.7.6__py3-none-any.whl
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- immichpy/cli/__main__.py +1 -1
- immichpy/cli/commands/activities.py +23 -11
- immichpy/cli/commands/albums.py +34 -20
- immichpy/cli/commands/api_keys.py +6 -4
- immichpy/cli/commands/assets.py +274 -65
- immichpy/cli/commands/authentication.py +115 -25
- immichpy/cli/commands/database_backups_admin.py +111 -0
- immichpy/cli/commands/download.py +13 -5
- immichpy/cli/commands/duplicates.py +1 -1
- immichpy/cli/commands/faces.py +17 -11
- immichpy/cli/commands/jobs.py +6 -4
- immichpy/cli/commands/libraries.py +15 -9
- immichpy/cli/commands/maintenance_admin.py +39 -2
- immichpy/cli/commands/map.py +8 -8
- immichpy/cli/commands/memories.py +35 -21
- immichpy/cli/commands/notifications.py +16 -8
- immichpy/cli/commands/notifications_admin.py +43 -17
- immichpy/cli/commands/partners.py +9 -3
- immichpy/cli/commands/people.py +30 -24
- immichpy/cli/commands/plugins.py +14 -0
- immichpy/cli/commands/queues.py +8 -6
- immichpy/cli/commands/search.py +395 -189
- immichpy/cli/commands/server.py +6 -2
- immichpy/cli/commands/sessions.py +6 -4
- immichpy/cli/commands/shared_links.py +42 -25
- immichpy/cli/commands/stacks.py +4 -4
- immichpy/cli/commands/sync.py +26 -10
- immichpy/cli/commands/system_config.py +216 -115
- immichpy/cli/commands/system_metadata.py +3 -1
- immichpy/cli/commands/tags.py +9 -9
- immichpy/cli/commands/trash.py +1 -1
- immichpy/cli/commands/users.py +57 -29
- immichpy/cli/commands/users_admin.py +79 -45
- immichpy/cli/commands/workflows.py +40 -11
- immichpy/cli/main.py +10 -2
- immichpy/cli/utils.py +2 -2
- immichpy/cli/wrapper/setup.py +1 -1
- immichpy/client/.openapi-generator/FILES +26 -2
- immichpy/client/generated/__init__.py +101 -7
- immichpy/client/generated/api/__init__.py +3 -0
- immichpy/client/generated/api/activities_api.py +73 -43
- immichpy/client/generated/api/albums_api.py +40 -19
- immichpy/client/generated/api/api_keys_api.py +1 -1
- immichpy/client/generated/api/assets_api.py +1768 -366
- immichpy/client/generated/api/authentication_admin_api.py +1 -1
- immichpy/client/generated/api/authentication_api.py +1 -1
- immichpy/client/generated/api/database_backups_admin_api.py +1224 -0
- immichpy/client/generated/api/deprecated_api.py +103 -73
- immichpy/client/generated/api/download_api.py +1 -1
- immichpy/client/generated/api/duplicates_api.py +1 -1
- immichpy/client/generated/api/faces_api.py +7 -7
- immichpy/client/generated/api/jobs_api.py +7 -7
- immichpy/client/generated/api/libraries_api.py +1 -1
- immichpy/client/generated/api/maintenance_admin_api.py +459 -1
- immichpy/client/generated/api/map_api.py +103 -49
- immichpy/client/generated/api/memories_api.py +109 -61
- immichpy/client/generated/api/notifications_admin_api.py +1 -1
- immichpy/client/generated/api/notifications_api.py +52 -25
- immichpy/client/generated/api/partners_api.py +7 -7
- immichpy/client/generated/api/people_api.py +37 -19
- immichpy/client/generated/api/plugins_api.py +230 -1
- immichpy/client/generated/api/queues_api.py +37 -31
- immichpy/client/generated/api/search_api.py +529 -283
- immichpy/client/generated/api/server_api.py +1 -1
- immichpy/client/generated/api/sessions_api.py +1 -1
- immichpy/client/generated/api/shared_links_api.py +53 -19
- immichpy/client/generated/api/stacks_api.py +13 -7
- immichpy/client/generated/api/sync_api.py +1 -1
- immichpy/client/generated/api/system_config_api.py +1 -1
- immichpy/client/generated/api/system_metadata_api.py +1 -1
- immichpy/client/generated/api/tags_api.py +1 -1
- immichpy/client/generated/api/timeline_api.py +1 -1
- immichpy/client/generated/api/trash_api.py +1 -1
- immichpy/client/generated/api/users_admin_api.py +55 -31
- immichpy/client/generated/api/users_api.py +16 -7
- immichpy/client/generated/api/views_api.py +1 -1
- immichpy/client/generated/api/workflows_api.py +1 -1
- immichpy/client/generated/api_client.py +1 -1
- immichpy/client/generated/configuration.py +2 -2
- immichpy/client/generated/exceptions.py +1 -1
- immichpy/client/generated/models/__init__.py +56 -3
- immichpy/client/generated/models/activity_create_dto.py +11 -5
- immichpy/client/generated/models/activity_response_dto.py +10 -6
- immichpy/client/generated/models/activity_statistics_response_dto.py +4 -4
- immichpy/client/generated/models/add_users_dto.py +2 -2
- immichpy/client/generated/models/admin_onboarding_update_dto.py +4 -2
- immichpy/client/generated/models/album_response_dto.py +28 -16
- immichpy/client/generated/models/album_statistics_response_dto.py +6 -4
- immichpy/client/generated/models/album_user_add_dto.py +3 -3
- immichpy/client/generated/models/album_user_create_dto.py +3 -3
- immichpy/client/generated/models/album_user_response_dto.py +3 -3
- immichpy/client/generated/models/album_user_role.py +2 -2
- immichpy/client/generated/models/albums_add_assets_dto.py +3 -3
- immichpy/client/generated/models/albums_add_assets_response_dto.py +4 -4
- immichpy/client/generated/models/albums_response.py +4 -2
- immichpy/client/generated/models/albums_update.py +5 -3
- immichpy/client/generated/models/api_key_create_dto.py +5 -3
- immichpy/client/generated/models/api_key_create_response_dto.py +2 -2
- immichpy/client/generated/models/api_key_response_dto.py +6 -6
- immichpy/client/generated/models/api_key_update_dto.py +5 -3
- immichpy/client/generated/models/asset_bulk_delete_dto.py +6 -4
- immichpy/client/generated/models/asset_bulk_update_dto.py +28 -12
- immichpy/client/generated/models/asset_bulk_upload_check_dto.py +3 -3
- immichpy/client/generated/models/asset_bulk_upload_check_item.py +3 -3
- immichpy/client/generated/models/asset_bulk_upload_check_response_dto.py +5 -3
- immichpy/client/generated/models/asset_bulk_upload_check_result.py +12 -6
- immichpy/client/generated/models/asset_copy_dto.py +16 -8
- immichpy/client/generated/models/asset_delta_sync_dto.py +5 -3
- immichpy/client/generated/models/asset_delta_sync_response_dto.py +6 -4
- immichpy/client/generated/models/asset_edit_action.py +35 -0
- immichpy/client/generated/models/asset_edit_action_crop.py +95 -0
- immichpy/client/generated/models/asset_edit_action_list_dto.py +104 -0
- immichpy/client/generated/models/asset_edit_action_list_dto_edits_inner.py +188 -0
- immichpy/client/generated/models/asset_edit_action_mirror.py +95 -0
- immichpy/client/generated/models/asset_edit_action_rotate.py +95 -0
- immichpy/client/generated/models/asset_edits_dto.py +107 -0
- immichpy/client/generated/models/asset_face_create_dto.py +13 -9
- immichpy/client/generated/models/asset_face_delete_dto.py +3 -3
- immichpy/client/generated/models/asset_face_response_dto.py +26 -10
- immichpy/client/generated/models/asset_face_update_dto.py +3 -3
- immichpy/client/generated/models/asset_face_update_item.py +3 -3
- immichpy/client/generated/models/asset_face_without_person_response_dto.py +23 -9
- immichpy/client/generated/models/asset_full_sync_dto.py +13 -5
- immichpy/client/generated/models/asset_ids_dto.py +2 -2
- immichpy/client/generated/models/asset_ids_response_dto.py +6 -4
- immichpy/client/generated/models/asset_job_name.py +2 -2
- immichpy/client/generated/models/asset_jobs_dto.py +3 -3
- immichpy/client/generated/models/asset_media_response_dto.py +4 -4
- immichpy/client/generated/models/asset_media_size.py +2 -1
- immichpy/client/generated/models/asset_media_status.py +2 -2
- immichpy/client/generated/models/asset_metadata_bulk_delete_dto.py +103 -0
- immichpy/client/generated/models/asset_metadata_bulk_delete_item_dto.py +86 -0
- immichpy/client/generated/models/asset_metadata_bulk_response_dto.py +93 -0
- immichpy/client/generated/models/asset_metadata_bulk_upsert_dto.py +103 -0
- immichpy/client/generated/models/asset_metadata_bulk_upsert_item_dto.py +91 -0
- immichpy/client/generated/models/asset_metadata_response_dto.py +5 -6
- immichpy/client/generated/models/asset_metadata_upsert_dto.py +5 -3
- immichpy/client/generated/models/asset_metadata_upsert_item_dto.py +4 -5
- immichpy/client/generated/models/asset_ocr_response_dto.py +1 -1
- immichpy/client/generated/models/asset_order.py +2 -2
- immichpy/client/generated/models/asset_response_dto.py +66 -24
- immichpy/client/generated/models/asset_stack_response_dto.py +8 -4
- immichpy/client/generated/models/asset_stats_response_dto.py +5 -5
- immichpy/client/generated/models/asset_type_enum.py +2 -2
- immichpy/client/generated/models/asset_visibility.py +2 -2
- immichpy/client/generated/models/audio_codec.py +2 -2
- immichpy/client/generated/models/auth_status_response_dto.py +12 -6
- immichpy/client/generated/models/avatar_update.py +3 -3
- immichpy/client/generated/models/bulk_id_error_reason.py +2 -2
- immichpy/client/generated/models/bulk_id_response_dto.py +14 -5
- immichpy/client/generated/models/bulk_ids_dto.py +3 -3
- immichpy/client/generated/models/cast_response.py +4 -2
- immichpy/client/generated/models/cast_update.py +4 -2
- immichpy/client/generated/models/change_password_dto.py +6 -4
- immichpy/client/generated/models/check_existing_assets_dto.py +3 -3
- immichpy/client/generated/models/check_existing_assets_response_dto.py +4 -2
- immichpy/client/generated/models/clip_config.py +5 -3
- immichpy/client/generated/models/colorspace.py +1 -1
- immichpy/client/generated/models/contributor_count_response_dto.py +5 -3
- immichpy/client/generated/models/cq_mode.py +2 -2
- immichpy/client/generated/models/create_album_dto.py +9 -5
- immichpy/client/generated/models/create_library_dto.py +9 -5
- immichpy/client/generated/models/create_profile_image_response_dto.py +8 -4
- immichpy/client/generated/models/crop_parameters.py +105 -0
- immichpy/client/generated/models/database_backup_config.py +6 -4
- immichpy/client/generated/models/database_backup_delete_dto.py +82 -0
- immichpy/client/generated/models/database_backup_dto.py +85 -0
- immichpy/client/generated/models/database_backup_list_response_dto.py +98 -0
- immichpy/client/generated/models/download_archive_info.py +5 -3
- immichpy/client/generated/models/download_info_dto.py +11 -5
- immichpy/client/generated/models/download_response.py +8 -3
- immichpy/client/generated/models/download_response_dto.py +3 -3
- immichpy/client/generated/models/download_update.py +5 -3
- immichpy/client/generated/models/duplicate_detection_config.py +6 -3
- immichpy/client/generated/models/duplicate_response_dto.py +5 -3
- immichpy/client/generated/models/email_notifications_response.py +10 -4
- immichpy/client/generated/models/email_notifications_update.py +14 -4
- immichpy/client/generated/models/exif_response_dto.py +47 -23
- immichpy/client/generated/models/face_dto.py +3 -3
- immichpy/client/generated/models/facial_recognition_config.py +15 -6
- immichpy/client/generated/models/folders_response.py +5 -3
- immichpy/client/generated/models/folders_update.py +9 -3
- immichpy/client/generated/models/image_format.py +2 -2
- immichpy/client/generated/models/job_create_dto.py +3 -3
- immichpy/client/generated/models/job_name.py +3 -2
- immichpy/client/generated/models/job_settings_dto.py +4 -2
- immichpy/client/generated/models/library_response_dto.py +16 -10
- immichpy/client/generated/models/library_stats_response_dto.py +6 -6
- immichpy/client/generated/models/license_key_dto.py +7 -3
- immichpy/client/generated/models/license_response_dto.py +8 -4
- immichpy/client/generated/models/log_level.py +1 -1
- immichpy/client/generated/models/login_credential_dto.py +4 -4
- immichpy/client/generated/models/login_response_dto.py +13 -9
- immichpy/client/generated/models/logout_response_dto.py +3 -3
- immichpy/client/generated/models/machine_learning_availability_checks_dto.py +3 -3
- immichpy/client/generated/models/maintenance_action.py +4 -2
- immichpy/client/generated/models/maintenance_auth_dto.py +3 -3
- immichpy/client/generated/models/maintenance_detect_install_response_dto.py +101 -0
- immichpy/client/generated/models/maintenance_detect_install_storage_folder_dto.py +95 -0
- immichpy/client/generated/models/maintenance_login_dto.py +3 -3
- immichpy/client/generated/models/maintenance_status_response_dto.py +109 -0
- immichpy/client/generated/models/manual_job_name.py +2 -2
- immichpy/client/generated/models/map_marker_response_dto.py +8 -8
- immichpy/client/generated/models/map_reverse_geocode_response_dto.py +5 -5
- immichpy/client/generated/models/memories_response.py +4 -4
- immichpy/client/generated/models/memories_update.py +7 -3
- immichpy/client/generated/models/memory_create_dto.py +12 -6
- immichpy/client/generated/models/memory_response_dto.py +20 -12
- immichpy/client/generated/models/memory_search_order.py +1 -1
- immichpy/client/generated/models/memory_statistics_response_dto.py +3 -3
- immichpy/client/generated/models/memory_type.py +1 -1
- immichpy/client/generated/models/memory_update_dto.py +10 -4
- immichpy/client/generated/models/merge_person_dto.py +3 -3
- immichpy/client/generated/models/metadata_search_dto.py +124 -46
- immichpy/client/generated/models/{asset_metadata_key.py → mirror_axis.py} +6 -5
- immichpy/client/generated/models/mirror_parameters.py +83 -0
- immichpy/client/generated/models/notification_create_dto.py +18 -8
- immichpy/client/generated/models/notification_delete_all_dto.py +3 -3
- immichpy/client/generated/models/notification_dto.py +15 -9
- immichpy/client/generated/models/notification_level.py +1 -1
- immichpy/client/generated/models/notification_type.py +1 -1
- immichpy/client/generated/models/notification_update_all_dto.py +5 -3
- immichpy/client/generated/models/notification_update_dto.py +4 -2
- immichpy/client/generated/models/o_auth_authorize_response_dto.py +3 -3
- immichpy/client/generated/models/o_auth_callback_dto.py +8 -4
- immichpy/client/generated/models/o_auth_config_dto.py +10 -4
- immichpy/client/generated/models/o_auth_token_endpoint_auth_method.py +2 -2
- immichpy/client/generated/models/ocr_config.py +14 -6
- immichpy/client/generated/models/on_this_day_dto.py +2 -2
- immichpy/client/generated/models/onboarding_dto.py +4 -2
- immichpy/client/generated/models/onboarding_response_dto.py +4 -2
- immichpy/client/generated/models/partner_create_dto.py +4 -2
- immichpy/client/generated/models/partner_direction.py +1 -1
- immichpy/client/generated/models/partner_response_dto.py +16 -8
- immichpy/client/generated/models/partner_update_dto.py +4 -2
- immichpy/client/generated/models/people_response.py +5 -3
- immichpy/client/generated/models/people_response_dto.py +7 -5
- immichpy/client/generated/models/people_update.py +9 -3
- immichpy/client/generated/models/people_update_dto.py +3 -3
- immichpy/client/generated/models/people_update_item.py +10 -10
- immichpy/client/generated/models/permission.py +13 -2
- immichpy/client/generated/models/person_create_dto.py +8 -8
- immichpy/client/generated/models/person_response_dto.py +17 -9
- immichpy/client/generated/models/person_statistics_response_dto.py +3 -3
- immichpy/client/generated/models/person_update_dto.py +9 -9
- immichpy/client/generated/models/person_with_faces_response_dto.py +20 -10
- immichpy/client/generated/models/pin_code_change_dto.py +10 -4
- immichpy/client/generated/models/pin_code_reset_dto.py +7 -3
- immichpy/client/generated/models/pin_code_setup_dto.py +2 -2
- immichpy/client/generated/models/places_response_dto.py +11 -7
- immichpy/client/generated/models/plugin_action_response_dto.py +13 -9
- immichpy/client/generated/models/{plugin_context.py → plugin_context_type.py} +4 -4
- immichpy/client/generated/models/plugin_filter_response_dto.py +13 -9
- immichpy/client/generated/models/plugin_response_dto.py +11 -11
- immichpy/client/generated/models/plugin_trigger_response_dto.py +89 -0
- immichpy/client/generated/models/plugin_trigger_type.py +2 -2
- immichpy/client/generated/models/purchase_response.py +7 -3
- immichpy/client/generated/models/purchase_update.py +7 -3
- immichpy/client/generated/models/queue_command.py +2 -2
- immichpy/client/generated/models/queue_command_dto.py +6 -4
- immichpy/client/generated/models/queue_delete_dto.py +1 -1
- immichpy/client/generated/models/queue_job_response_dto.py +6 -6
- immichpy/client/generated/models/queue_job_status.py +1 -1
- immichpy/client/generated/models/queue_name.py +2 -1
- immichpy/client/generated/models/queue_response_dto.py +5 -3
- immichpy/client/generated/models/queue_response_legacy_dto.py +1 -1
- immichpy/client/generated/models/queue_statistics_dto.py +8 -8
- immichpy/client/generated/models/queue_status_legacy_dto.py +8 -3
- immichpy/client/generated/models/queue_update_dto.py +4 -2
- immichpy/client/generated/models/queues_response_legacy_dto.py +9 -1
- immichpy/client/generated/models/random_search_dto.py +96 -34
- immichpy/client/generated/models/ratings_response.py +3 -3
- immichpy/client/generated/models/ratings_update.py +5 -3
- immichpy/client/generated/models/reaction_level.py +1 -1
- immichpy/client/generated/models/reaction_type.py +1 -1
- immichpy/client/generated/models/reverse_geocoding_state_response_dto.py +7 -3
- immichpy/client/generated/models/rotate_parameters.py +84 -0
- immichpy/client/generated/models/search_album_response_dto.py +4 -4
- immichpy/client/generated/models/search_asset_response_dto.py +6 -4
- immichpy/client/generated/models/search_explore_item.py +3 -3
- immichpy/client/generated/models/search_explore_response_dto.py +2 -2
- immichpy/client/generated/models/search_facet_count_response_dto.py +4 -4
- immichpy/client/generated/models/search_facet_response_dto.py +3 -3
- immichpy/client/generated/models/search_response_dto.py +1 -1
- immichpy/client/generated/models/search_statistics_response_dto.py +3 -3
- immichpy/client/generated/models/search_suggestion_type.py +1 -1
- immichpy/client/generated/models/server_about_response_dto.py +46 -22
- immichpy/client/generated/models/server_apk_links_dto.py +12 -6
- immichpy/client/generated/models/server_config_dto.py +36 -12
- immichpy/client/generated/models/server_features_dto.py +32 -16
- immichpy/client/generated/models/server_media_types_response_dto.py +5 -5
- immichpy/client/generated/models/server_ping_response.py +1 -1
- immichpy/client/generated/models/server_stats_response_dto.py +10 -6
- immichpy/client/generated/models/server_storage_response_dto.py +21 -8
- immichpy/client/generated/models/server_theme_dto.py +4 -2
- immichpy/client/generated/models/server_version_history_response_dto.py +6 -4
- immichpy/client/generated/models/server_version_response_dto.py +5 -5
- immichpy/client/generated/models/session_create_dto.py +8 -4
- immichpy/client/generated/models/session_create_response_dto.py +17 -11
- immichpy/client/generated/models/session_response_dto.py +16 -10
- immichpy/client/generated/models/session_unlock_dto.py +7 -3
- immichpy/client/generated/models/session_update_dto.py +2 -2
- immichpy/client/generated/models/set_maintenance_mode_dto.py +17 -7
- immichpy/client/generated/models/shared_link_create_dto.py +25 -11
- immichpy/client/generated/models/shared_link_edit_dto.py +19 -9
- immichpy/client/generated/models/shared_link_response_dto.py +18 -14
- immichpy/client/generated/models/shared_link_type.py +2 -2
- immichpy/client/generated/models/shared_links_response.py +5 -3
- immichpy/client/generated/models/shared_links_update.py +9 -3
- immichpy/client/generated/models/sign_up_dto.py +5 -5
- immichpy/client/generated/models/smart_search_dto.py +102 -36
- immichpy/client/generated/models/source_type.py +2 -2
- immichpy/client/generated/models/stack_create_dto.py +2 -2
- immichpy/client/generated/models/stack_response_dto.py +6 -4
- immichpy/client/generated/models/stack_update_dto.py +4 -2
- immichpy/client/generated/models/statistics_search_dto.py +86 -30
- immichpy/client/generated/models/storage_folder.py +38 -0
- immichpy/client/generated/models/sync_ack_delete_dto.py +5 -3
- immichpy/client/generated/models/sync_ack_dto.py +4 -4
- immichpy/client/generated/models/sync_ack_set_dto.py +4 -2
- immichpy/client/generated/models/sync_album_delete_v1.py +2 -2
- immichpy/client/generated/models/sync_album_to_asset_delete_v1.py +3 -3
- immichpy/client/generated/models/sync_album_to_asset_v1.py +3 -3
- immichpy/client/generated/models/sync_album_user_delete_v1.py +3 -3
- immichpy/client/generated/models/sync_album_user_v1.py +4 -4
- immichpy/client/generated/models/sync_album_v1.py +13 -9
- immichpy/client/generated/models/sync_asset_delete_v1.py +2 -2
- immichpy/client/generated/models/sync_asset_exif_v1.py +46 -26
- immichpy/client/generated/models/sync_asset_face_delete_v1.py +2 -2
- immichpy/client/generated/models/sync_asset_face_v1.py +5 -5
- immichpy/client/generated/models/sync_asset_metadata_delete_v1.py +3 -4
- immichpy/client/generated/models/sync_asset_metadata_v1.py +4 -5
- immichpy/client/generated/models/sync_asset_v1.py +47 -18
- immichpy/client/generated/models/sync_auth_user_v1.py +22 -12
- immichpy/client/generated/models/sync_entity_type.py +2 -2
- immichpy/client/generated/models/sync_memory_asset_delete_v1.py +3 -3
- immichpy/client/generated/models/sync_memory_asset_v1.py +3 -3
- immichpy/client/generated/models/sync_memory_delete_v1.py +2 -2
- immichpy/client/generated/models/sync_memory_v1.py +13 -13
- immichpy/client/generated/models/sync_partner_delete_v1.py +5 -3
- immichpy/client/generated/models/sync_partner_v1.py +6 -4
- immichpy/client/generated/models/sync_person_delete_v1.py +2 -2
- immichpy/client/generated/models/sync_person_v1.py +13 -11
- immichpy/client/generated/models/sync_request_type.py +2 -2
- immichpy/client/generated/models/sync_stack_delete_v1.py +2 -2
- immichpy/client/generated/models/sync_stack_v1.py +8 -6
- immichpy/client/generated/models/sync_stream_dto.py +4 -4
- immichpy/client/generated/models/sync_user_delete_v1.py +2 -2
- immichpy/client/generated/models/sync_user_metadata_delete_v1.py +3 -3
- immichpy/client/generated/models/sync_user_metadata_v1.py +4 -4
- immichpy/client/generated/models/sync_user_v1.py +16 -8
- immichpy/client/generated/models/system_config_backups_dto.py +1 -1
- immichpy/client/generated/models/system_config_dto.py +1 -1
- immichpy/client/generated/models/system_config_f_fmpeg_dto.py +44 -22
- immichpy/client/generated/models/system_config_faces_dto.py +2 -2
- immichpy/client/generated/models/system_config_generated_fullsize_image_dto.py +13 -7
- immichpy/client/generated/models/system_config_generated_image_dto.py +14 -8
- immichpy/client/generated/models/system_config_image_dto.py +5 -3
- immichpy/client/generated/models/system_config_job_dto.py +9 -1
- immichpy/client/generated/models/system_config_library_dto.py +1 -1
- immichpy/client/generated/models/system_config_library_scan_dto.py +2 -2
- immichpy/client/generated/models/system_config_library_watch_dto.py +3 -3
- immichpy/client/generated/models/system_config_logging_dto.py +3 -3
- immichpy/client/generated/models/system_config_machine_learning_dto.py +2 -2
- immichpy/client/generated/models/system_config_map_dto.py +2 -2
- immichpy/client/generated/models/system_config_metadata_dto.py +1 -1
- immichpy/client/generated/models/system_config_new_version_check_dto.py +3 -3
- immichpy/client/generated/models/system_config_nightly_tasks_dto.py +16 -6
- immichpy/client/generated/models/system_config_notifications_dto.py +1 -1
- immichpy/client/generated/models/system_config_o_auth_dto.py +28 -18
- immichpy/client/generated/models/system_config_password_login_dto.py +3 -3
- immichpy/client/generated/models/system_config_reverse_geocoding_dto.py +3 -3
- immichpy/client/generated/models/system_config_server_dto.py +8 -4
- immichpy/client/generated/models/system_config_smtp_dto.py +8 -4
- immichpy/client/generated/models/system_config_smtp_transport_dto.py +9 -7
- immichpy/client/generated/models/system_config_storage_template_dto.py +6 -4
- immichpy/client/generated/models/system_config_template_emails_dto.py +1 -1
- immichpy/client/generated/models/system_config_template_storage_option_dto.py +32 -9
- immichpy/client/generated/models/system_config_templates_dto.py +1 -1
- immichpy/client/generated/models/system_config_theme_dto.py +4 -2
- immichpy/client/generated/models/system_config_trash_dto.py +3 -3
- immichpy/client/generated/models/system_config_user_dto.py +4 -2
- immichpy/client/generated/models/tag_bulk_assets_dto.py +3 -3
- immichpy/client/generated/models/tag_bulk_assets_response_dto.py +3 -3
- immichpy/client/generated/models/tag_create_dto.py +8 -4
- immichpy/client/generated/models/tag_response_dto.py +10 -8
- immichpy/client/generated/models/tag_update_dto.py +3 -3
- immichpy/client/generated/models/tag_upsert_dto.py +3 -3
- immichpy/client/generated/models/tags_response.py +5 -3
- immichpy/client/generated/models/tags_update.py +9 -3
- immichpy/client/generated/models/template_dto.py +3 -3
- immichpy/client/generated/models/template_response_dto.py +4 -4
- immichpy/client/generated/models/test_email_response_dto.py +2 -2
- immichpy/client/generated/models/time_bucket_asset_response_dto.py +2 -3
- immichpy/client/generated/models/time_buckets_response_dto.py +1 -1
- immichpy/client/generated/models/tone_mapping.py +2 -2
- immichpy/client/generated/models/transcode_hw_accel.py +2 -2
- immichpy/client/generated/models/transcode_policy.py +2 -2
- immichpy/client/generated/models/trash_response_dto.py +3 -3
- immichpy/client/generated/models/update_album_dto.py +12 -6
- immichpy/client/generated/models/update_album_user_dto.py +3 -3
- immichpy/client/generated/models/update_asset_dto.py +21 -9
- immichpy/client/generated/models/update_library_dto.py +8 -4
- immichpy/client/generated/models/usage_by_user_dto.py +16 -9
- immichpy/client/generated/models/user_admin_create_dto.py +20 -10
- immichpy/client/generated/models/user_admin_delete_dto.py +5 -3
- immichpy/client/generated/models/user_admin_response_dto.py +35 -18
- immichpy/client/generated/models/user_admin_update_dto.py +20 -10
- immichpy/client/generated/models/user_avatar_color.py +2 -2
- immichpy/client/generated/models/user_license.py +6 -4
- immichpy/client/generated/models/user_metadata_key.py +2 -2
- immichpy/client/generated/models/user_preferences_response_dto.py +1 -1
- immichpy/client/generated/models/user_preferences_update_dto.py +1 -1
- immichpy/client/generated/models/user_response_dto.py +13 -7
- immichpy/client/generated/models/user_status.py +2 -2
- immichpy/client/generated/models/user_update_me_dto.py +10 -5
- immichpy/client/generated/models/validate_access_token_response_dto.py +4 -2
- immichpy/client/generated/models/validate_library_dto.py +9 -3
- immichpy/client/generated/models/validate_library_import_path_response_dto.py +4 -4
- immichpy/client/generated/models/validate_library_response_dto.py +4 -2
- immichpy/client/generated/models/version_check_state_response_dto.py +7 -3
- immichpy/client/generated/models/video_codec.py +2 -2
- immichpy/client/generated/models/video_container.py +2 -2
- immichpy/client/generated/models/workflow_action_item_dto.py +7 -3
- immichpy/client/generated/models/workflow_action_response_dto.py +10 -6
- immichpy/client/generated/models/workflow_create_dto.py +11 -7
- immichpy/client/generated/models/workflow_filter_item_dto.py +7 -3
- immichpy/client/generated/models/workflow_filter_response_dto.py +10 -6
- immichpy/client/generated/models/workflow_response_dto.py +14 -27
- immichpy/client/generated/models/workflow_update_dto.py +19 -7
- immichpy/client/generated/rest.py +1 -1
- immichpy/client/main.py +4 -1
- {immichpy-1.6.5.dist-info → immichpy-1.7.6.dist-info}/METADATA +1 -3
- immichpy-1.7.6.dist-info/RECORD +464 -0
- immichpy-1.6.5.dist-info/RECORD +0 -439
- {immichpy-1.6.5.dist-info → immichpy-1.7.6.dist-info}/WHEEL +0 -0
- {immichpy-1.6.5.dist-info → immichpy-1.7.6.dist-info}/entry_points.txt +0 -0
- {immichpy-1.6.5.dist-info → immichpy-1.7.6.dist-info}/licenses/LICENSE +0 -0
|
@@ -0,0 +1,1224 @@
|
|
|
1
|
+
# coding: utf-8
|
|
2
|
+
|
|
3
|
+
"""
|
|
4
|
+
Immich
|
|
5
|
+
|
|
6
|
+
Immich API
|
|
7
|
+
|
|
8
|
+
The version of the OpenAPI document: 2.5.2
|
|
9
|
+
Generated by OpenAPI Generator (https://openapi-generator.tech)
|
|
10
|
+
|
|
11
|
+
Do not edit the class manually.
|
|
12
|
+
""" # noqa: E501
|
|
13
|
+
|
|
14
|
+
from pydantic import validate_call, Field, StrictFloat, StrictStr, StrictInt
|
|
15
|
+
from typing import Any, Dict, List, Optional, Tuple, Union
|
|
16
|
+
from typing_extensions import Annotated
|
|
17
|
+
|
|
18
|
+
from pydantic import StrictBytes
|
|
19
|
+
from immichpy.client.generated.models.database_backup_delete_dto import (
|
|
20
|
+
DatabaseBackupDeleteDto,
|
|
21
|
+
)
|
|
22
|
+
from immichpy.client.generated.models.database_backup_list_response_dto import (
|
|
23
|
+
DatabaseBackupListResponseDto,
|
|
24
|
+
)
|
|
25
|
+
|
|
26
|
+
from immichpy.client.generated.api_client import ApiClient, RequestSerialized
|
|
27
|
+
from immichpy.client.generated.api_response import ApiResponse
|
|
28
|
+
from immichpy.client.generated.rest import RESTResponseType
|
|
29
|
+
|
|
30
|
+
|
|
31
|
+
class DatabaseBackupsAdminApi:
|
|
32
|
+
"""NOTE: This class is auto generated by OpenAPI Generator
|
|
33
|
+
Ref: https://openapi-generator.tech
|
|
34
|
+
|
|
35
|
+
Do not edit the class manually.
|
|
36
|
+
"""
|
|
37
|
+
|
|
38
|
+
def __init__(self, api_client=None) -> None:
|
|
39
|
+
if api_client is None:
|
|
40
|
+
api_client = ApiClient.get_default()
|
|
41
|
+
self.api_client = api_client
|
|
42
|
+
|
|
43
|
+
@validate_call
|
|
44
|
+
async def delete_database_backup(
|
|
45
|
+
self,
|
|
46
|
+
database_backup_delete_dto: DatabaseBackupDeleteDto,
|
|
47
|
+
_request_timeout: Union[
|
|
48
|
+
None,
|
|
49
|
+
Annotated[StrictFloat, Field(gt=0)],
|
|
50
|
+
Tuple[
|
|
51
|
+
Annotated[StrictFloat, Field(gt=0)], Annotated[StrictFloat, Field(gt=0)]
|
|
52
|
+
],
|
|
53
|
+
] = None,
|
|
54
|
+
_request_auth: Optional[Dict[StrictStr, Any]] = None,
|
|
55
|
+
_content_type: Optional[StrictStr] = None,
|
|
56
|
+
_headers: Optional[Dict[StrictStr, Any]] = None,
|
|
57
|
+
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
|
|
58
|
+
) -> None:
|
|
59
|
+
"""Delete database backup
|
|
60
|
+
|
|
61
|
+
Delete a backup by its filename
|
|
62
|
+
|
|
63
|
+
:param database_backup_delete_dto: (required)
|
|
64
|
+
:type database_backup_delete_dto: DatabaseBackupDeleteDto
|
|
65
|
+
:param _request_timeout: timeout setting for this request. If one
|
|
66
|
+
number provided, it will be total request
|
|
67
|
+
timeout. It can also be a pair (tuple) of
|
|
68
|
+
(connection, read) timeouts.
|
|
69
|
+
:type _request_timeout: int, tuple(int, int), optional
|
|
70
|
+
:param _request_auth: set to override the auth_settings for an a single
|
|
71
|
+
request; this effectively ignores the
|
|
72
|
+
authentication in the spec for a single request.
|
|
73
|
+
:type _request_auth: dict, optional
|
|
74
|
+
:param _content_type: force content-type for the request.
|
|
75
|
+
:type _content_type: str, Optional
|
|
76
|
+
:param _headers: set to override the headers for a single
|
|
77
|
+
request; this effectively ignores the headers
|
|
78
|
+
in the spec for a single request.
|
|
79
|
+
:type _headers: dict, optional
|
|
80
|
+
:param _host_index: set to override the host_index for a single
|
|
81
|
+
request; this effectively ignores the host_index
|
|
82
|
+
in the spec for a single request.
|
|
83
|
+
:type _host_index: int, optional
|
|
84
|
+
:return: Returns the result object.
|
|
85
|
+
""" # noqa: E501
|
|
86
|
+
|
|
87
|
+
_param = self._delete_database_backup_serialize(
|
|
88
|
+
database_backup_delete_dto=database_backup_delete_dto,
|
|
89
|
+
_request_auth=_request_auth,
|
|
90
|
+
_content_type=_content_type,
|
|
91
|
+
_headers=_headers,
|
|
92
|
+
_host_index=_host_index,
|
|
93
|
+
)
|
|
94
|
+
|
|
95
|
+
_response_types_map: Dict[str, Optional[str]] = {
|
|
96
|
+
"200": None,
|
|
97
|
+
}
|
|
98
|
+
response_data = await self.api_client.call_api(
|
|
99
|
+
*_param, _request_timeout=_request_timeout
|
|
100
|
+
)
|
|
101
|
+
await response_data.read()
|
|
102
|
+
return self.api_client.response_deserialize(
|
|
103
|
+
response_data=response_data,
|
|
104
|
+
response_types_map=_response_types_map,
|
|
105
|
+
).data
|
|
106
|
+
|
|
107
|
+
@validate_call
|
|
108
|
+
async def delete_database_backup_with_http_info(
|
|
109
|
+
self,
|
|
110
|
+
database_backup_delete_dto: DatabaseBackupDeleteDto,
|
|
111
|
+
_request_timeout: Union[
|
|
112
|
+
None,
|
|
113
|
+
Annotated[StrictFloat, Field(gt=0)],
|
|
114
|
+
Tuple[
|
|
115
|
+
Annotated[StrictFloat, Field(gt=0)], Annotated[StrictFloat, Field(gt=0)]
|
|
116
|
+
],
|
|
117
|
+
] = None,
|
|
118
|
+
_request_auth: Optional[Dict[StrictStr, Any]] = None,
|
|
119
|
+
_content_type: Optional[StrictStr] = None,
|
|
120
|
+
_headers: Optional[Dict[StrictStr, Any]] = None,
|
|
121
|
+
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
|
|
122
|
+
) -> ApiResponse[None]:
|
|
123
|
+
"""Delete database backup
|
|
124
|
+
|
|
125
|
+
Delete a backup by its filename
|
|
126
|
+
|
|
127
|
+
:param database_backup_delete_dto: (required)
|
|
128
|
+
:type database_backup_delete_dto: DatabaseBackupDeleteDto
|
|
129
|
+
:param _request_timeout: timeout setting for this request. If one
|
|
130
|
+
number provided, it will be total request
|
|
131
|
+
timeout. It can also be a pair (tuple) of
|
|
132
|
+
(connection, read) timeouts.
|
|
133
|
+
:type _request_timeout: int, tuple(int, int), optional
|
|
134
|
+
:param _request_auth: set to override the auth_settings for an a single
|
|
135
|
+
request; this effectively ignores the
|
|
136
|
+
authentication in the spec for a single request.
|
|
137
|
+
:type _request_auth: dict, optional
|
|
138
|
+
:param _content_type: force content-type for the request.
|
|
139
|
+
:type _content_type: str, Optional
|
|
140
|
+
:param _headers: set to override the headers for a single
|
|
141
|
+
request; this effectively ignores the headers
|
|
142
|
+
in the spec for a single request.
|
|
143
|
+
:type _headers: dict, optional
|
|
144
|
+
:param _host_index: set to override the host_index for a single
|
|
145
|
+
request; this effectively ignores the host_index
|
|
146
|
+
in the spec for a single request.
|
|
147
|
+
:type _host_index: int, optional
|
|
148
|
+
:return: Returns the result object.
|
|
149
|
+
""" # noqa: E501
|
|
150
|
+
|
|
151
|
+
_param = self._delete_database_backup_serialize(
|
|
152
|
+
database_backup_delete_dto=database_backup_delete_dto,
|
|
153
|
+
_request_auth=_request_auth,
|
|
154
|
+
_content_type=_content_type,
|
|
155
|
+
_headers=_headers,
|
|
156
|
+
_host_index=_host_index,
|
|
157
|
+
)
|
|
158
|
+
|
|
159
|
+
_response_types_map: Dict[str, Optional[str]] = {
|
|
160
|
+
"200": None,
|
|
161
|
+
}
|
|
162
|
+
response_data = await self.api_client.call_api(
|
|
163
|
+
*_param, _request_timeout=_request_timeout
|
|
164
|
+
)
|
|
165
|
+
await response_data.read()
|
|
166
|
+
return self.api_client.response_deserialize(
|
|
167
|
+
response_data=response_data,
|
|
168
|
+
response_types_map=_response_types_map,
|
|
169
|
+
)
|
|
170
|
+
|
|
171
|
+
@validate_call
|
|
172
|
+
async def delete_database_backup_without_preload_content(
|
|
173
|
+
self,
|
|
174
|
+
database_backup_delete_dto: DatabaseBackupDeleteDto,
|
|
175
|
+
_request_timeout: Union[
|
|
176
|
+
None,
|
|
177
|
+
Annotated[StrictFloat, Field(gt=0)],
|
|
178
|
+
Tuple[
|
|
179
|
+
Annotated[StrictFloat, Field(gt=0)], Annotated[StrictFloat, Field(gt=0)]
|
|
180
|
+
],
|
|
181
|
+
] = None,
|
|
182
|
+
_request_auth: Optional[Dict[StrictStr, Any]] = None,
|
|
183
|
+
_content_type: Optional[StrictStr] = None,
|
|
184
|
+
_headers: Optional[Dict[StrictStr, Any]] = None,
|
|
185
|
+
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
|
|
186
|
+
) -> RESTResponseType:
|
|
187
|
+
"""Delete database backup
|
|
188
|
+
|
|
189
|
+
Delete a backup by its filename
|
|
190
|
+
|
|
191
|
+
:param database_backup_delete_dto: (required)
|
|
192
|
+
:type database_backup_delete_dto: DatabaseBackupDeleteDto
|
|
193
|
+
:param _request_timeout: timeout setting for this request. If one
|
|
194
|
+
number provided, it will be total request
|
|
195
|
+
timeout. It can also be a pair (tuple) of
|
|
196
|
+
(connection, read) timeouts.
|
|
197
|
+
:type _request_timeout: int, tuple(int, int), optional
|
|
198
|
+
:param _request_auth: set to override the auth_settings for an a single
|
|
199
|
+
request; this effectively ignores the
|
|
200
|
+
authentication in the spec for a single request.
|
|
201
|
+
:type _request_auth: dict, optional
|
|
202
|
+
:param _content_type: force content-type for the request.
|
|
203
|
+
:type _content_type: str, Optional
|
|
204
|
+
:param _headers: set to override the headers for a single
|
|
205
|
+
request; this effectively ignores the headers
|
|
206
|
+
in the spec for a single request.
|
|
207
|
+
:type _headers: dict, optional
|
|
208
|
+
:param _host_index: set to override the host_index for a single
|
|
209
|
+
request; this effectively ignores the host_index
|
|
210
|
+
in the spec for a single request.
|
|
211
|
+
:type _host_index: int, optional
|
|
212
|
+
:return: Returns the result object.
|
|
213
|
+
""" # noqa: E501
|
|
214
|
+
|
|
215
|
+
_param = self._delete_database_backup_serialize(
|
|
216
|
+
database_backup_delete_dto=database_backup_delete_dto,
|
|
217
|
+
_request_auth=_request_auth,
|
|
218
|
+
_content_type=_content_type,
|
|
219
|
+
_headers=_headers,
|
|
220
|
+
_host_index=_host_index,
|
|
221
|
+
)
|
|
222
|
+
|
|
223
|
+
_response_types_map: Dict[str, Optional[str]] = {
|
|
224
|
+
"200": None,
|
|
225
|
+
}
|
|
226
|
+
response_data = await self.api_client.call_api(
|
|
227
|
+
*_param, _request_timeout=_request_timeout
|
|
228
|
+
)
|
|
229
|
+
return response_data.response
|
|
230
|
+
|
|
231
|
+
def _delete_database_backup_serialize(
|
|
232
|
+
self,
|
|
233
|
+
database_backup_delete_dto,
|
|
234
|
+
_request_auth,
|
|
235
|
+
_content_type,
|
|
236
|
+
_headers,
|
|
237
|
+
_host_index,
|
|
238
|
+
) -> RequestSerialized:
|
|
239
|
+
_host = None
|
|
240
|
+
|
|
241
|
+
_collection_formats: Dict[str, str] = {}
|
|
242
|
+
|
|
243
|
+
_path_params: Dict[str, str] = {}
|
|
244
|
+
_query_params: List[Tuple[str, str]] = []
|
|
245
|
+
_header_params: Dict[str, Optional[str]] = _headers or {}
|
|
246
|
+
_form_params: List[Tuple[str, str]] = []
|
|
247
|
+
_files: Dict[
|
|
248
|
+
str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
|
|
249
|
+
] = {}
|
|
250
|
+
_body_params: Optional[bytes] = None
|
|
251
|
+
|
|
252
|
+
# process the path parameters
|
|
253
|
+
# process the query parameters
|
|
254
|
+
# process the header parameters
|
|
255
|
+
# process the form parameters
|
|
256
|
+
# process the body parameter
|
|
257
|
+
if database_backup_delete_dto is not None:
|
|
258
|
+
_body_params = database_backup_delete_dto
|
|
259
|
+
|
|
260
|
+
# set the HTTP header `Content-Type`
|
|
261
|
+
if _content_type:
|
|
262
|
+
_header_params["Content-Type"] = _content_type
|
|
263
|
+
else:
|
|
264
|
+
_default_content_type = self.api_client.select_header_content_type(
|
|
265
|
+
["application/json"]
|
|
266
|
+
)
|
|
267
|
+
if _default_content_type is not None:
|
|
268
|
+
_header_params["Content-Type"] = _default_content_type
|
|
269
|
+
|
|
270
|
+
# authentication setting
|
|
271
|
+
_auth_settings: List[str] = ["cookie", "api_key", "bearer"]
|
|
272
|
+
|
|
273
|
+
return self.api_client.param_serialize(
|
|
274
|
+
method="DELETE",
|
|
275
|
+
resource_path="/admin/database-backups",
|
|
276
|
+
path_params=_path_params,
|
|
277
|
+
query_params=_query_params,
|
|
278
|
+
header_params=_header_params,
|
|
279
|
+
body=_body_params,
|
|
280
|
+
post_params=_form_params,
|
|
281
|
+
files=_files,
|
|
282
|
+
auth_settings=_auth_settings,
|
|
283
|
+
collection_formats=_collection_formats,
|
|
284
|
+
_host=_host,
|
|
285
|
+
_request_auth=_request_auth,
|
|
286
|
+
)
|
|
287
|
+
|
|
288
|
+
@validate_call
|
|
289
|
+
async def download_database_backup(
|
|
290
|
+
self,
|
|
291
|
+
filename: StrictStr,
|
|
292
|
+
_request_timeout: Union[
|
|
293
|
+
None,
|
|
294
|
+
Annotated[StrictFloat, Field(gt=0)],
|
|
295
|
+
Tuple[
|
|
296
|
+
Annotated[StrictFloat, Field(gt=0)], Annotated[StrictFloat, Field(gt=0)]
|
|
297
|
+
],
|
|
298
|
+
] = None,
|
|
299
|
+
_request_auth: Optional[Dict[StrictStr, Any]] = None,
|
|
300
|
+
_content_type: Optional[StrictStr] = None,
|
|
301
|
+
_headers: Optional[Dict[StrictStr, Any]] = None,
|
|
302
|
+
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
|
|
303
|
+
) -> bytearray:
|
|
304
|
+
"""Download database backup
|
|
305
|
+
|
|
306
|
+
Downloads the database backup file
|
|
307
|
+
|
|
308
|
+
:param filename: (required)
|
|
309
|
+
:type filename: str
|
|
310
|
+
:param _request_timeout: timeout setting for this request. If one
|
|
311
|
+
number provided, it will be total request
|
|
312
|
+
timeout. It can also be a pair (tuple) of
|
|
313
|
+
(connection, read) timeouts.
|
|
314
|
+
:type _request_timeout: int, tuple(int, int), optional
|
|
315
|
+
:param _request_auth: set to override the auth_settings for an a single
|
|
316
|
+
request; this effectively ignores the
|
|
317
|
+
authentication in the spec for a single request.
|
|
318
|
+
:type _request_auth: dict, optional
|
|
319
|
+
:param _content_type: force content-type for the request.
|
|
320
|
+
:type _content_type: str, Optional
|
|
321
|
+
:param _headers: set to override the headers for a single
|
|
322
|
+
request; this effectively ignores the headers
|
|
323
|
+
in the spec for a single request.
|
|
324
|
+
:type _headers: dict, optional
|
|
325
|
+
:param _host_index: set to override the host_index for a single
|
|
326
|
+
request; this effectively ignores the host_index
|
|
327
|
+
in the spec for a single request.
|
|
328
|
+
:type _host_index: int, optional
|
|
329
|
+
:return: Returns the result object.
|
|
330
|
+
""" # noqa: E501
|
|
331
|
+
|
|
332
|
+
_param = self._download_database_backup_serialize(
|
|
333
|
+
filename=filename,
|
|
334
|
+
_request_auth=_request_auth,
|
|
335
|
+
_content_type=_content_type,
|
|
336
|
+
_headers=_headers,
|
|
337
|
+
_host_index=_host_index,
|
|
338
|
+
)
|
|
339
|
+
|
|
340
|
+
_response_types_map: Dict[str, Optional[str]] = {
|
|
341
|
+
"200": "bytearray",
|
|
342
|
+
}
|
|
343
|
+
response_data = await self.api_client.call_api(
|
|
344
|
+
*_param, _request_timeout=_request_timeout
|
|
345
|
+
)
|
|
346
|
+
await response_data.read()
|
|
347
|
+
return self.api_client.response_deserialize(
|
|
348
|
+
response_data=response_data,
|
|
349
|
+
response_types_map=_response_types_map,
|
|
350
|
+
).data
|
|
351
|
+
|
|
352
|
+
@validate_call
|
|
353
|
+
async def download_database_backup_with_http_info(
|
|
354
|
+
self,
|
|
355
|
+
filename: StrictStr,
|
|
356
|
+
_request_timeout: Union[
|
|
357
|
+
None,
|
|
358
|
+
Annotated[StrictFloat, Field(gt=0)],
|
|
359
|
+
Tuple[
|
|
360
|
+
Annotated[StrictFloat, Field(gt=0)], Annotated[StrictFloat, Field(gt=0)]
|
|
361
|
+
],
|
|
362
|
+
] = None,
|
|
363
|
+
_request_auth: Optional[Dict[StrictStr, Any]] = None,
|
|
364
|
+
_content_type: Optional[StrictStr] = None,
|
|
365
|
+
_headers: Optional[Dict[StrictStr, Any]] = None,
|
|
366
|
+
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
|
|
367
|
+
) -> ApiResponse[bytearray]:
|
|
368
|
+
"""Download database backup
|
|
369
|
+
|
|
370
|
+
Downloads the database backup file
|
|
371
|
+
|
|
372
|
+
:param filename: (required)
|
|
373
|
+
:type filename: str
|
|
374
|
+
:param _request_timeout: timeout setting for this request. If one
|
|
375
|
+
number provided, it will be total request
|
|
376
|
+
timeout. It can also be a pair (tuple) of
|
|
377
|
+
(connection, read) timeouts.
|
|
378
|
+
:type _request_timeout: int, tuple(int, int), optional
|
|
379
|
+
:param _request_auth: set to override the auth_settings for an a single
|
|
380
|
+
request; this effectively ignores the
|
|
381
|
+
authentication in the spec for a single request.
|
|
382
|
+
:type _request_auth: dict, optional
|
|
383
|
+
:param _content_type: force content-type for the request.
|
|
384
|
+
:type _content_type: str, Optional
|
|
385
|
+
:param _headers: set to override the headers for a single
|
|
386
|
+
request; this effectively ignores the headers
|
|
387
|
+
in the spec for a single request.
|
|
388
|
+
:type _headers: dict, optional
|
|
389
|
+
:param _host_index: set to override the host_index for a single
|
|
390
|
+
request; this effectively ignores the host_index
|
|
391
|
+
in the spec for a single request.
|
|
392
|
+
:type _host_index: int, optional
|
|
393
|
+
:return: Returns the result object.
|
|
394
|
+
""" # noqa: E501
|
|
395
|
+
|
|
396
|
+
_param = self._download_database_backup_serialize(
|
|
397
|
+
filename=filename,
|
|
398
|
+
_request_auth=_request_auth,
|
|
399
|
+
_content_type=_content_type,
|
|
400
|
+
_headers=_headers,
|
|
401
|
+
_host_index=_host_index,
|
|
402
|
+
)
|
|
403
|
+
|
|
404
|
+
_response_types_map: Dict[str, Optional[str]] = {
|
|
405
|
+
"200": "bytearray",
|
|
406
|
+
}
|
|
407
|
+
response_data = await self.api_client.call_api(
|
|
408
|
+
*_param, _request_timeout=_request_timeout
|
|
409
|
+
)
|
|
410
|
+
await response_data.read()
|
|
411
|
+
return self.api_client.response_deserialize(
|
|
412
|
+
response_data=response_data,
|
|
413
|
+
response_types_map=_response_types_map,
|
|
414
|
+
)
|
|
415
|
+
|
|
416
|
+
@validate_call
|
|
417
|
+
async def download_database_backup_without_preload_content(
|
|
418
|
+
self,
|
|
419
|
+
filename: StrictStr,
|
|
420
|
+
_request_timeout: Union[
|
|
421
|
+
None,
|
|
422
|
+
Annotated[StrictFloat, Field(gt=0)],
|
|
423
|
+
Tuple[
|
|
424
|
+
Annotated[StrictFloat, Field(gt=0)], Annotated[StrictFloat, Field(gt=0)]
|
|
425
|
+
],
|
|
426
|
+
] = None,
|
|
427
|
+
_request_auth: Optional[Dict[StrictStr, Any]] = None,
|
|
428
|
+
_content_type: Optional[StrictStr] = None,
|
|
429
|
+
_headers: Optional[Dict[StrictStr, Any]] = None,
|
|
430
|
+
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
|
|
431
|
+
) -> RESTResponseType:
|
|
432
|
+
"""Download database backup
|
|
433
|
+
|
|
434
|
+
Downloads the database backup file
|
|
435
|
+
|
|
436
|
+
:param filename: (required)
|
|
437
|
+
:type filename: str
|
|
438
|
+
:param _request_timeout: timeout setting for this request. If one
|
|
439
|
+
number provided, it will be total request
|
|
440
|
+
timeout. It can also be a pair (tuple) of
|
|
441
|
+
(connection, read) timeouts.
|
|
442
|
+
:type _request_timeout: int, tuple(int, int), optional
|
|
443
|
+
:param _request_auth: set to override the auth_settings for an a single
|
|
444
|
+
request; this effectively ignores the
|
|
445
|
+
authentication in the spec for a single request.
|
|
446
|
+
:type _request_auth: dict, optional
|
|
447
|
+
:param _content_type: force content-type for the request.
|
|
448
|
+
:type _content_type: str, Optional
|
|
449
|
+
:param _headers: set to override the headers for a single
|
|
450
|
+
request; this effectively ignores the headers
|
|
451
|
+
in the spec for a single request.
|
|
452
|
+
:type _headers: dict, optional
|
|
453
|
+
:param _host_index: set to override the host_index for a single
|
|
454
|
+
request; this effectively ignores the host_index
|
|
455
|
+
in the spec for a single request.
|
|
456
|
+
:type _host_index: int, optional
|
|
457
|
+
:return: Returns the result object.
|
|
458
|
+
""" # noqa: E501
|
|
459
|
+
|
|
460
|
+
_param = self._download_database_backup_serialize(
|
|
461
|
+
filename=filename,
|
|
462
|
+
_request_auth=_request_auth,
|
|
463
|
+
_content_type=_content_type,
|
|
464
|
+
_headers=_headers,
|
|
465
|
+
_host_index=_host_index,
|
|
466
|
+
)
|
|
467
|
+
|
|
468
|
+
_response_types_map: Dict[str, Optional[str]] = {
|
|
469
|
+
"200": "bytearray",
|
|
470
|
+
}
|
|
471
|
+
response_data = await self.api_client.call_api(
|
|
472
|
+
*_param, _request_timeout=_request_timeout
|
|
473
|
+
)
|
|
474
|
+
return response_data.response
|
|
475
|
+
|
|
476
|
+
def _download_database_backup_serialize(
|
|
477
|
+
self,
|
|
478
|
+
filename,
|
|
479
|
+
_request_auth,
|
|
480
|
+
_content_type,
|
|
481
|
+
_headers,
|
|
482
|
+
_host_index,
|
|
483
|
+
) -> RequestSerialized:
|
|
484
|
+
_host = None
|
|
485
|
+
|
|
486
|
+
_collection_formats: Dict[str, str] = {}
|
|
487
|
+
|
|
488
|
+
_path_params: Dict[str, str] = {}
|
|
489
|
+
_query_params: List[Tuple[str, str]] = []
|
|
490
|
+
_header_params: Dict[str, Optional[str]] = _headers or {}
|
|
491
|
+
_form_params: List[Tuple[str, str]] = []
|
|
492
|
+
_files: Dict[
|
|
493
|
+
str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
|
|
494
|
+
] = {}
|
|
495
|
+
_body_params: Optional[bytes] = None
|
|
496
|
+
|
|
497
|
+
# process the path parameters
|
|
498
|
+
if filename is not None:
|
|
499
|
+
_path_params["filename"] = filename
|
|
500
|
+
# process the query parameters
|
|
501
|
+
# process the header parameters
|
|
502
|
+
# process the form parameters
|
|
503
|
+
# process the body parameter
|
|
504
|
+
|
|
505
|
+
# set the HTTP header `Accept`
|
|
506
|
+
if "Accept" not in _header_params:
|
|
507
|
+
_header_params["Accept"] = self.api_client.select_header_accept(
|
|
508
|
+
["application/octet-stream"]
|
|
509
|
+
)
|
|
510
|
+
|
|
511
|
+
# authentication setting
|
|
512
|
+
_auth_settings: List[str] = ["cookie", "api_key", "bearer"]
|
|
513
|
+
|
|
514
|
+
return self.api_client.param_serialize(
|
|
515
|
+
method="GET",
|
|
516
|
+
resource_path="/admin/database-backups/{filename}",
|
|
517
|
+
path_params=_path_params,
|
|
518
|
+
query_params=_query_params,
|
|
519
|
+
header_params=_header_params,
|
|
520
|
+
body=_body_params,
|
|
521
|
+
post_params=_form_params,
|
|
522
|
+
files=_files,
|
|
523
|
+
auth_settings=_auth_settings,
|
|
524
|
+
collection_formats=_collection_formats,
|
|
525
|
+
_host=_host,
|
|
526
|
+
_request_auth=_request_auth,
|
|
527
|
+
)
|
|
528
|
+
|
|
529
|
+
@validate_call
|
|
530
|
+
async def list_database_backups(
|
|
531
|
+
self,
|
|
532
|
+
_request_timeout: Union[
|
|
533
|
+
None,
|
|
534
|
+
Annotated[StrictFloat, Field(gt=0)],
|
|
535
|
+
Tuple[
|
|
536
|
+
Annotated[StrictFloat, Field(gt=0)], Annotated[StrictFloat, Field(gt=0)]
|
|
537
|
+
],
|
|
538
|
+
] = None,
|
|
539
|
+
_request_auth: Optional[Dict[StrictStr, Any]] = None,
|
|
540
|
+
_content_type: Optional[StrictStr] = None,
|
|
541
|
+
_headers: Optional[Dict[StrictStr, Any]] = None,
|
|
542
|
+
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
|
|
543
|
+
) -> DatabaseBackupListResponseDto:
|
|
544
|
+
"""List database backups
|
|
545
|
+
|
|
546
|
+
Get the list of the successful and failed backups
|
|
547
|
+
|
|
548
|
+
:param _request_timeout: timeout setting for this request. If one
|
|
549
|
+
number provided, it will be total request
|
|
550
|
+
timeout. It can also be a pair (tuple) of
|
|
551
|
+
(connection, read) timeouts.
|
|
552
|
+
:type _request_timeout: int, tuple(int, int), optional
|
|
553
|
+
:param _request_auth: set to override the auth_settings for an a single
|
|
554
|
+
request; this effectively ignores the
|
|
555
|
+
authentication in the spec for a single request.
|
|
556
|
+
:type _request_auth: dict, optional
|
|
557
|
+
:param _content_type: force content-type for the request.
|
|
558
|
+
:type _content_type: str, Optional
|
|
559
|
+
:param _headers: set to override the headers for a single
|
|
560
|
+
request; this effectively ignores the headers
|
|
561
|
+
in the spec for a single request.
|
|
562
|
+
:type _headers: dict, optional
|
|
563
|
+
:param _host_index: set to override the host_index for a single
|
|
564
|
+
request; this effectively ignores the host_index
|
|
565
|
+
in the spec for a single request.
|
|
566
|
+
:type _host_index: int, optional
|
|
567
|
+
:return: Returns the result object.
|
|
568
|
+
""" # noqa: E501
|
|
569
|
+
|
|
570
|
+
_param = self._list_database_backups_serialize(
|
|
571
|
+
_request_auth=_request_auth,
|
|
572
|
+
_content_type=_content_type,
|
|
573
|
+
_headers=_headers,
|
|
574
|
+
_host_index=_host_index,
|
|
575
|
+
)
|
|
576
|
+
|
|
577
|
+
_response_types_map: Dict[str, Optional[str]] = {
|
|
578
|
+
"200": "DatabaseBackupListResponseDto",
|
|
579
|
+
}
|
|
580
|
+
response_data = await self.api_client.call_api(
|
|
581
|
+
*_param, _request_timeout=_request_timeout
|
|
582
|
+
)
|
|
583
|
+
await response_data.read()
|
|
584
|
+
return self.api_client.response_deserialize(
|
|
585
|
+
response_data=response_data,
|
|
586
|
+
response_types_map=_response_types_map,
|
|
587
|
+
).data
|
|
588
|
+
|
|
589
|
+
@validate_call
|
|
590
|
+
async def list_database_backups_with_http_info(
|
|
591
|
+
self,
|
|
592
|
+
_request_timeout: Union[
|
|
593
|
+
None,
|
|
594
|
+
Annotated[StrictFloat, Field(gt=0)],
|
|
595
|
+
Tuple[
|
|
596
|
+
Annotated[StrictFloat, Field(gt=0)], Annotated[StrictFloat, Field(gt=0)]
|
|
597
|
+
],
|
|
598
|
+
] = None,
|
|
599
|
+
_request_auth: Optional[Dict[StrictStr, Any]] = None,
|
|
600
|
+
_content_type: Optional[StrictStr] = None,
|
|
601
|
+
_headers: Optional[Dict[StrictStr, Any]] = None,
|
|
602
|
+
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
|
|
603
|
+
) -> ApiResponse[DatabaseBackupListResponseDto]:
|
|
604
|
+
"""List database backups
|
|
605
|
+
|
|
606
|
+
Get the list of the successful and failed backups
|
|
607
|
+
|
|
608
|
+
:param _request_timeout: timeout setting for this request. If one
|
|
609
|
+
number provided, it will be total request
|
|
610
|
+
timeout. It can also be a pair (tuple) of
|
|
611
|
+
(connection, read) timeouts.
|
|
612
|
+
:type _request_timeout: int, tuple(int, int), optional
|
|
613
|
+
:param _request_auth: set to override the auth_settings for an a single
|
|
614
|
+
request; this effectively ignores the
|
|
615
|
+
authentication in the spec for a single request.
|
|
616
|
+
:type _request_auth: dict, optional
|
|
617
|
+
:param _content_type: force content-type for the request.
|
|
618
|
+
:type _content_type: str, Optional
|
|
619
|
+
:param _headers: set to override the headers for a single
|
|
620
|
+
request; this effectively ignores the headers
|
|
621
|
+
in the spec for a single request.
|
|
622
|
+
:type _headers: dict, optional
|
|
623
|
+
:param _host_index: set to override the host_index for a single
|
|
624
|
+
request; this effectively ignores the host_index
|
|
625
|
+
in the spec for a single request.
|
|
626
|
+
:type _host_index: int, optional
|
|
627
|
+
:return: Returns the result object.
|
|
628
|
+
""" # noqa: E501
|
|
629
|
+
|
|
630
|
+
_param = self._list_database_backups_serialize(
|
|
631
|
+
_request_auth=_request_auth,
|
|
632
|
+
_content_type=_content_type,
|
|
633
|
+
_headers=_headers,
|
|
634
|
+
_host_index=_host_index,
|
|
635
|
+
)
|
|
636
|
+
|
|
637
|
+
_response_types_map: Dict[str, Optional[str]] = {
|
|
638
|
+
"200": "DatabaseBackupListResponseDto",
|
|
639
|
+
}
|
|
640
|
+
response_data = await self.api_client.call_api(
|
|
641
|
+
*_param, _request_timeout=_request_timeout
|
|
642
|
+
)
|
|
643
|
+
await response_data.read()
|
|
644
|
+
return self.api_client.response_deserialize(
|
|
645
|
+
response_data=response_data,
|
|
646
|
+
response_types_map=_response_types_map,
|
|
647
|
+
)
|
|
648
|
+
|
|
649
|
+
@validate_call
|
|
650
|
+
async def list_database_backups_without_preload_content(
|
|
651
|
+
self,
|
|
652
|
+
_request_timeout: Union[
|
|
653
|
+
None,
|
|
654
|
+
Annotated[StrictFloat, Field(gt=0)],
|
|
655
|
+
Tuple[
|
|
656
|
+
Annotated[StrictFloat, Field(gt=0)], Annotated[StrictFloat, Field(gt=0)]
|
|
657
|
+
],
|
|
658
|
+
] = None,
|
|
659
|
+
_request_auth: Optional[Dict[StrictStr, Any]] = None,
|
|
660
|
+
_content_type: Optional[StrictStr] = None,
|
|
661
|
+
_headers: Optional[Dict[StrictStr, Any]] = None,
|
|
662
|
+
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
|
|
663
|
+
) -> RESTResponseType:
|
|
664
|
+
"""List database backups
|
|
665
|
+
|
|
666
|
+
Get the list of the successful and failed backups
|
|
667
|
+
|
|
668
|
+
:param _request_timeout: timeout setting for this request. If one
|
|
669
|
+
number provided, it will be total request
|
|
670
|
+
timeout. It can also be a pair (tuple) of
|
|
671
|
+
(connection, read) timeouts.
|
|
672
|
+
:type _request_timeout: int, tuple(int, int), optional
|
|
673
|
+
:param _request_auth: set to override the auth_settings for an a single
|
|
674
|
+
request; this effectively ignores the
|
|
675
|
+
authentication in the spec for a single request.
|
|
676
|
+
:type _request_auth: dict, optional
|
|
677
|
+
:param _content_type: force content-type for the request.
|
|
678
|
+
:type _content_type: str, Optional
|
|
679
|
+
:param _headers: set to override the headers for a single
|
|
680
|
+
request; this effectively ignores the headers
|
|
681
|
+
in the spec for a single request.
|
|
682
|
+
:type _headers: dict, optional
|
|
683
|
+
:param _host_index: set to override the host_index for a single
|
|
684
|
+
request; this effectively ignores the host_index
|
|
685
|
+
in the spec for a single request.
|
|
686
|
+
:type _host_index: int, optional
|
|
687
|
+
:return: Returns the result object.
|
|
688
|
+
""" # noqa: E501
|
|
689
|
+
|
|
690
|
+
_param = self._list_database_backups_serialize(
|
|
691
|
+
_request_auth=_request_auth,
|
|
692
|
+
_content_type=_content_type,
|
|
693
|
+
_headers=_headers,
|
|
694
|
+
_host_index=_host_index,
|
|
695
|
+
)
|
|
696
|
+
|
|
697
|
+
_response_types_map: Dict[str, Optional[str]] = {
|
|
698
|
+
"200": "DatabaseBackupListResponseDto",
|
|
699
|
+
}
|
|
700
|
+
response_data = await self.api_client.call_api(
|
|
701
|
+
*_param, _request_timeout=_request_timeout
|
|
702
|
+
)
|
|
703
|
+
return response_data.response
|
|
704
|
+
|
|
705
|
+
def _list_database_backups_serialize(
|
|
706
|
+
self,
|
|
707
|
+
_request_auth,
|
|
708
|
+
_content_type,
|
|
709
|
+
_headers,
|
|
710
|
+
_host_index,
|
|
711
|
+
) -> RequestSerialized:
|
|
712
|
+
_host = None
|
|
713
|
+
|
|
714
|
+
_collection_formats: Dict[str, str] = {}
|
|
715
|
+
|
|
716
|
+
_path_params: Dict[str, str] = {}
|
|
717
|
+
_query_params: List[Tuple[str, str]] = []
|
|
718
|
+
_header_params: Dict[str, Optional[str]] = _headers or {}
|
|
719
|
+
_form_params: List[Tuple[str, str]] = []
|
|
720
|
+
_files: Dict[
|
|
721
|
+
str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
|
|
722
|
+
] = {}
|
|
723
|
+
_body_params: Optional[bytes] = None
|
|
724
|
+
|
|
725
|
+
# process the path parameters
|
|
726
|
+
# process the query parameters
|
|
727
|
+
# process the header parameters
|
|
728
|
+
# process the form parameters
|
|
729
|
+
# process the body parameter
|
|
730
|
+
|
|
731
|
+
# set the HTTP header `Accept`
|
|
732
|
+
if "Accept" not in _header_params:
|
|
733
|
+
_header_params["Accept"] = self.api_client.select_header_accept(
|
|
734
|
+
["application/json"]
|
|
735
|
+
)
|
|
736
|
+
|
|
737
|
+
# authentication setting
|
|
738
|
+
_auth_settings: List[str] = ["cookie", "api_key", "bearer"]
|
|
739
|
+
|
|
740
|
+
return self.api_client.param_serialize(
|
|
741
|
+
method="GET",
|
|
742
|
+
resource_path="/admin/database-backups",
|
|
743
|
+
path_params=_path_params,
|
|
744
|
+
query_params=_query_params,
|
|
745
|
+
header_params=_header_params,
|
|
746
|
+
body=_body_params,
|
|
747
|
+
post_params=_form_params,
|
|
748
|
+
files=_files,
|
|
749
|
+
auth_settings=_auth_settings,
|
|
750
|
+
collection_formats=_collection_formats,
|
|
751
|
+
_host=_host,
|
|
752
|
+
_request_auth=_request_auth,
|
|
753
|
+
)
|
|
754
|
+
|
|
755
|
+
@validate_call
|
|
756
|
+
async def start_database_restore_flow(
|
|
757
|
+
self,
|
|
758
|
+
_request_timeout: Union[
|
|
759
|
+
None,
|
|
760
|
+
Annotated[StrictFloat, Field(gt=0)],
|
|
761
|
+
Tuple[
|
|
762
|
+
Annotated[StrictFloat, Field(gt=0)], Annotated[StrictFloat, Field(gt=0)]
|
|
763
|
+
],
|
|
764
|
+
] = None,
|
|
765
|
+
_request_auth: Optional[Dict[StrictStr, Any]] = None,
|
|
766
|
+
_content_type: Optional[StrictStr] = None,
|
|
767
|
+
_headers: Optional[Dict[StrictStr, Any]] = None,
|
|
768
|
+
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
|
|
769
|
+
) -> None:
|
|
770
|
+
"""Start database backup restore flow
|
|
771
|
+
|
|
772
|
+
Put Immich into maintenance mode to restore a backup (Immich must not be configured)
|
|
773
|
+
|
|
774
|
+
:param _request_timeout: timeout setting for this request. If one
|
|
775
|
+
number provided, it will be total request
|
|
776
|
+
timeout. It can also be a pair (tuple) of
|
|
777
|
+
(connection, read) timeouts.
|
|
778
|
+
:type _request_timeout: int, tuple(int, int), optional
|
|
779
|
+
:param _request_auth: set to override the auth_settings for an a single
|
|
780
|
+
request; this effectively ignores the
|
|
781
|
+
authentication in the spec for a single request.
|
|
782
|
+
:type _request_auth: dict, optional
|
|
783
|
+
:param _content_type: force content-type for the request.
|
|
784
|
+
:type _content_type: str, Optional
|
|
785
|
+
:param _headers: set to override the headers for a single
|
|
786
|
+
request; this effectively ignores the headers
|
|
787
|
+
in the spec for a single request.
|
|
788
|
+
:type _headers: dict, optional
|
|
789
|
+
:param _host_index: set to override the host_index for a single
|
|
790
|
+
request; this effectively ignores the host_index
|
|
791
|
+
in the spec for a single request.
|
|
792
|
+
:type _host_index: int, optional
|
|
793
|
+
:return: Returns the result object.
|
|
794
|
+
""" # noqa: E501
|
|
795
|
+
|
|
796
|
+
_param = self._start_database_restore_flow_serialize(
|
|
797
|
+
_request_auth=_request_auth,
|
|
798
|
+
_content_type=_content_type,
|
|
799
|
+
_headers=_headers,
|
|
800
|
+
_host_index=_host_index,
|
|
801
|
+
)
|
|
802
|
+
|
|
803
|
+
_response_types_map: Dict[str, Optional[str]] = {
|
|
804
|
+
"201": None,
|
|
805
|
+
}
|
|
806
|
+
response_data = await self.api_client.call_api(
|
|
807
|
+
*_param, _request_timeout=_request_timeout
|
|
808
|
+
)
|
|
809
|
+
await response_data.read()
|
|
810
|
+
return self.api_client.response_deserialize(
|
|
811
|
+
response_data=response_data,
|
|
812
|
+
response_types_map=_response_types_map,
|
|
813
|
+
).data
|
|
814
|
+
|
|
815
|
+
@validate_call
|
|
816
|
+
async def start_database_restore_flow_with_http_info(
|
|
817
|
+
self,
|
|
818
|
+
_request_timeout: Union[
|
|
819
|
+
None,
|
|
820
|
+
Annotated[StrictFloat, Field(gt=0)],
|
|
821
|
+
Tuple[
|
|
822
|
+
Annotated[StrictFloat, Field(gt=0)], Annotated[StrictFloat, Field(gt=0)]
|
|
823
|
+
],
|
|
824
|
+
] = None,
|
|
825
|
+
_request_auth: Optional[Dict[StrictStr, Any]] = None,
|
|
826
|
+
_content_type: Optional[StrictStr] = None,
|
|
827
|
+
_headers: Optional[Dict[StrictStr, Any]] = None,
|
|
828
|
+
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
|
|
829
|
+
) -> ApiResponse[None]:
|
|
830
|
+
"""Start database backup restore flow
|
|
831
|
+
|
|
832
|
+
Put Immich into maintenance mode to restore a backup (Immich must not be configured)
|
|
833
|
+
|
|
834
|
+
:param _request_timeout: timeout setting for this request. If one
|
|
835
|
+
number provided, it will be total request
|
|
836
|
+
timeout. It can also be a pair (tuple) of
|
|
837
|
+
(connection, read) timeouts.
|
|
838
|
+
:type _request_timeout: int, tuple(int, int), optional
|
|
839
|
+
:param _request_auth: set to override the auth_settings for an a single
|
|
840
|
+
request; this effectively ignores the
|
|
841
|
+
authentication in the spec for a single request.
|
|
842
|
+
:type _request_auth: dict, optional
|
|
843
|
+
:param _content_type: force content-type for the request.
|
|
844
|
+
:type _content_type: str, Optional
|
|
845
|
+
:param _headers: set to override the headers for a single
|
|
846
|
+
request; this effectively ignores the headers
|
|
847
|
+
in the spec for a single request.
|
|
848
|
+
:type _headers: dict, optional
|
|
849
|
+
:param _host_index: set to override the host_index for a single
|
|
850
|
+
request; this effectively ignores the host_index
|
|
851
|
+
in the spec for a single request.
|
|
852
|
+
:type _host_index: int, optional
|
|
853
|
+
:return: Returns the result object.
|
|
854
|
+
""" # noqa: E501
|
|
855
|
+
|
|
856
|
+
_param = self._start_database_restore_flow_serialize(
|
|
857
|
+
_request_auth=_request_auth,
|
|
858
|
+
_content_type=_content_type,
|
|
859
|
+
_headers=_headers,
|
|
860
|
+
_host_index=_host_index,
|
|
861
|
+
)
|
|
862
|
+
|
|
863
|
+
_response_types_map: Dict[str, Optional[str]] = {
|
|
864
|
+
"201": None,
|
|
865
|
+
}
|
|
866
|
+
response_data = await self.api_client.call_api(
|
|
867
|
+
*_param, _request_timeout=_request_timeout
|
|
868
|
+
)
|
|
869
|
+
await response_data.read()
|
|
870
|
+
return self.api_client.response_deserialize(
|
|
871
|
+
response_data=response_data,
|
|
872
|
+
response_types_map=_response_types_map,
|
|
873
|
+
)
|
|
874
|
+
|
|
875
|
+
@validate_call
|
|
876
|
+
async def start_database_restore_flow_without_preload_content(
|
|
877
|
+
self,
|
|
878
|
+
_request_timeout: Union[
|
|
879
|
+
None,
|
|
880
|
+
Annotated[StrictFloat, Field(gt=0)],
|
|
881
|
+
Tuple[
|
|
882
|
+
Annotated[StrictFloat, Field(gt=0)], Annotated[StrictFloat, Field(gt=0)]
|
|
883
|
+
],
|
|
884
|
+
] = None,
|
|
885
|
+
_request_auth: Optional[Dict[StrictStr, Any]] = None,
|
|
886
|
+
_content_type: Optional[StrictStr] = None,
|
|
887
|
+
_headers: Optional[Dict[StrictStr, Any]] = None,
|
|
888
|
+
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
|
|
889
|
+
) -> RESTResponseType:
|
|
890
|
+
"""Start database backup restore flow
|
|
891
|
+
|
|
892
|
+
Put Immich into maintenance mode to restore a backup (Immich must not be configured)
|
|
893
|
+
|
|
894
|
+
:param _request_timeout: timeout setting for this request. If one
|
|
895
|
+
number provided, it will be total request
|
|
896
|
+
timeout. It can also be a pair (tuple) of
|
|
897
|
+
(connection, read) timeouts.
|
|
898
|
+
:type _request_timeout: int, tuple(int, int), optional
|
|
899
|
+
:param _request_auth: set to override the auth_settings for an a single
|
|
900
|
+
request; this effectively ignores the
|
|
901
|
+
authentication in the spec for a single request.
|
|
902
|
+
:type _request_auth: dict, optional
|
|
903
|
+
:param _content_type: force content-type for the request.
|
|
904
|
+
:type _content_type: str, Optional
|
|
905
|
+
:param _headers: set to override the headers for a single
|
|
906
|
+
request; this effectively ignores the headers
|
|
907
|
+
in the spec for a single request.
|
|
908
|
+
:type _headers: dict, optional
|
|
909
|
+
:param _host_index: set to override the host_index for a single
|
|
910
|
+
request; this effectively ignores the host_index
|
|
911
|
+
in the spec for a single request.
|
|
912
|
+
:type _host_index: int, optional
|
|
913
|
+
:return: Returns the result object.
|
|
914
|
+
""" # noqa: E501
|
|
915
|
+
|
|
916
|
+
_param = self._start_database_restore_flow_serialize(
|
|
917
|
+
_request_auth=_request_auth,
|
|
918
|
+
_content_type=_content_type,
|
|
919
|
+
_headers=_headers,
|
|
920
|
+
_host_index=_host_index,
|
|
921
|
+
)
|
|
922
|
+
|
|
923
|
+
_response_types_map: Dict[str, Optional[str]] = {
|
|
924
|
+
"201": None,
|
|
925
|
+
}
|
|
926
|
+
response_data = await self.api_client.call_api(
|
|
927
|
+
*_param, _request_timeout=_request_timeout
|
|
928
|
+
)
|
|
929
|
+
return response_data.response
|
|
930
|
+
|
|
931
|
+
def _start_database_restore_flow_serialize(
|
|
932
|
+
self,
|
|
933
|
+
_request_auth,
|
|
934
|
+
_content_type,
|
|
935
|
+
_headers,
|
|
936
|
+
_host_index,
|
|
937
|
+
) -> RequestSerialized:
|
|
938
|
+
_host = None
|
|
939
|
+
|
|
940
|
+
_collection_formats: Dict[str, str] = {}
|
|
941
|
+
|
|
942
|
+
_path_params: Dict[str, str] = {}
|
|
943
|
+
_query_params: List[Tuple[str, str]] = []
|
|
944
|
+
_header_params: Dict[str, Optional[str]] = _headers or {}
|
|
945
|
+
_form_params: List[Tuple[str, str]] = []
|
|
946
|
+
_files: Dict[
|
|
947
|
+
str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
|
|
948
|
+
] = {}
|
|
949
|
+
_body_params: Optional[bytes] = None
|
|
950
|
+
|
|
951
|
+
# process the path parameters
|
|
952
|
+
# process the query parameters
|
|
953
|
+
# process the header parameters
|
|
954
|
+
# process the form parameters
|
|
955
|
+
# process the body parameter
|
|
956
|
+
|
|
957
|
+
# authentication setting
|
|
958
|
+
_auth_settings: List[str] = []
|
|
959
|
+
|
|
960
|
+
return self.api_client.param_serialize(
|
|
961
|
+
method="POST",
|
|
962
|
+
resource_path="/admin/database-backups/start-restore",
|
|
963
|
+
path_params=_path_params,
|
|
964
|
+
query_params=_query_params,
|
|
965
|
+
header_params=_header_params,
|
|
966
|
+
body=_body_params,
|
|
967
|
+
post_params=_form_params,
|
|
968
|
+
files=_files,
|
|
969
|
+
auth_settings=_auth_settings,
|
|
970
|
+
collection_formats=_collection_formats,
|
|
971
|
+
_host=_host,
|
|
972
|
+
_request_auth=_request_auth,
|
|
973
|
+
)
|
|
974
|
+
|
|
975
|
+
@validate_call
|
|
976
|
+
async def upload_database_backup(
|
|
977
|
+
self,
|
|
978
|
+
file: Optional[
|
|
979
|
+
Union[StrictBytes, StrictStr, Tuple[StrictStr, StrictBytes]]
|
|
980
|
+
] = None,
|
|
981
|
+
_request_timeout: Union[
|
|
982
|
+
None,
|
|
983
|
+
Annotated[StrictFloat, Field(gt=0)],
|
|
984
|
+
Tuple[
|
|
985
|
+
Annotated[StrictFloat, Field(gt=0)], Annotated[StrictFloat, Field(gt=0)]
|
|
986
|
+
],
|
|
987
|
+
] = None,
|
|
988
|
+
_request_auth: Optional[Dict[StrictStr, Any]] = None,
|
|
989
|
+
_content_type: Optional[StrictStr] = None,
|
|
990
|
+
_headers: Optional[Dict[StrictStr, Any]] = None,
|
|
991
|
+
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
|
|
992
|
+
) -> None:
|
|
993
|
+
"""Upload database backup
|
|
994
|
+
|
|
995
|
+
Uploads .sql/.sql.gz file to restore backup from
|
|
996
|
+
|
|
997
|
+
:param file:
|
|
998
|
+
:type file: bytearray
|
|
999
|
+
:param _request_timeout: timeout setting for this request. If one
|
|
1000
|
+
number provided, it will be total request
|
|
1001
|
+
timeout. It can also be a pair (tuple) of
|
|
1002
|
+
(connection, read) timeouts.
|
|
1003
|
+
:type _request_timeout: int, tuple(int, int), optional
|
|
1004
|
+
:param _request_auth: set to override the auth_settings for an a single
|
|
1005
|
+
request; this effectively ignores the
|
|
1006
|
+
authentication in the spec for a single request.
|
|
1007
|
+
:type _request_auth: dict, optional
|
|
1008
|
+
:param _content_type: force content-type for the request.
|
|
1009
|
+
:type _content_type: str, Optional
|
|
1010
|
+
:param _headers: set to override the headers for a single
|
|
1011
|
+
request; this effectively ignores the headers
|
|
1012
|
+
in the spec for a single request.
|
|
1013
|
+
:type _headers: dict, optional
|
|
1014
|
+
:param _host_index: set to override the host_index for a single
|
|
1015
|
+
request; this effectively ignores the host_index
|
|
1016
|
+
in the spec for a single request.
|
|
1017
|
+
:type _host_index: int, optional
|
|
1018
|
+
:return: Returns the result object.
|
|
1019
|
+
""" # noqa: E501
|
|
1020
|
+
|
|
1021
|
+
_param = self._upload_database_backup_serialize(
|
|
1022
|
+
file=file,
|
|
1023
|
+
_request_auth=_request_auth,
|
|
1024
|
+
_content_type=_content_type,
|
|
1025
|
+
_headers=_headers,
|
|
1026
|
+
_host_index=_host_index,
|
|
1027
|
+
)
|
|
1028
|
+
|
|
1029
|
+
_response_types_map: Dict[str, Optional[str]] = {
|
|
1030
|
+
"201": None,
|
|
1031
|
+
}
|
|
1032
|
+
response_data = await self.api_client.call_api(
|
|
1033
|
+
*_param, _request_timeout=_request_timeout
|
|
1034
|
+
)
|
|
1035
|
+
await response_data.read()
|
|
1036
|
+
return self.api_client.response_deserialize(
|
|
1037
|
+
response_data=response_data,
|
|
1038
|
+
response_types_map=_response_types_map,
|
|
1039
|
+
).data
|
|
1040
|
+
|
|
1041
|
+
@validate_call
|
|
1042
|
+
async def upload_database_backup_with_http_info(
|
|
1043
|
+
self,
|
|
1044
|
+
file: Optional[
|
|
1045
|
+
Union[StrictBytes, StrictStr, Tuple[StrictStr, StrictBytes]]
|
|
1046
|
+
] = None,
|
|
1047
|
+
_request_timeout: Union[
|
|
1048
|
+
None,
|
|
1049
|
+
Annotated[StrictFloat, Field(gt=0)],
|
|
1050
|
+
Tuple[
|
|
1051
|
+
Annotated[StrictFloat, Field(gt=0)], Annotated[StrictFloat, Field(gt=0)]
|
|
1052
|
+
],
|
|
1053
|
+
] = None,
|
|
1054
|
+
_request_auth: Optional[Dict[StrictStr, Any]] = None,
|
|
1055
|
+
_content_type: Optional[StrictStr] = None,
|
|
1056
|
+
_headers: Optional[Dict[StrictStr, Any]] = None,
|
|
1057
|
+
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
|
|
1058
|
+
) -> ApiResponse[None]:
|
|
1059
|
+
"""Upload database backup
|
|
1060
|
+
|
|
1061
|
+
Uploads .sql/.sql.gz file to restore backup from
|
|
1062
|
+
|
|
1063
|
+
:param file:
|
|
1064
|
+
:type file: bytearray
|
|
1065
|
+
:param _request_timeout: timeout setting for this request. If one
|
|
1066
|
+
number provided, it will be total request
|
|
1067
|
+
timeout. It can also be a pair (tuple) of
|
|
1068
|
+
(connection, read) timeouts.
|
|
1069
|
+
:type _request_timeout: int, tuple(int, int), optional
|
|
1070
|
+
:param _request_auth: set to override the auth_settings for an a single
|
|
1071
|
+
request; this effectively ignores the
|
|
1072
|
+
authentication in the spec for a single request.
|
|
1073
|
+
:type _request_auth: dict, optional
|
|
1074
|
+
:param _content_type: force content-type for the request.
|
|
1075
|
+
:type _content_type: str, Optional
|
|
1076
|
+
:param _headers: set to override the headers for a single
|
|
1077
|
+
request; this effectively ignores the headers
|
|
1078
|
+
in the spec for a single request.
|
|
1079
|
+
:type _headers: dict, optional
|
|
1080
|
+
:param _host_index: set to override the host_index for a single
|
|
1081
|
+
request; this effectively ignores the host_index
|
|
1082
|
+
in the spec for a single request.
|
|
1083
|
+
:type _host_index: int, optional
|
|
1084
|
+
:return: Returns the result object.
|
|
1085
|
+
""" # noqa: E501
|
|
1086
|
+
|
|
1087
|
+
_param = self._upload_database_backup_serialize(
|
|
1088
|
+
file=file,
|
|
1089
|
+
_request_auth=_request_auth,
|
|
1090
|
+
_content_type=_content_type,
|
|
1091
|
+
_headers=_headers,
|
|
1092
|
+
_host_index=_host_index,
|
|
1093
|
+
)
|
|
1094
|
+
|
|
1095
|
+
_response_types_map: Dict[str, Optional[str]] = {
|
|
1096
|
+
"201": None,
|
|
1097
|
+
}
|
|
1098
|
+
response_data = await self.api_client.call_api(
|
|
1099
|
+
*_param, _request_timeout=_request_timeout
|
|
1100
|
+
)
|
|
1101
|
+
await response_data.read()
|
|
1102
|
+
return self.api_client.response_deserialize(
|
|
1103
|
+
response_data=response_data,
|
|
1104
|
+
response_types_map=_response_types_map,
|
|
1105
|
+
)
|
|
1106
|
+
|
|
1107
|
+
@validate_call
|
|
1108
|
+
async def upload_database_backup_without_preload_content(
|
|
1109
|
+
self,
|
|
1110
|
+
file: Optional[
|
|
1111
|
+
Union[StrictBytes, StrictStr, Tuple[StrictStr, StrictBytes]]
|
|
1112
|
+
] = None,
|
|
1113
|
+
_request_timeout: Union[
|
|
1114
|
+
None,
|
|
1115
|
+
Annotated[StrictFloat, Field(gt=0)],
|
|
1116
|
+
Tuple[
|
|
1117
|
+
Annotated[StrictFloat, Field(gt=0)], Annotated[StrictFloat, Field(gt=0)]
|
|
1118
|
+
],
|
|
1119
|
+
] = None,
|
|
1120
|
+
_request_auth: Optional[Dict[StrictStr, Any]] = None,
|
|
1121
|
+
_content_type: Optional[StrictStr] = None,
|
|
1122
|
+
_headers: Optional[Dict[StrictStr, Any]] = None,
|
|
1123
|
+
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
|
|
1124
|
+
) -> RESTResponseType:
|
|
1125
|
+
"""Upload database backup
|
|
1126
|
+
|
|
1127
|
+
Uploads .sql/.sql.gz file to restore backup from
|
|
1128
|
+
|
|
1129
|
+
:param file:
|
|
1130
|
+
:type file: bytearray
|
|
1131
|
+
:param _request_timeout: timeout setting for this request. If one
|
|
1132
|
+
number provided, it will be total request
|
|
1133
|
+
timeout. It can also be a pair (tuple) of
|
|
1134
|
+
(connection, read) timeouts.
|
|
1135
|
+
:type _request_timeout: int, tuple(int, int), optional
|
|
1136
|
+
:param _request_auth: set to override the auth_settings for an a single
|
|
1137
|
+
request; this effectively ignores the
|
|
1138
|
+
authentication in the spec for a single request.
|
|
1139
|
+
:type _request_auth: dict, optional
|
|
1140
|
+
:param _content_type: force content-type for the request.
|
|
1141
|
+
:type _content_type: str, Optional
|
|
1142
|
+
:param _headers: set to override the headers for a single
|
|
1143
|
+
request; this effectively ignores the headers
|
|
1144
|
+
in the spec for a single request.
|
|
1145
|
+
:type _headers: dict, optional
|
|
1146
|
+
:param _host_index: set to override the host_index for a single
|
|
1147
|
+
request; this effectively ignores the host_index
|
|
1148
|
+
in the spec for a single request.
|
|
1149
|
+
:type _host_index: int, optional
|
|
1150
|
+
:return: Returns the result object.
|
|
1151
|
+
""" # noqa: E501
|
|
1152
|
+
|
|
1153
|
+
_param = self._upload_database_backup_serialize(
|
|
1154
|
+
file=file,
|
|
1155
|
+
_request_auth=_request_auth,
|
|
1156
|
+
_content_type=_content_type,
|
|
1157
|
+
_headers=_headers,
|
|
1158
|
+
_host_index=_host_index,
|
|
1159
|
+
)
|
|
1160
|
+
|
|
1161
|
+
_response_types_map: Dict[str, Optional[str]] = {
|
|
1162
|
+
"201": None,
|
|
1163
|
+
}
|
|
1164
|
+
response_data = await self.api_client.call_api(
|
|
1165
|
+
*_param, _request_timeout=_request_timeout
|
|
1166
|
+
)
|
|
1167
|
+
return response_data.response
|
|
1168
|
+
|
|
1169
|
+
def _upload_database_backup_serialize(
|
|
1170
|
+
self,
|
|
1171
|
+
file,
|
|
1172
|
+
_request_auth,
|
|
1173
|
+
_content_type,
|
|
1174
|
+
_headers,
|
|
1175
|
+
_host_index,
|
|
1176
|
+
) -> RequestSerialized:
|
|
1177
|
+
_host = None
|
|
1178
|
+
|
|
1179
|
+
_collection_formats: Dict[str, str] = {}
|
|
1180
|
+
|
|
1181
|
+
_path_params: Dict[str, str] = {}
|
|
1182
|
+
_query_params: List[Tuple[str, str]] = []
|
|
1183
|
+
_header_params: Dict[str, Optional[str]] = _headers or {}
|
|
1184
|
+
_form_params: List[Tuple[str, str]] = []
|
|
1185
|
+
_files: Dict[
|
|
1186
|
+
str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
|
|
1187
|
+
] = {}
|
|
1188
|
+
_body_params: Optional[bytes] = None
|
|
1189
|
+
|
|
1190
|
+
# process the path parameters
|
|
1191
|
+
# process the query parameters
|
|
1192
|
+
# process the header parameters
|
|
1193
|
+
# process the form parameters
|
|
1194
|
+
if file is not None:
|
|
1195
|
+
_files["file"] = file
|
|
1196
|
+
# process the body parameter
|
|
1197
|
+
|
|
1198
|
+
# set the HTTP header `Content-Type`
|
|
1199
|
+
if _content_type:
|
|
1200
|
+
_header_params["Content-Type"] = _content_type
|
|
1201
|
+
else:
|
|
1202
|
+
_default_content_type = self.api_client.select_header_content_type(
|
|
1203
|
+
["multipart/form-data"]
|
|
1204
|
+
)
|
|
1205
|
+
if _default_content_type is not None:
|
|
1206
|
+
_header_params["Content-Type"] = _default_content_type
|
|
1207
|
+
|
|
1208
|
+
# authentication setting
|
|
1209
|
+
_auth_settings: List[str] = ["cookie", "api_key", "bearer"]
|
|
1210
|
+
|
|
1211
|
+
return self.api_client.param_serialize(
|
|
1212
|
+
method="POST",
|
|
1213
|
+
resource_path="/admin/database-backups/upload",
|
|
1214
|
+
path_params=_path_params,
|
|
1215
|
+
query_params=_query_params,
|
|
1216
|
+
header_params=_header_params,
|
|
1217
|
+
body=_body_params,
|
|
1218
|
+
post_params=_form_params,
|
|
1219
|
+
files=_files,
|
|
1220
|
+
auth_settings=_auth_settings,
|
|
1221
|
+
collection_formats=_collection_formats,
|
|
1222
|
+
_host=_host,
|
|
1223
|
+
_request_auth=_request_auth,
|
|
1224
|
+
)
|