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