qanswer_sdk 3.1193.0__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.
- qanswer_sdk/__init__.py +366 -0
- qanswer_sdk/api/__init__.py +47 -0
- qanswer_sdk/api/admin_api.py +11207 -0
- qanswer_sdk/api/ai_assistant_access_rights_api.py +5331 -0
- qanswer_sdk/api/ai_assistant_api.py +4377 -0
- qanswer_sdk/api/bot_slack_api.py +814 -0
- qanswer_sdk/api/chat_completion_api.py +309 -0
- qanswer_sdk/api/chatbot_api.py +1091 -0
- qanswer_sdk/api/connector_document_api.py +1406 -0
- qanswer_sdk/api/connector_e_consilium_api.py +326 -0
- qanswer_sdk/api/connector_e_consilium_search_index_connector_api.py +1215 -0
- qanswer_sdk/api/connector_google_drive_api.py +1870 -0
- qanswer_sdk/api/connector_one_drive_api.py +1559 -0
- qanswer_sdk/api/connector_onenote_api.py +1576 -0
- qanswer_sdk/api/connector_pinecone_api.py +892 -0
- qanswer_sdk/api/connector_publication_office_controller_api.py +1215 -0
- qanswer_sdk/api/connector_qn_a_api.py +1538 -0
- qanswer_sdk/api/connector_rdf_answer_api.py +1445 -0
- qanswer_sdk/api/connector_rdf_api.py +5318 -0
- qanswer_sdk/api/connector_sharepoint_api.py +2584 -0
- qanswer_sdk/api/connector_websearch_api.py +326 -0
- qanswer_sdk/api/connector_website_api.py +2068 -0
- qanswer_sdk/api/connectors_api.py +1497 -0
- qanswer_sdk/api/connectors_data_api.py +3697 -0
- qanswer_sdk/api/conversation_logs_api.py +6668 -0
- qanswer_sdk/api/dataset_config_api.py +2178 -0
- qanswer_sdk/api/debug_api.py +282 -0
- qanswer_sdk/api/llm_api.py +563 -0
- qanswer_sdk/api/llm_consumption_controller_api.py +310 -0
- qanswer_sdk/api/organizations_teams_api.py +8465 -0
- qanswer_sdk/api/payment_api.py +1546 -0
- qanswer_sdk/api/socket_api.py +2975 -0
- qanswer_sdk/api/speech_to_text_api.py +734 -0
- qanswer_sdk/api/tag_api.py +2396 -0
- qanswer_sdk/api/task_chat_api.py +2064 -0
- qanswer_sdk/api/task_rdf_linker_api.py +4382 -0
- qanswer_sdk/api/task_rdf_sparql_endpoint_api.py +3522 -0
- qanswer_sdk/api/task_rdf_text_linker_api.py +1346 -0
- qanswer_sdk/api/task_relation_extraction_api.py +2977 -0
- qanswer_sdk/api/task_report_copilot_api.py +2980 -0
- qanswer_sdk/api/task_search_api.py +1784 -0
- qanswer_sdk/api/task_sparql2text_api.py +326 -0
- qanswer_sdk/api/task_text2sparql_api.py +908 -0
- qanswer_sdk/api/task_text_classification_api.py +914 -0
- qanswer_sdk/api/user_api.py +7098 -0
- qanswer_sdk/api_client.py +797 -0
- qanswer_sdk/api_response.py +21 -0
- qanswer_sdk/configuration.py +487 -0
- qanswer_sdk/exceptions.py +199 -0
- qanswer_sdk/models/__init__.py +307 -0
- qanswer_sdk/models/access_pdf_payload_model.py +109 -0
- qanswer_sdk/models/add_qn_a_request.py +103 -0
- qanswer_sdk/models/add_synonyms.py +91 -0
- qanswer_sdk/models/add_synonyms_resp.py +89 -0
- qanswer_sdk/models/aggregate.py +97 -0
- qanswer_sdk/models/aggregation.py +112 -0
- qanswer_sdk/models/aggregations_group.py +102 -0
- qanswer_sdk/models/ai_assistant_dto.py +103 -0
- qanswer_sdk/models/ai_assistant_shared_access.py +113 -0
- qanswer_sdk/models/allowed_file_extensions.py +98 -0
- qanswer_sdk/models/api_response.py +87 -0
- qanswer_sdk/models/applied_metadata_filter.py +98 -0
- qanswer_sdk/models/assistant_message_stop.py +93 -0
- qanswer_sdk/models/auth_link_response.py +91 -0
- qanswer_sdk/models/autocompletion_config.py +93 -0
- qanswer_sdk/models/available_connectors_response.py +99 -0
- qanswer_sdk/models/available_embedding_models_response.py +95 -0
- qanswer_sdk/models/available_endpoints_response.py +95 -0
- qanswer_sdk/models/available_logs_visibility_policy.py +103 -0
- qanswer_sdk/models/available_space_quota_for_dataset.py +91 -0
- qanswer_sdk/models/available_storage_preference.py +103 -0
- qanswer_sdk/models/base_connectors_response.py +89 -0
- qanswer_sdk/models/base_conversation_response.py +89 -0
- qanswer_sdk/models/base_feedback_response.py +89 -0
- qanswer_sdk/models/branding_data.py +87 -0
- qanswer_sdk/models/cell.py +89 -0
- qanswer_sdk/models/change_password.py +89 -0
- qanswer_sdk/models/change_password_admin.py +89 -0
- qanswer_sdk/models/change_role.py +96 -0
- qanswer_sdk/models/chat_task_settings.py +135 -0
- qanswer_sdk/models/chat_task_settings_update_payload.py +95 -0
- qanswer_sdk/models/chat_task_update.py +129 -0
- qanswer_sdk/models/chatbot_chat_payload.py +115 -0
- qanswer_sdk/models/chatbot_conversation_model.py +141 -0
- qanswer_sdk/models/chatbot_response.py +119 -0
- qanswer_sdk/models/check_mode_response.py +100 -0
- qanswer_sdk/models/class_info.py +89 -0
- qanswer_sdk/models/connector_model.py +112 -0
- qanswer_sdk/models/content_item.py +130 -0
- qanswer_sdk/models/conversation_message.py +186 -0
- qanswer_sdk/models/conversation_model.py +131 -0
- qanswer_sdk/models/conversation_statistics.py +95 -0
- qanswer_sdk/models/conversation_update.py +93 -0
- qanswer_sdk/models/conversation_users_stats.py +99 -0
- qanswer_sdk/models/conversation_users_stats_response.py +99 -0
- qanswer_sdk/models/coordinates.py +89 -0
- qanswer_sdk/models/cost_summary.py +99 -0
- qanswer_sdk/models/create_connector_request.py +93 -0
- qanswer_sdk/models/create_connector_response.py +95 -0
- qanswer_sdk/models/create_pinecone_connector_request.py +95 -0
- qanswer_sdk/models/create_sharepoint_connector_from_certificate_request.py +103 -0
- qanswer_sdk/models/create_sharepoint_connector_request.py +101 -0
- qanswer_sdk/models/dataset_config_request.py +187 -0
- qanswer_sdk/models/dataset_default_values_model.py +141 -0
- qanswer_sdk/models/dataset_description.py +91 -0
- qanswer_sdk/models/dataset_detail.py +133 -0
- qanswer_sdk/models/dataset_detail_kg.py +158 -0
- qanswer_sdk/models/dataset_schema.py +207 -0
- qanswer_sdk/models/dataset_update_object.py +195 -0
- qanswer_sdk/models/dataset_users_response.py +87 -0
- qanswer_sdk/models/default_prompt.py +106 -0
- qanswer_sdk/models/delete_connector_model.py +96 -0
- qanswer_sdk/models/delete_connector_request.py +99 -0
- qanswer_sdk/models/delete_connectors_response.py +91 -0
- qanswer_sdk/models/delete_qn_a_pair_request.py +95 -0
- qanswer_sdk/models/delete_qn_a_pair_response.py +89 -0
- qanswer_sdk/models/delete_synonym.py +91 -0
- qanswer_sdk/models/delete_synonym_resp.py +89 -0
- qanswer_sdk/models/diarization_segment.py +93 -0
- qanswer_sdk/models/document_content_response.py +91 -0
- qanswer_sdk/models/document_content_update_model.py +95 -0
- qanswer_sdk/models/document_file_delete_by_connector_model.py +99 -0
- qanswer_sdk/models/document_metadata.py +107 -0
- qanswer_sdk/models/document_metadata_list_wrapper.py +95 -0
- qanswer_sdk/models/document_status_response.py +89 -0
- qanswer_sdk/models/e_consilium_search_index_search_response.py +113 -0
- qanswer_sdk/models/econsilium_file_metadata.py +105 -0
- qanswer_sdk/models/econsilium_search_index_add_payload.py +105 -0
- qanswer_sdk/models/econsilium_search_index_additional_fields.py +101 -0
- qanswer_sdk/models/email_request.py +87 -0
- qanswer_sdk/models/embedding_endpoint.py +139 -0
- qanswer_sdk/models/embedding_endpoint_create.py +137 -0
- qanswer_sdk/models/embedding_endpoint_update.py +131 -0
- qanswer_sdk/models/embedding_endpoint_validation_response.py +96 -0
- qanswer_sdk/models/embedding_model.py +96 -0
- qanswer_sdk/models/entity.py +97 -0
- qanswer_sdk/models/entity_linker_response.py +99 -0
- qanswer_sdk/models/entity_model.py +99 -0
- qanswer_sdk/models/extra_body.py +91 -0
- qanswer_sdk/models/extract_hyper_links_payload.py +102 -0
- qanswer_sdk/models/extract_robot_links_payload.py +88 -0
- qanswer_sdk/models/extract_robot_links_response.py +88 -0
- qanswer_sdk/models/fact.py +96 -0
- qanswer_sdk/models/feedback_model.py +107 -0
- qanswer_sdk/models/feedback_update.py +103 -0
- qanswer_sdk/models/file_es_meta_data.py +89 -0
- qanswer_sdk/models/file_folder_model.py +113 -0
- qanswer_sdk/models/file_model.py +134 -0
- qanswer_sdk/models/files_by_connector_model.py +89 -0
- qanswer_sdk/models/format_return.py +87 -0
- qanswer_sdk/models/g_drive_connector_info.py +95 -0
- qanswer_sdk/models/g_drive_download_by_ids.py +89 -0
- qanswer_sdk/models/g_drive_download_request.py +101 -0
- qanswer_sdk/models/generation_params.py +89 -0
- qanswer_sdk/models/get_connector_by_id_response.py +91 -0
- qanswer_sdk/models/get_conversation_response.py +95 -0
- qanswer_sdk/models/guardrail_endpoint.py +121 -0
- qanswer_sdk/models/has_lucene_index_result.py +87 -0
- qanswer_sdk/models/index_config.py +95 -0
- qanswer_sdk/models/install_response.py +89 -0
- qanswer_sdk/models/is_enabled_response.py +87 -0
- qanswer_sdk/models/is_merging_result.py +87 -0
- qanswer_sdk/models/json_nullable_file_failure_reason.py +87 -0
- qanswer_sdk/models/json_nullable_source_metadata.py +87 -0
- qanswer_sdk/models/jwt_authentication_response.py +93 -0
- qanswer_sdk/models/label.py +89 -0
- qanswer_sdk/models/labeled_node.py +89 -0
- qanswer_sdk/models/link.py +103 -0
- qanswer_sdk/models/link_extraction_response.py +97 -0
- qanswer_sdk/models/link_result_paginated.py +97 -0
- qanswer_sdk/models/linker.py +103 -0
- qanswer_sdk/models/linking_result.py +95 -0
- qanswer_sdk/models/links.py +99 -0
- qanswer_sdk/models/list_chatbot_conversation_response.py +105 -0
- qanswer_sdk/models/list_connectors_response.py +95 -0
- qanswer_sdk/models/list_conversation_response.py +105 -0
- qanswer_sdk/models/list_feedback_response.py +105 -0
- qanswer_sdk/models/list_files_connector_response.py +101 -0
- qanswer_sdk/models/list_socket_events.py +95 -0
- qanswer_sdk/models/list_synonyms_model.py +89 -0
- qanswer_sdk/models/llm_context_ranges_response.py +93 -0
- qanswer_sdk/models/llm_cost.py +108 -0
- qanswer_sdk/models/llm_details.py +111 -0
- qanswer_sdk/models/llm_endpoint.py +167 -0
- qanswer_sdk/models/llm_endpoint_create.py +165 -0
- qanswer_sdk/models/llm_endpoint_default_prompts.py +93 -0
- qanswer_sdk/models/llm_endpoint_update.py +163 -0
- qanswer_sdk/models/llm_endpoint_validation_response.py +96 -0
- qanswer_sdk/models/login_request.py +89 -0
- qanswer_sdk/models/logo.py +89 -0
- qanswer_sdk/models/lucene_index_request_result.py +87 -0
- qanswer_sdk/models/merge_request_result.py +87 -0
- qanswer_sdk/models/messages_stats_per_day_response.py +99 -0
- qanswer_sdk/models/modify_connector_request.py +111 -0
- qanswer_sdk/models/o_auth_service.py +89 -0
- qanswer_sdk/models/one_drive_download_by_ids.py +89 -0
- qanswer_sdk/models/one_drive_download_request.py +101 -0
- qanswer_sdk/models/one_note_download_by_ids.py +91 -0
- qanswer_sdk/models/one_note_download_request.py +101 -0
- qanswer_sdk/models/organization.py +93 -0
- qanswer_sdk/models/organization_creation.py +91 -0
- qanswer_sdk/models/organization_filter.py +87 -0
- qanswer_sdk/models/organization_shared.py +105 -0
- qanswer_sdk/models/page_organization.py +123 -0
- qanswer_sdk/models/page_team_with_count.py +123 -0
- qanswer_sdk/models/pageable.py +92 -0
- qanswer_sdk/models/pageable_object.py +101 -0
- qanswer_sdk/models/password.py +89 -0
- qanswer_sdk/models/pinecone_index_model.py +91 -0
- qanswer_sdk/models/plan.py +123 -0
- qanswer_sdk/models/predicted_class.py +89 -0
- qanswer_sdk/models/prompt_token_count_details.py +99 -0
- qanswer_sdk/models/provider.py +87 -0
- qanswer_sdk/models/publication_add_payload.py +103 -0
- qanswer_sdk/models/publication_file_metadata.py +105 -0
- qanswer_sdk/models/publication_office_additional_fields.py +111 -0
- qanswer_sdk/models/publication_search_index_search_response.py +113 -0
- qanswer_sdk/models/qa_context.py +129 -0
- qanswer_sdk/models/qa_contexts.py +116 -0
- qanswer_sdk/models/qa_metadata_payload.py +123 -0
- qanswer_sdk/models/qa_table.py +102 -0
- qanswer_sdk/models/qn_a_pair_model.py +103 -0
- qanswer_sdk/models/qn_a_pair_response.py +95 -0
- qanswer_sdk/models/question_completion.py +89 -0
- qanswer_sdk/models/rag_params.py +89 -0
- qanswer_sdk/models/rag_payload.py +154 -0
- qanswer_sdk/models/rag_response.py +150 -0
- qanswer_sdk/models/ranker_config.py +93 -0
- qanswer_sdk/models/reference_model.py +95 -0
- qanswer_sdk/models/refresh_token_request.py +87 -0
- qanswer_sdk/models/refresh_website_connector_payload.py +94 -0
- qanswer_sdk/models/register_pinecone_connector_request.py +95 -0
- qanswer_sdk/models/relation_extraction_configuration.py +105 -0
- qanswer_sdk/models/relation_extraction_payload.py +111 -0
- qanswer_sdk/models/relation_extraction_result.py +101 -0
- qanswer_sdk/models/relation_extraction_schema.py +101 -0
- qanswer_sdk/models/relation_extraction_task_settings.py +123 -0
- qanswer_sdk/models/relation_extraction_task_settings_update_payload.py +95 -0
- qanswer_sdk/models/relation_extraction_task_update.py +117 -0
- qanswer_sdk/models/relation_extraction_template_payload.py +97 -0
- qanswer_sdk/models/relation_extraction_template_update_payload.py +95 -0
- qanswer_sdk/models/relation_model.py +89 -0
- qanswer_sdk/models/report_copilot_create_payload.py +103 -0
- qanswer_sdk/models/report_copilot_export_template_as_docx_payload_simplified.py +91 -0
- qanswer_sdk/models/report_copilot_generation_from_slots_payload.py +95 -0
- qanswer_sdk/models/report_copilot_generation_from_slots_response.py +95 -0
- qanswer_sdk/models/report_copilot_refinement_payload.py +104 -0
- qanswer_sdk/models/report_copilot_refinement_response.py +87 -0
- qanswer_sdk/models/report_copilot_slot_task_settings.py +125 -0
- qanswer_sdk/models/report_copilot_slot_task_update.py +119 -0
- qanswer_sdk/models/report_copilot_task_settings.py +123 -0
- qanswer_sdk/models/report_copilot_task_settings_update_payload.py +95 -0
- qanswer_sdk/models/report_copilot_task_update.py +117 -0
- qanswer_sdk/models/report_copilot_template.py +107 -0
- qanswer_sdk/models/report_copilot_template_simplified.py +95 -0
- qanswer_sdk/models/report_copilot_update_payload.py +101 -0
- qanswer_sdk/models/reset_password.py +87 -0
- qanswer_sdk/models/response_audit_model.py +99 -0
- qanswer_sdk/models/response_audit_stats_response.py +101 -0
- qanswer_sdk/models/retreive_all_synonyms_resp.py +99 -0
- qanswer_sdk/models/retry_params.py +89 -0
- qanswer_sdk/models/role.py +99 -0
- qanswer_sdk/models/search_document_response.py +105 -0
- qanswer_sdk/models/search_index_payload.py +114 -0
- qanswer_sdk/models/search_metadata_filter.py +89 -0
- qanswer_sdk/models/search_payload.py +124 -0
- qanswer_sdk/models/search_response.py +113 -0
- qanswer_sdk/models/search_task_settings.py +131 -0
- qanswer_sdk/models/search_task_settings_update_payload.py +95 -0
- qanswer_sdk/models/search_task_update.py +123 -0
- qanswer_sdk/models/set_logo1_request.py +87 -0
- qanswer_sdk/models/share_point_download_by_ids.py +99 -0
- qanswer_sdk/models/share_point_download_request.py +101 -0
- qanswer_sdk/models/shared_organization_access.py +109 -0
- qanswer_sdk/models/shared_team_access.py +107 -0
- qanswer_sdk/models/shared_user.py +99 -0
- qanswer_sdk/models/sign_up_request.py +96 -0
- qanswer_sdk/models/signout_request.py +87 -0
- qanswer_sdk/models/slot.py +138 -0
- qanswer_sdk/models/slot_in_prompt.py +91 -0
- qanswer_sdk/models/slot_update.py +138 -0
- qanswer_sdk/models/socket_conversation_message.py +207 -0
- qanswer_sdk/models/socket_data_extraction.py +109 -0
- qanswer_sdk/models/socket_file_metadata.py +172 -0
- qanswer_sdk/models/socket_join_conversation.py +97 -0
- qanswer_sdk/models/socket_join_dataset.py +93 -0
- qanswer_sdk/models/socket_report_continuation_response.py +106 -0
- qanswer_sdk/models/socket_report_copilot_generation_from_slots_response.py +120 -0
- qanswer_sdk/models/socket_report_copilot_refinement_response.py +108 -0
- qanswer_sdk/models/socket_speech2_text_response.py +99 -0
- qanswer_sdk/models/socket_stop_conversation.py +97 -0
- qanswer_sdk/models/sort_object.py +91 -0
- qanswer_sdk/models/source.py +125 -0
- qanswer_sdk/models/sparql2_text_payload.py +97 -0
- qanswer_sdk/models/speech2_text_response.py +87 -0
- qanswer_sdk/models/speech2_text_with_diarization_response.py +106 -0
- qanswer_sdk/models/stat_per_date.py +89 -0
- qanswer_sdk/models/status_response.py +89 -0
- qanswer_sdk/models/subject_model.py +91 -0
- qanswer_sdk/models/suggestion_list_response.py +87 -0
- qanswer_sdk/models/summa_server.py +101 -0
- qanswer_sdk/models/tag_payload.py +87 -0
- qanswer_sdk/models/tag_qa_list_payload.py +100 -0
- qanswer_sdk/models/tag_qa_payload.py +91 -0
- qanswer_sdk/models/team.py +93 -0
- qanswer_sdk/models/team_creation.py +89 -0
- qanswer_sdk/models/team_filter.py +91 -0
- qanswer_sdk/models/team_shared.py +105 -0
- qanswer_sdk/models/team_with_count.py +95 -0
- qanswer_sdk/models/terms_bucket.py +89 -0
- qanswer_sdk/models/text2_sparql_payload.py +156 -0
- qanswer_sdk/models/text2_sparql_task_settings.py +123 -0
- qanswer_sdk/models/text2_sparql_task_settings_update_payload.py +95 -0
- qanswer_sdk/models/text2_sparql_task_update.py +117 -0
- qanswer_sdk/models/text_classification_payload.py +99 -0
- qanswer_sdk/models/text_classification_response.py +87 -0
- qanswer_sdk/models/text_classification_v2_payload.py +99 -0
- qanswer_sdk/models/text_classification_v2_response.py +95 -0
- qanswer_sdk/models/total_stat.py +96 -0
- qanswer_sdk/models/ui_mappings.py +141 -0
- qanswer_sdk/models/update_metadata_model.py +95 -0
- qanswer_sdk/models/update_qn_a_pair_request.py +101 -0
- qanswer_sdk/models/update_qn_a_pair_response.py +89 -0
- qanswer_sdk/models/update_synonyms.py +93 -0
- qanswer_sdk/models/update_synonyms_resp.py +89 -0
- qanswer_sdk/models/uri_mapping.py +89 -0
- qanswer_sdk/models/user.py +91 -0
- qanswer_sdk/models/user_chatbot_setting_payload.py +106 -0
- qanswer_sdk/models/user_chatbot_setting_response.py +105 -0
- qanswer_sdk/models/user_dataset.py +144 -0
- qanswer_sdk/models/user_dataset_api_key.py +116 -0
- qanswer_sdk/models/user_filter.py +101 -0
- qanswer_sdk/models/user_identity_availability.py +87 -0
- qanswer_sdk/models/user_list_dto.py +101 -0
- qanswer_sdk/models/user_oauth_token.py +96 -0
- qanswer_sdk/models/user_profile.py +184 -0
- qanswer_sdk/models/user_profile_list_dto.py +101 -0
- qanswer_sdk/models/user_profile_paginated.py +101 -0
- qanswer_sdk/models/website_add_payload.py +98 -0
- qanswer_sdk/models/website_connector_settings.py +160 -0
- qanswer_sdk/models/widget_configs.py +105 -0
- qanswer_sdk/py.typed +0 -0
- qanswer_sdk/rest.py +257 -0
- qanswer_sdk-3.1193.0.dist-info/METADATA +125 -0
- qanswer_sdk-3.1193.0.dist-info/RECORD +346 -0
- qanswer_sdk-3.1193.0.dist-info/WHEEL +4 -0
@@ -0,0 +1,1215 @@
|
|
1
|
+
# coding: utf-8
|
2
|
+
|
3
|
+
"""
|
4
|
+
QAnswer: Api Documentation
|
5
|
+
|
6
|
+
APIs provided by QAnswer
|
7
|
+
|
8
|
+
The version of the OpenAPI document: 1.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 pydantic import StrictInt, StrictStr
|
20
|
+
from typing import List, Optional
|
21
|
+
from qanswer_sdk.models.aggregations_group import AggregationsGroup
|
22
|
+
from qanswer_sdk.models.create_connector_request import CreateConnectorRequest
|
23
|
+
from qanswer_sdk.models.create_connector_response import CreateConnectorResponse
|
24
|
+
from qanswer_sdk.models.publication_add_payload import PublicationAddPayload
|
25
|
+
from qanswer_sdk.models.publication_search_index_search_response import PublicationSearchIndexSearchResponse
|
26
|
+
from qanswer_sdk.models.search_index_payload import SearchIndexPayload
|
27
|
+
from qanswer_sdk.models.status_response import StatusResponse
|
28
|
+
|
29
|
+
from qanswer_sdk.api_client import ApiClient, RequestSerialized
|
30
|
+
from qanswer_sdk.api_response import ApiResponse
|
31
|
+
from qanswer_sdk.rest import RESTResponseType
|
32
|
+
|
33
|
+
|
34
|
+
class ConnectorPublicationOfficeControllerApi:
|
35
|
+
"""NOTE: This class is auto generated by OpenAPI Generator
|
36
|
+
Ref: https://openapi-generator.tech
|
37
|
+
|
38
|
+
Do not edit the class manually.
|
39
|
+
"""
|
40
|
+
|
41
|
+
def __init__(self, api_client=None) -> None:
|
42
|
+
if api_client is None:
|
43
|
+
api_client = ApiClient.get_default()
|
44
|
+
self.api_client = api_client
|
45
|
+
|
46
|
+
|
47
|
+
@validate_call
|
48
|
+
def add_publication_office(
|
49
|
+
self,
|
50
|
+
publication_add_payload: PublicationAddPayload,
|
51
|
+
q_answer_api_key: Optional[StrictStr] = None,
|
52
|
+
_request_timeout: Union[
|
53
|
+
None,
|
54
|
+
Annotated[StrictFloat, Field(gt=0)],
|
55
|
+
Tuple[
|
56
|
+
Annotated[StrictFloat, Field(gt=0)],
|
57
|
+
Annotated[StrictFloat, Field(gt=0)]
|
58
|
+
]
|
59
|
+
] = None,
|
60
|
+
_request_auth: Optional[Dict[StrictStr, Any]] = None,
|
61
|
+
_content_type: Optional[StrictStr] = None,
|
62
|
+
_headers: Optional[Dict[StrictStr, Any]] = None,
|
63
|
+
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
|
64
|
+
) -> StatusResponse:
|
65
|
+
"""add_publication_office
|
66
|
+
|
67
|
+
|
68
|
+
:param publication_add_payload: (required)
|
69
|
+
:type publication_add_payload: PublicationAddPayload
|
70
|
+
:param q_answer_api_key:
|
71
|
+
:type q_answer_api_key: str
|
72
|
+
:param _request_timeout: timeout setting for this request. If one
|
73
|
+
number provided, it will be total request
|
74
|
+
timeout. It can also be a pair (tuple) of
|
75
|
+
(connection, read) timeouts.
|
76
|
+
:type _request_timeout: int, tuple(int, int), optional
|
77
|
+
:param _request_auth: set to override the auth_settings for an a single
|
78
|
+
request; this effectively ignores the
|
79
|
+
authentication in the spec for a single request.
|
80
|
+
:type _request_auth: dict, optional
|
81
|
+
:param _content_type: force content-type for the request.
|
82
|
+
:type _content_type: str, Optional
|
83
|
+
:param _headers: set to override the headers for a single
|
84
|
+
request; this effectively ignores the headers
|
85
|
+
in the spec for a single request.
|
86
|
+
:type _headers: dict, optional
|
87
|
+
:param _host_index: set to override the host_index for a single
|
88
|
+
request; this effectively ignores the host_index
|
89
|
+
in the spec for a single request.
|
90
|
+
:type _host_index: int, optional
|
91
|
+
:return: Returns the result object.
|
92
|
+
""" # noqa: E501
|
93
|
+
|
94
|
+
_param = self._add_publication_office_serialize(
|
95
|
+
publication_add_payload=publication_add_payload,
|
96
|
+
q_answer_api_key=q_answer_api_key,
|
97
|
+
_request_auth=_request_auth,
|
98
|
+
_content_type=_content_type,
|
99
|
+
_headers=_headers,
|
100
|
+
_host_index=_host_index
|
101
|
+
)
|
102
|
+
|
103
|
+
_response_types_map: Dict[str, Optional[str]] = {
|
104
|
+
'200': "StatusResponse",
|
105
|
+
}
|
106
|
+
response_data = self.api_client.call_api(
|
107
|
+
*_param,
|
108
|
+
_request_timeout=_request_timeout
|
109
|
+
)
|
110
|
+
response_data.read()
|
111
|
+
return self.api_client.response_deserialize(
|
112
|
+
response_data=response_data,
|
113
|
+
response_types_map=_response_types_map,
|
114
|
+
).data
|
115
|
+
|
116
|
+
|
117
|
+
@validate_call
|
118
|
+
def add_publication_office_with_http_info(
|
119
|
+
self,
|
120
|
+
publication_add_payload: PublicationAddPayload,
|
121
|
+
q_answer_api_key: Optional[StrictStr] = None,
|
122
|
+
_request_timeout: Union[
|
123
|
+
None,
|
124
|
+
Annotated[StrictFloat, Field(gt=0)],
|
125
|
+
Tuple[
|
126
|
+
Annotated[StrictFloat, Field(gt=0)],
|
127
|
+
Annotated[StrictFloat, Field(gt=0)]
|
128
|
+
]
|
129
|
+
] = None,
|
130
|
+
_request_auth: Optional[Dict[StrictStr, Any]] = None,
|
131
|
+
_content_type: Optional[StrictStr] = None,
|
132
|
+
_headers: Optional[Dict[StrictStr, Any]] = None,
|
133
|
+
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
|
134
|
+
) -> ApiResponse[StatusResponse]:
|
135
|
+
"""add_publication_office
|
136
|
+
|
137
|
+
|
138
|
+
:param publication_add_payload: (required)
|
139
|
+
:type publication_add_payload: PublicationAddPayload
|
140
|
+
:param q_answer_api_key:
|
141
|
+
:type q_answer_api_key: str
|
142
|
+
:param _request_timeout: timeout setting for this request. If one
|
143
|
+
number provided, it will be total request
|
144
|
+
timeout. It can also be a pair (tuple) of
|
145
|
+
(connection, read) timeouts.
|
146
|
+
:type _request_timeout: int, tuple(int, int), optional
|
147
|
+
:param _request_auth: set to override the auth_settings for an a single
|
148
|
+
request; this effectively ignores the
|
149
|
+
authentication in the spec for a single request.
|
150
|
+
:type _request_auth: dict, optional
|
151
|
+
:param _content_type: force content-type for the request.
|
152
|
+
:type _content_type: str, Optional
|
153
|
+
:param _headers: set to override the headers for a single
|
154
|
+
request; this effectively ignores the headers
|
155
|
+
in the spec for a single request.
|
156
|
+
:type _headers: dict, optional
|
157
|
+
:param _host_index: set to override the host_index for a single
|
158
|
+
request; this effectively ignores the host_index
|
159
|
+
in the spec for a single request.
|
160
|
+
:type _host_index: int, optional
|
161
|
+
:return: Returns the result object.
|
162
|
+
""" # noqa: E501
|
163
|
+
|
164
|
+
_param = self._add_publication_office_serialize(
|
165
|
+
publication_add_payload=publication_add_payload,
|
166
|
+
q_answer_api_key=q_answer_api_key,
|
167
|
+
_request_auth=_request_auth,
|
168
|
+
_content_type=_content_type,
|
169
|
+
_headers=_headers,
|
170
|
+
_host_index=_host_index
|
171
|
+
)
|
172
|
+
|
173
|
+
_response_types_map: Dict[str, Optional[str]] = {
|
174
|
+
'200': "StatusResponse",
|
175
|
+
}
|
176
|
+
response_data = self.api_client.call_api(
|
177
|
+
*_param,
|
178
|
+
_request_timeout=_request_timeout
|
179
|
+
)
|
180
|
+
response_data.read()
|
181
|
+
return self.api_client.response_deserialize(
|
182
|
+
response_data=response_data,
|
183
|
+
response_types_map=_response_types_map,
|
184
|
+
)
|
185
|
+
|
186
|
+
|
187
|
+
@validate_call
|
188
|
+
def add_publication_office_without_preload_content(
|
189
|
+
self,
|
190
|
+
publication_add_payload: PublicationAddPayload,
|
191
|
+
q_answer_api_key: Optional[StrictStr] = None,
|
192
|
+
_request_timeout: Union[
|
193
|
+
None,
|
194
|
+
Annotated[StrictFloat, Field(gt=0)],
|
195
|
+
Tuple[
|
196
|
+
Annotated[StrictFloat, Field(gt=0)],
|
197
|
+
Annotated[StrictFloat, Field(gt=0)]
|
198
|
+
]
|
199
|
+
] = None,
|
200
|
+
_request_auth: Optional[Dict[StrictStr, Any]] = None,
|
201
|
+
_content_type: Optional[StrictStr] = None,
|
202
|
+
_headers: Optional[Dict[StrictStr, Any]] = None,
|
203
|
+
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
|
204
|
+
) -> RESTResponseType:
|
205
|
+
"""add_publication_office
|
206
|
+
|
207
|
+
|
208
|
+
:param publication_add_payload: (required)
|
209
|
+
:type publication_add_payload: PublicationAddPayload
|
210
|
+
:param q_answer_api_key:
|
211
|
+
:type q_answer_api_key: str
|
212
|
+
:param _request_timeout: timeout setting for this request. If one
|
213
|
+
number provided, it will be total request
|
214
|
+
timeout. It can also be a pair (tuple) of
|
215
|
+
(connection, read) timeouts.
|
216
|
+
:type _request_timeout: int, tuple(int, int), optional
|
217
|
+
:param _request_auth: set to override the auth_settings for an a single
|
218
|
+
request; this effectively ignores the
|
219
|
+
authentication in the spec for a single request.
|
220
|
+
:type _request_auth: dict, optional
|
221
|
+
:param _content_type: force content-type for the request.
|
222
|
+
:type _content_type: str, Optional
|
223
|
+
:param _headers: set to override the headers for a single
|
224
|
+
request; this effectively ignores the headers
|
225
|
+
in the spec for a single request.
|
226
|
+
:type _headers: dict, optional
|
227
|
+
:param _host_index: set to override the host_index for a single
|
228
|
+
request; this effectively ignores the host_index
|
229
|
+
in the spec for a single request.
|
230
|
+
:type _host_index: int, optional
|
231
|
+
:return: Returns the result object.
|
232
|
+
""" # noqa: E501
|
233
|
+
|
234
|
+
_param = self._add_publication_office_serialize(
|
235
|
+
publication_add_payload=publication_add_payload,
|
236
|
+
q_answer_api_key=q_answer_api_key,
|
237
|
+
_request_auth=_request_auth,
|
238
|
+
_content_type=_content_type,
|
239
|
+
_headers=_headers,
|
240
|
+
_host_index=_host_index
|
241
|
+
)
|
242
|
+
|
243
|
+
_response_types_map: Dict[str, Optional[str]] = {
|
244
|
+
'200': "StatusResponse",
|
245
|
+
}
|
246
|
+
response_data = self.api_client.call_api(
|
247
|
+
*_param,
|
248
|
+
_request_timeout=_request_timeout
|
249
|
+
)
|
250
|
+
return response_data.response
|
251
|
+
|
252
|
+
|
253
|
+
def _add_publication_office_serialize(
|
254
|
+
self,
|
255
|
+
publication_add_payload,
|
256
|
+
q_answer_api_key,
|
257
|
+
_request_auth,
|
258
|
+
_content_type,
|
259
|
+
_headers,
|
260
|
+
_host_index,
|
261
|
+
) -> RequestSerialized:
|
262
|
+
|
263
|
+
_host = None
|
264
|
+
|
265
|
+
_collection_formats: Dict[str, str] = {
|
266
|
+
}
|
267
|
+
|
268
|
+
_path_params: Dict[str, str] = {}
|
269
|
+
_query_params: List[Tuple[str, str]] = []
|
270
|
+
_header_params: Dict[str, Optional[str]] = _headers or {}
|
271
|
+
_form_params: List[Tuple[str, str]] = []
|
272
|
+
_files: Dict[
|
273
|
+
str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
|
274
|
+
] = {}
|
275
|
+
_body_params: Optional[bytes] = None
|
276
|
+
|
277
|
+
# process the path parameters
|
278
|
+
# process the query parameters
|
279
|
+
# process the header parameters
|
280
|
+
if q_answer_api_key is not None:
|
281
|
+
_header_params['QAnswer-Api-Key'] = q_answer_api_key
|
282
|
+
# process the form parameters
|
283
|
+
# process the body parameter
|
284
|
+
if publication_add_payload is not None:
|
285
|
+
_body_params = publication_add_payload
|
286
|
+
|
287
|
+
|
288
|
+
# set the HTTP header `Accept`
|
289
|
+
if 'Accept' not in _header_params:
|
290
|
+
_header_params['Accept'] = self.api_client.select_header_accept(
|
291
|
+
[
|
292
|
+
'*/*'
|
293
|
+
]
|
294
|
+
)
|
295
|
+
|
296
|
+
# set the HTTP header `Content-Type`
|
297
|
+
if _content_type:
|
298
|
+
_header_params['Content-Type'] = _content_type
|
299
|
+
else:
|
300
|
+
_default_content_type = (
|
301
|
+
self.api_client.select_header_content_type(
|
302
|
+
[
|
303
|
+
'application/json'
|
304
|
+
]
|
305
|
+
)
|
306
|
+
)
|
307
|
+
if _default_content_type is not None:
|
308
|
+
_header_params['Content-Type'] = _default_content_type
|
309
|
+
|
310
|
+
# authentication setting
|
311
|
+
_auth_settings: List[str] = [
|
312
|
+
'QAnswer-Api-Key',
|
313
|
+
'Bearer'
|
314
|
+
]
|
315
|
+
|
316
|
+
return self.api_client.param_serialize(
|
317
|
+
method='POST',
|
318
|
+
resource_path='/api/connectors/publication-office/add',
|
319
|
+
path_params=_path_params,
|
320
|
+
query_params=_query_params,
|
321
|
+
header_params=_header_params,
|
322
|
+
body=_body_params,
|
323
|
+
post_params=_form_params,
|
324
|
+
files=_files,
|
325
|
+
auth_settings=_auth_settings,
|
326
|
+
collection_formats=_collection_formats,
|
327
|
+
_host=_host,
|
328
|
+
_request_auth=_request_auth
|
329
|
+
)
|
330
|
+
|
331
|
+
|
332
|
+
|
333
|
+
|
334
|
+
@validate_call
|
335
|
+
def get_publication_office_filter_definitions(
|
336
|
+
self,
|
337
|
+
q_answer_api_key: Optional[StrictStr] = None,
|
338
|
+
username: Optional[StrictStr] = None,
|
339
|
+
dataset: Optional[StrictStr] = None,
|
340
|
+
connector_id: Optional[StrictInt] = None,
|
341
|
+
_request_timeout: Union[
|
342
|
+
None,
|
343
|
+
Annotated[StrictFloat, Field(gt=0)],
|
344
|
+
Tuple[
|
345
|
+
Annotated[StrictFloat, Field(gt=0)],
|
346
|
+
Annotated[StrictFloat, Field(gt=0)]
|
347
|
+
]
|
348
|
+
] = None,
|
349
|
+
_request_auth: Optional[Dict[StrictStr, Any]] = None,
|
350
|
+
_content_type: Optional[StrictStr] = None,
|
351
|
+
_headers: Optional[Dict[StrictStr, Any]] = None,
|
352
|
+
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
|
353
|
+
) -> List[AggregationsGroup]:
|
354
|
+
"""get_publication_office_filter_definitions
|
355
|
+
|
356
|
+
|
357
|
+
:param q_answer_api_key:
|
358
|
+
:type q_answer_api_key: str
|
359
|
+
:param username:
|
360
|
+
:type username: str
|
361
|
+
:param dataset:
|
362
|
+
:type dataset: str
|
363
|
+
:param connector_id:
|
364
|
+
:type connector_id: int
|
365
|
+
:param _request_timeout: timeout setting for this request. If one
|
366
|
+
number provided, it will be total request
|
367
|
+
timeout. It can also be a pair (tuple) of
|
368
|
+
(connection, read) timeouts.
|
369
|
+
:type _request_timeout: int, tuple(int, int), optional
|
370
|
+
:param _request_auth: set to override the auth_settings for an a single
|
371
|
+
request; this effectively ignores the
|
372
|
+
authentication in the spec for a single request.
|
373
|
+
:type _request_auth: dict, optional
|
374
|
+
:param _content_type: force content-type for the request.
|
375
|
+
:type _content_type: str, Optional
|
376
|
+
:param _headers: set to override the headers for a single
|
377
|
+
request; this effectively ignores the headers
|
378
|
+
in the spec for a single request.
|
379
|
+
:type _headers: dict, optional
|
380
|
+
:param _host_index: set to override the host_index for a single
|
381
|
+
request; this effectively ignores the host_index
|
382
|
+
in the spec for a single request.
|
383
|
+
:type _host_index: int, optional
|
384
|
+
:return: Returns the result object.
|
385
|
+
""" # noqa: E501
|
386
|
+
|
387
|
+
_param = self._get_publication_office_filter_definitions_serialize(
|
388
|
+
q_answer_api_key=q_answer_api_key,
|
389
|
+
username=username,
|
390
|
+
dataset=dataset,
|
391
|
+
connector_id=connector_id,
|
392
|
+
_request_auth=_request_auth,
|
393
|
+
_content_type=_content_type,
|
394
|
+
_headers=_headers,
|
395
|
+
_host_index=_host_index
|
396
|
+
)
|
397
|
+
|
398
|
+
_response_types_map: Dict[str, Optional[str]] = {
|
399
|
+
'200': "List[AggregationsGroup]",
|
400
|
+
}
|
401
|
+
response_data = self.api_client.call_api(
|
402
|
+
*_param,
|
403
|
+
_request_timeout=_request_timeout
|
404
|
+
)
|
405
|
+
response_data.read()
|
406
|
+
return self.api_client.response_deserialize(
|
407
|
+
response_data=response_data,
|
408
|
+
response_types_map=_response_types_map,
|
409
|
+
).data
|
410
|
+
|
411
|
+
|
412
|
+
@validate_call
|
413
|
+
def get_publication_office_filter_definitions_with_http_info(
|
414
|
+
self,
|
415
|
+
q_answer_api_key: Optional[StrictStr] = None,
|
416
|
+
username: Optional[StrictStr] = None,
|
417
|
+
dataset: Optional[StrictStr] = None,
|
418
|
+
connector_id: Optional[StrictInt] = None,
|
419
|
+
_request_timeout: Union[
|
420
|
+
None,
|
421
|
+
Annotated[StrictFloat, Field(gt=0)],
|
422
|
+
Tuple[
|
423
|
+
Annotated[StrictFloat, Field(gt=0)],
|
424
|
+
Annotated[StrictFloat, Field(gt=0)]
|
425
|
+
]
|
426
|
+
] = None,
|
427
|
+
_request_auth: Optional[Dict[StrictStr, Any]] = None,
|
428
|
+
_content_type: Optional[StrictStr] = None,
|
429
|
+
_headers: Optional[Dict[StrictStr, Any]] = None,
|
430
|
+
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
|
431
|
+
) -> ApiResponse[List[AggregationsGroup]]:
|
432
|
+
"""get_publication_office_filter_definitions
|
433
|
+
|
434
|
+
|
435
|
+
:param q_answer_api_key:
|
436
|
+
:type q_answer_api_key: str
|
437
|
+
:param username:
|
438
|
+
:type username: str
|
439
|
+
:param dataset:
|
440
|
+
:type dataset: str
|
441
|
+
:param connector_id:
|
442
|
+
:type connector_id: int
|
443
|
+
:param _request_timeout: timeout setting for this request. If one
|
444
|
+
number provided, it will be total request
|
445
|
+
timeout. It can also be a pair (tuple) of
|
446
|
+
(connection, read) timeouts.
|
447
|
+
:type _request_timeout: int, tuple(int, int), optional
|
448
|
+
:param _request_auth: set to override the auth_settings for an a single
|
449
|
+
request; this effectively ignores the
|
450
|
+
authentication in the spec for a single request.
|
451
|
+
:type _request_auth: dict, optional
|
452
|
+
:param _content_type: force content-type for the request.
|
453
|
+
:type _content_type: str, Optional
|
454
|
+
:param _headers: set to override the headers for a single
|
455
|
+
request; this effectively ignores the headers
|
456
|
+
in the spec for a single request.
|
457
|
+
:type _headers: dict, optional
|
458
|
+
:param _host_index: set to override the host_index for a single
|
459
|
+
request; this effectively ignores the host_index
|
460
|
+
in the spec for a single request.
|
461
|
+
:type _host_index: int, optional
|
462
|
+
:return: Returns the result object.
|
463
|
+
""" # noqa: E501
|
464
|
+
|
465
|
+
_param = self._get_publication_office_filter_definitions_serialize(
|
466
|
+
q_answer_api_key=q_answer_api_key,
|
467
|
+
username=username,
|
468
|
+
dataset=dataset,
|
469
|
+
connector_id=connector_id,
|
470
|
+
_request_auth=_request_auth,
|
471
|
+
_content_type=_content_type,
|
472
|
+
_headers=_headers,
|
473
|
+
_host_index=_host_index
|
474
|
+
)
|
475
|
+
|
476
|
+
_response_types_map: Dict[str, Optional[str]] = {
|
477
|
+
'200': "List[AggregationsGroup]",
|
478
|
+
}
|
479
|
+
response_data = self.api_client.call_api(
|
480
|
+
*_param,
|
481
|
+
_request_timeout=_request_timeout
|
482
|
+
)
|
483
|
+
response_data.read()
|
484
|
+
return self.api_client.response_deserialize(
|
485
|
+
response_data=response_data,
|
486
|
+
response_types_map=_response_types_map,
|
487
|
+
)
|
488
|
+
|
489
|
+
|
490
|
+
@validate_call
|
491
|
+
def get_publication_office_filter_definitions_without_preload_content(
|
492
|
+
self,
|
493
|
+
q_answer_api_key: Optional[StrictStr] = None,
|
494
|
+
username: Optional[StrictStr] = None,
|
495
|
+
dataset: Optional[StrictStr] = None,
|
496
|
+
connector_id: Optional[StrictInt] = None,
|
497
|
+
_request_timeout: Union[
|
498
|
+
None,
|
499
|
+
Annotated[StrictFloat, Field(gt=0)],
|
500
|
+
Tuple[
|
501
|
+
Annotated[StrictFloat, Field(gt=0)],
|
502
|
+
Annotated[StrictFloat, Field(gt=0)]
|
503
|
+
]
|
504
|
+
] = None,
|
505
|
+
_request_auth: Optional[Dict[StrictStr, Any]] = None,
|
506
|
+
_content_type: Optional[StrictStr] = None,
|
507
|
+
_headers: Optional[Dict[StrictStr, Any]] = None,
|
508
|
+
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
|
509
|
+
) -> RESTResponseType:
|
510
|
+
"""get_publication_office_filter_definitions
|
511
|
+
|
512
|
+
|
513
|
+
:param q_answer_api_key:
|
514
|
+
:type q_answer_api_key: str
|
515
|
+
:param username:
|
516
|
+
:type username: str
|
517
|
+
:param dataset:
|
518
|
+
:type dataset: str
|
519
|
+
:param connector_id:
|
520
|
+
:type connector_id: int
|
521
|
+
:param _request_timeout: timeout setting for this request. If one
|
522
|
+
number provided, it will be total request
|
523
|
+
timeout. It can also be a pair (tuple) of
|
524
|
+
(connection, read) timeouts.
|
525
|
+
:type _request_timeout: int, tuple(int, int), optional
|
526
|
+
:param _request_auth: set to override the auth_settings for an a single
|
527
|
+
request; this effectively ignores the
|
528
|
+
authentication in the spec for a single request.
|
529
|
+
:type _request_auth: dict, optional
|
530
|
+
:param _content_type: force content-type for the request.
|
531
|
+
:type _content_type: str, Optional
|
532
|
+
:param _headers: set to override the headers for a single
|
533
|
+
request; this effectively ignores the headers
|
534
|
+
in the spec for a single request.
|
535
|
+
:type _headers: dict, optional
|
536
|
+
:param _host_index: set to override the host_index for a single
|
537
|
+
request; this effectively ignores the host_index
|
538
|
+
in the spec for a single request.
|
539
|
+
:type _host_index: int, optional
|
540
|
+
:return: Returns the result object.
|
541
|
+
""" # noqa: E501
|
542
|
+
|
543
|
+
_param = self._get_publication_office_filter_definitions_serialize(
|
544
|
+
q_answer_api_key=q_answer_api_key,
|
545
|
+
username=username,
|
546
|
+
dataset=dataset,
|
547
|
+
connector_id=connector_id,
|
548
|
+
_request_auth=_request_auth,
|
549
|
+
_content_type=_content_type,
|
550
|
+
_headers=_headers,
|
551
|
+
_host_index=_host_index
|
552
|
+
)
|
553
|
+
|
554
|
+
_response_types_map: Dict[str, Optional[str]] = {
|
555
|
+
'200': "List[AggregationsGroup]",
|
556
|
+
}
|
557
|
+
response_data = self.api_client.call_api(
|
558
|
+
*_param,
|
559
|
+
_request_timeout=_request_timeout
|
560
|
+
)
|
561
|
+
return response_data.response
|
562
|
+
|
563
|
+
|
564
|
+
def _get_publication_office_filter_definitions_serialize(
|
565
|
+
self,
|
566
|
+
q_answer_api_key,
|
567
|
+
username,
|
568
|
+
dataset,
|
569
|
+
connector_id,
|
570
|
+
_request_auth,
|
571
|
+
_content_type,
|
572
|
+
_headers,
|
573
|
+
_host_index,
|
574
|
+
) -> RequestSerialized:
|
575
|
+
|
576
|
+
_host = None
|
577
|
+
|
578
|
+
_collection_formats: Dict[str, str] = {
|
579
|
+
}
|
580
|
+
|
581
|
+
_path_params: Dict[str, str] = {}
|
582
|
+
_query_params: List[Tuple[str, str]] = []
|
583
|
+
_header_params: Dict[str, Optional[str]] = _headers or {}
|
584
|
+
_form_params: List[Tuple[str, str]] = []
|
585
|
+
_files: Dict[
|
586
|
+
str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
|
587
|
+
] = {}
|
588
|
+
_body_params: Optional[bytes] = None
|
589
|
+
|
590
|
+
# process the path parameters
|
591
|
+
# process the query parameters
|
592
|
+
if username is not None:
|
593
|
+
|
594
|
+
_query_params.append(('username', username))
|
595
|
+
|
596
|
+
if dataset is not None:
|
597
|
+
|
598
|
+
_query_params.append(('dataset', dataset))
|
599
|
+
|
600
|
+
if connector_id is not None:
|
601
|
+
|
602
|
+
_query_params.append(('connectorId', connector_id))
|
603
|
+
|
604
|
+
# process the header parameters
|
605
|
+
if q_answer_api_key is not None:
|
606
|
+
_header_params['QAnswer-Api-Key'] = q_answer_api_key
|
607
|
+
# process the form parameters
|
608
|
+
# process the body parameter
|
609
|
+
|
610
|
+
|
611
|
+
# set the HTTP header `Accept`
|
612
|
+
if 'Accept' not in _header_params:
|
613
|
+
_header_params['Accept'] = self.api_client.select_header_accept(
|
614
|
+
[
|
615
|
+
'*/*'
|
616
|
+
]
|
617
|
+
)
|
618
|
+
|
619
|
+
|
620
|
+
# authentication setting
|
621
|
+
_auth_settings: List[str] = [
|
622
|
+
'QAnswer-Api-Key',
|
623
|
+
'Bearer'
|
624
|
+
]
|
625
|
+
|
626
|
+
return self.api_client.param_serialize(
|
627
|
+
method='GET',
|
628
|
+
resource_path='/api/connectors/publication-office/filter-definitions',
|
629
|
+
path_params=_path_params,
|
630
|
+
query_params=_query_params,
|
631
|
+
header_params=_header_params,
|
632
|
+
body=_body_params,
|
633
|
+
post_params=_form_params,
|
634
|
+
files=_files,
|
635
|
+
auth_settings=_auth_settings,
|
636
|
+
collection_formats=_collection_formats,
|
637
|
+
_host=_host,
|
638
|
+
_request_auth=_request_auth
|
639
|
+
)
|
640
|
+
|
641
|
+
|
642
|
+
|
643
|
+
|
644
|
+
@validate_call
|
645
|
+
def publication_office_connector_create(
|
646
|
+
self,
|
647
|
+
create_connector_request: CreateConnectorRequest,
|
648
|
+
q_answer_api_key: Optional[StrictStr] = None,
|
649
|
+
_request_timeout: Union[
|
650
|
+
None,
|
651
|
+
Annotated[StrictFloat, Field(gt=0)],
|
652
|
+
Tuple[
|
653
|
+
Annotated[StrictFloat, Field(gt=0)],
|
654
|
+
Annotated[StrictFloat, Field(gt=0)]
|
655
|
+
]
|
656
|
+
] = None,
|
657
|
+
_request_auth: Optional[Dict[StrictStr, Any]] = None,
|
658
|
+
_content_type: Optional[StrictStr] = None,
|
659
|
+
_headers: Optional[Dict[StrictStr, Any]] = None,
|
660
|
+
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
|
661
|
+
) -> CreateConnectorResponse:
|
662
|
+
"""publication_office_connector_create
|
663
|
+
|
664
|
+
|
665
|
+
:param create_connector_request: (required)
|
666
|
+
:type create_connector_request: CreateConnectorRequest
|
667
|
+
:param q_answer_api_key:
|
668
|
+
:type q_answer_api_key: str
|
669
|
+
:param _request_timeout: timeout setting for this request. If one
|
670
|
+
number provided, it will be total request
|
671
|
+
timeout. It can also be a pair (tuple) of
|
672
|
+
(connection, read) timeouts.
|
673
|
+
:type _request_timeout: int, tuple(int, int), optional
|
674
|
+
:param _request_auth: set to override the auth_settings for an a single
|
675
|
+
request; this effectively ignores the
|
676
|
+
authentication in the spec for a single request.
|
677
|
+
:type _request_auth: dict, optional
|
678
|
+
:param _content_type: force content-type for the request.
|
679
|
+
:type _content_type: str, Optional
|
680
|
+
:param _headers: set to override the headers for a single
|
681
|
+
request; this effectively ignores the headers
|
682
|
+
in the spec for a single request.
|
683
|
+
:type _headers: dict, optional
|
684
|
+
:param _host_index: set to override the host_index for a single
|
685
|
+
request; this effectively ignores the host_index
|
686
|
+
in the spec for a single request.
|
687
|
+
:type _host_index: int, optional
|
688
|
+
:return: Returns the result object.
|
689
|
+
""" # noqa: E501
|
690
|
+
|
691
|
+
_param = self._publication_office_connector_create_serialize(
|
692
|
+
create_connector_request=create_connector_request,
|
693
|
+
q_answer_api_key=q_answer_api_key,
|
694
|
+
_request_auth=_request_auth,
|
695
|
+
_content_type=_content_type,
|
696
|
+
_headers=_headers,
|
697
|
+
_host_index=_host_index
|
698
|
+
)
|
699
|
+
|
700
|
+
_response_types_map: Dict[str, Optional[str]] = {
|
701
|
+
'200': "CreateConnectorResponse",
|
702
|
+
}
|
703
|
+
response_data = self.api_client.call_api(
|
704
|
+
*_param,
|
705
|
+
_request_timeout=_request_timeout
|
706
|
+
)
|
707
|
+
response_data.read()
|
708
|
+
return self.api_client.response_deserialize(
|
709
|
+
response_data=response_data,
|
710
|
+
response_types_map=_response_types_map,
|
711
|
+
).data
|
712
|
+
|
713
|
+
|
714
|
+
@validate_call
|
715
|
+
def publication_office_connector_create_with_http_info(
|
716
|
+
self,
|
717
|
+
create_connector_request: CreateConnectorRequest,
|
718
|
+
q_answer_api_key: Optional[StrictStr] = None,
|
719
|
+
_request_timeout: Union[
|
720
|
+
None,
|
721
|
+
Annotated[StrictFloat, Field(gt=0)],
|
722
|
+
Tuple[
|
723
|
+
Annotated[StrictFloat, Field(gt=0)],
|
724
|
+
Annotated[StrictFloat, Field(gt=0)]
|
725
|
+
]
|
726
|
+
] = None,
|
727
|
+
_request_auth: Optional[Dict[StrictStr, Any]] = None,
|
728
|
+
_content_type: Optional[StrictStr] = None,
|
729
|
+
_headers: Optional[Dict[StrictStr, Any]] = None,
|
730
|
+
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
|
731
|
+
) -> ApiResponse[CreateConnectorResponse]:
|
732
|
+
"""publication_office_connector_create
|
733
|
+
|
734
|
+
|
735
|
+
:param create_connector_request: (required)
|
736
|
+
:type create_connector_request: CreateConnectorRequest
|
737
|
+
:param q_answer_api_key:
|
738
|
+
:type q_answer_api_key: str
|
739
|
+
:param _request_timeout: timeout setting for this request. If one
|
740
|
+
number provided, it will be total request
|
741
|
+
timeout. It can also be a pair (tuple) of
|
742
|
+
(connection, read) timeouts.
|
743
|
+
:type _request_timeout: int, tuple(int, int), optional
|
744
|
+
:param _request_auth: set to override the auth_settings for an a single
|
745
|
+
request; this effectively ignores the
|
746
|
+
authentication in the spec for a single request.
|
747
|
+
:type _request_auth: dict, optional
|
748
|
+
:param _content_type: force content-type for the request.
|
749
|
+
:type _content_type: str, Optional
|
750
|
+
:param _headers: set to override the headers for a single
|
751
|
+
request; this effectively ignores the headers
|
752
|
+
in the spec for a single request.
|
753
|
+
:type _headers: dict, optional
|
754
|
+
:param _host_index: set to override the host_index for a single
|
755
|
+
request; this effectively ignores the host_index
|
756
|
+
in the spec for a single request.
|
757
|
+
:type _host_index: int, optional
|
758
|
+
:return: Returns the result object.
|
759
|
+
""" # noqa: E501
|
760
|
+
|
761
|
+
_param = self._publication_office_connector_create_serialize(
|
762
|
+
create_connector_request=create_connector_request,
|
763
|
+
q_answer_api_key=q_answer_api_key,
|
764
|
+
_request_auth=_request_auth,
|
765
|
+
_content_type=_content_type,
|
766
|
+
_headers=_headers,
|
767
|
+
_host_index=_host_index
|
768
|
+
)
|
769
|
+
|
770
|
+
_response_types_map: Dict[str, Optional[str]] = {
|
771
|
+
'200': "CreateConnectorResponse",
|
772
|
+
}
|
773
|
+
response_data = self.api_client.call_api(
|
774
|
+
*_param,
|
775
|
+
_request_timeout=_request_timeout
|
776
|
+
)
|
777
|
+
response_data.read()
|
778
|
+
return self.api_client.response_deserialize(
|
779
|
+
response_data=response_data,
|
780
|
+
response_types_map=_response_types_map,
|
781
|
+
)
|
782
|
+
|
783
|
+
|
784
|
+
@validate_call
|
785
|
+
def publication_office_connector_create_without_preload_content(
|
786
|
+
self,
|
787
|
+
create_connector_request: CreateConnectorRequest,
|
788
|
+
q_answer_api_key: Optional[StrictStr] = None,
|
789
|
+
_request_timeout: Union[
|
790
|
+
None,
|
791
|
+
Annotated[StrictFloat, Field(gt=0)],
|
792
|
+
Tuple[
|
793
|
+
Annotated[StrictFloat, Field(gt=0)],
|
794
|
+
Annotated[StrictFloat, Field(gt=0)]
|
795
|
+
]
|
796
|
+
] = None,
|
797
|
+
_request_auth: Optional[Dict[StrictStr, Any]] = None,
|
798
|
+
_content_type: Optional[StrictStr] = None,
|
799
|
+
_headers: Optional[Dict[StrictStr, Any]] = None,
|
800
|
+
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
|
801
|
+
) -> RESTResponseType:
|
802
|
+
"""publication_office_connector_create
|
803
|
+
|
804
|
+
|
805
|
+
:param create_connector_request: (required)
|
806
|
+
:type create_connector_request: CreateConnectorRequest
|
807
|
+
:param q_answer_api_key:
|
808
|
+
:type q_answer_api_key: str
|
809
|
+
:param _request_timeout: timeout setting for this request. If one
|
810
|
+
number provided, it will be total request
|
811
|
+
timeout. It can also be a pair (tuple) of
|
812
|
+
(connection, read) timeouts.
|
813
|
+
:type _request_timeout: int, tuple(int, int), optional
|
814
|
+
:param _request_auth: set to override the auth_settings for an a single
|
815
|
+
request; this effectively ignores the
|
816
|
+
authentication in the spec for a single request.
|
817
|
+
:type _request_auth: dict, optional
|
818
|
+
:param _content_type: force content-type for the request.
|
819
|
+
:type _content_type: str, Optional
|
820
|
+
:param _headers: set to override the headers for a single
|
821
|
+
request; this effectively ignores the headers
|
822
|
+
in the spec for a single request.
|
823
|
+
:type _headers: dict, optional
|
824
|
+
:param _host_index: set to override the host_index for a single
|
825
|
+
request; this effectively ignores the host_index
|
826
|
+
in the spec for a single request.
|
827
|
+
:type _host_index: int, optional
|
828
|
+
:return: Returns the result object.
|
829
|
+
""" # noqa: E501
|
830
|
+
|
831
|
+
_param = self._publication_office_connector_create_serialize(
|
832
|
+
create_connector_request=create_connector_request,
|
833
|
+
q_answer_api_key=q_answer_api_key,
|
834
|
+
_request_auth=_request_auth,
|
835
|
+
_content_type=_content_type,
|
836
|
+
_headers=_headers,
|
837
|
+
_host_index=_host_index
|
838
|
+
)
|
839
|
+
|
840
|
+
_response_types_map: Dict[str, Optional[str]] = {
|
841
|
+
'200': "CreateConnectorResponse",
|
842
|
+
}
|
843
|
+
response_data = self.api_client.call_api(
|
844
|
+
*_param,
|
845
|
+
_request_timeout=_request_timeout
|
846
|
+
)
|
847
|
+
return response_data.response
|
848
|
+
|
849
|
+
|
850
|
+
def _publication_office_connector_create_serialize(
|
851
|
+
self,
|
852
|
+
create_connector_request,
|
853
|
+
q_answer_api_key,
|
854
|
+
_request_auth,
|
855
|
+
_content_type,
|
856
|
+
_headers,
|
857
|
+
_host_index,
|
858
|
+
) -> RequestSerialized:
|
859
|
+
|
860
|
+
_host = None
|
861
|
+
|
862
|
+
_collection_formats: Dict[str, str] = {
|
863
|
+
}
|
864
|
+
|
865
|
+
_path_params: Dict[str, str] = {}
|
866
|
+
_query_params: List[Tuple[str, str]] = []
|
867
|
+
_header_params: Dict[str, Optional[str]] = _headers or {}
|
868
|
+
_form_params: List[Tuple[str, str]] = []
|
869
|
+
_files: Dict[
|
870
|
+
str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
|
871
|
+
] = {}
|
872
|
+
_body_params: Optional[bytes] = None
|
873
|
+
|
874
|
+
# process the path parameters
|
875
|
+
# process the query parameters
|
876
|
+
# process the header parameters
|
877
|
+
if q_answer_api_key is not None:
|
878
|
+
_header_params['QAnswer-Api-Key'] = q_answer_api_key
|
879
|
+
# process the form parameters
|
880
|
+
# process the body parameter
|
881
|
+
if create_connector_request is not None:
|
882
|
+
_body_params = create_connector_request
|
883
|
+
|
884
|
+
|
885
|
+
# set the HTTP header `Accept`
|
886
|
+
if 'Accept' not in _header_params:
|
887
|
+
_header_params['Accept'] = self.api_client.select_header_accept(
|
888
|
+
[
|
889
|
+
'*/*'
|
890
|
+
]
|
891
|
+
)
|
892
|
+
|
893
|
+
# set the HTTP header `Content-Type`
|
894
|
+
if _content_type:
|
895
|
+
_header_params['Content-Type'] = _content_type
|
896
|
+
else:
|
897
|
+
_default_content_type = (
|
898
|
+
self.api_client.select_header_content_type(
|
899
|
+
[
|
900
|
+
'application/json'
|
901
|
+
]
|
902
|
+
)
|
903
|
+
)
|
904
|
+
if _default_content_type is not None:
|
905
|
+
_header_params['Content-Type'] = _default_content_type
|
906
|
+
|
907
|
+
# authentication setting
|
908
|
+
_auth_settings: List[str] = [
|
909
|
+
'QAnswer-Api-Key',
|
910
|
+
'Bearer'
|
911
|
+
]
|
912
|
+
|
913
|
+
return self.api_client.param_serialize(
|
914
|
+
method='POST',
|
915
|
+
resource_path='/api/connectors/publication-office/create',
|
916
|
+
path_params=_path_params,
|
917
|
+
query_params=_query_params,
|
918
|
+
header_params=_header_params,
|
919
|
+
body=_body_params,
|
920
|
+
post_params=_form_params,
|
921
|
+
files=_files,
|
922
|
+
auth_settings=_auth_settings,
|
923
|
+
collection_formats=_collection_formats,
|
924
|
+
_host=_host,
|
925
|
+
_request_auth=_request_auth
|
926
|
+
)
|
927
|
+
|
928
|
+
|
929
|
+
|
930
|
+
|
931
|
+
@validate_call
|
932
|
+
def search_publication_office(
|
933
|
+
self,
|
934
|
+
search_index_payload: SearchIndexPayload,
|
935
|
+
q_answer_api_key: Optional[StrictStr] = None,
|
936
|
+
_request_timeout: Union[
|
937
|
+
None,
|
938
|
+
Annotated[StrictFloat, Field(gt=0)],
|
939
|
+
Tuple[
|
940
|
+
Annotated[StrictFloat, Field(gt=0)],
|
941
|
+
Annotated[StrictFloat, Field(gt=0)]
|
942
|
+
]
|
943
|
+
] = None,
|
944
|
+
_request_auth: Optional[Dict[StrictStr, Any]] = None,
|
945
|
+
_content_type: Optional[StrictStr] = None,
|
946
|
+
_headers: Optional[Dict[StrictStr, Any]] = None,
|
947
|
+
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
|
948
|
+
) -> PublicationSearchIndexSearchResponse:
|
949
|
+
"""search_publication_office
|
950
|
+
|
951
|
+
|
952
|
+
:param search_index_payload: (required)
|
953
|
+
:type search_index_payload: SearchIndexPayload
|
954
|
+
:param q_answer_api_key:
|
955
|
+
:type q_answer_api_key: str
|
956
|
+
:param _request_timeout: timeout setting for this request. If one
|
957
|
+
number provided, it will be total request
|
958
|
+
timeout. It can also be a pair (tuple) of
|
959
|
+
(connection, read) timeouts.
|
960
|
+
:type _request_timeout: int, tuple(int, int), optional
|
961
|
+
:param _request_auth: set to override the auth_settings for an a single
|
962
|
+
request; this effectively ignores the
|
963
|
+
authentication in the spec for a single request.
|
964
|
+
:type _request_auth: dict, optional
|
965
|
+
:param _content_type: force content-type for the request.
|
966
|
+
:type _content_type: str, Optional
|
967
|
+
:param _headers: set to override the headers for a single
|
968
|
+
request; this effectively ignores the headers
|
969
|
+
in the spec for a single request.
|
970
|
+
:type _headers: dict, optional
|
971
|
+
:param _host_index: set to override the host_index for a single
|
972
|
+
request; this effectively ignores the host_index
|
973
|
+
in the spec for a single request.
|
974
|
+
:type _host_index: int, optional
|
975
|
+
:return: Returns the result object.
|
976
|
+
""" # noqa: E501
|
977
|
+
|
978
|
+
_param = self._search_publication_office_serialize(
|
979
|
+
search_index_payload=search_index_payload,
|
980
|
+
q_answer_api_key=q_answer_api_key,
|
981
|
+
_request_auth=_request_auth,
|
982
|
+
_content_type=_content_type,
|
983
|
+
_headers=_headers,
|
984
|
+
_host_index=_host_index
|
985
|
+
)
|
986
|
+
|
987
|
+
_response_types_map: Dict[str, Optional[str]] = {
|
988
|
+
'200': "PublicationSearchIndexSearchResponse",
|
989
|
+
}
|
990
|
+
response_data = self.api_client.call_api(
|
991
|
+
*_param,
|
992
|
+
_request_timeout=_request_timeout
|
993
|
+
)
|
994
|
+
response_data.read()
|
995
|
+
return self.api_client.response_deserialize(
|
996
|
+
response_data=response_data,
|
997
|
+
response_types_map=_response_types_map,
|
998
|
+
).data
|
999
|
+
|
1000
|
+
|
1001
|
+
@validate_call
|
1002
|
+
def search_publication_office_with_http_info(
|
1003
|
+
self,
|
1004
|
+
search_index_payload: SearchIndexPayload,
|
1005
|
+
q_answer_api_key: Optional[StrictStr] = None,
|
1006
|
+
_request_timeout: Union[
|
1007
|
+
None,
|
1008
|
+
Annotated[StrictFloat, Field(gt=0)],
|
1009
|
+
Tuple[
|
1010
|
+
Annotated[StrictFloat, Field(gt=0)],
|
1011
|
+
Annotated[StrictFloat, Field(gt=0)]
|
1012
|
+
]
|
1013
|
+
] = None,
|
1014
|
+
_request_auth: Optional[Dict[StrictStr, Any]] = None,
|
1015
|
+
_content_type: Optional[StrictStr] = None,
|
1016
|
+
_headers: Optional[Dict[StrictStr, Any]] = None,
|
1017
|
+
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
|
1018
|
+
) -> ApiResponse[PublicationSearchIndexSearchResponse]:
|
1019
|
+
"""search_publication_office
|
1020
|
+
|
1021
|
+
|
1022
|
+
:param search_index_payload: (required)
|
1023
|
+
:type search_index_payload: SearchIndexPayload
|
1024
|
+
:param q_answer_api_key:
|
1025
|
+
:type q_answer_api_key: str
|
1026
|
+
:param _request_timeout: timeout setting for this request. If one
|
1027
|
+
number provided, it will be total request
|
1028
|
+
timeout. It can also be a pair (tuple) of
|
1029
|
+
(connection, read) timeouts.
|
1030
|
+
:type _request_timeout: int, tuple(int, int), optional
|
1031
|
+
:param _request_auth: set to override the auth_settings for an a single
|
1032
|
+
request; this effectively ignores the
|
1033
|
+
authentication in the spec for a single request.
|
1034
|
+
:type _request_auth: dict, optional
|
1035
|
+
:param _content_type: force content-type for the request.
|
1036
|
+
:type _content_type: str, Optional
|
1037
|
+
:param _headers: set to override the headers for a single
|
1038
|
+
request; this effectively ignores the headers
|
1039
|
+
in the spec for a single request.
|
1040
|
+
:type _headers: dict, optional
|
1041
|
+
:param _host_index: set to override the host_index for a single
|
1042
|
+
request; this effectively ignores the host_index
|
1043
|
+
in the spec for a single request.
|
1044
|
+
:type _host_index: int, optional
|
1045
|
+
:return: Returns the result object.
|
1046
|
+
""" # noqa: E501
|
1047
|
+
|
1048
|
+
_param = self._search_publication_office_serialize(
|
1049
|
+
search_index_payload=search_index_payload,
|
1050
|
+
q_answer_api_key=q_answer_api_key,
|
1051
|
+
_request_auth=_request_auth,
|
1052
|
+
_content_type=_content_type,
|
1053
|
+
_headers=_headers,
|
1054
|
+
_host_index=_host_index
|
1055
|
+
)
|
1056
|
+
|
1057
|
+
_response_types_map: Dict[str, Optional[str]] = {
|
1058
|
+
'200': "PublicationSearchIndexSearchResponse",
|
1059
|
+
}
|
1060
|
+
response_data = self.api_client.call_api(
|
1061
|
+
*_param,
|
1062
|
+
_request_timeout=_request_timeout
|
1063
|
+
)
|
1064
|
+
response_data.read()
|
1065
|
+
return self.api_client.response_deserialize(
|
1066
|
+
response_data=response_data,
|
1067
|
+
response_types_map=_response_types_map,
|
1068
|
+
)
|
1069
|
+
|
1070
|
+
|
1071
|
+
@validate_call
|
1072
|
+
def search_publication_office_without_preload_content(
|
1073
|
+
self,
|
1074
|
+
search_index_payload: SearchIndexPayload,
|
1075
|
+
q_answer_api_key: Optional[StrictStr] = None,
|
1076
|
+
_request_timeout: Union[
|
1077
|
+
None,
|
1078
|
+
Annotated[StrictFloat, Field(gt=0)],
|
1079
|
+
Tuple[
|
1080
|
+
Annotated[StrictFloat, Field(gt=0)],
|
1081
|
+
Annotated[StrictFloat, Field(gt=0)]
|
1082
|
+
]
|
1083
|
+
] = None,
|
1084
|
+
_request_auth: Optional[Dict[StrictStr, Any]] = None,
|
1085
|
+
_content_type: Optional[StrictStr] = None,
|
1086
|
+
_headers: Optional[Dict[StrictStr, Any]] = None,
|
1087
|
+
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
|
1088
|
+
) -> RESTResponseType:
|
1089
|
+
"""search_publication_office
|
1090
|
+
|
1091
|
+
|
1092
|
+
:param search_index_payload: (required)
|
1093
|
+
:type search_index_payload: SearchIndexPayload
|
1094
|
+
:param q_answer_api_key:
|
1095
|
+
:type q_answer_api_key: str
|
1096
|
+
:param _request_timeout: timeout setting for this request. If one
|
1097
|
+
number provided, it will be total request
|
1098
|
+
timeout. It can also be a pair (tuple) of
|
1099
|
+
(connection, read) timeouts.
|
1100
|
+
:type _request_timeout: int, tuple(int, int), optional
|
1101
|
+
:param _request_auth: set to override the auth_settings for an a single
|
1102
|
+
request; this effectively ignores the
|
1103
|
+
authentication in the spec for a single request.
|
1104
|
+
:type _request_auth: dict, optional
|
1105
|
+
:param _content_type: force content-type for the request.
|
1106
|
+
:type _content_type: str, Optional
|
1107
|
+
:param _headers: set to override the headers for a single
|
1108
|
+
request; this effectively ignores the headers
|
1109
|
+
in the spec for a single request.
|
1110
|
+
:type _headers: dict, optional
|
1111
|
+
:param _host_index: set to override the host_index for a single
|
1112
|
+
request; this effectively ignores the host_index
|
1113
|
+
in the spec for a single request.
|
1114
|
+
:type _host_index: int, optional
|
1115
|
+
:return: Returns the result object.
|
1116
|
+
""" # noqa: E501
|
1117
|
+
|
1118
|
+
_param = self._search_publication_office_serialize(
|
1119
|
+
search_index_payload=search_index_payload,
|
1120
|
+
q_answer_api_key=q_answer_api_key,
|
1121
|
+
_request_auth=_request_auth,
|
1122
|
+
_content_type=_content_type,
|
1123
|
+
_headers=_headers,
|
1124
|
+
_host_index=_host_index
|
1125
|
+
)
|
1126
|
+
|
1127
|
+
_response_types_map: Dict[str, Optional[str]] = {
|
1128
|
+
'200': "PublicationSearchIndexSearchResponse",
|
1129
|
+
}
|
1130
|
+
response_data = self.api_client.call_api(
|
1131
|
+
*_param,
|
1132
|
+
_request_timeout=_request_timeout
|
1133
|
+
)
|
1134
|
+
return response_data.response
|
1135
|
+
|
1136
|
+
|
1137
|
+
def _search_publication_office_serialize(
|
1138
|
+
self,
|
1139
|
+
search_index_payload,
|
1140
|
+
q_answer_api_key,
|
1141
|
+
_request_auth,
|
1142
|
+
_content_type,
|
1143
|
+
_headers,
|
1144
|
+
_host_index,
|
1145
|
+
) -> RequestSerialized:
|
1146
|
+
|
1147
|
+
_host = None
|
1148
|
+
|
1149
|
+
_collection_formats: Dict[str, str] = {
|
1150
|
+
}
|
1151
|
+
|
1152
|
+
_path_params: Dict[str, str] = {}
|
1153
|
+
_query_params: List[Tuple[str, str]] = []
|
1154
|
+
_header_params: Dict[str, Optional[str]] = _headers or {}
|
1155
|
+
_form_params: List[Tuple[str, str]] = []
|
1156
|
+
_files: Dict[
|
1157
|
+
str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
|
1158
|
+
] = {}
|
1159
|
+
_body_params: Optional[bytes] = None
|
1160
|
+
|
1161
|
+
# process the path parameters
|
1162
|
+
# process the query parameters
|
1163
|
+
# process the header parameters
|
1164
|
+
if q_answer_api_key is not None:
|
1165
|
+
_header_params['QAnswer-Api-Key'] = q_answer_api_key
|
1166
|
+
# process the form parameters
|
1167
|
+
# process the body parameter
|
1168
|
+
if search_index_payload is not None:
|
1169
|
+
_body_params = search_index_payload
|
1170
|
+
|
1171
|
+
|
1172
|
+
# set the HTTP header `Accept`
|
1173
|
+
if 'Accept' not in _header_params:
|
1174
|
+
_header_params['Accept'] = self.api_client.select_header_accept(
|
1175
|
+
[
|
1176
|
+
'*/*'
|
1177
|
+
]
|
1178
|
+
)
|
1179
|
+
|
1180
|
+
# set the HTTP header `Content-Type`
|
1181
|
+
if _content_type:
|
1182
|
+
_header_params['Content-Type'] = _content_type
|
1183
|
+
else:
|
1184
|
+
_default_content_type = (
|
1185
|
+
self.api_client.select_header_content_type(
|
1186
|
+
[
|
1187
|
+
'application/json'
|
1188
|
+
]
|
1189
|
+
)
|
1190
|
+
)
|
1191
|
+
if _default_content_type is not None:
|
1192
|
+
_header_params['Content-Type'] = _default_content_type
|
1193
|
+
|
1194
|
+
# authentication setting
|
1195
|
+
_auth_settings: List[str] = [
|
1196
|
+
'QAnswer-Api-Key',
|
1197
|
+
'Bearer'
|
1198
|
+
]
|
1199
|
+
|
1200
|
+
return self.api_client.param_serialize(
|
1201
|
+
method='POST',
|
1202
|
+
resource_path='/api/connectors/publication-office/search',
|
1203
|
+
path_params=_path_params,
|
1204
|
+
query_params=_query_params,
|
1205
|
+
header_params=_header_params,
|
1206
|
+
body=_body_params,
|
1207
|
+
post_params=_form_params,
|
1208
|
+
files=_files,
|
1209
|
+
auth_settings=_auth_settings,
|
1210
|
+
collection_formats=_collection_formats,
|
1211
|
+
_host=_host,
|
1212
|
+
_request_auth=_request_auth
|
1213
|
+
)
|
1214
|
+
|
1215
|
+
|