qanswer-sdk 0.1.0.dev0__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.
Files changed (618) hide show
  1. qanswer_sdk/__init__.py +1256 -0
  2. qanswer_sdk/api/__init__.py +63 -0
  3. qanswer_sdk/api/admin_api.py +7893 -0
  4. qanswer_sdk/api/ai_assistant_access_rights_api.py +5881 -0
  5. qanswer_sdk/api/ai_assistant_api.py +11047 -0
  6. qanswer_sdk/api/anthropic_compatible_api.py +311 -0
  7. qanswer_sdk/api/auto_complete_api.py +612 -0
  8. qanswer_sdk/api/bot_slack_api.py +1015 -0
  9. qanswer_sdk/api/branding_api.py +5733 -0
  10. qanswer_sdk/api/bulk_reindex_api.py +2029 -0
  11. qanswer_sdk/api/chatbot_api.py +1102 -0
  12. qanswer_sdk/api/connector_audio_api.py +3469 -0
  13. qanswer_sdk/api/connector_document_api.py +2685 -0
  14. qanswer_sdk/api/connector_e_consilium_api.py +333 -0
  15. qanswer_sdk/api/connector_e_consilium_search_index_api_api.py +1231 -0
  16. qanswer_sdk/api/connector_google_drive_api.py +2175 -0
  17. qanswer_sdk/api/connector_imapapi_api.py +1866 -0
  18. qanswer_sdk/api/connector_one_drive_api.py +1579 -0
  19. qanswer_sdk/api/connector_onenote_api.py +1596 -0
  20. qanswer_sdk/api/connector_pinecone_api.py +893 -0
  21. qanswer_sdk/api/connector_publication_office_api_api.py +1230 -0
  22. qanswer_sdk/api/connector_qn_a_api.py +1521 -0
  23. qanswer_sdk/api/connector_rdf_answer_api.py +1454 -0
  24. qanswer_sdk/api/connector_rdf_api.py +5090 -0
  25. qanswer_sdk/api/connector_sharepoint_api.py +3926 -0
  26. qanswer_sdk/api/connector_websearch_api.py +332 -0
  27. qanswer_sdk/api/connector_website_api.py +3108 -0
  28. qanswer_sdk/api/connector_x_wiki_api_api.py +1278 -0
  29. qanswer_sdk/api/connectors_api.py +6946 -0
  30. qanswer_sdk/api/connectors_data_api.py +5903 -0
  31. qanswer_sdk/api/conversation_logs_api.py +14228 -0
  32. qanswer_sdk/api/dataset_config_api.py +4016 -0
  33. qanswer_sdk/api/debug_api.py +278 -0
  34. qanswer_sdk/api/default_api.py +763 -0
  35. qanswer_sdk/api/frontend_config_api.py +270 -0
  36. qanswer_sdk/api/health_check_api_api.py +278 -0
  37. qanswer_sdk/api/mcp_api.py +10758 -0
  38. qanswer_sdk/api/metadata_api.py +1309 -0
  39. qanswer_sdk/api/notifications_api.py +1842 -0
  40. qanswer_sdk/api/o_auth2_api.py +648 -0
  41. qanswer_sdk/api/open_ai_compatible_api.py +1093 -0
  42. qanswer_sdk/api/payment_api.py +1854 -0
  43. qanswer_sdk/api/retention_policy_api.py +4404 -0
  44. qanswer_sdk/api/socket_api.py +4706 -0
  45. qanswer_sdk/api/speech_to_text_api.py +968 -0
  46. qanswer_sdk/api/task_ai_excel_api.py +3749 -0
  47. qanswer_sdk/api/task_chat_api.py +2079 -0
  48. qanswer_sdk/api/task_entity_linking_api.py +315 -0
  49. qanswer_sdk/api/task_rdf_linker_api.py +4407 -0
  50. qanswer_sdk/api/task_rdf_sparql_endpoint_api.py +3355 -0
  51. qanswer_sdk/api/task_rdf_text_linker_api.py +1513 -0
  52. qanswer_sdk/api/task_report_copilot_api.py +7355 -0
  53. qanswer_sdk/api/task_search_api.py +2142 -0
  54. qanswer_sdk/api/task_text2sparql_api.py +947 -0
  55. qanswer_sdk/api/task_text_classification_api.py +592 -0
  56. qanswer_sdk/api/tasks_api.py +26394 -0
  57. qanswer_sdk/api/tool_embedder_api.py +5532 -0
  58. qanswer_sdk/api/tool_llm_api.py +6364 -0
  59. qanswer_sdk/api/unit_organizations_api.py +8600 -0
  60. qanswer_sdk/api/unit_teams_api.py +4492 -0
  61. qanswer_sdk/api/unit_user_api.py +12759 -0
  62. qanswer_sdk/api_client.py +804 -0
  63. qanswer_sdk/api_response.py +21 -0
  64. qanswer_sdk/configuration.py +614 -0
  65. qanswer_sdk/exceptions.py +216 -0
  66. qanswer_sdk/models/__init__.py +562 -0
  67. qanswer_sdk/models/access_audio_spans_response_model.py +91 -0
  68. qanswer_sdk/models/access_pdf_payload_model.py +102 -0
  69. qanswer_sdk/models/access_type.py +42 -0
  70. qanswer_sdk/models/access_type_shared.py +38 -0
  71. qanswer_sdk/models/add_qn_a_request.py +103 -0
  72. qanswer_sdk/models/add_synonyms.py +93 -0
  73. qanswer_sdk/models/add_synonyms_resp.py +89 -0
  74. qanswer_sdk/models/admin_overall_stats_response.py +105 -0
  75. qanswer_sdk/models/admin_user_overall_stats.py +99 -0
  76. qanswer_sdk/models/advanced_o_auth2_mcp_authentication_config.py +95 -0
  77. qanswer_sdk/models/aggregate.py +93 -0
  78. qanswer_sdk/models/aggregation.py +110 -0
  79. qanswer_sdk/models/aggregation_type.py +41 -0
  80. qanswer_sdk/models/aggregations_group.py +102 -0
  81. qanswer_sdk/models/ai_assistant_clone_response.py +91 -0
  82. qanswer_sdk/models/ai_assistant_dto.py +113 -0
  83. qanswer_sdk/models/ai_assistant_filter_dto.py +113 -0
  84. qanswer_sdk/models/ai_assistant_list.py +101 -0
  85. qanswer_sdk/models/ai_assistant_share_response.py +93 -0
  86. qanswer_sdk/models/ai_assistant_shared_access.py +95 -0
  87. qanswer_sdk/models/ai_excel_entity_result.py +97 -0
  88. qanswer_sdk/models/ai_excel_entity_search_payload.py +95 -0
  89. qanswer_sdk/models/ai_excel_entity_search_response.py +103 -0
  90. qanswer_sdk/models/ai_excel_global_settings.py +95 -0
  91. qanswer_sdk/models/ai_excel_global_settings_request.py +95 -0
  92. qanswer_sdk/models/ai_excel_task_settings.py +119 -0
  93. qanswer_sdk/models/ai_excel_task_update.py +119 -0
  94. qanswer_sdk/models/ai_excel_template_create.py +119 -0
  95. qanswer_sdk/models/ai_excel_template_read.py +121 -0
  96. qanswer_sdk/models/ai_excel_template_settings_request.py +91 -0
  97. qanswer_sdk/models/ai_excel_template_update.py +125 -0
  98. qanswer_sdk/models/ai_excel_templates_search_request.py +104 -0
  99. qanswer_sdk/models/ai_excel_templates_search_response.py +101 -0
  100. qanswer_sdk/models/allowed_extension.py +53 -0
  101. qanswer_sdk/models/allowed_file_extensions.py +88 -0
  102. qanswer_sdk/models/api_key_header_type.py +39 -0
  103. qanswer_sdk/models/api_key_mcp_authentication_config.py +98 -0
  104. qanswer_sdk/models/applied_filter_type.py +37 -0
  105. qanswer_sdk/models/applied_metadata_filter.py +97 -0
  106. qanswer_sdk/models/apply_template_task_settings_to_slots_response.py +89 -0
  107. qanswer_sdk/models/assistant_category_color_definition.py +89 -0
  108. qanswer_sdk/models/assistant_category_color_item.py +89 -0
  109. qanswer_sdk/models/assistant_category_colors_update_payload.py +95 -0
  110. qanswer_sdk/models/assistant_category_count.py +91 -0
  111. qanswer_sdk/models/assistant_message_stop.py +93 -0
  112. qanswer_sdk/models/assistant_retention_response.py +97 -0
  113. qanswer_sdk/models/assistant_task.py +43 -0
  114. qanswer_sdk/models/assistant_template_with_tools_selection_dto.py +123 -0
  115. qanswer_sdk/models/audio_allowed_file_extensions.py +87 -0
  116. qanswer_sdk/models/audio_format.py +37 -0
  117. qanswer_sdk/models/audio_segment.py +95 -0
  118. qanswer_sdk/models/audio_segment_update_payload.py +97 -0
  119. qanswer_sdk/models/audio_segment_update_response.py +91 -0
  120. qanswer_sdk/models/audio_speaker_update_payload.py +99 -0
  121. qanswer_sdk/models/audio_speaker_update_response.py +91 -0
  122. qanswer_sdk/models/audio_transcription_list_response.py +101 -0
  123. qanswer_sdk/models/audio_transcription_mode.py +37 -0
  124. qanswer_sdk/models/audio_transcription_record.py +101 -0
  125. qanswer_sdk/models/audio_transcription_status.py +39 -0
  126. qanswer_sdk/models/audio_upload_response.py +91 -0
  127. qanswer_sdk/models/audio_word_segment.py +93 -0
  128. qanswer_sdk/models/audio_word_span_change.py +94 -0
  129. qanswer_sdk/models/audio_word_span_update_payload.py +104 -0
  130. qanswer_sdk/models/audio_word_span_update_response.py +91 -0
  131. qanswer_sdk/models/audio_word_update_payload.py +100 -0
  132. qanswer_sdk/models/audio_word_update_response.py +91 -0
  133. qanswer_sdk/models/auth_link_response.py +91 -0
  134. qanswer_sdk/models/auto_bot_description_request.py +89 -0
  135. qanswer_sdk/models/auto_bot_description_response.py +87 -0
  136. qanswer_sdk/models/available_aggregation.py +92 -0
  137. qanswer_sdk/models/available_connectors_response.py +92 -0
  138. qanswer_sdk/models/available_logs_visibility_policy.py +91 -0
  139. qanswer_sdk/models/available_space_quota_for_dataset.py +95 -0
  140. qanswer_sdk/models/available_storage_preference.py +91 -0
  141. qanswer_sdk/models/base_connectors_response.py +89 -0
  142. qanswer_sdk/models/base_conversation_response.py +89 -0
  143. qanswer_sdk/models/base_feedback_response.py +89 -0
  144. qanswer_sdk/models/bot_answer_length.py +38 -0
  145. qanswer_sdk/models/branding_app_title.py +87 -0
  146. qanswer_sdk/models/branding_system_message.py +87 -0
  147. qanswer_sdk/models/bulk_reindex_counts_by_type.py +89 -0
  148. qanswer_sdk/models/bulk_reindex_item_status.py +41 -0
  149. qanswer_sdk/models/bulk_reindex_job_detail_dto.py +103 -0
  150. qanswer_sdk/models/bulk_reindex_job_dto.py +125 -0
  151. qanswer_sdk/models/bulk_reindex_job_item_dto.py +113 -0
  152. qanswer_sdk/models/bulk_reindex_job_item_sort_by.py +40 -0
  153. qanswer_sdk/models/bulk_reindex_job_status.py +41 -0
  154. qanswer_sdk/models/bulk_reindex_jobs_list_response.py +97 -0
  155. qanswer_sdk/models/bulk_reindex_preview_counts.py +99 -0
  156. qanswer_sdk/models/bulk_reindex_preview_request.py +91 -0
  157. qanswer_sdk/models/bulk_reindex_preview_response.py +102 -0
  158. qanswer_sdk/models/bulk_reindex_skip_reason.py +40 -0
  159. qanswer_sdk/models/bulk_reindex_sort_order.py +37 -0
  160. qanswer_sdk/models/bulk_reindex_submit_request.py +94 -0
  161. qanswer_sdk/models/bulk_update_tool_selections_request.py +87 -0
  162. qanswer_sdk/models/capability_type.py +37 -0
  163. qanswer_sdk/models/cell.py +89 -0
  164. qanswer_sdk/models/change_password.py +89 -0
  165. qanswer_sdk/models/change_password_admin.py +89 -0
  166. qanswer_sdk/models/change_role.py +90 -0
  167. qanswer_sdk/models/chat_task_settings.py +141 -0
  168. qanswer_sdk/models/chat_task_settings_update_payload.py +95 -0
  169. qanswer_sdk/models/chat_task_update.py +139 -0
  170. qanswer_sdk/models/chatbot_chat_payload.py +150 -0
  171. qanswer_sdk/models/chatbot_default_settings_response.py +95 -0
  172. qanswer_sdk/models/chatbot_llm_dto.py +120 -0
  173. qanswer_sdk/models/chatbot_response.py +143 -0
  174. qanswer_sdk/models/chatbot_setting_dto.py +99 -0
  175. qanswer_sdk/models/chatbot_setting_request.py +91 -0
  176. qanswer_sdk/models/class_info.py +89 -0
  177. qanswer_sdk/models/config.py +228 -0
  178. qanswer_sdk/models/config1.py +138 -0
  179. qanswer_sdk/models/connector_config_list_response.py +99 -0
  180. qanswer_sdk/models/connector_config_model.py +96 -0
  181. qanswer_sdk/models/connector_config_patch_payload.py +93 -0
  182. qanswer_sdk/models/connector_config_response.py +95 -0
  183. qanswer_sdk/models/connector_config_sync_response.py +93 -0
  184. qanswer_sdk/models/connector_config_type.py +37 -0
  185. qanswer_sdk/models/connector_model.py +114 -0
  186. qanswer_sdk/models/connector_type.py +51 -0
  187. qanswer_sdk/models/connector_type_dto.py +92 -0
  188. qanswer_sdk/models/connector_type_list_dto.py +95 -0
  189. qanswer_sdk/models/content_item.py +106 -0
  190. qanswer_sdk/models/content_item_type.py +39 -0
  191. qanswer_sdk/models/conversation_aggregations_request.py +107 -0
  192. qanswer_sdk/models/conversation_message.py +230 -0
  193. qanswer_sdk/models/conversation_message_error_key.py +52 -0
  194. qanswer_sdk/models/conversation_message_search_result.py +112 -0
  195. qanswer_sdk/models/conversation_model.py +144 -0
  196. qanswer_sdk/models/conversation_overall_stats.py +97 -0
  197. qanswer_sdk/models/conversation_overall_stats_response.py +95 -0
  198. qanswer_sdk/models/conversation_retention_response.py +91 -0
  199. qanswer_sdk/models/conversation_statistics.py +95 -0
  200. qanswer_sdk/models/conversation_update.py +93 -0
  201. qanswer_sdk/models/conversation_users_stats.py +99 -0
  202. qanswer_sdk/models/conversation_users_stats_response.py +99 -0
  203. qanswer_sdk/models/coordinates.py +89 -0
  204. qanswer_sdk/models/cost_summary_dto.py +99 -0
  205. qanswer_sdk/models/create_connector_request.py +95 -0
  206. qanswer_sdk/models/create_connector_response.py +95 -0
  207. qanswer_sdk/models/create_imap_connector_request.py +105 -0
  208. qanswer_sdk/models/create_pinecone_connector_request.py +97 -0
  209. qanswer_sdk/models/create_sharepoint_connector_from_certificate_request.py +105 -0
  210. qanswer_sdk/models/create_sharepoint_connector_request.py +103 -0
  211. qanswer_sdk/models/create_x_wiki_connector_request.py +103 -0
  212. qanswer_sdk/models/credits_info_dto.py +95 -0
  213. qanswer_sdk/models/credits_info_global_dto.py +97 -0
  214. qanswer_sdk/models/currency.py +38 -0
  215. qanswer_sdk/models/data.py +211 -0
  216. qanswer_sdk/models/data_filling_mode.py +39 -0
  217. qanswer_sdk/models/data_storage_preference.py +38 -0
  218. qanswer_sdk/models/dataset_config_request.py +138 -0
  219. qanswer_sdk/models/dataset_default_values_model.py +129 -0
  220. qanswer_sdk/models/dataset_detail.py +128 -0
  221. qanswer_sdk/models/dataset_detail_kg.py +88 -0
  222. qanswer_sdk/models/dataset_schema.py +193 -0
  223. qanswer_sdk/models/dataset_type.py +38 -0
  224. qanswer_sdk/models/dataset_update_object.py +185 -0
  225. qanswer_sdk/models/dataset_users_response.py +87 -0
  226. qanswer_sdk/models/default_prompt.py +100 -0
  227. qanswer_sdk/models/delete_connector_model.py +90 -0
  228. qanswer_sdk/models/delete_connector_request.py +99 -0
  229. qanswer_sdk/models/delete_connectors_response.py +89 -0
  230. qanswer_sdk/models/delete_files_status_response.py +91 -0
  231. qanswer_sdk/models/delete_index.py +91 -0
  232. qanswer_sdk/models/delete_index_resp.py +89 -0
  233. qanswer_sdk/models/delete_qn_a_pair_request.py +95 -0
  234. qanswer_sdk/models/delete_qn_a_pair_response.py +89 -0
  235. qanswer_sdk/models/delete_synonym.py +93 -0
  236. qanswer_sdk/models/delete_synonym_resp.py +89 -0
  237. qanswer_sdk/models/delete_synonyms.py +91 -0
  238. qanswer_sdk/models/diarization_queue_status.py +99 -0
  239. qanswer_sdk/models/document_content_response.py +91 -0
  240. qanswer_sdk/models/document_content_update_model.py +99 -0
  241. qanswer_sdk/models/document_file_delete_by_connector_model.py +101 -0
  242. qanswer_sdk/models/document_file_delete_by_id_model.py +91 -0
  243. qanswer_sdk/models/document_parsing_task_settings.py +124 -0
  244. qanswer_sdk/models/document_parsing_task_settings_update_payload.py +95 -0
  245. qanswer_sdk/models/document_parsing_task_update.py +121 -0
  246. qanswer_sdk/models/document_status_group.py +39 -0
  247. qanswer_sdk/models/document_status_response.py +89 -0
  248. qanswer_sdk/models/dummy_error.py +89 -0
  249. qanswer_sdk/models/duplicate_ai_excel_template_request.py +97 -0
  250. qanswer_sdk/models/duplicate_ai_excel_template_response.py +87 -0
  251. qanswer_sdk/models/duplicate_report_template_payload.py +97 -0
  252. qanswer_sdk/models/duplicate_report_template_response.py +87 -0
  253. qanswer_sdk/models/e_consilium_connector_config.py +108 -0
  254. qanswer_sdk/models/e_consilium_search_index_search_response.py +113 -0
  255. qanswer_sdk/models/econsilium_file_metadata.py +105 -0
  256. qanswer_sdk/models/econsilium_search_index_add_payload.py +107 -0
  257. qanswer_sdk/models/econsilium_search_index_additional_fields.py +103 -0
  258. qanswer_sdk/models/effective_retention_dto.py +95 -0
  259. qanswer_sdk/models/email_folder.py +91 -0
  260. qanswer_sdk/models/email_request.py +87 -0
  261. qanswer_sdk/models/embedder_cost_filter.py +112 -0
  262. qanswer_sdk/models/embedder_cost_list.py +101 -0
  263. qanswer_sdk/models/embedder_create_dto.py +143 -0
  264. qanswer_sdk/models/embedder_detailed_dto.py +163 -0
  265. qanswer_sdk/models/embedder_dto.py +103 -0
  266. qanswer_sdk/models/embedder_list_dto.py +101 -0
  267. qanswer_sdk/models/embedder_ref.py +95 -0
  268. qanswer_sdk/models/embedder_update_dto.py +135 -0
  269. qanswer_sdk/models/embedding_endpoint_import_failure.py +89 -0
  270. qanswer_sdk/models/embedding_endpoint_import_response.py +99 -0
  271. qanswer_sdk/models/embedding_endpoint_modality.py +37 -0
  272. qanswer_sdk/models/embedding_endpoint_validation_response.py +90 -0
  273. qanswer_sdk/models/embedding_provider.py +44 -0
  274. qanswer_sdk/models/enable_enhanced_context_payload.py +91 -0
  275. qanswer_sdk/models/enable_enhanced_context_response.py +87 -0
  276. qanswer_sdk/models/endpoint_status.py +38 -0
  277. qanswer_sdk/models/entity_description_dto.py +93 -0
  278. qanswer_sdk/models/entity_linking_payload.py +97 -0
  279. qanswer_sdk/models/entity_linking_response.py +97 -0
  280. qanswer_sdk/models/entity_model_in_linking.py +95 -0
  281. qanswer_sdk/models/es_meta_data.py +92 -0
  282. qanswer_sdk/models/es_meta_data_value.py +87 -0
  283. qanswer_sdk/models/evaluate_feedback_response.py +109 -0
  284. qanswer_sdk/models/evaluate_single_feedback_response.py +97 -0
  285. qanswer_sdk/models/extra_body.py +91 -0
  286. qanswer_sdk/models/extract_hyper_links_payload.py +100 -0
  287. qanswer_sdk/models/extract_robot_links_payload.py +88 -0
  288. qanswer_sdk/models/extract_robot_links_response.py +88 -0
  289. qanswer_sdk/models/extraction_strategy.py +38 -0
  290. qanswer_sdk/models/fact.py +96 -0
  291. qanswer_sdk/models/feedback_evaluation_history_entries_response.py +101 -0
  292. qanswer_sdk/models/feedback_evaluation_history_entry_model.py +105 -0
  293. qanswer_sdk/models/feedback_model.py +132 -0
  294. qanswer_sdk/models/feedback_response.py +95 -0
  295. qanswer_sdk/models/feedback_update.py +105 -0
  296. qanswer_sdk/models/file_acl_principal.py +99 -0
  297. qanswer_sdk/models/file_acl_response.py +101 -0
  298. qanswer_sdk/models/file_es_meta_data.py +116 -0
  299. qanswer_sdk/models/file_failure_reason.py +49 -0
  300. qanswer_sdk/models/file_folder_model.py +117 -0
  301. qanswer_sdk/models/file_model.py +124 -0
  302. qanswer_sdk/models/file_status.py +43 -0
  303. qanswer_sdk/models/file_type.py +37 -0
  304. qanswer_sdk/models/file_upload_payload.py +107 -0
  305. qanswer_sdk/models/files_by_connector_model.py +89 -0
  306. qanswer_sdk/models/g_drive_connector_info.py +96 -0
  307. qanswer_sdk/models/g_drive_download_by_ids.py +89 -0
  308. qanswer_sdk/models/g_drive_download_request.py +103 -0
  309. qanswer_sdk/models/g_drive_refresh_request.py +91 -0
  310. qanswer_sdk/models/generation_params.py +89 -0
  311. qanswer_sdk/models/get_connector_by_id_response.py +91 -0
  312. qanswer_sdk/models/get_conversation_response.py +95 -0
  313. qanswer_sdk/models/global_config_dto.py +155 -0
  314. qanswer_sdk/models/google_drive_connector_config.py +110 -0
  315. qanswer_sdk/models/guardrail_endpoint.py +112 -0
  316. qanswer_sdk/models/guardrail_mode.py +38 -0
  317. qanswer_sdk/models/highlight_audio_payload_model.py +100 -0
  318. qanswer_sdk/models/http_validation_error.py +95 -0
  319. qanswer_sdk/models/iframe_strategy.py +38 -0
  320. qanswer_sdk/models/image_url_detail.py +38 -0
  321. qanswer_sdk/models/imap_add_payload.py +105 -0
  322. qanswer_sdk/models/imap_additional_fields.py +101 -0
  323. qanswer_sdk/models/imap_file_metadata.py +108 -0
  324. qanswer_sdk/models/imap_search_response.py +113 -0
  325. qanswer_sdk/models/index_config.py +89 -0
  326. qanswer_sdk/models/install_response.py +89 -0
  327. qanswer_sdk/models/interface_origin.py +47 -0
  328. qanswer_sdk/models/ip2_geo_response.py +91 -0
  329. qanswer_sdk/models/is_enabled_response.py +87 -0
  330. qanswer_sdk/models/jwt_authentication_response.py +93 -0
  331. qanswer_sdk/models/label.py +89 -0
  332. qanswer_sdk/models/labeled_node.py +89 -0
  333. qanswer_sdk/models/language.py +38 -0
  334. qanswer_sdk/models/last_updated_template_conversation_id_response.py +87 -0
  335. qanswer_sdk/models/link.py +99 -0
  336. qanswer_sdk/models/link_extraction_response.py +97 -0
  337. qanswer_sdk/models/link_result_paginated.py +97 -0
  338. qanswer_sdk/models/linked_entity_model_in_linking.py +99 -0
  339. qanswer_sdk/models/linker.py +103 -0
  340. qanswer_sdk/models/linking_result.py +95 -0
  341. qanswer_sdk/models/links.py +99 -0
  342. qanswer_sdk/models/list_connectors_response.py +95 -0
  343. qanswer_sdk/models/list_conversation_response.py +105 -0
  344. qanswer_sdk/models/list_feedback_response.py +105 -0
  345. qanswer_sdk/models/list_files_connector_response.py +107 -0
  346. qanswer_sdk/models/list_socket_events.py +88 -0
  347. qanswer_sdk/models/list_synonyms_model.py +95 -0
  348. qanswer_sdk/models/llm_context_ranges.py +93 -0
  349. qanswer_sdk/models/llm_cost_filter.py +112 -0
  350. qanswer_sdk/models/llm_cost_list.py +101 -0
  351. qanswer_sdk/models/llm_create_dto.py +177 -0
  352. qanswer_sdk/models/llm_detailed_dto.py +198 -0
  353. qanswer_sdk/models/llm_dto.py +120 -0
  354. qanswer_sdk/models/llm_endpoint.py +179 -0
  355. qanswer_sdk/models/llm_endpoint_default_prompts.py +93 -0
  356. qanswer_sdk/models/llm_endpoint_import_failure.py +89 -0
  357. qanswer_sdk/models/llm_endpoint_import_response.py +99 -0
  358. qanswer_sdk/models/llm_endpoint_modality.py +37 -0
  359. qanswer_sdk/models/llm_endpoint_provider.py +44 -0
  360. qanswer_sdk/models/llm_endpoint_read.py +179 -0
  361. qanswer_sdk/models/llm_endpoint_validation_response.py +90 -0
  362. qanswer_sdk/models/llm_health_response.py +89 -0
  363. qanswer_sdk/models/llm_list_detailed_dto.py +101 -0
  364. qanswer_sdk/models/llm_list_dto.py +101 -0
  365. qanswer_sdk/models/llm_update_dto.py +174 -0
  366. qanswer_sdk/models/location_details.py +97 -0
  367. qanswer_sdk/models/log_stats_request.py +100 -0
  368. qanswer_sdk/models/login_request.py +89 -0
  369. qanswer_sdk/models/logs_visibility_policy.py +38 -0
  370. qanswer_sdk/models/logs_visibility_policy_payload.py +92 -0
  371. qanswer_sdk/models/logs_visibility_policy_response.py +92 -0
  372. qanswer_sdk/models/mcp_auth_field_definition.py +98 -0
  373. qanswer_sdk/models/mcp_auth_field_type.py +37 -0
  374. qanswer_sdk/models/mcp_authentication_type.py +39 -0
  375. qanswer_sdk/models/mcp_connection.py +108 -0
  376. qanswer_sdk/models/mcp_connection_create.py +100 -0
  377. qanswer_sdk/models/mcp_server.py +146 -0
  378. qanswer_sdk/models/mcp_server_create.py +116 -0
  379. qanswer_sdk/models/mcp_server_type.py +37 -0
  380. qanswer_sdk/models/mcp_server_update.py +114 -0
  381. qanswer_sdk/models/mcp_tool_dto.py +131 -0
  382. qanswer_sdk/models/mcp_tool_info.py +95 -0
  383. qanswer_sdk/models/mcp_tool_selection_source.py +37 -0
  384. qanswer_sdk/models/mcp_tool_sync_action.py +39 -0
  385. qanswer_sdk/models/mcp_tool_sync_diff.py +94 -0
  386. qanswer_sdk/models/mcp_tool_sync_preview.py +95 -0
  387. qanswer_sdk/models/mcp_tool_update.py +91 -0
  388. qanswer_sdk/models/mcp_transport.py +37 -0
  389. qanswer_sdk/models/mcp_visibility.py +38 -0
  390. qanswer_sdk/models/mcpo_auth2_authorize_body.py +105 -0
  391. qanswer_sdk/models/mcpo_auth2_initiating_origin.py +42 -0
  392. qanswer_sdk/models/message_role.py +38 -0
  393. qanswer_sdk/models/messages_stats_per_day_response.py +99 -0
  394. qanswer_sdk/models/microsoft_connector_config.py +110 -0
  395. qanswer_sdk/models/modify_connector_request.py +98 -0
  396. qanswer_sdk/models/modify_file_display_name_request.py +97 -0
  397. qanswer_sdk/models/notification_dto.py +114 -0
  398. qanswer_sdk/models/notification_filter.py +107 -0
  399. qanswer_sdk/models/notification_list_dto.py +101 -0
  400. qanswer_sdk/models/notification_payload_add_to_org_dto.py +87 -0
  401. qanswer_sdk/models/notification_payload_add_to_team_dto.py +89 -0
  402. qanswer_sdk/models/notification_payload_ai_assistant_shared_dto.py +100 -0
  403. qanswer_sdk/models/notification_payload_conversation_shared_dto.py +96 -0
  404. qanswer_sdk/models/notification_payload_human_takeover_requested_dto.py +89 -0
  405. qanswer_sdk/models/notification_payload_quota_reaching_dto.py +91 -0
  406. qanswer_sdk/models/notification_read_dto.py +89 -0
  407. qanswer_sdk/models/notification_type.py +44 -0
  408. qanswer_sdk/models/o_auth_redirect_response.py +89 -0
  409. qanswer_sdk/models/o_auth_service_dto.py +89 -0
  410. qanswer_sdk/models/one_drive_download_by_ids.py +89 -0
  411. qanswer_sdk/models/one_drive_download_request.py +103 -0
  412. qanswer_sdk/models/one_note_download_by_ids.py +91 -0
  413. qanswer_sdk/models/one_note_download_request.py +103 -0
  414. qanswer_sdk/models/org_llm_detailed_dto.py +105 -0
  415. qanswer_sdk/models/org_llm_features_dto.py +89 -0
  416. qanswer_sdk/models/org_role.py +37 -0
  417. qanswer_sdk/models/org_user_profile_dto.py +210 -0
  418. qanswer_sdk/models/org_user_profile_list_dto.py +101 -0
  419. qanswer_sdk/models/organization_admin_dto.py +97 -0
  420. qanswer_sdk/models/organization_creation_dto.py +91 -0
  421. qanswer_sdk/models/organization_dto.py +93 -0
  422. qanswer_sdk/models/organization_list_dto.py +101 -0
  423. qanswer_sdk/models/organization_user_dto.py +101 -0
  424. qanswer_sdk/models/organization_user_list_dto.py +101 -0
  425. qanswer_sdk/models/paginated_report_templates.py +101 -0
  426. qanswer_sdk/models/password.py +89 -0
  427. qanswer_sdk/models/pinecone_index_model.py +91 -0
  428. qanswer_sdk/models/plan_dto.py +108 -0
  429. qanswer_sdk/models/predicted_class.py +89 -0
  430. qanswer_sdk/models/prepare_synonyms_upload_resp.py +99 -0
  431. qanswer_sdk/models/prepared_synonym_group.py +87 -0
  432. qanswer_sdk/models/pricing_plan.py +51 -0
  433. qanswer_sdk/models/pricing_type.py +38 -0
  434. qanswer_sdk/models/prompt_type.py +49 -0
  435. qanswer_sdk/models/provider.py +87 -0
  436. qanswer_sdk/models/publication_add_payload.py +105 -0
  437. qanswer_sdk/models/publication_file_metadata.py +105 -0
  438. qanswer_sdk/models/publication_office_additional_fields.py +111 -0
  439. qanswer_sdk/models/publication_office_connector_config.py +112 -0
  440. qanswer_sdk/models/publication_search_index_search_response.py +113 -0
  441. qanswer_sdk/models/qa_context.py +129 -0
  442. qanswer_sdk/models/qa_context_display_type.py +44 -0
  443. qanswer_sdk/models/qa_contexts.py +106 -0
  444. qanswer_sdk/models/qa_table.py +100 -0
  445. qanswer_sdk/models/qn_a_pair_model.py +103 -0
  446. qanswer_sdk/models/qn_a_pair_response.py +95 -0
  447. qanswer_sdk/models/rag_payload.py +185 -0
  448. qanswer_sdk/models/rag_response.py +147 -0
  449. qanswer_sdk/models/rdf_entity_linker_response.py +99 -0
  450. qanswer_sdk/models/rdf_linked_entity.py +97 -0
  451. qanswer_sdk/models/reasoning_effort.py +39 -0
  452. qanswer_sdk/models/reference_model.py +99 -0
  453. qanswer_sdk/models/refresh_frequency.py +39 -0
  454. qanswer_sdk/models/refresh_token_request.py +87 -0
  455. qanswer_sdk/models/refresh_website_connector_links_payload.py +96 -0
  456. qanswer_sdk/models/refresh_website_connector_payload.py +94 -0
  457. qanswer_sdk/models/register_pinecone_connector_request.py +95 -0
  458. qanswer_sdk/models/report_copilot_generation_from_slots_ack.py +91 -0
  459. qanswer_sdk/models/report_copilot_generation_from_slots_payload.py +95 -0
  460. qanswer_sdk/models/report_copilot_refinement_payload.py +106 -0
  461. qanswer_sdk/models/report_copilot_refinement_response.py +87 -0
  462. qanswer_sdk/models/report_copilot_slot_feedback_update.py +95 -0
  463. qanswer_sdk/models/report_copilot_slot_feedback_update_response.py +95 -0
  464. qanswer_sdk/models/report_copilot_slot_task_settings.py +121 -0
  465. qanswer_sdk/models/report_copilot_slot_task_settings_update.py +121 -0
  466. qanswer_sdk/models/report_copilot_task_settings.py +119 -0
  467. qanswer_sdk/models/report_copilot_task_settings_update_payload.py +95 -0
  468. qanswer_sdk/models/report_copilot_task_update.py +119 -0
  469. qanswer_sdk/models/report_template.py +155 -0
  470. qanswer_sdk/models/report_template_create_payload.py +132 -0
  471. qanswer_sdk/models/report_template_image_upload_response.py +87 -0
  472. qanswer_sdk/models/report_template_simplified.py +116 -0
  473. qanswer_sdk/models/report_template_simplified_payload.py +91 -0
  474. qanswer_sdk/models/report_template_task_settings_update_payload.py +91 -0
  475. qanswer_sdk/models/report_template_update_payload.py +136 -0
  476. qanswer_sdk/models/report_templates_search_payload.py +106 -0
  477. qanswer_sdk/models/reset_password.py +87 -0
  478. qanswer_sdk/models/response_audit_model.py +99 -0
  479. qanswer_sdk/models/response_audit_stats_response.py +101 -0
  480. qanswer_sdk/models/response_get_dummy_union_connector_config_model_api_connectors_config_dummy_models_union_get.py +228 -0
  481. qanswer_sdk/models/retention_policy_dto.py +106 -0
  482. qanswer_sdk/models/retention_policy_update.py +101 -0
  483. qanswer_sdk/models/retention_preview_response.py +92 -0
  484. qanswer_sdk/models/retention_run_progress_event.py +98 -0
  485. qanswer_sdk/models/retention_run_status_response.py +91 -0
  486. qanswer_sdk/models/retention_scope_type.py +38 -0
  487. qanswer_sdk/models/retention_sweep_result.py +89 -0
  488. qanswer_sdk/models/retention_unit.py +38 -0
  489. qanswer_sdk/models/retreive_all_synonyms_resp.py +99 -0
  490. qanswer_sdk/models/retry_params.py +89 -0
  491. qanswer_sdk/models/return_type.py +38 -0
  492. qanswer_sdk/models/role.py +90 -0
  493. qanswer_sdk/models/role_name.py +37 -0
  494. qanswer_sdk/models/scrolling_strategy.py +37 -0
  495. qanswer_sdk/models/search_conversation_messages_response.py +105 -0
  496. qanswer_sdk/models/search_document_response.py +107 -0
  497. qanswer_sdk/models/search_index_payload.py +114 -0
  498. qanswer_sdk/models/search_metadata_filter.py +94 -0
  499. qanswer_sdk/models/search_payload.py +150 -0
  500. qanswer_sdk/models/search_response.py +120 -0
  501. qanswer_sdk/models/search_synonyms_resp.py +91 -0
  502. qanswer_sdk/models/search_task_settings.py +135 -0
  503. qanswer_sdk/models/search_task_settings_update_payload.py +95 -0
  504. qanswer_sdk/models/search_task_update.py +133 -0
  505. qanswer_sdk/models/sender_type.py +38 -0
  506. qanswer_sdk/models/serve_pdf200_response.py +87 -0
  507. qanswer_sdk/models/share_point_connector_settings.py +99 -0
  508. qanswer_sdk/models/share_point_download_by_ids.py +99 -0
  509. qanswer_sdk/models/share_point_download_request.py +103 -0
  510. qanswer_sdk/models/shared_by.py +38 -0
  511. qanswer_sdk/models/shared_entity_type.py +38 -0
  512. qanswer_sdk/models/shared_organization_access_dto.py +116 -0
  513. qanswer_sdk/models/shared_team_access_dto.py +116 -0
  514. qanswer_sdk/models/shared_user.py +90 -0
  515. qanswer_sdk/models/sign_out_request.py +87 -0
  516. qanswer_sdk/models/sign_up_request.py +99 -0
  517. qanswer_sdk/models/slot.py +153 -0
  518. qanswer_sdk/models/slot_history_entry.py +119 -0
  519. qanswer_sdk/models/slot_in_prompt.py +91 -0
  520. qanswer_sdk/models/slot_info_with_latest_version.py +95 -0
  521. qanswer_sdk/models/slot_update.py +133 -0
  522. qanswer_sdk/models/socker_join_user.py +91 -0
  523. qanswer_sdk/models/socket_audio_transcription_status.py +102 -0
  524. qanswer_sdk/models/socket_conversation_message.py +245 -0
  525. qanswer_sdk/models/socket_dataset_reindexing_status.py +97 -0
  526. qanswer_sdk/models/socket_events_q_answer.py +55 -0
  527. qanswer_sdk/models/socket_feedback_evaluation_progress.py +108 -0
  528. qanswer_sdk/models/socket_file_metadata.py +194 -0
  529. qanswer_sdk/models/socket_file_status_batch.py +103 -0
  530. qanswer_sdk/models/socket_file_status_item.py +99 -0
  531. qanswer_sdk/models/socket_join_conversation.py +97 -0
  532. qanswer_sdk/models/socket_join_dataset.py +93 -0
  533. qanswer_sdk/models/socket_message_status.py +40 -0
  534. qanswer_sdk/models/socket_notification.py +109 -0
  535. qanswer_sdk/models/socket_report_continuation_response.py +100 -0
  536. qanswer_sdk/models/socket_report_copilot_generation_from_slots_response.py +116 -0
  537. qanswer_sdk/models/socket_report_copilot_generation_from_template_response.py +116 -0
  538. qanswer_sdk/models/socket_report_copilot_refinement_response.py +102 -0
  539. qanswer_sdk/models/socket_speech2_text_response.py +122 -0
  540. qanswer_sdk/models/socket_stop_conversation.py +97 -0
  541. qanswer_sdk/models/source.py +125 -0
  542. qanswer_sdk/models/source_metadata.py +109 -0
  543. qanswer_sdk/models/speech2_text_response.py +110 -0
  544. qanswer_sdk/models/stat_per_date.py +89 -0
  545. qanswer_sdk/models/status_response.py +89 -0
  546. qanswer_sdk/models/storage_active_status.py +37 -0
  547. qanswer_sdk/models/subscription_response.py +92 -0
  548. qanswer_sdk/models/subscription_status.py +39 -0
  549. qanswer_sdk/models/suggested_replies.py +87 -0
  550. qanswer_sdk/models/suggestion_list_response.py +87 -0
  551. qanswer_sdk/models/summa_server.py +101 -0
  552. qanswer_sdk/models/task_category.py +61 -0
  553. qanswer_sdk/models/task_name.py +43 -0
  554. qanswer_sdk/models/team_admin_dto.py +95 -0
  555. qanswer_sdk/models/team_creation_dto.py +89 -0
  556. qanswer_sdk/models/team_dto.py +93 -0
  557. qanswer_sdk/models/team_list_dto.py +101 -0
  558. qanswer_sdk/models/team_list_dto_teams_inner.py +149 -0
  559. qanswer_sdk/models/team_role.py +37 -0
  560. qanswer_sdk/models/team_with_count_dto.py +95 -0
  561. qanswer_sdk/models/teams_bot_auth_type.py +38 -0
  562. qanswer_sdk/models/teams_bot_registration_dto.py +107 -0
  563. qanswer_sdk/models/teams_bot_registration_upsert_dto.py +105 -0
  564. qanswer_sdk/models/template_clip_structure.py +114 -0
  565. qanswer_sdk/models/template_toggle_request.py +93 -0
  566. qanswer_sdk/models/terms_bucket.py +107 -0
  567. qanswer_sdk/models/test_imap_connection_payload.py +95 -0
  568. qanswer_sdk/models/text2_sparql_payload.py +187 -0
  569. qanswer_sdk/models/text2_sparql_task_settings.py +119 -0
  570. qanswer_sdk/models/text2_sparql_task_settings_update_payload.py +95 -0
  571. qanswer_sdk/models/text2_sparql_task_update.py +119 -0
  572. qanswer_sdk/models/text_classification_payload.py +99 -0
  573. qanswer_sdk/models/text_classification_response.py +87 -0
  574. qanswer_sdk/models/text_classification_v2_payload.py +99 -0
  575. qanswer_sdk/models/text_classification_v2_response.py +95 -0
  576. qanswer_sdk/models/thinking_block.py +91 -0
  577. qanswer_sdk/models/tool_selection.py +89 -0
  578. qanswer_sdk/models/total_stat.py +96 -0
  579. qanswer_sdk/models/ui_mappings.py +141 -0
  580. qanswer_sdk/models/update_file_es_meta_data.py +116 -0
  581. qanswer_sdk/models/update_metadata_model.py +97 -0
  582. qanswer_sdk/models/update_qn_a_pair_request.py +101 -0
  583. qanswer_sdk/models/update_qn_a_pair_response.py +89 -0
  584. qanswer_sdk/models/update_synonyms.py +95 -0
  585. qanswer_sdk/models/update_synonyms_resp.py +89 -0
  586. qanswer_sdk/models/upload_metadata.py +115 -0
  587. qanswer_sdk/models/user_credits_config_dto.py +99 -0
  588. qanswer_sdk/models/user_credits_dto.py +106 -0
  589. qanswer_sdk/models/user_dataset_api_key_dto.py +120 -0
  590. qanswer_sdk/models/user_dataset_mcp_tool_selection_dto.py +100 -0
  591. qanswer_sdk/models/user_dto.py +91 -0
  592. qanswer_sdk/models/user_identity_availability.py +87 -0
  593. qanswer_sdk/models/user_info_dto.py +95 -0
  594. qanswer_sdk/models/user_list_dto.py +101 -0
  595. qanswer_sdk/models/user_log_dto.py +102 -0
  596. qanswer_sdk/models/user_logs_list_dto.py +97 -0
  597. qanswer_sdk/models/user_mcp_tool_selection_dto.py +107 -0
  598. qanswer_sdk/models/user_oauth_token_dto.py +96 -0
  599. qanswer_sdk/models/user_profile_dto.py +199 -0
  600. qanswer_sdk/models/user_profile_list_dto.py +101 -0
  601. qanswer_sdk/models/user_team_dto.py +94 -0
  602. qanswer_sdk/models/validation_error.py +108 -0
  603. qanswer_sdk/models/validation_error_loc_inner.py +138 -0
  604. qanswer_sdk/models/warn_visibility.py +40 -0
  605. qanswer_sdk/models/websearch_connector_config.py +102 -0
  606. qanswer_sdk/models/websearch_scraping_site.py +91 -0
  607. qanswer_sdk/models/website_add_payload.py +102 -0
  608. qanswer_sdk/models/website_connector_config.py +102 -0
  609. qanswer_sdk/models/website_connector_settings.py +123 -0
  610. qanswer_sdk/models/widget_configs.py +109 -0
  611. qanswer_sdk/models/x_wiki_add_request.py +97 -0
  612. qanswer_sdk/models/x_wiki_download_by_ids.py +89 -0
  613. qanswer_sdk/py.typed +0 -0
  614. qanswer_sdk/rest.py +258 -0
  615. qanswer_sdk-0.1.0.dev0.dist-info/METADATA +252 -0
  616. qanswer_sdk-0.1.0.dev0.dist-info/RECORD +618 -0
  617. qanswer_sdk-0.1.0.dev0.dist-info/WHEEL +5 -0
  618. qanswer_sdk-0.1.0.dev0.dist-info/top_level.txt +1 -0
@@ -0,0 +1,1842 @@
1
+ # coding: utf-8
2
+
3
+ """
4
+ free-text-client
5
+
6
+ QAnswer 2.0 API
7
+
8
+ The version of the OpenAPI document: 2.0.0
9
+ Generated by OpenAPI Generator (https://openapi-generator.tech)
10
+
11
+ Do not edit the class manually.
12
+ """ # noqa: E501
13
+
14
+ import warnings
15
+ from pydantic import validate_call, Field, StrictFloat, StrictStr, StrictInt
16
+ from typing import Any, Dict, List, Optional, Tuple, Union
17
+ from typing_extensions import Annotated
18
+
19
+ from datetime import date
20
+ from pydantic import StrictBool, StrictInt, StrictStr
21
+ from typing import Any, Optional
22
+ from qanswer_sdk.models.notification_dto import NotificationDto
23
+ from qanswer_sdk.models.notification_filter import NotificationFilter
24
+ from qanswer_sdk.models.notification_list_dto import NotificationListDto
25
+ from qanswer_sdk.models.notification_read_dto import NotificationReadDto
26
+ from qanswer_sdk.models.notification_type import NotificationType
27
+
28
+ from qanswer_sdk.api_client import ApiClient, RequestSerialized
29
+ from qanswer_sdk.api_response import ApiResponse
30
+ from qanswer_sdk.rest import RESTResponseType
31
+
32
+
33
+ class NotificationsApi:
34
+ """NOTE: This class is auto generated by OpenAPI Generator
35
+ Ref: https://openapi-generator.tech
36
+
37
+ Do not edit the class manually.
38
+ """
39
+
40
+ def __init__(self, api_client=None) -> None:
41
+ if api_client is None:
42
+ api_client = ApiClient.get_default()
43
+ self.api_client = api_client
44
+
45
+
46
+ @validate_call
47
+ def delete_notification(
48
+ self,
49
+ notification_id: StrictInt,
50
+ _request_timeout: Union[
51
+ None,
52
+ Annotated[StrictFloat, Field(gt=0)],
53
+ Tuple[
54
+ Annotated[StrictFloat, Field(gt=0)],
55
+ Annotated[StrictFloat, Field(gt=0)]
56
+ ]
57
+ ] = None,
58
+ _request_auth: Optional[Dict[StrictStr, Any]] = None,
59
+ _content_type: Optional[StrictStr] = None,
60
+ _headers: Optional[Dict[StrictStr, Any]] = None,
61
+ _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
62
+ ) -> object:
63
+ """Delete a notification
64
+
65
+
66
+ :param notification_id: (required)
67
+ :type notification_id: int
68
+ :param _request_timeout: timeout setting for this request. If one
69
+ number provided, it will be total request
70
+ timeout. It can also be a pair (tuple) of
71
+ (connection, read) timeouts.
72
+ :type _request_timeout: int, tuple(int, int), optional
73
+ :param _request_auth: set to override the auth_settings for an a single
74
+ request; this effectively ignores the
75
+ authentication in the spec for a single request.
76
+ :type _request_auth: dict, optional
77
+ :param _content_type: force content-type for the request.
78
+ :type _content_type: str, Optional
79
+ :param _headers: set to override the headers for a single
80
+ request; this effectively ignores the headers
81
+ in the spec for a single request.
82
+ :type _headers: dict, optional
83
+ :param _host_index: set to override the host_index for a single
84
+ request; this effectively ignores the host_index
85
+ in the spec for a single request.
86
+ :type _host_index: int, optional
87
+ :return: Returns the result object.
88
+ """ # noqa: E501
89
+
90
+ _param = self._delete_notification_serialize(
91
+ notification_id=notification_id,
92
+ _request_auth=_request_auth,
93
+ _content_type=_content_type,
94
+ _headers=_headers,
95
+ _host_index=_host_index
96
+ )
97
+
98
+ _response_types_map: Dict[str, Optional[str]] = {
99
+ '200': "object",
100
+ '422': "HTTPValidationError",
101
+ }
102
+ response_data = self.api_client.call_api(
103
+ *_param,
104
+ _request_timeout=_request_timeout
105
+ )
106
+ response_data.read()
107
+ return self.api_client.response_deserialize(
108
+ response_data=response_data,
109
+ response_types_map=_response_types_map,
110
+ ).data
111
+
112
+
113
+ @validate_call
114
+ def delete_notification_with_http_info(
115
+ self,
116
+ notification_id: StrictInt,
117
+ _request_timeout: Union[
118
+ None,
119
+ Annotated[StrictFloat, Field(gt=0)],
120
+ Tuple[
121
+ Annotated[StrictFloat, Field(gt=0)],
122
+ Annotated[StrictFloat, Field(gt=0)]
123
+ ]
124
+ ] = None,
125
+ _request_auth: Optional[Dict[StrictStr, Any]] = None,
126
+ _content_type: Optional[StrictStr] = None,
127
+ _headers: Optional[Dict[StrictStr, Any]] = None,
128
+ _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
129
+ ) -> ApiResponse[object]:
130
+ """Delete a notification
131
+
132
+
133
+ :param notification_id: (required)
134
+ :type notification_id: int
135
+ :param _request_timeout: timeout setting for this request. If one
136
+ number provided, it will be total request
137
+ timeout. It can also be a pair (tuple) of
138
+ (connection, read) timeouts.
139
+ :type _request_timeout: int, tuple(int, int), optional
140
+ :param _request_auth: set to override the auth_settings for an a single
141
+ request; this effectively ignores the
142
+ authentication in the spec for a single request.
143
+ :type _request_auth: dict, optional
144
+ :param _content_type: force content-type for the request.
145
+ :type _content_type: str, Optional
146
+ :param _headers: set to override the headers for a single
147
+ request; this effectively ignores the headers
148
+ in the spec for a single request.
149
+ :type _headers: dict, optional
150
+ :param _host_index: set to override the host_index for a single
151
+ request; this effectively ignores the host_index
152
+ in the spec for a single request.
153
+ :type _host_index: int, optional
154
+ :return: Returns the result object.
155
+ """ # noqa: E501
156
+
157
+ _param = self._delete_notification_serialize(
158
+ notification_id=notification_id,
159
+ _request_auth=_request_auth,
160
+ _content_type=_content_type,
161
+ _headers=_headers,
162
+ _host_index=_host_index
163
+ )
164
+
165
+ _response_types_map: Dict[str, Optional[str]] = {
166
+ '200': "object",
167
+ '422': "HTTPValidationError",
168
+ }
169
+ response_data = self.api_client.call_api(
170
+ *_param,
171
+ _request_timeout=_request_timeout
172
+ )
173
+ response_data.read()
174
+ return self.api_client.response_deserialize(
175
+ response_data=response_data,
176
+ response_types_map=_response_types_map,
177
+ )
178
+
179
+
180
+ @validate_call
181
+ def delete_notification_without_preload_content(
182
+ self,
183
+ notification_id: StrictInt,
184
+ _request_timeout: Union[
185
+ None,
186
+ Annotated[StrictFloat, Field(gt=0)],
187
+ Tuple[
188
+ Annotated[StrictFloat, Field(gt=0)],
189
+ Annotated[StrictFloat, Field(gt=0)]
190
+ ]
191
+ ] = None,
192
+ _request_auth: Optional[Dict[StrictStr, Any]] = None,
193
+ _content_type: Optional[StrictStr] = None,
194
+ _headers: Optional[Dict[StrictStr, Any]] = None,
195
+ _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
196
+ ) -> RESTResponseType:
197
+ """Delete a notification
198
+
199
+
200
+ :param notification_id: (required)
201
+ :type notification_id: int
202
+ :param _request_timeout: timeout setting for this request. If one
203
+ number provided, it will be total request
204
+ timeout. It can also be a pair (tuple) of
205
+ (connection, read) timeouts.
206
+ :type _request_timeout: int, tuple(int, int), optional
207
+ :param _request_auth: set to override the auth_settings for an a single
208
+ request; this effectively ignores the
209
+ authentication in the spec for a single request.
210
+ :type _request_auth: dict, optional
211
+ :param _content_type: force content-type for the request.
212
+ :type _content_type: str, Optional
213
+ :param _headers: set to override the headers for a single
214
+ request; this effectively ignores the headers
215
+ in the spec for a single request.
216
+ :type _headers: dict, optional
217
+ :param _host_index: set to override the host_index for a single
218
+ request; this effectively ignores the host_index
219
+ in the spec for a single request.
220
+ :type _host_index: int, optional
221
+ :return: Returns the result object.
222
+ """ # noqa: E501
223
+
224
+ _param = self._delete_notification_serialize(
225
+ notification_id=notification_id,
226
+ _request_auth=_request_auth,
227
+ _content_type=_content_type,
228
+ _headers=_headers,
229
+ _host_index=_host_index
230
+ )
231
+
232
+ _response_types_map: Dict[str, Optional[str]] = {
233
+ '200': "object",
234
+ '422': "HTTPValidationError",
235
+ }
236
+ response_data = self.api_client.call_api(
237
+ *_param,
238
+ _request_timeout=_request_timeout
239
+ )
240
+ return response_data.response
241
+
242
+
243
+ def _delete_notification_serialize(
244
+ self,
245
+ notification_id,
246
+ _request_auth,
247
+ _content_type,
248
+ _headers,
249
+ _host_index,
250
+ ) -> RequestSerialized:
251
+
252
+ _host = None
253
+
254
+ _collection_formats: Dict[str, str] = {
255
+ }
256
+
257
+ _path_params: Dict[str, str] = {}
258
+ _query_params: List[Tuple[str, str]] = []
259
+ _header_params: Dict[str, Optional[str]] = _headers or {}
260
+ _form_params: List[Tuple[str, str]] = []
261
+ _files: Dict[
262
+ str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
263
+ ] = {}
264
+ _body_params: Optional[bytes] = None
265
+
266
+ # process the path parameters
267
+ if notification_id is not None:
268
+ _path_params['notificationId'] = notification_id
269
+ # process the query parameters
270
+ # process the header parameters
271
+ # process the form parameters
272
+ # process the body parameter
273
+
274
+
275
+ # set the HTTP header `Accept`
276
+ if 'Accept' not in _header_params:
277
+ _header_params['Accept'] = self.api_client.select_header_accept(
278
+ [
279
+ 'application/json'
280
+ ]
281
+ )
282
+
283
+
284
+ # authentication setting
285
+ _auth_settings: List[str] = [
286
+ 'QAnswer-Api-Key',
287
+ 'Bearer token'
288
+ ]
289
+
290
+ return self.api_client.param_serialize(
291
+ method='POST',
292
+ resource_path='/api/notifications/{notificationId}/delete',
293
+ path_params=_path_params,
294
+ query_params=_query_params,
295
+ header_params=_header_params,
296
+ body=_body_params,
297
+ post_params=_form_params,
298
+ files=_files,
299
+ auth_settings=_auth_settings,
300
+ collection_formats=_collection_formats,
301
+ _host=_host,
302
+ _request_auth=_request_auth
303
+ )
304
+
305
+
306
+
307
+
308
+ @validate_call
309
+ def download_notifications(
310
+ self,
311
+ user_id: Optional[StrictInt] = None,
312
+ sender_id: Optional[StrictInt] = None,
313
+ title: Optional[StrictStr] = None,
314
+ message: Optional[StrictStr] = None,
315
+ notification_type: Optional[NotificationType] = None,
316
+ is_read: Optional[StrictBool] = None,
317
+ from_date: Optional[date] = None,
318
+ to_date: Optional[date] = None,
319
+ page: Optional[StrictInt] = None,
320
+ page_size: Optional[StrictInt] = None,
321
+ _request_timeout: Union[
322
+ None,
323
+ Annotated[StrictFloat, Field(gt=0)],
324
+ Tuple[
325
+ Annotated[StrictFloat, Field(gt=0)],
326
+ Annotated[StrictFloat, Field(gt=0)]
327
+ ]
328
+ ] = None,
329
+ _request_auth: Optional[Dict[StrictStr, Any]] = None,
330
+ _content_type: Optional[StrictStr] = None,
331
+ _headers: Optional[Dict[StrictStr, Any]] = None,
332
+ _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
333
+ ) -> object:
334
+ """Download notifications.
335
+
336
+
337
+ :param user_id:
338
+ :type user_id: int
339
+ :param sender_id:
340
+ :type sender_id: int
341
+ :param title:
342
+ :type title: str
343
+ :param message:
344
+ :type message: str
345
+ :param notification_type:
346
+ :type notification_type: NotificationType
347
+ :param is_read:
348
+ :type is_read: bool
349
+ :param from_date:
350
+ :type from_date: date
351
+ :param to_date:
352
+ :type to_date: date
353
+ :param page:
354
+ :type page: int
355
+ :param page_size:
356
+ :type page_size: int
357
+ :param _request_timeout: timeout setting for this request. If one
358
+ number provided, it will be total request
359
+ timeout. It can also be a pair (tuple) of
360
+ (connection, read) timeouts.
361
+ :type _request_timeout: int, tuple(int, int), optional
362
+ :param _request_auth: set to override the auth_settings for an a single
363
+ request; this effectively ignores the
364
+ authentication in the spec for a single request.
365
+ :type _request_auth: dict, optional
366
+ :param _content_type: force content-type for the request.
367
+ :type _content_type: str, Optional
368
+ :param _headers: set to override the headers for a single
369
+ request; this effectively ignores the headers
370
+ in the spec for a single request.
371
+ :type _headers: dict, optional
372
+ :param _host_index: set to override the host_index for a single
373
+ request; this effectively ignores the host_index
374
+ in the spec for a single request.
375
+ :type _host_index: int, optional
376
+ :return: Returns the result object.
377
+ """ # noqa: E501
378
+
379
+ _param = self._download_notifications_serialize(
380
+ user_id=user_id,
381
+ sender_id=sender_id,
382
+ title=title,
383
+ message=message,
384
+ notification_type=notification_type,
385
+ is_read=is_read,
386
+ from_date=from_date,
387
+ to_date=to_date,
388
+ page=page,
389
+ page_size=page_size,
390
+ _request_auth=_request_auth,
391
+ _content_type=_content_type,
392
+ _headers=_headers,
393
+ _host_index=_host_index
394
+ )
395
+
396
+ _response_types_map: Dict[str, Optional[str]] = {
397
+ '200': "object",
398
+ '422': "HTTPValidationError",
399
+ }
400
+ response_data = self.api_client.call_api(
401
+ *_param,
402
+ _request_timeout=_request_timeout
403
+ )
404
+ response_data.read()
405
+ return self.api_client.response_deserialize(
406
+ response_data=response_data,
407
+ response_types_map=_response_types_map,
408
+ ).data
409
+
410
+
411
+ @validate_call
412
+ def download_notifications_with_http_info(
413
+ self,
414
+ user_id: Optional[StrictInt] = None,
415
+ sender_id: Optional[StrictInt] = None,
416
+ title: Optional[StrictStr] = None,
417
+ message: Optional[StrictStr] = None,
418
+ notification_type: Optional[NotificationType] = None,
419
+ is_read: Optional[StrictBool] = None,
420
+ from_date: Optional[date] = None,
421
+ to_date: Optional[date] = None,
422
+ page: Optional[StrictInt] = None,
423
+ page_size: Optional[StrictInt] = None,
424
+ _request_timeout: Union[
425
+ None,
426
+ Annotated[StrictFloat, Field(gt=0)],
427
+ Tuple[
428
+ Annotated[StrictFloat, Field(gt=0)],
429
+ Annotated[StrictFloat, Field(gt=0)]
430
+ ]
431
+ ] = None,
432
+ _request_auth: Optional[Dict[StrictStr, Any]] = None,
433
+ _content_type: Optional[StrictStr] = None,
434
+ _headers: Optional[Dict[StrictStr, Any]] = None,
435
+ _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
436
+ ) -> ApiResponse[object]:
437
+ """Download notifications.
438
+
439
+
440
+ :param user_id:
441
+ :type user_id: int
442
+ :param sender_id:
443
+ :type sender_id: int
444
+ :param title:
445
+ :type title: str
446
+ :param message:
447
+ :type message: str
448
+ :param notification_type:
449
+ :type notification_type: NotificationType
450
+ :param is_read:
451
+ :type is_read: bool
452
+ :param from_date:
453
+ :type from_date: date
454
+ :param to_date:
455
+ :type to_date: date
456
+ :param page:
457
+ :type page: int
458
+ :param page_size:
459
+ :type page_size: int
460
+ :param _request_timeout: timeout setting for this request. If one
461
+ number provided, it will be total request
462
+ timeout. It can also be a pair (tuple) of
463
+ (connection, read) timeouts.
464
+ :type _request_timeout: int, tuple(int, int), optional
465
+ :param _request_auth: set to override the auth_settings for an a single
466
+ request; this effectively ignores the
467
+ authentication in the spec for a single request.
468
+ :type _request_auth: dict, optional
469
+ :param _content_type: force content-type for the request.
470
+ :type _content_type: str, Optional
471
+ :param _headers: set to override the headers for a single
472
+ request; this effectively ignores the headers
473
+ in the spec for a single request.
474
+ :type _headers: dict, optional
475
+ :param _host_index: set to override the host_index for a single
476
+ request; this effectively ignores the host_index
477
+ in the spec for a single request.
478
+ :type _host_index: int, optional
479
+ :return: Returns the result object.
480
+ """ # noqa: E501
481
+
482
+ _param = self._download_notifications_serialize(
483
+ user_id=user_id,
484
+ sender_id=sender_id,
485
+ title=title,
486
+ message=message,
487
+ notification_type=notification_type,
488
+ is_read=is_read,
489
+ from_date=from_date,
490
+ to_date=to_date,
491
+ page=page,
492
+ page_size=page_size,
493
+ _request_auth=_request_auth,
494
+ _content_type=_content_type,
495
+ _headers=_headers,
496
+ _host_index=_host_index
497
+ )
498
+
499
+ _response_types_map: Dict[str, Optional[str]] = {
500
+ '200': "object",
501
+ '422': "HTTPValidationError",
502
+ }
503
+ response_data = self.api_client.call_api(
504
+ *_param,
505
+ _request_timeout=_request_timeout
506
+ )
507
+ response_data.read()
508
+ return self.api_client.response_deserialize(
509
+ response_data=response_data,
510
+ response_types_map=_response_types_map,
511
+ )
512
+
513
+
514
+ @validate_call
515
+ def download_notifications_without_preload_content(
516
+ self,
517
+ user_id: Optional[StrictInt] = None,
518
+ sender_id: Optional[StrictInt] = None,
519
+ title: Optional[StrictStr] = None,
520
+ message: Optional[StrictStr] = None,
521
+ notification_type: Optional[NotificationType] = None,
522
+ is_read: Optional[StrictBool] = None,
523
+ from_date: Optional[date] = None,
524
+ to_date: Optional[date] = None,
525
+ page: Optional[StrictInt] = None,
526
+ page_size: Optional[StrictInt] = None,
527
+ _request_timeout: Union[
528
+ None,
529
+ Annotated[StrictFloat, Field(gt=0)],
530
+ Tuple[
531
+ Annotated[StrictFloat, Field(gt=0)],
532
+ Annotated[StrictFloat, Field(gt=0)]
533
+ ]
534
+ ] = None,
535
+ _request_auth: Optional[Dict[StrictStr, Any]] = None,
536
+ _content_type: Optional[StrictStr] = None,
537
+ _headers: Optional[Dict[StrictStr, Any]] = None,
538
+ _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
539
+ ) -> RESTResponseType:
540
+ """Download notifications.
541
+
542
+
543
+ :param user_id:
544
+ :type user_id: int
545
+ :param sender_id:
546
+ :type sender_id: int
547
+ :param title:
548
+ :type title: str
549
+ :param message:
550
+ :type message: str
551
+ :param notification_type:
552
+ :type notification_type: NotificationType
553
+ :param is_read:
554
+ :type is_read: bool
555
+ :param from_date:
556
+ :type from_date: date
557
+ :param to_date:
558
+ :type to_date: date
559
+ :param page:
560
+ :type page: int
561
+ :param page_size:
562
+ :type page_size: int
563
+ :param _request_timeout: timeout setting for this request. If one
564
+ number provided, it will be total request
565
+ timeout. It can also be a pair (tuple) of
566
+ (connection, read) timeouts.
567
+ :type _request_timeout: int, tuple(int, int), optional
568
+ :param _request_auth: set to override the auth_settings for an a single
569
+ request; this effectively ignores the
570
+ authentication in the spec for a single request.
571
+ :type _request_auth: dict, optional
572
+ :param _content_type: force content-type for the request.
573
+ :type _content_type: str, Optional
574
+ :param _headers: set to override the headers for a single
575
+ request; this effectively ignores the headers
576
+ in the spec for a single request.
577
+ :type _headers: dict, optional
578
+ :param _host_index: set to override the host_index for a single
579
+ request; this effectively ignores the host_index
580
+ in the spec for a single request.
581
+ :type _host_index: int, optional
582
+ :return: Returns the result object.
583
+ """ # noqa: E501
584
+
585
+ _param = self._download_notifications_serialize(
586
+ user_id=user_id,
587
+ sender_id=sender_id,
588
+ title=title,
589
+ message=message,
590
+ notification_type=notification_type,
591
+ is_read=is_read,
592
+ from_date=from_date,
593
+ to_date=to_date,
594
+ page=page,
595
+ page_size=page_size,
596
+ _request_auth=_request_auth,
597
+ _content_type=_content_type,
598
+ _headers=_headers,
599
+ _host_index=_host_index
600
+ )
601
+
602
+ _response_types_map: Dict[str, Optional[str]] = {
603
+ '200': "object",
604
+ '422': "HTTPValidationError",
605
+ }
606
+ response_data = self.api_client.call_api(
607
+ *_param,
608
+ _request_timeout=_request_timeout
609
+ )
610
+ return response_data.response
611
+
612
+
613
+ def _download_notifications_serialize(
614
+ self,
615
+ user_id,
616
+ sender_id,
617
+ title,
618
+ message,
619
+ notification_type,
620
+ is_read,
621
+ from_date,
622
+ to_date,
623
+ page,
624
+ page_size,
625
+ _request_auth,
626
+ _content_type,
627
+ _headers,
628
+ _host_index,
629
+ ) -> RequestSerialized:
630
+
631
+ _host = None
632
+
633
+ _collection_formats: Dict[str, str] = {
634
+ }
635
+
636
+ _path_params: Dict[str, str] = {}
637
+ _query_params: List[Tuple[str, str]] = []
638
+ _header_params: Dict[str, Optional[str]] = _headers or {}
639
+ _form_params: List[Tuple[str, str]] = []
640
+ _files: Dict[
641
+ str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
642
+ ] = {}
643
+ _body_params: Optional[bytes] = None
644
+
645
+ # process the path parameters
646
+ # process the query parameters
647
+ if user_id is not None:
648
+
649
+ _query_params.append(('userId', user_id))
650
+
651
+ if sender_id is not None:
652
+
653
+ _query_params.append(('senderId', sender_id))
654
+
655
+ if title is not None:
656
+
657
+ _query_params.append(('title', title))
658
+
659
+ if message is not None:
660
+
661
+ _query_params.append(('message', message))
662
+
663
+ if notification_type is not None:
664
+
665
+ _query_params.append(('notificationType', notification_type.value))
666
+
667
+ if is_read is not None:
668
+
669
+ _query_params.append(('isRead', is_read))
670
+
671
+ if from_date is not None:
672
+ if isinstance(from_date, date):
673
+ _query_params.append(
674
+ (
675
+ 'fromDate',
676
+ from_date.strftime(
677
+ self.api_client.configuration.date_format
678
+ )
679
+ )
680
+ )
681
+ else:
682
+ _query_params.append(('fromDate', from_date))
683
+
684
+ if to_date is not None:
685
+ if isinstance(to_date, date):
686
+ _query_params.append(
687
+ (
688
+ 'toDate',
689
+ to_date.strftime(
690
+ self.api_client.configuration.date_format
691
+ )
692
+ )
693
+ )
694
+ else:
695
+ _query_params.append(('toDate', to_date))
696
+
697
+ if page is not None:
698
+
699
+ _query_params.append(('page', page))
700
+
701
+ if page_size is not None:
702
+
703
+ _query_params.append(('pageSize', page_size))
704
+
705
+ # process the header parameters
706
+ # process the form parameters
707
+ # process the body parameter
708
+
709
+
710
+ # set the HTTP header `Accept`
711
+ if 'Accept' not in _header_params:
712
+ _header_params['Accept'] = self.api_client.select_header_accept(
713
+ [
714
+ 'application/json'
715
+ ]
716
+ )
717
+
718
+
719
+ # authentication setting
720
+ _auth_settings: List[str] = [
721
+ 'QAnswer-Api-Key',
722
+ 'Bearer token'
723
+ ]
724
+
725
+ return self.api_client.param_serialize(
726
+ method='GET',
727
+ resource_path='/api/notifications/download',
728
+ path_params=_path_params,
729
+ query_params=_query_params,
730
+ header_params=_header_params,
731
+ body=_body_params,
732
+ post_params=_form_params,
733
+ files=_files,
734
+ auth_settings=_auth_settings,
735
+ collection_formats=_collection_formats,
736
+ _host=_host,
737
+ _request_auth=_request_auth
738
+ )
739
+
740
+
741
+
742
+
743
+ @validate_call
744
+ def get_notification(
745
+ self,
746
+ notification_id: StrictInt,
747
+ _request_timeout: Union[
748
+ None,
749
+ Annotated[StrictFloat, Field(gt=0)],
750
+ Tuple[
751
+ Annotated[StrictFloat, Field(gt=0)],
752
+ Annotated[StrictFloat, Field(gt=0)]
753
+ ]
754
+ ] = None,
755
+ _request_auth: Optional[Dict[StrictStr, Any]] = None,
756
+ _content_type: Optional[StrictStr] = None,
757
+ _headers: Optional[Dict[StrictStr, Any]] = None,
758
+ _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
759
+ ) -> NotificationDto:
760
+ """Get a notification by id
761
+
762
+
763
+ :param notification_id: (required)
764
+ :type notification_id: int
765
+ :param _request_timeout: timeout setting for this request. If one
766
+ number provided, it will be total request
767
+ timeout. It can also be a pair (tuple) of
768
+ (connection, read) timeouts.
769
+ :type _request_timeout: int, tuple(int, int), optional
770
+ :param _request_auth: set to override the auth_settings for an a single
771
+ request; this effectively ignores the
772
+ authentication in the spec for a single request.
773
+ :type _request_auth: dict, optional
774
+ :param _content_type: force content-type for the request.
775
+ :type _content_type: str, Optional
776
+ :param _headers: set to override the headers for a single
777
+ request; this effectively ignores the headers
778
+ in the spec for a single request.
779
+ :type _headers: dict, optional
780
+ :param _host_index: set to override the host_index for a single
781
+ request; this effectively ignores the host_index
782
+ in the spec for a single request.
783
+ :type _host_index: int, optional
784
+ :return: Returns the result object.
785
+ """ # noqa: E501
786
+
787
+ _param = self._get_notification_serialize(
788
+ notification_id=notification_id,
789
+ _request_auth=_request_auth,
790
+ _content_type=_content_type,
791
+ _headers=_headers,
792
+ _host_index=_host_index
793
+ )
794
+
795
+ _response_types_map: Dict[str, Optional[str]] = {
796
+ '200': "NotificationDto",
797
+ '422': "HTTPValidationError",
798
+ }
799
+ response_data = self.api_client.call_api(
800
+ *_param,
801
+ _request_timeout=_request_timeout
802
+ )
803
+ response_data.read()
804
+ return self.api_client.response_deserialize(
805
+ response_data=response_data,
806
+ response_types_map=_response_types_map,
807
+ ).data
808
+
809
+
810
+ @validate_call
811
+ def get_notification_with_http_info(
812
+ self,
813
+ notification_id: StrictInt,
814
+ _request_timeout: Union[
815
+ None,
816
+ Annotated[StrictFloat, Field(gt=0)],
817
+ Tuple[
818
+ Annotated[StrictFloat, Field(gt=0)],
819
+ Annotated[StrictFloat, Field(gt=0)]
820
+ ]
821
+ ] = None,
822
+ _request_auth: Optional[Dict[StrictStr, Any]] = None,
823
+ _content_type: Optional[StrictStr] = None,
824
+ _headers: Optional[Dict[StrictStr, Any]] = None,
825
+ _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
826
+ ) -> ApiResponse[NotificationDto]:
827
+ """Get a notification by id
828
+
829
+
830
+ :param notification_id: (required)
831
+ :type notification_id: int
832
+ :param _request_timeout: timeout setting for this request. If one
833
+ number provided, it will be total request
834
+ timeout. It can also be a pair (tuple) of
835
+ (connection, read) timeouts.
836
+ :type _request_timeout: int, tuple(int, int), optional
837
+ :param _request_auth: set to override the auth_settings for an a single
838
+ request; this effectively ignores the
839
+ authentication in the spec for a single request.
840
+ :type _request_auth: dict, optional
841
+ :param _content_type: force content-type for the request.
842
+ :type _content_type: str, Optional
843
+ :param _headers: set to override the headers for a single
844
+ request; this effectively ignores the headers
845
+ in the spec for a single request.
846
+ :type _headers: dict, optional
847
+ :param _host_index: set to override the host_index for a single
848
+ request; this effectively ignores the host_index
849
+ in the spec for a single request.
850
+ :type _host_index: int, optional
851
+ :return: Returns the result object.
852
+ """ # noqa: E501
853
+
854
+ _param = self._get_notification_serialize(
855
+ notification_id=notification_id,
856
+ _request_auth=_request_auth,
857
+ _content_type=_content_type,
858
+ _headers=_headers,
859
+ _host_index=_host_index
860
+ )
861
+
862
+ _response_types_map: Dict[str, Optional[str]] = {
863
+ '200': "NotificationDto",
864
+ '422': "HTTPValidationError",
865
+ }
866
+ response_data = self.api_client.call_api(
867
+ *_param,
868
+ _request_timeout=_request_timeout
869
+ )
870
+ response_data.read()
871
+ return self.api_client.response_deserialize(
872
+ response_data=response_data,
873
+ response_types_map=_response_types_map,
874
+ )
875
+
876
+
877
+ @validate_call
878
+ def get_notification_without_preload_content(
879
+ self,
880
+ notification_id: StrictInt,
881
+ _request_timeout: Union[
882
+ None,
883
+ Annotated[StrictFloat, Field(gt=0)],
884
+ Tuple[
885
+ Annotated[StrictFloat, Field(gt=0)],
886
+ Annotated[StrictFloat, Field(gt=0)]
887
+ ]
888
+ ] = None,
889
+ _request_auth: Optional[Dict[StrictStr, Any]] = None,
890
+ _content_type: Optional[StrictStr] = None,
891
+ _headers: Optional[Dict[StrictStr, Any]] = None,
892
+ _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
893
+ ) -> RESTResponseType:
894
+ """Get a notification by id
895
+
896
+
897
+ :param notification_id: (required)
898
+ :type notification_id: int
899
+ :param _request_timeout: timeout setting for this request. If one
900
+ number provided, it will be total request
901
+ timeout. It can also be a pair (tuple) of
902
+ (connection, read) timeouts.
903
+ :type _request_timeout: int, tuple(int, int), optional
904
+ :param _request_auth: set to override the auth_settings for an a single
905
+ request; this effectively ignores the
906
+ authentication in the spec for a single request.
907
+ :type _request_auth: dict, optional
908
+ :param _content_type: force content-type for the request.
909
+ :type _content_type: str, Optional
910
+ :param _headers: set to override the headers for a single
911
+ request; this effectively ignores the headers
912
+ in the spec for a single request.
913
+ :type _headers: dict, optional
914
+ :param _host_index: set to override the host_index for a single
915
+ request; this effectively ignores the host_index
916
+ in the spec for a single request.
917
+ :type _host_index: int, optional
918
+ :return: Returns the result object.
919
+ """ # noqa: E501
920
+
921
+ _param = self._get_notification_serialize(
922
+ notification_id=notification_id,
923
+ _request_auth=_request_auth,
924
+ _content_type=_content_type,
925
+ _headers=_headers,
926
+ _host_index=_host_index
927
+ )
928
+
929
+ _response_types_map: Dict[str, Optional[str]] = {
930
+ '200': "NotificationDto",
931
+ '422': "HTTPValidationError",
932
+ }
933
+ response_data = self.api_client.call_api(
934
+ *_param,
935
+ _request_timeout=_request_timeout
936
+ )
937
+ return response_data.response
938
+
939
+
940
+ def _get_notification_serialize(
941
+ self,
942
+ notification_id,
943
+ _request_auth,
944
+ _content_type,
945
+ _headers,
946
+ _host_index,
947
+ ) -> RequestSerialized:
948
+
949
+ _host = None
950
+
951
+ _collection_formats: Dict[str, str] = {
952
+ }
953
+
954
+ _path_params: Dict[str, str] = {}
955
+ _query_params: List[Tuple[str, str]] = []
956
+ _header_params: Dict[str, Optional[str]] = _headers or {}
957
+ _form_params: List[Tuple[str, str]] = []
958
+ _files: Dict[
959
+ str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
960
+ ] = {}
961
+ _body_params: Optional[bytes] = None
962
+
963
+ # process the path parameters
964
+ if notification_id is not None:
965
+ _path_params['notificationId'] = notification_id
966
+ # process the query parameters
967
+ # process the header parameters
968
+ # process the form parameters
969
+ # process the body parameter
970
+
971
+
972
+ # set the HTTP header `Accept`
973
+ if 'Accept' not in _header_params:
974
+ _header_params['Accept'] = self.api_client.select_header_accept(
975
+ [
976
+ 'application/json'
977
+ ]
978
+ )
979
+
980
+
981
+ # authentication setting
982
+ _auth_settings: List[str] = [
983
+ 'QAnswer-Api-Key',
984
+ 'Bearer token'
985
+ ]
986
+
987
+ return self.api_client.param_serialize(
988
+ method='GET',
989
+ resource_path='/api/notifications/{notificationId}',
990
+ path_params=_path_params,
991
+ query_params=_query_params,
992
+ header_params=_header_params,
993
+ body=_body_params,
994
+ post_params=_form_params,
995
+ files=_files,
996
+ auth_settings=_auth_settings,
997
+ collection_formats=_collection_formats,
998
+ _host=_host,
999
+ _request_auth=_request_auth
1000
+ )
1001
+
1002
+
1003
+
1004
+
1005
+ @validate_call
1006
+ def mark_as_read(
1007
+ self,
1008
+ notification_id: StrictInt,
1009
+ body: StrictBool,
1010
+ _request_timeout: Union[
1011
+ None,
1012
+ Annotated[StrictFloat, Field(gt=0)],
1013
+ Tuple[
1014
+ Annotated[StrictFloat, Field(gt=0)],
1015
+ Annotated[StrictFloat, Field(gt=0)]
1016
+ ]
1017
+ ] = None,
1018
+ _request_auth: Optional[Dict[StrictStr, Any]] = None,
1019
+ _content_type: Optional[StrictStr] = None,
1020
+ _headers: Optional[Dict[StrictStr, Any]] = None,
1021
+ _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
1022
+ ) -> object:
1023
+ """Mark a notification as read or unread
1024
+
1025
+
1026
+ :param notification_id: (required)
1027
+ :type notification_id: int
1028
+ :param body: (required)
1029
+ :type body: bool
1030
+ :param _request_timeout: timeout setting for this request. If one
1031
+ number provided, it will be total request
1032
+ timeout. It can also be a pair (tuple) of
1033
+ (connection, read) timeouts.
1034
+ :type _request_timeout: int, tuple(int, int), optional
1035
+ :param _request_auth: set to override the auth_settings for an a single
1036
+ request; this effectively ignores the
1037
+ authentication in the spec for a single request.
1038
+ :type _request_auth: dict, optional
1039
+ :param _content_type: force content-type for the request.
1040
+ :type _content_type: str, Optional
1041
+ :param _headers: set to override the headers for a single
1042
+ request; this effectively ignores the headers
1043
+ in the spec for a single request.
1044
+ :type _headers: dict, optional
1045
+ :param _host_index: set to override the host_index for a single
1046
+ request; this effectively ignores the host_index
1047
+ in the spec for a single request.
1048
+ :type _host_index: int, optional
1049
+ :return: Returns the result object.
1050
+ """ # noqa: E501
1051
+
1052
+ _param = self._mark_as_read_serialize(
1053
+ notification_id=notification_id,
1054
+ body=body,
1055
+ _request_auth=_request_auth,
1056
+ _content_type=_content_type,
1057
+ _headers=_headers,
1058
+ _host_index=_host_index
1059
+ )
1060
+
1061
+ _response_types_map: Dict[str, Optional[str]] = {
1062
+ '200': "object",
1063
+ '422': "HTTPValidationError",
1064
+ }
1065
+ response_data = self.api_client.call_api(
1066
+ *_param,
1067
+ _request_timeout=_request_timeout
1068
+ )
1069
+ response_data.read()
1070
+ return self.api_client.response_deserialize(
1071
+ response_data=response_data,
1072
+ response_types_map=_response_types_map,
1073
+ ).data
1074
+
1075
+
1076
+ @validate_call
1077
+ def mark_as_read_with_http_info(
1078
+ self,
1079
+ notification_id: StrictInt,
1080
+ body: StrictBool,
1081
+ _request_timeout: Union[
1082
+ None,
1083
+ Annotated[StrictFloat, Field(gt=0)],
1084
+ Tuple[
1085
+ Annotated[StrictFloat, Field(gt=0)],
1086
+ Annotated[StrictFloat, Field(gt=0)]
1087
+ ]
1088
+ ] = None,
1089
+ _request_auth: Optional[Dict[StrictStr, Any]] = None,
1090
+ _content_type: Optional[StrictStr] = None,
1091
+ _headers: Optional[Dict[StrictStr, Any]] = None,
1092
+ _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
1093
+ ) -> ApiResponse[object]:
1094
+ """Mark a notification as read or unread
1095
+
1096
+
1097
+ :param notification_id: (required)
1098
+ :type notification_id: int
1099
+ :param body: (required)
1100
+ :type body: bool
1101
+ :param _request_timeout: timeout setting for this request. If one
1102
+ number provided, it will be total request
1103
+ timeout. It can also be a pair (tuple) of
1104
+ (connection, read) timeouts.
1105
+ :type _request_timeout: int, tuple(int, int), optional
1106
+ :param _request_auth: set to override the auth_settings for an a single
1107
+ request; this effectively ignores the
1108
+ authentication in the spec for a single request.
1109
+ :type _request_auth: dict, optional
1110
+ :param _content_type: force content-type for the request.
1111
+ :type _content_type: str, Optional
1112
+ :param _headers: set to override the headers for a single
1113
+ request; this effectively ignores the headers
1114
+ in the spec for a single request.
1115
+ :type _headers: dict, optional
1116
+ :param _host_index: set to override the host_index for a single
1117
+ request; this effectively ignores the host_index
1118
+ in the spec for a single request.
1119
+ :type _host_index: int, optional
1120
+ :return: Returns the result object.
1121
+ """ # noqa: E501
1122
+
1123
+ _param = self._mark_as_read_serialize(
1124
+ notification_id=notification_id,
1125
+ body=body,
1126
+ _request_auth=_request_auth,
1127
+ _content_type=_content_type,
1128
+ _headers=_headers,
1129
+ _host_index=_host_index
1130
+ )
1131
+
1132
+ _response_types_map: Dict[str, Optional[str]] = {
1133
+ '200': "object",
1134
+ '422': "HTTPValidationError",
1135
+ }
1136
+ response_data = self.api_client.call_api(
1137
+ *_param,
1138
+ _request_timeout=_request_timeout
1139
+ )
1140
+ response_data.read()
1141
+ return self.api_client.response_deserialize(
1142
+ response_data=response_data,
1143
+ response_types_map=_response_types_map,
1144
+ )
1145
+
1146
+
1147
+ @validate_call
1148
+ def mark_as_read_without_preload_content(
1149
+ self,
1150
+ notification_id: StrictInt,
1151
+ body: StrictBool,
1152
+ _request_timeout: Union[
1153
+ None,
1154
+ Annotated[StrictFloat, Field(gt=0)],
1155
+ Tuple[
1156
+ Annotated[StrictFloat, Field(gt=0)],
1157
+ Annotated[StrictFloat, Field(gt=0)]
1158
+ ]
1159
+ ] = None,
1160
+ _request_auth: Optional[Dict[StrictStr, Any]] = None,
1161
+ _content_type: Optional[StrictStr] = None,
1162
+ _headers: Optional[Dict[StrictStr, Any]] = None,
1163
+ _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
1164
+ ) -> RESTResponseType:
1165
+ """Mark a notification as read or unread
1166
+
1167
+
1168
+ :param notification_id: (required)
1169
+ :type notification_id: int
1170
+ :param body: (required)
1171
+ :type body: bool
1172
+ :param _request_timeout: timeout setting for this request. If one
1173
+ number provided, it will be total request
1174
+ timeout. It can also be a pair (tuple) of
1175
+ (connection, read) timeouts.
1176
+ :type _request_timeout: int, tuple(int, int), optional
1177
+ :param _request_auth: set to override the auth_settings for an a single
1178
+ request; this effectively ignores the
1179
+ authentication in the spec for a single request.
1180
+ :type _request_auth: dict, optional
1181
+ :param _content_type: force content-type for the request.
1182
+ :type _content_type: str, Optional
1183
+ :param _headers: set to override the headers for a single
1184
+ request; this effectively ignores the headers
1185
+ in the spec for a single request.
1186
+ :type _headers: dict, optional
1187
+ :param _host_index: set to override the host_index for a single
1188
+ request; this effectively ignores the host_index
1189
+ in the spec for a single request.
1190
+ :type _host_index: int, optional
1191
+ :return: Returns the result object.
1192
+ """ # noqa: E501
1193
+
1194
+ _param = self._mark_as_read_serialize(
1195
+ notification_id=notification_id,
1196
+ body=body,
1197
+ _request_auth=_request_auth,
1198
+ _content_type=_content_type,
1199
+ _headers=_headers,
1200
+ _host_index=_host_index
1201
+ )
1202
+
1203
+ _response_types_map: Dict[str, Optional[str]] = {
1204
+ '200': "object",
1205
+ '422': "HTTPValidationError",
1206
+ }
1207
+ response_data = self.api_client.call_api(
1208
+ *_param,
1209
+ _request_timeout=_request_timeout
1210
+ )
1211
+ return response_data.response
1212
+
1213
+
1214
+ def _mark_as_read_serialize(
1215
+ self,
1216
+ notification_id,
1217
+ body,
1218
+ _request_auth,
1219
+ _content_type,
1220
+ _headers,
1221
+ _host_index,
1222
+ ) -> RequestSerialized:
1223
+
1224
+ _host = None
1225
+
1226
+ _collection_formats: Dict[str, str] = {
1227
+ }
1228
+
1229
+ _path_params: Dict[str, str] = {}
1230
+ _query_params: List[Tuple[str, str]] = []
1231
+ _header_params: Dict[str, Optional[str]] = _headers or {}
1232
+ _form_params: List[Tuple[str, str]] = []
1233
+ _files: Dict[
1234
+ str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
1235
+ ] = {}
1236
+ _body_params: Optional[bytes] = None
1237
+
1238
+ # process the path parameters
1239
+ if notification_id is not None:
1240
+ _path_params['notificationId'] = notification_id
1241
+ # process the query parameters
1242
+ # process the header parameters
1243
+ # process the form parameters
1244
+ # process the body parameter
1245
+ if body is not None:
1246
+ _body_params = body
1247
+
1248
+
1249
+ # set the HTTP header `Accept`
1250
+ if 'Accept' not in _header_params:
1251
+ _header_params['Accept'] = self.api_client.select_header_accept(
1252
+ [
1253
+ 'application/json'
1254
+ ]
1255
+ )
1256
+
1257
+ # set the HTTP header `Content-Type`
1258
+ if _content_type:
1259
+ _header_params['Content-Type'] = _content_type
1260
+ else:
1261
+ _default_content_type = (
1262
+ self.api_client.select_header_content_type(
1263
+ [
1264
+ 'application/json'
1265
+ ]
1266
+ )
1267
+ )
1268
+ if _default_content_type is not None:
1269
+ _header_params['Content-Type'] = _default_content_type
1270
+
1271
+ # authentication setting
1272
+ _auth_settings: List[str] = [
1273
+ 'QAnswer-Api-Key',
1274
+ 'Bearer token'
1275
+ ]
1276
+
1277
+ return self.api_client.param_serialize(
1278
+ method='PUT',
1279
+ resource_path='/api/notifications/{notificationId}/read',
1280
+ path_params=_path_params,
1281
+ query_params=_query_params,
1282
+ header_params=_header_params,
1283
+ body=_body_params,
1284
+ post_params=_form_params,
1285
+ files=_files,
1286
+ auth_settings=_auth_settings,
1287
+ collection_formats=_collection_formats,
1288
+ _host=_host,
1289
+ _request_auth=_request_auth
1290
+ )
1291
+
1292
+
1293
+
1294
+
1295
+ @validate_call
1296
+ def mark_multiple_as_read(
1297
+ self,
1298
+ notification_read_dto: NotificationReadDto,
1299
+ _request_timeout: Union[
1300
+ None,
1301
+ Annotated[StrictFloat, Field(gt=0)],
1302
+ Tuple[
1303
+ Annotated[StrictFloat, Field(gt=0)],
1304
+ Annotated[StrictFloat, Field(gt=0)]
1305
+ ]
1306
+ ] = None,
1307
+ _request_auth: Optional[Dict[StrictStr, Any]] = None,
1308
+ _content_type: Optional[StrictStr] = None,
1309
+ _headers: Optional[Dict[StrictStr, Any]] = None,
1310
+ _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
1311
+ ) -> object:
1312
+ """Mark multiple notifications as read or unread
1313
+
1314
+
1315
+ :param notification_read_dto: (required)
1316
+ :type notification_read_dto: NotificationReadDto
1317
+ :param _request_timeout: timeout setting for this request. If one
1318
+ number provided, it will be total request
1319
+ timeout. It can also be a pair (tuple) of
1320
+ (connection, read) timeouts.
1321
+ :type _request_timeout: int, tuple(int, int), optional
1322
+ :param _request_auth: set to override the auth_settings for an a single
1323
+ request; this effectively ignores the
1324
+ authentication in the spec for a single request.
1325
+ :type _request_auth: dict, optional
1326
+ :param _content_type: force content-type for the request.
1327
+ :type _content_type: str, Optional
1328
+ :param _headers: set to override the headers for a single
1329
+ request; this effectively ignores the headers
1330
+ in the spec for a single request.
1331
+ :type _headers: dict, optional
1332
+ :param _host_index: set to override the host_index for a single
1333
+ request; this effectively ignores the host_index
1334
+ in the spec for a single request.
1335
+ :type _host_index: int, optional
1336
+ :return: Returns the result object.
1337
+ """ # noqa: E501
1338
+
1339
+ _param = self._mark_multiple_as_read_serialize(
1340
+ notification_read_dto=notification_read_dto,
1341
+ _request_auth=_request_auth,
1342
+ _content_type=_content_type,
1343
+ _headers=_headers,
1344
+ _host_index=_host_index
1345
+ )
1346
+
1347
+ _response_types_map: Dict[str, Optional[str]] = {
1348
+ '200': "object",
1349
+ '422': "HTTPValidationError",
1350
+ }
1351
+ response_data = self.api_client.call_api(
1352
+ *_param,
1353
+ _request_timeout=_request_timeout
1354
+ )
1355
+ response_data.read()
1356
+ return self.api_client.response_deserialize(
1357
+ response_data=response_data,
1358
+ response_types_map=_response_types_map,
1359
+ ).data
1360
+
1361
+
1362
+ @validate_call
1363
+ def mark_multiple_as_read_with_http_info(
1364
+ self,
1365
+ notification_read_dto: NotificationReadDto,
1366
+ _request_timeout: Union[
1367
+ None,
1368
+ Annotated[StrictFloat, Field(gt=0)],
1369
+ Tuple[
1370
+ Annotated[StrictFloat, Field(gt=0)],
1371
+ Annotated[StrictFloat, Field(gt=0)]
1372
+ ]
1373
+ ] = None,
1374
+ _request_auth: Optional[Dict[StrictStr, Any]] = None,
1375
+ _content_type: Optional[StrictStr] = None,
1376
+ _headers: Optional[Dict[StrictStr, Any]] = None,
1377
+ _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
1378
+ ) -> ApiResponse[object]:
1379
+ """Mark multiple notifications as read or unread
1380
+
1381
+
1382
+ :param notification_read_dto: (required)
1383
+ :type notification_read_dto: NotificationReadDto
1384
+ :param _request_timeout: timeout setting for this request. If one
1385
+ number provided, it will be total request
1386
+ timeout. It can also be a pair (tuple) of
1387
+ (connection, read) timeouts.
1388
+ :type _request_timeout: int, tuple(int, int), optional
1389
+ :param _request_auth: set to override the auth_settings for an a single
1390
+ request; this effectively ignores the
1391
+ authentication in the spec for a single request.
1392
+ :type _request_auth: dict, optional
1393
+ :param _content_type: force content-type for the request.
1394
+ :type _content_type: str, Optional
1395
+ :param _headers: set to override the headers for a single
1396
+ request; this effectively ignores the headers
1397
+ in the spec for a single request.
1398
+ :type _headers: dict, optional
1399
+ :param _host_index: set to override the host_index for a single
1400
+ request; this effectively ignores the host_index
1401
+ in the spec for a single request.
1402
+ :type _host_index: int, optional
1403
+ :return: Returns the result object.
1404
+ """ # noqa: E501
1405
+
1406
+ _param = self._mark_multiple_as_read_serialize(
1407
+ notification_read_dto=notification_read_dto,
1408
+ _request_auth=_request_auth,
1409
+ _content_type=_content_type,
1410
+ _headers=_headers,
1411
+ _host_index=_host_index
1412
+ )
1413
+
1414
+ _response_types_map: Dict[str, Optional[str]] = {
1415
+ '200': "object",
1416
+ '422': "HTTPValidationError",
1417
+ }
1418
+ response_data = self.api_client.call_api(
1419
+ *_param,
1420
+ _request_timeout=_request_timeout
1421
+ )
1422
+ response_data.read()
1423
+ return self.api_client.response_deserialize(
1424
+ response_data=response_data,
1425
+ response_types_map=_response_types_map,
1426
+ )
1427
+
1428
+
1429
+ @validate_call
1430
+ def mark_multiple_as_read_without_preload_content(
1431
+ self,
1432
+ notification_read_dto: NotificationReadDto,
1433
+ _request_timeout: Union[
1434
+ None,
1435
+ Annotated[StrictFloat, Field(gt=0)],
1436
+ Tuple[
1437
+ Annotated[StrictFloat, Field(gt=0)],
1438
+ Annotated[StrictFloat, Field(gt=0)]
1439
+ ]
1440
+ ] = None,
1441
+ _request_auth: Optional[Dict[StrictStr, Any]] = None,
1442
+ _content_type: Optional[StrictStr] = None,
1443
+ _headers: Optional[Dict[StrictStr, Any]] = None,
1444
+ _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
1445
+ ) -> RESTResponseType:
1446
+ """Mark multiple notifications as read or unread
1447
+
1448
+
1449
+ :param notification_read_dto: (required)
1450
+ :type notification_read_dto: NotificationReadDto
1451
+ :param _request_timeout: timeout setting for this request. If one
1452
+ number provided, it will be total request
1453
+ timeout. It can also be a pair (tuple) of
1454
+ (connection, read) timeouts.
1455
+ :type _request_timeout: int, tuple(int, int), optional
1456
+ :param _request_auth: set to override the auth_settings for an a single
1457
+ request; this effectively ignores the
1458
+ authentication in the spec for a single request.
1459
+ :type _request_auth: dict, optional
1460
+ :param _content_type: force content-type for the request.
1461
+ :type _content_type: str, Optional
1462
+ :param _headers: set to override the headers for a single
1463
+ request; this effectively ignores the headers
1464
+ in the spec for a single request.
1465
+ :type _headers: dict, optional
1466
+ :param _host_index: set to override the host_index for a single
1467
+ request; this effectively ignores the host_index
1468
+ in the spec for a single request.
1469
+ :type _host_index: int, optional
1470
+ :return: Returns the result object.
1471
+ """ # noqa: E501
1472
+
1473
+ _param = self._mark_multiple_as_read_serialize(
1474
+ notification_read_dto=notification_read_dto,
1475
+ _request_auth=_request_auth,
1476
+ _content_type=_content_type,
1477
+ _headers=_headers,
1478
+ _host_index=_host_index
1479
+ )
1480
+
1481
+ _response_types_map: Dict[str, Optional[str]] = {
1482
+ '200': "object",
1483
+ '422': "HTTPValidationError",
1484
+ }
1485
+ response_data = self.api_client.call_api(
1486
+ *_param,
1487
+ _request_timeout=_request_timeout
1488
+ )
1489
+ return response_data.response
1490
+
1491
+
1492
+ def _mark_multiple_as_read_serialize(
1493
+ self,
1494
+ notification_read_dto,
1495
+ _request_auth,
1496
+ _content_type,
1497
+ _headers,
1498
+ _host_index,
1499
+ ) -> RequestSerialized:
1500
+
1501
+ _host = None
1502
+
1503
+ _collection_formats: Dict[str, str] = {
1504
+ }
1505
+
1506
+ _path_params: Dict[str, str] = {}
1507
+ _query_params: List[Tuple[str, str]] = []
1508
+ _header_params: Dict[str, Optional[str]] = _headers or {}
1509
+ _form_params: List[Tuple[str, str]] = []
1510
+ _files: Dict[
1511
+ str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
1512
+ ] = {}
1513
+ _body_params: Optional[bytes] = None
1514
+
1515
+ # process the path parameters
1516
+ # process the query parameters
1517
+ # process the header parameters
1518
+ # process the form parameters
1519
+ # process the body parameter
1520
+ if notification_read_dto is not None:
1521
+ _body_params = notification_read_dto
1522
+
1523
+
1524
+ # set the HTTP header `Accept`
1525
+ if 'Accept' not in _header_params:
1526
+ _header_params['Accept'] = self.api_client.select_header_accept(
1527
+ [
1528
+ 'application/json'
1529
+ ]
1530
+ )
1531
+
1532
+ # set the HTTP header `Content-Type`
1533
+ if _content_type:
1534
+ _header_params['Content-Type'] = _content_type
1535
+ else:
1536
+ _default_content_type = (
1537
+ self.api_client.select_header_content_type(
1538
+ [
1539
+ 'application/json'
1540
+ ]
1541
+ )
1542
+ )
1543
+ if _default_content_type is not None:
1544
+ _header_params['Content-Type'] = _default_content_type
1545
+
1546
+ # authentication setting
1547
+ _auth_settings: List[str] = [
1548
+ 'QAnswer-Api-Key',
1549
+ 'Bearer token'
1550
+ ]
1551
+
1552
+ return self.api_client.param_serialize(
1553
+ method='PUT',
1554
+ resource_path='/api/notifications/read',
1555
+ path_params=_path_params,
1556
+ query_params=_query_params,
1557
+ header_params=_header_params,
1558
+ body=_body_params,
1559
+ post_params=_form_params,
1560
+ files=_files,
1561
+ auth_settings=_auth_settings,
1562
+ collection_formats=_collection_formats,
1563
+ _host=_host,
1564
+ _request_auth=_request_auth
1565
+ )
1566
+
1567
+
1568
+
1569
+
1570
+ @validate_call
1571
+ def search_notifications(
1572
+ self,
1573
+ notification_filter: NotificationFilter,
1574
+ _request_timeout: Union[
1575
+ None,
1576
+ Annotated[StrictFloat, Field(gt=0)],
1577
+ Tuple[
1578
+ Annotated[StrictFloat, Field(gt=0)],
1579
+ Annotated[StrictFloat, Field(gt=0)]
1580
+ ]
1581
+ ] = None,
1582
+ _request_auth: Optional[Dict[StrictStr, Any]] = None,
1583
+ _content_type: Optional[StrictStr] = None,
1584
+ _headers: Optional[Dict[StrictStr, Any]] = None,
1585
+ _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
1586
+ ) -> NotificationListDto:
1587
+ """Search notifications
1588
+
1589
+
1590
+ :param notification_filter: (required)
1591
+ :type notification_filter: NotificationFilter
1592
+ :param _request_timeout: timeout setting for this request. If one
1593
+ number provided, it will be total request
1594
+ timeout. It can also be a pair (tuple) of
1595
+ (connection, read) timeouts.
1596
+ :type _request_timeout: int, tuple(int, int), optional
1597
+ :param _request_auth: set to override the auth_settings for an a single
1598
+ request; this effectively ignores the
1599
+ authentication in the spec for a single request.
1600
+ :type _request_auth: dict, optional
1601
+ :param _content_type: force content-type for the request.
1602
+ :type _content_type: str, Optional
1603
+ :param _headers: set to override the headers for a single
1604
+ request; this effectively ignores the headers
1605
+ in the spec for a single request.
1606
+ :type _headers: dict, optional
1607
+ :param _host_index: set to override the host_index for a single
1608
+ request; this effectively ignores the host_index
1609
+ in the spec for a single request.
1610
+ :type _host_index: int, optional
1611
+ :return: Returns the result object.
1612
+ """ # noqa: E501
1613
+
1614
+ _param = self._search_notifications_serialize(
1615
+ notification_filter=notification_filter,
1616
+ _request_auth=_request_auth,
1617
+ _content_type=_content_type,
1618
+ _headers=_headers,
1619
+ _host_index=_host_index
1620
+ )
1621
+
1622
+ _response_types_map: Dict[str, Optional[str]] = {
1623
+ '200': "NotificationListDto",
1624
+ '422': "HTTPValidationError",
1625
+ }
1626
+ response_data = self.api_client.call_api(
1627
+ *_param,
1628
+ _request_timeout=_request_timeout
1629
+ )
1630
+ response_data.read()
1631
+ return self.api_client.response_deserialize(
1632
+ response_data=response_data,
1633
+ response_types_map=_response_types_map,
1634
+ ).data
1635
+
1636
+
1637
+ @validate_call
1638
+ def search_notifications_with_http_info(
1639
+ self,
1640
+ notification_filter: NotificationFilter,
1641
+ _request_timeout: Union[
1642
+ None,
1643
+ Annotated[StrictFloat, Field(gt=0)],
1644
+ Tuple[
1645
+ Annotated[StrictFloat, Field(gt=0)],
1646
+ Annotated[StrictFloat, Field(gt=0)]
1647
+ ]
1648
+ ] = None,
1649
+ _request_auth: Optional[Dict[StrictStr, Any]] = None,
1650
+ _content_type: Optional[StrictStr] = None,
1651
+ _headers: Optional[Dict[StrictStr, Any]] = None,
1652
+ _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
1653
+ ) -> ApiResponse[NotificationListDto]:
1654
+ """Search notifications
1655
+
1656
+
1657
+ :param notification_filter: (required)
1658
+ :type notification_filter: NotificationFilter
1659
+ :param _request_timeout: timeout setting for this request. If one
1660
+ number provided, it will be total request
1661
+ timeout. It can also be a pair (tuple) of
1662
+ (connection, read) timeouts.
1663
+ :type _request_timeout: int, tuple(int, int), optional
1664
+ :param _request_auth: set to override the auth_settings for an a single
1665
+ request; this effectively ignores the
1666
+ authentication in the spec for a single request.
1667
+ :type _request_auth: dict, optional
1668
+ :param _content_type: force content-type for the request.
1669
+ :type _content_type: str, Optional
1670
+ :param _headers: set to override the headers for a single
1671
+ request; this effectively ignores the headers
1672
+ in the spec for a single request.
1673
+ :type _headers: dict, optional
1674
+ :param _host_index: set to override the host_index for a single
1675
+ request; this effectively ignores the host_index
1676
+ in the spec for a single request.
1677
+ :type _host_index: int, optional
1678
+ :return: Returns the result object.
1679
+ """ # noqa: E501
1680
+
1681
+ _param = self._search_notifications_serialize(
1682
+ notification_filter=notification_filter,
1683
+ _request_auth=_request_auth,
1684
+ _content_type=_content_type,
1685
+ _headers=_headers,
1686
+ _host_index=_host_index
1687
+ )
1688
+
1689
+ _response_types_map: Dict[str, Optional[str]] = {
1690
+ '200': "NotificationListDto",
1691
+ '422': "HTTPValidationError",
1692
+ }
1693
+ response_data = self.api_client.call_api(
1694
+ *_param,
1695
+ _request_timeout=_request_timeout
1696
+ )
1697
+ response_data.read()
1698
+ return self.api_client.response_deserialize(
1699
+ response_data=response_data,
1700
+ response_types_map=_response_types_map,
1701
+ )
1702
+
1703
+
1704
+ @validate_call
1705
+ def search_notifications_without_preload_content(
1706
+ self,
1707
+ notification_filter: NotificationFilter,
1708
+ _request_timeout: Union[
1709
+ None,
1710
+ Annotated[StrictFloat, Field(gt=0)],
1711
+ Tuple[
1712
+ Annotated[StrictFloat, Field(gt=0)],
1713
+ Annotated[StrictFloat, Field(gt=0)]
1714
+ ]
1715
+ ] = None,
1716
+ _request_auth: Optional[Dict[StrictStr, Any]] = None,
1717
+ _content_type: Optional[StrictStr] = None,
1718
+ _headers: Optional[Dict[StrictStr, Any]] = None,
1719
+ _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
1720
+ ) -> RESTResponseType:
1721
+ """Search notifications
1722
+
1723
+
1724
+ :param notification_filter: (required)
1725
+ :type notification_filter: NotificationFilter
1726
+ :param _request_timeout: timeout setting for this request. If one
1727
+ number provided, it will be total request
1728
+ timeout. It can also be a pair (tuple) of
1729
+ (connection, read) timeouts.
1730
+ :type _request_timeout: int, tuple(int, int), optional
1731
+ :param _request_auth: set to override the auth_settings for an a single
1732
+ request; this effectively ignores the
1733
+ authentication in the spec for a single request.
1734
+ :type _request_auth: dict, optional
1735
+ :param _content_type: force content-type for the request.
1736
+ :type _content_type: str, Optional
1737
+ :param _headers: set to override the headers for a single
1738
+ request; this effectively ignores the headers
1739
+ in the spec for a single request.
1740
+ :type _headers: dict, optional
1741
+ :param _host_index: set to override the host_index for a single
1742
+ request; this effectively ignores the host_index
1743
+ in the spec for a single request.
1744
+ :type _host_index: int, optional
1745
+ :return: Returns the result object.
1746
+ """ # noqa: E501
1747
+
1748
+ _param = self._search_notifications_serialize(
1749
+ notification_filter=notification_filter,
1750
+ _request_auth=_request_auth,
1751
+ _content_type=_content_type,
1752
+ _headers=_headers,
1753
+ _host_index=_host_index
1754
+ )
1755
+
1756
+ _response_types_map: Dict[str, Optional[str]] = {
1757
+ '200': "NotificationListDto",
1758
+ '422': "HTTPValidationError",
1759
+ }
1760
+ response_data = self.api_client.call_api(
1761
+ *_param,
1762
+ _request_timeout=_request_timeout
1763
+ )
1764
+ return response_data.response
1765
+
1766
+
1767
+ def _search_notifications_serialize(
1768
+ self,
1769
+ notification_filter,
1770
+ _request_auth,
1771
+ _content_type,
1772
+ _headers,
1773
+ _host_index,
1774
+ ) -> RequestSerialized:
1775
+
1776
+ _host = None
1777
+
1778
+ _collection_formats: Dict[str, str] = {
1779
+ }
1780
+
1781
+ _path_params: Dict[str, str] = {}
1782
+ _query_params: List[Tuple[str, str]] = []
1783
+ _header_params: Dict[str, Optional[str]] = _headers or {}
1784
+ _form_params: List[Tuple[str, str]] = []
1785
+ _files: Dict[
1786
+ str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
1787
+ ] = {}
1788
+ _body_params: Optional[bytes] = None
1789
+
1790
+ # process the path parameters
1791
+ # process the query parameters
1792
+ # process the header parameters
1793
+ # process the form parameters
1794
+ # process the body parameter
1795
+ if notification_filter is not None:
1796
+ _body_params = notification_filter
1797
+
1798
+
1799
+ # set the HTTP header `Accept`
1800
+ if 'Accept' not in _header_params:
1801
+ _header_params['Accept'] = self.api_client.select_header_accept(
1802
+ [
1803
+ 'application/json'
1804
+ ]
1805
+ )
1806
+
1807
+ # set the HTTP header `Content-Type`
1808
+ if _content_type:
1809
+ _header_params['Content-Type'] = _content_type
1810
+ else:
1811
+ _default_content_type = (
1812
+ self.api_client.select_header_content_type(
1813
+ [
1814
+ 'application/json'
1815
+ ]
1816
+ )
1817
+ )
1818
+ if _default_content_type is not None:
1819
+ _header_params['Content-Type'] = _default_content_type
1820
+
1821
+ # authentication setting
1822
+ _auth_settings: List[str] = [
1823
+ 'QAnswer-Api-Key',
1824
+ 'Bearer token'
1825
+ ]
1826
+
1827
+ return self.api_client.param_serialize(
1828
+ method='POST',
1829
+ resource_path='/api/notifications/search',
1830
+ path_params=_path_params,
1831
+ query_params=_query_params,
1832
+ header_params=_header_params,
1833
+ body=_body_params,
1834
+ post_params=_form_params,
1835
+ files=_files,
1836
+ auth_settings=_auth_settings,
1837
+ collection_formats=_collection_formats,
1838
+ _host=_host,
1839
+ _request_auth=_request_auth
1840
+ )
1841
+
1842
+