revengai 2.74.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.
- revengai/__init__.py +647 -0
- revengai/api/__init__.py +22 -0
- revengai/api/analyses_comments_api.py +1198 -0
- revengai/api/analyses_core_api.py +3870 -0
- revengai/api/analyses_dynamic_execution_api.py +1884 -0
- revengai/api/analyses_results_metadata_api.py +2240 -0
- revengai/api/analyses_security_checks_api.py +862 -0
- revengai/api/authentication_users_api.py +1323 -0
- revengai/api/binaries_api.py +1610 -0
- revengai/api/collections_api.py +2167 -0
- revengai/api/external_sources_api.py +827 -0
- revengai/api/firmware_api.py +592 -0
- revengai/api/functions_ai_decompilation_api.py +2592 -0
- revengai/api/functions_block_comments_api.py +849 -0
- revengai/api/functions_core_api.py +3430 -0
- revengai/api/functions_data_types_api.py +1746 -0
- revengai/api/functions_decompilation_api.py +1198 -0
- revengai/api/functions_renaming_history_api.py +1151 -0
- revengai/api/models_api.py +284 -0
- revengai/api/search_api.py +1454 -0
- revengai/api_client.py +803 -0
- revengai/api_response.py +21 -0
- revengai/configuration.py +605 -0
- revengai/exceptions.py +215 -0
- revengai/models/__init__.py +298 -0
- revengai/models/addr.py +143 -0
- revengai/models/ai_decompilation_rating.py +37 -0
- revengai/models/ai_unstrip_request.py +86 -0
- revengai/models/analysis_access_info.py +88 -0
- revengai/models/analysis_config.py +106 -0
- revengai/models/analysis_create_request.py +131 -0
- revengai/models/analysis_create_response.py +88 -0
- revengai/models/analysis_detail_response.py +121 -0
- revengai/models/analysis_function_mapping.py +90 -0
- revengai/models/analysis_function_matching_request.py +110 -0
- revengai/models/analysis_functions.py +94 -0
- revengai/models/analysis_functions_list.py +94 -0
- revengai/models/analysis_record.py +128 -0
- revengai/models/analysis_scope.py +36 -0
- revengai/models/analysis_strings_response.py +96 -0
- revengai/models/analysis_tags.py +94 -0
- revengai/models/analysis_update_request.py +108 -0
- revengai/models/analysis_update_tags_request.py +86 -0
- revengai/models/analysis_update_tags_response.py +94 -0
- revengai/models/app_api_rest_v2_analyses_enums_dynamic_execution_status.py +38 -0
- revengai/models/app_api_rest_v2_analyses_enums_order_by.py +37 -0
- revengai/models/app_api_rest_v2_collections_enums_order_by.py +40 -0
- revengai/models/app_api_rest_v2_functions_responses_function.py +93 -0
- revengai/models/app_api_rest_v2_functions_types_function.py +110 -0
- revengai/models/app_services_dynamic_execution_schemas_dynamic_execution_status.py +86 -0
- revengai/models/argument.py +99 -0
- revengai/models/auto_unstrip_request.py +99 -0
- revengai/models/auto_unstrip_response.py +129 -0
- revengai/models/base_response.py +124 -0
- revengai/models/base_response_analysis_create_response.py +125 -0
- revengai/models/base_response_analysis_detail_response.py +125 -0
- revengai/models/base_response_analysis_function_mapping.py +125 -0
- revengai/models/base_response_analysis_functions.py +125 -0
- revengai/models/base_response_analysis_functions_list.py +125 -0
- revengai/models/base_response_analysis_strings_response.py +125 -0
- revengai/models/base_response_analysis_tags.py +125 -0
- revengai/models/base_response_analysis_update_tags_response.py +125 -0
- revengai/models/base_response_basic.py +125 -0
- revengai/models/base_response_binary_additional_response.py +125 -0
- revengai/models/base_response_binary_details_response.py +125 -0
- revengai/models/base_response_binary_externals_response.py +125 -0
- revengai/models/base_response_binary_search_response.py +125 -0
- revengai/models/base_response_block_comments_generation_for_function_response.py +125 -0
- revengai/models/base_response_block_comments_overview_generation_response.py +116 -0
- revengai/models/base_response_bool.py +121 -0
- revengai/models/base_response_callees_caller_functions_response.py +125 -0
- revengai/models/base_response_capabilities.py +125 -0
- revengai/models/base_response_check_security_checks_task_response.py +125 -0
- revengai/models/base_response_child_binaries_response.py +125 -0
- revengai/models/base_response_collection_binaries_update_response.py +125 -0
- revengai/models/base_response_collection_response.py +125 -0
- revengai/models/base_response_collection_search_response.py +125 -0
- revengai/models/base_response_collection_tags_update_response.py +125 -0
- revengai/models/base_response_comment_response.py +125 -0
- revengai/models/base_response_communities.py +125 -0
- revengai/models/base_response_created.py +125 -0
- revengai/models/base_response_dict.py +121 -0
- revengai/models/base_response_dynamic_execution_status.py +125 -0
- revengai/models/base_response_external_response.py +125 -0
- revengai/models/base_response_function_blocks_response.py +125 -0
- revengai/models/base_response_function_capability_response.py +125 -0
- revengai/models/base_response_function_data_types.py +125 -0
- revengai/models/base_response_function_data_types_list.py +125 -0
- revengai/models/base_response_function_search_response.py +125 -0
- revengai/models/base_response_function_strings_response.py +125 -0
- revengai/models/base_response_function_task_response.py +125 -0
- revengai/models/base_response_functions_detail_response.py +125 -0
- revengai/models/base_response_generate_function_data_types.py +125 -0
- revengai/models/base_response_generation_status_list.py +125 -0
- revengai/models/base_response_get_ai_decompilation_rating_response.py +125 -0
- revengai/models/base_response_get_ai_decompilation_task.py +125 -0
- revengai/models/base_response_get_me_response.py +125 -0
- revengai/models/base_response_get_public_user_response.py +125 -0
- revengai/models/base_response_list_collection_results.py +125 -0
- revengai/models/base_response_list_comment_response.py +129 -0
- revengai/models/base_response_list_die_match.py +129 -0
- revengai/models/base_response_list_function_name_history.py +129 -0
- revengai/models/base_response_list_sbom.py +129 -0
- revengai/models/base_response_list_user_activity_response.py +129 -0
- revengai/models/base_response_login_response.py +125 -0
- revengai/models/base_response_logs.py +125 -0
- revengai/models/base_response_models_response.py +125 -0
- revengai/models/base_response_network_overview_response.py +125 -0
- revengai/models/base_response_params.py +125 -0
- revengai/models/base_response_process_dumps.py +125 -0
- revengai/models/base_response_process_registry.py +125 -0
- revengai/models/base_response_process_tree.py +125 -0
- revengai/models/base_response_queued_security_checks_task_response.py +125 -0
- revengai/models/base_response_recent.py +125 -0
- revengai/models/base_response_security_checks_response.py +125 -0
- revengai/models/base_response_status.py +125 -0
- revengai/models/base_response_str.py +121 -0
- revengai/models/base_response_tag_search_response.py +125 -0
- revengai/models/base_response_task_response.py +125 -0
- revengai/models/base_response_ttps.py +125 -0
- revengai/models/base_response_upload_response.py +125 -0
- revengai/models/base_response_vulnerabilities.py +125 -0
- revengai/models/basic.py +116 -0
- revengai/models/binary_additional_details_data_response.py +112 -0
- revengai/models/binary_additional_response.py +105 -0
- revengai/models/binary_config.py +108 -0
- revengai/models/binary_details_response.py +125 -0
- revengai/models/binary_externals_response.py +95 -0
- revengai/models/binary_search_response.py +94 -0
- revengai/models/binary_search_result.py +108 -0
- revengai/models/binary_task_status.py +39 -0
- revengai/models/block.py +86 -0
- revengai/models/block_comments_generation_for_function_response.py +86 -0
- revengai/models/callee_function_info.py +106 -0
- revengai/models/callees_caller_functions_response.py +106 -0
- revengai/models/caller_function_info.py +106 -0
- revengai/models/capabilities.py +94 -0
- revengai/models/capability.py +90 -0
- revengai/models/check_security_checks_task_response.py +87 -0
- revengai/models/child_binaries_response.py +104 -0
- revengai/models/code_signature_model.py +98 -0
- revengai/models/collection_binaries_update_request.py +86 -0
- revengai/models/collection_binaries_update_response.py +94 -0
- revengai/models/collection_binary_response.py +97 -0
- revengai/models/collection_create_request.py +107 -0
- revengai/models/collection_list_item.py +112 -0
- revengai/models/collection_response.py +131 -0
- revengai/models/collection_response_binaries_inner.py +135 -0
- revengai/models/collection_scope.py +38 -0
- revengai/models/collection_search_response.py +94 -0
- revengai/models/collection_search_result.py +124 -0
- revengai/models/collection_tags_update_request.py +86 -0
- revengai/models/collection_tags_update_response.py +86 -0
- revengai/models/collection_update_request.py +106 -0
- revengai/models/comment_base.py +86 -0
- revengai/models/comment_response.py +110 -0
- revengai/models/comment_update_request.py +86 -0
- revengai/models/communities.py +100 -0
- revengai/models/community_match_percentages.py +92 -0
- revengai/models/confidence_type.py +39 -0
- revengai/models/context.py +141 -0
- revengai/models/created.py +90 -0
- revengai/models/decompilation_comment_context.py +98 -0
- revengai/models/die_match.py +92 -0
- revengai/models/dynamic_execution_status_input.py +38 -0
- revengai/models/elf_dynamic_entry.py +88 -0
- revengai/models/elf_import_model.py +88 -0
- revengai/models/elf_model.py +179 -0
- revengai/models/elf_relocation.py +98 -0
- revengai/models/elf_section.py +104 -0
- revengai/models/elf_security.py +94 -0
- revengai/models/elf_segment.py +102 -0
- revengai/models/elf_symbol.py +98 -0
- revengai/models/entrypoint_model.py +88 -0
- revengai/models/enumeration.py +97 -0
- revengai/models/error_model.py +88 -0
- revengai/models/export_model.py +88 -0
- revengai/models/external_response.py +91 -0
- revengai/models/file_format.py +37 -0
- revengai/models/file_hashes.py +140 -0
- revengai/models/file_metadata.py +96 -0
- revengai/models/filters.py +39 -0
- revengai/models/function_block_destination_response.py +95 -0
- revengai/models/function_block_response.py +109 -0
- revengai/models/function_blocks_response.py +121 -0
- revengai/models/function_boundary.py +90 -0
- revengai/models/function_capability_response.py +86 -0
- revengai/models/function_comment_create_request.py +92 -0
- revengai/models/function_data_types.py +106 -0
- revengai/models/function_data_types_list.py +98 -0
- revengai/models/function_data_types_list_item.py +108 -0
- revengai/models/function_data_types_params.py +86 -0
- revengai/models/function_data_types_status.py +90 -0
- revengai/models/function_header.py +112 -0
- revengai/models/function_info_input.py +105 -0
- revengai/models/function_info_input_func_deps_inner.py +163 -0
- revengai/models/function_info_output.py +105 -0
- revengai/models/function_list_item.py +96 -0
- revengai/models/function_local_variable_response.py +94 -0
- revengai/models/function_mapping.py +90 -0
- revengai/models/function_mapping_full.py +275 -0
- revengai/models/function_match.py +111 -0
- revengai/models/function_matching_filters.py +103 -0
- revengai/models/function_matching_request.py +114 -0
- revengai/models/function_matching_response.py +157 -0
- revengai/models/function_name_history.py +99 -0
- revengai/models/function_param_response.py +94 -0
- revengai/models/function_rename.py +88 -0
- revengai/models/function_rename_map.py +90 -0
- revengai/models/function_search_response.py +94 -0
- revengai/models/function_search_result.py +99 -0
- revengai/models/function_source_type.py +39 -0
- revengai/models/function_string.py +88 -0
- revengai/models/function_strings_response.py +96 -0
- revengai/models/function_task_response.py +94 -0
- revengai/models/function_task_status.py +39 -0
- revengai/models/function_type_input.py +127 -0
- revengai/models/function_type_output.py +127 -0
- revengai/models/functions_detail_response.py +125 -0
- revengai/models/functions_list_rename.py +94 -0
- revengai/models/generate_function_data_types.py +94 -0
- revengai/models/generation_status_list.py +98 -0
- revengai/models/get_ai_decompilation_rating_response.py +94 -0
- revengai/models/get_ai_decompilation_task.py +159 -0
- revengai/models/get_me_response.py +108 -0
- revengai/models/get_public_user_response.py +88 -0
- revengai/models/global_variable.py +101 -0
- revengai/models/icon_model.py +91 -0
- revengai/models/import_model.py +88 -0
- revengai/models/inverse_function_map_item.py +99 -0
- revengai/models/inverse_string_map_item.py +93 -0
- revengai/models/inverse_value.py +86 -0
- revengai/models/isa.py +37 -0
- revengai/models/list_collection_results.py +94 -0
- revengai/models/login_request.py +89 -0
- revengai/models/login_response.py +86 -0
- revengai/models/logs.py +86 -0
- revengai/models/matched_function.py +116 -0
- revengai/models/matched_function_suggestion.py +97 -0
- revengai/models/meta_model.py +95 -0
- revengai/models/model_name.py +40 -0
- revengai/models/models_response.py +86 -0
- revengai/models/name_confidence.py +89 -0
- revengai/models/network_overview_dns.py +98 -0
- revengai/models/network_overview_dns_answer.py +88 -0
- revengai/models/network_overview_metadata.py +99 -0
- revengai/models/network_overview_response.py +104 -0
- revengai/models/order.py +36 -0
- revengai/models/pagination_model.py +90 -0
- revengai/models/params.py +103 -0
- revengai/models/pdb_debug_model.py +94 -0
- revengai/models/pe_model.py +215 -0
- revengai/models/platform.py +36 -0
- revengai/models/process.py +103 -0
- revengai/models/process_dump.py +96 -0
- revengai/models/process_dump_metadata.py +90 -0
- revengai/models/process_dumps.py +92 -0
- revengai/models/process_dumps_data.py +96 -0
- revengai/models/process_registry.py +105 -0
- revengai/models/process_tree.py +96 -0
- revengai/models/queued_security_checks_task_response.py +86 -0
- revengai/models/re_analysis_form.py +101 -0
- revengai/models/recent.py +94 -0
- revengai/models/registry.py +102 -0
- revengai/models/relative_binary_response.py +90 -0
- revengai/models/sandbox_options.py +88 -0
- revengai/models/sbom.py +96 -0
- revengai/models/sbom_package.py +88 -0
- revengai/models/scrape_third_party_config.py +86 -0
- revengai/models/section_model.py +96 -0
- revengai/models/security_checks_response.py +98 -0
- revengai/models/security_checks_result.py +103 -0
- revengai/models/security_model.py +106 -0
- revengai/models/severity_type.py +40 -0
- revengai/models/single_code_certificate_model.py +96 -0
- revengai/models/single_code_signature_model.py +96 -0
- revengai/models/single_pdb_entry_model.py +90 -0
- revengai/models/single_section_model.py +98 -0
- revengai/models/stack_variable.py +101 -0
- revengai/models/status_input.py +40 -0
- revengai/models/status_output.py +88 -0
- revengai/models/string_functions.py +96 -0
- revengai/models/structure.py +117 -0
- revengai/models/structure_member.py +99 -0
- revengai/models/symbols.py +96 -0
- revengai/models/tag.py +86 -0
- revengai/models/tag_item.py +95 -0
- revengai/models/tag_response.py +88 -0
- revengai/models/tag_search_response.py +94 -0
- revengai/models/tag_search_result.py +88 -0
- revengai/models/task_response.py +94 -0
- revengai/models/task_status.py +39 -0
- revengai/models/timestamp_model.py +90 -0
- revengai/models/ttps.py +92 -0
- revengai/models/ttps_attack.py +88 -0
- revengai/models/ttps_data.py +96 -0
- revengai/models/ttps_element.py +108 -0
- revengai/models/ttps_occurance.py +88 -0
- revengai/models/type_definition.py +97 -0
- revengai/models/update_function_data_types.py +92 -0
- revengai/models/upload_file_type.py +38 -0
- revengai/models/upload_response.py +91 -0
- revengai/models/upsert_ai_decomplation_rating_request.py +94 -0
- revengai/models/user_activity_response.py +97 -0
- revengai/models/vulnerabilities.py +94 -0
- revengai/models/vulnerability.py +113 -0
- revengai/models/vulnerability_type.py +40 -0
- revengai/models/workspace.py +37 -0
- revengai/py.typed +0 -0
- revengai/rest.py +257 -0
- revengai-2.74.0.dist-info/METADATA +447 -0
- revengai-2.74.0.dist-info/RECORD +314 -0
- revengai-2.74.0.dist-info/WHEEL +4 -0
- revengai-2.74.0.dist-info/licenses/LICENSE.md +19 -0
|
@@ -0,0 +1,1198 @@
|
|
|
1
|
+
# coding: utf-8
|
|
2
|
+
|
|
3
|
+
"""
|
|
4
|
+
RevEng.AI API
|
|
5
|
+
|
|
6
|
+
RevEng.AI is Similarity Search Engine for executable binaries
|
|
7
|
+
|
|
8
|
+
Generated by OpenAPI Generator (https://openapi-generator.tech)
|
|
9
|
+
|
|
10
|
+
Do not edit the class manually.
|
|
11
|
+
""" # noqa: E501
|
|
12
|
+
|
|
13
|
+
import warnings
|
|
14
|
+
from pydantic import validate_call, Field, StrictFloat, StrictStr, StrictInt
|
|
15
|
+
from typing import Any, Dict, List, Optional, Tuple, Union
|
|
16
|
+
from typing_extensions import Annotated
|
|
17
|
+
|
|
18
|
+
from pydantic import Field, StrictInt
|
|
19
|
+
from typing_extensions import Annotated
|
|
20
|
+
from revengai.models.base_response_bool import BaseResponseBool
|
|
21
|
+
from revengai.models.base_response_comment_response import BaseResponseCommentResponse
|
|
22
|
+
from revengai.models.base_response_list_comment_response import BaseResponseListCommentResponse
|
|
23
|
+
from revengai.models.comment_update_request import CommentUpdateRequest
|
|
24
|
+
from revengai.models.function_comment_create_request import FunctionCommentCreateRequest
|
|
25
|
+
|
|
26
|
+
from revengai.api_client import ApiClient, RequestSerialized
|
|
27
|
+
from revengai.api_response import ApiResponse
|
|
28
|
+
from revengai.rest import RESTResponseType
|
|
29
|
+
|
|
30
|
+
|
|
31
|
+
class FunctionsDecompilationApi:
|
|
32
|
+
"""NOTE: This class is auto generated by OpenAPI Generator
|
|
33
|
+
Ref: https://openapi-generator.tech
|
|
34
|
+
|
|
35
|
+
Do not edit the class manually.
|
|
36
|
+
"""
|
|
37
|
+
|
|
38
|
+
def __init__(self, api_client=None) -> None:
|
|
39
|
+
if api_client is None:
|
|
40
|
+
api_client = ApiClient.get_default()
|
|
41
|
+
self.api_client = api_client
|
|
42
|
+
|
|
43
|
+
|
|
44
|
+
@validate_call
|
|
45
|
+
def create_decompilation_comment(
|
|
46
|
+
self,
|
|
47
|
+
function_id: StrictInt,
|
|
48
|
+
function_comment_create_request: FunctionCommentCreateRequest,
|
|
49
|
+
_request_timeout: Union[
|
|
50
|
+
None,
|
|
51
|
+
Annotated[StrictFloat, Field(gt=0)],
|
|
52
|
+
Tuple[
|
|
53
|
+
Annotated[StrictFloat, Field(gt=0)],
|
|
54
|
+
Annotated[StrictFloat, Field(gt=0)]
|
|
55
|
+
]
|
|
56
|
+
] = None,
|
|
57
|
+
_request_auth: Optional[Dict[StrictStr, Any]] = None,
|
|
58
|
+
_content_type: Optional[StrictStr] = None,
|
|
59
|
+
_headers: Optional[Dict[StrictStr, Any]] = None,
|
|
60
|
+
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
|
|
61
|
+
) -> BaseResponseCommentResponse:
|
|
62
|
+
"""Create a comment for this function
|
|
63
|
+
|
|
64
|
+
Creates a comment associated with a specified function).
|
|
65
|
+
|
|
66
|
+
:param function_id: (required)
|
|
67
|
+
:type function_id: int
|
|
68
|
+
:param function_comment_create_request: (required)
|
|
69
|
+
:type function_comment_create_request: FunctionCommentCreateRequest
|
|
70
|
+
:param _request_timeout: timeout setting for this request. If one
|
|
71
|
+
number provided, it will be total request
|
|
72
|
+
timeout. It can also be a pair (tuple) of
|
|
73
|
+
(connection, read) timeouts.
|
|
74
|
+
:type _request_timeout: int, tuple(int, int), optional
|
|
75
|
+
:param _request_auth: set to override the auth_settings for an a single
|
|
76
|
+
request; this effectively ignores the
|
|
77
|
+
authentication in the spec for a single request.
|
|
78
|
+
:type _request_auth: dict, optional
|
|
79
|
+
:param _content_type: force content-type for the request.
|
|
80
|
+
:type _content_type: str, Optional
|
|
81
|
+
:param _headers: set to override the headers for a single
|
|
82
|
+
request; this effectively ignores the headers
|
|
83
|
+
in the spec for a single request.
|
|
84
|
+
:type _headers: dict, optional
|
|
85
|
+
:param _host_index: set to override the host_index for a single
|
|
86
|
+
request; this effectively ignores the host_index
|
|
87
|
+
in the spec for a single request.
|
|
88
|
+
:type _host_index: int, optional
|
|
89
|
+
:return: Returns the result object.
|
|
90
|
+
""" # noqa: E501
|
|
91
|
+
|
|
92
|
+
_param = self._create_decompilation_comment_serialize(
|
|
93
|
+
function_id=function_id,
|
|
94
|
+
function_comment_create_request=function_comment_create_request,
|
|
95
|
+
_request_auth=_request_auth,
|
|
96
|
+
_content_type=_content_type,
|
|
97
|
+
_headers=_headers,
|
|
98
|
+
_host_index=_host_index
|
|
99
|
+
)
|
|
100
|
+
|
|
101
|
+
_response_types_map: Dict[str, Optional[str]] = {
|
|
102
|
+
'201': "BaseResponseCommentResponse",
|
|
103
|
+
'422': "BaseResponse",
|
|
104
|
+
'400': "BaseResponse",
|
|
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 create_decompilation_comment_with_http_info(
|
|
119
|
+
self,
|
|
120
|
+
function_id: StrictInt,
|
|
121
|
+
function_comment_create_request: FunctionCommentCreateRequest,
|
|
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[BaseResponseCommentResponse]:
|
|
135
|
+
"""Create a comment for this function
|
|
136
|
+
|
|
137
|
+
Creates a comment associated with a specified function).
|
|
138
|
+
|
|
139
|
+
:param function_id: (required)
|
|
140
|
+
:type function_id: int
|
|
141
|
+
:param function_comment_create_request: (required)
|
|
142
|
+
:type function_comment_create_request: FunctionCommentCreateRequest
|
|
143
|
+
:param _request_timeout: timeout setting for this request. If one
|
|
144
|
+
number provided, it will be total request
|
|
145
|
+
timeout. It can also be a pair (tuple) of
|
|
146
|
+
(connection, read) timeouts.
|
|
147
|
+
:type _request_timeout: int, tuple(int, int), optional
|
|
148
|
+
:param _request_auth: set to override the auth_settings for an a single
|
|
149
|
+
request; this effectively ignores the
|
|
150
|
+
authentication in the spec for a single request.
|
|
151
|
+
:type _request_auth: dict, optional
|
|
152
|
+
:param _content_type: force content-type for the request.
|
|
153
|
+
:type _content_type: str, Optional
|
|
154
|
+
:param _headers: set to override the headers for a single
|
|
155
|
+
request; this effectively ignores the headers
|
|
156
|
+
in the spec for a single request.
|
|
157
|
+
:type _headers: dict, optional
|
|
158
|
+
:param _host_index: set to override the host_index for a single
|
|
159
|
+
request; this effectively ignores the host_index
|
|
160
|
+
in the spec for a single request.
|
|
161
|
+
:type _host_index: int, optional
|
|
162
|
+
:return: Returns the result object.
|
|
163
|
+
""" # noqa: E501
|
|
164
|
+
|
|
165
|
+
_param = self._create_decompilation_comment_serialize(
|
|
166
|
+
function_id=function_id,
|
|
167
|
+
function_comment_create_request=function_comment_create_request,
|
|
168
|
+
_request_auth=_request_auth,
|
|
169
|
+
_content_type=_content_type,
|
|
170
|
+
_headers=_headers,
|
|
171
|
+
_host_index=_host_index
|
|
172
|
+
)
|
|
173
|
+
|
|
174
|
+
_response_types_map: Dict[str, Optional[str]] = {
|
|
175
|
+
'201': "BaseResponseCommentResponse",
|
|
176
|
+
'422': "BaseResponse",
|
|
177
|
+
'400': "BaseResponse",
|
|
178
|
+
}
|
|
179
|
+
response_data = self.api_client.call_api(
|
|
180
|
+
*_param,
|
|
181
|
+
_request_timeout=_request_timeout
|
|
182
|
+
)
|
|
183
|
+
response_data.read()
|
|
184
|
+
return self.api_client.response_deserialize(
|
|
185
|
+
response_data=response_data,
|
|
186
|
+
response_types_map=_response_types_map,
|
|
187
|
+
)
|
|
188
|
+
|
|
189
|
+
|
|
190
|
+
@validate_call
|
|
191
|
+
def create_decompilation_comment_without_preload_content(
|
|
192
|
+
self,
|
|
193
|
+
function_id: StrictInt,
|
|
194
|
+
function_comment_create_request: FunctionCommentCreateRequest,
|
|
195
|
+
_request_timeout: Union[
|
|
196
|
+
None,
|
|
197
|
+
Annotated[StrictFloat, Field(gt=0)],
|
|
198
|
+
Tuple[
|
|
199
|
+
Annotated[StrictFloat, Field(gt=0)],
|
|
200
|
+
Annotated[StrictFloat, Field(gt=0)]
|
|
201
|
+
]
|
|
202
|
+
] = None,
|
|
203
|
+
_request_auth: Optional[Dict[StrictStr, Any]] = None,
|
|
204
|
+
_content_type: Optional[StrictStr] = None,
|
|
205
|
+
_headers: Optional[Dict[StrictStr, Any]] = None,
|
|
206
|
+
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
|
|
207
|
+
) -> RESTResponseType:
|
|
208
|
+
"""Create a comment for this function
|
|
209
|
+
|
|
210
|
+
Creates a comment associated with a specified function).
|
|
211
|
+
|
|
212
|
+
:param function_id: (required)
|
|
213
|
+
:type function_id: int
|
|
214
|
+
:param function_comment_create_request: (required)
|
|
215
|
+
:type function_comment_create_request: FunctionCommentCreateRequest
|
|
216
|
+
:param _request_timeout: timeout setting for this request. If one
|
|
217
|
+
number provided, it will be total request
|
|
218
|
+
timeout. It can also be a pair (tuple) of
|
|
219
|
+
(connection, read) timeouts.
|
|
220
|
+
:type _request_timeout: int, tuple(int, int), optional
|
|
221
|
+
:param _request_auth: set to override the auth_settings for an a single
|
|
222
|
+
request; this effectively ignores the
|
|
223
|
+
authentication in the spec for a single request.
|
|
224
|
+
:type _request_auth: dict, optional
|
|
225
|
+
:param _content_type: force content-type for the request.
|
|
226
|
+
:type _content_type: str, Optional
|
|
227
|
+
:param _headers: set to override the headers for a single
|
|
228
|
+
request; this effectively ignores the headers
|
|
229
|
+
in the spec for a single request.
|
|
230
|
+
:type _headers: dict, optional
|
|
231
|
+
:param _host_index: set to override the host_index for a single
|
|
232
|
+
request; this effectively ignores the host_index
|
|
233
|
+
in the spec for a single request.
|
|
234
|
+
:type _host_index: int, optional
|
|
235
|
+
:return: Returns the result object.
|
|
236
|
+
""" # noqa: E501
|
|
237
|
+
|
|
238
|
+
_param = self._create_decompilation_comment_serialize(
|
|
239
|
+
function_id=function_id,
|
|
240
|
+
function_comment_create_request=function_comment_create_request,
|
|
241
|
+
_request_auth=_request_auth,
|
|
242
|
+
_content_type=_content_type,
|
|
243
|
+
_headers=_headers,
|
|
244
|
+
_host_index=_host_index
|
|
245
|
+
)
|
|
246
|
+
|
|
247
|
+
_response_types_map: Dict[str, Optional[str]] = {
|
|
248
|
+
'201': "BaseResponseCommentResponse",
|
|
249
|
+
'422': "BaseResponse",
|
|
250
|
+
'400': "BaseResponse",
|
|
251
|
+
}
|
|
252
|
+
response_data = self.api_client.call_api(
|
|
253
|
+
*_param,
|
|
254
|
+
_request_timeout=_request_timeout
|
|
255
|
+
)
|
|
256
|
+
return response_data.response
|
|
257
|
+
|
|
258
|
+
|
|
259
|
+
def _create_decompilation_comment_serialize(
|
|
260
|
+
self,
|
|
261
|
+
function_id,
|
|
262
|
+
function_comment_create_request,
|
|
263
|
+
_request_auth,
|
|
264
|
+
_content_type,
|
|
265
|
+
_headers,
|
|
266
|
+
_host_index,
|
|
267
|
+
) -> RequestSerialized:
|
|
268
|
+
|
|
269
|
+
_host = None
|
|
270
|
+
|
|
271
|
+
_collection_formats: Dict[str, str] = {
|
|
272
|
+
}
|
|
273
|
+
|
|
274
|
+
_path_params: Dict[str, str] = {}
|
|
275
|
+
_query_params: List[Tuple[str, str]] = []
|
|
276
|
+
_header_params: Dict[str, Optional[str]] = _headers or {}
|
|
277
|
+
_form_params: List[Tuple[str, str]] = []
|
|
278
|
+
_files: Dict[
|
|
279
|
+
str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
|
|
280
|
+
] = {}
|
|
281
|
+
_body_params: Optional[bytes] = None
|
|
282
|
+
|
|
283
|
+
# process the path parameters
|
|
284
|
+
if function_id is not None:
|
|
285
|
+
_path_params['function_id'] = function_id
|
|
286
|
+
# process the query parameters
|
|
287
|
+
# process the header parameters
|
|
288
|
+
# process the form parameters
|
|
289
|
+
# process the body parameter
|
|
290
|
+
if function_comment_create_request is not None:
|
|
291
|
+
_body_params = function_comment_create_request
|
|
292
|
+
|
|
293
|
+
|
|
294
|
+
# set the HTTP header `Accept`
|
|
295
|
+
if 'Accept' not in _header_params:
|
|
296
|
+
_header_params['Accept'] = self.api_client.select_header_accept(
|
|
297
|
+
[
|
|
298
|
+
'application/json'
|
|
299
|
+
]
|
|
300
|
+
)
|
|
301
|
+
|
|
302
|
+
# set the HTTP header `Content-Type`
|
|
303
|
+
if _content_type:
|
|
304
|
+
_header_params['Content-Type'] = _content_type
|
|
305
|
+
else:
|
|
306
|
+
_default_content_type = (
|
|
307
|
+
self.api_client.select_header_content_type(
|
|
308
|
+
[
|
|
309
|
+
'application/json'
|
|
310
|
+
]
|
|
311
|
+
)
|
|
312
|
+
)
|
|
313
|
+
if _default_content_type is not None:
|
|
314
|
+
_header_params['Content-Type'] = _default_content_type
|
|
315
|
+
|
|
316
|
+
# authentication setting
|
|
317
|
+
_auth_settings: List[str] = [
|
|
318
|
+
'APIKey'
|
|
319
|
+
]
|
|
320
|
+
|
|
321
|
+
return self.api_client.param_serialize(
|
|
322
|
+
method='POST',
|
|
323
|
+
resource_path='/v2/functions/{function_id}/decompilation/comments',
|
|
324
|
+
path_params=_path_params,
|
|
325
|
+
query_params=_query_params,
|
|
326
|
+
header_params=_header_params,
|
|
327
|
+
body=_body_params,
|
|
328
|
+
post_params=_form_params,
|
|
329
|
+
files=_files,
|
|
330
|
+
auth_settings=_auth_settings,
|
|
331
|
+
collection_formats=_collection_formats,
|
|
332
|
+
_host=_host,
|
|
333
|
+
_request_auth=_request_auth
|
|
334
|
+
)
|
|
335
|
+
|
|
336
|
+
|
|
337
|
+
|
|
338
|
+
|
|
339
|
+
@validate_call
|
|
340
|
+
def delete_decompilation_comment(
|
|
341
|
+
self,
|
|
342
|
+
comment_id: Annotated[int, Field(strict=True, ge=1)],
|
|
343
|
+
function_id: StrictInt,
|
|
344
|
+
_request_timeout: Union[
|
|
345
|
+
None,
|
|
346
|
+
Annotated[StrictFloat, Field(gt=0)],
|
|
347
|
+
Tuple[
|
|
348
|
+
Annotated[StrictFloat, Field(gt=0)],
|
|
349
|
+
Annotated[StrictFloat, Field(gt=0)]
|
|
350
|
+
]
|
|
351
|
+
] = None,
|
|
352
|
+
_request_auth: Optional[Dict[StrictStr, Any]] = None,
|
|
353
|
+
_content_type: Optional[StrictStr] = None,
|
|
354
|
+
_headers: Optional[Dict[StrictStr, Any]] = None,
|
|
355
|
+
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
|
|
356
|
+
) -> BaseResponseBool:
|
|
357
|
+
"""Delete a comment
|
|
358
|
+
|
|
359
|
+
Deletes an existing comment. Users can only delete their own comments.
|
|
360
|
+
|
|
361
|
+
:param comment_id: (required)
|
|
362
|
+
:type comment_id: int
|
|
363
|
+
:param function_id: (required)
|
|
364
|
+
:type function_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._delete_decompilation_comment_serialize(
|
|
388
|
+
comment_id=comment_id,
|
|
389
|
+
function_id=function_id,
|
|
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': "BaseResponseBool",
|
|
398
|
+
'422': "BaseResponse",
|
|
399
|
+
'403': "BaseResponse",
|
|
400
|
+
'400': "BaseResponse",
|
|
401
|
+
}
|
|
402
|
+
response_data = self.api_client.call_api(
|
|
403
|
+
*_param,
|
|
404
|
+
_request_timeout=_request_timeout
|
|
405
|
+
)
|
|
406
|
+
response_data.read()
|
|
407
|
+
return self.api_client.response_deserialize(
|
|
408
|
+
response_data=response_data,
|
|
409
|
+
response_types_map=_response_types_map,
|
|
410
|
+
).data
|
|
411
|
+
|
|
412
|
+
|
|
413
|
+
@validate_call
|
|
414
|
+
def delete_decompilation_comment_with_http_info(
|
|
415
|
+
self,
|
|
416
|
+
comment_id: Annotated[int, Field(strict=True, ge=1)],
|
|
417
|
+
function_id: StrictInt,
|
|
418
|
+
_request_timeout: Union[
|
|
419
|
+
None,
|
|
420
|
+
Annotated[StrictFloat, Field(gt=0)],
|
|
421
|
+
Tuple[
|
|
422
|
+
Annotated[StrictFloat, Field(gt=0)],
|
|
423
|
+
Annotated[StrictFloat, Field(gt=0)]
|
|
424
|
+
]
|
|
425
|
+
] = None,
|
|
426
|
+
_request_auth: Optional[Dict[StrictStr, Any]] = None,
|
|
427
|
+
_content_type: Optional[StrictStr] = None,
|
|
428
|
+
_headers: Optional[Dict[StrictStr, Any]] = None,
|
|
429
|
+
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
|
|
430
|
+
) -> ApiResponse[BaseResponseBool]:
|
|
431
|
+
"""Delete a comment
|
|
432
|
+
|
|
433
|
+
Deletes an existing comment. Users can only delete their own comments.
|
|
434
|
+
|
|
435
|
+
:param comment_id: (required)
|
|
436
|
+
:type comment_id: int
|
|
437
|
+
:param function_id: (required)
|
|
438
|
+
:type function_id: int
|
|
439
|
+
:param _request_timeout: timeout setting for this request. If one
|
|
440
|
+
number provided, it will be total request
|
|
441
|
+
timeout. It can also be a pair (tuple) of
|
|
442
|
+
(connection, read) timeouts.
|
|
443
|
+
:type _request_timeout: int, tuple(int, int), optional
|
|
444
|
+
:param _request_auth: set to override the auth_settings for an a single
|
|
445
|
+
request; this effectively ignores the
|
|
446
|
+
authentication in the spec for a single request.
|
|
447
|
+
:type _request_auth: dict, optional
|
|
448
|
+
:param _content_type: force content-type for the request.
|
|
449
|
+
:type _content_type: str, Optional
|
|
450
|
+
:param _headers: set to override the headers for a single
|
|
451
|
+
request; this effectively ignores the headers
|
|
452
|
+
in the spec for a single request.
|
|
453
|
+
:type _headers: dict, optional
|
|
454
|
+
:param _host_index: set to override the host_index for a single
|
|
455
|
+
request; this effectively ignores the host_index
|
|
456
|
+
in the spec for a single request.
|
|
457
|
+
:type _host_index: int, optional
|
|
458
|
+
:return: Returns the result object.
|
|
459
|
+
""" # noqa: E501
|
|
460
|
+
|
|
461
|
+
_param = self._delete_decompilation_comment_serialize(
|
|
462
|
+
comment_id=comment_id,
|
|
463
|
+
function_id=function_id,
|
|
464
|
+
_request_auth=_request_auth,
|
|
465
|
+
_content_type=_content_type,
|
|
466
|
+
_headers=_headers,
|
|
467
|
+
_host_index=_host_index
|
|
468
|
+
)
|
|
469
|
+
|
|
470
|
+
_response_types_map: Dict[str, Optional[str]] = {
|
|
471
|
+
'200': "BaseResponseBool",
|
|
472
|
+
'422': "BaseResponse",
|
|
473
|
+
'403': "BaseResponse",
|
|
474
|
+
'400': "BaseResponse",
|
|
475
|
+
}
|
|
476
|
+
response_data = self.api_client.call_api(
|
|
477
|
+
*_param,
|
|
478
|
+
_request_timeout=_request_timeout
|
|
479
|
+
)
|
|
480
|
+
response_data.read()
|
|
481
|
+
return self.api_client.response_deserialize(
|
|
482
|
+
response_data=response_data,
|
|
483
|
+
response_types_map=_response_types_map,
|
|
484
|
+
)
|
|
485
|
+
|
|
486
|
+
|
|
487
|
+
@validate_call
|
|
488
|
+
def delete_decompilation_comment_without_preload_content(
|
|
489
|
+
self,
|
|
490
|
+
comment_id: Annotated[int, Field(strict=True, ge=1)],
|
|
491
|
+
function_id: StrictInt,
|
|
492
|
+
_request_timeout: Union[
|
|
493
|
+
None,
|
|
494
|
+
Annotated[StrictFloat, Field(gt=0)],
|
|
495
|
+
Tuple[
|
|
496
|
+
Annotated[StrictFloat, Field(gt=0)],
|
|
497
|
+
Annotated[StrictFloat, Field(gt=0)]
|
|
498
|
+
]
|
|
499
|
+
] = None,
|
|
500
|
+
_request_auth: Optional[Dict[StrictStr, Any]] = None,
|
|
501
|
+
_content_type: Optional[StrictStr] = None,
|
|
502
|
+
_headers: Optional[Dict[StrictStr, Any]] = None,
|
|
503
|
+
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
|
|
504
|
+
) -> RESTResponseType:
|
|
505
|
+
"""Delete a comment
|
|
506
|
+
|
|
507
|
+
Deletes an existing comment. Users can only delete their own comments.
|
|
508
|
+
|
|
509
|
+
:param comment_id: (required)
|
|
510
|
+
:type comment_id: int
|
|
511
|
+
:param function_id: (required)
|
|
512
|
+
:type function_id: int
|
|
513
|
+
:param _request_timeout: timeout setting for this request. If one
|
|
514
|
+
number provided, it will be total request
|
|
515
|
+
timeout. It can also be a pair (tuple) of
|
|
516
|
+
(connection, read) timeouts.
|
|
517
|
+
:type _request_timeout: int, tuple(int, int), optional
|
|
518
|
+
:param _request_auth: set to override the auth_settings for an a single
|
|
519
|
+
request; this effectively ignores the
|
|
520
|
+
authentication in the spec for a single request.
|
|
521
|
+
:type _request_auth: dict, optional
|
|
522
|
+
:param _content_type: force content-type for the request.
|
|
523
|
+
:type _content_type: str, Optional
|
|
524
|
+
:param _headers: set to override the headers for a single
|
|
525
|
+
request; this effectively ignores the headers
|
|
526
|
+
in the spec for a single request.
|
|
527
|
+
:type _headers: dict, optional
|
|
528
|
+
:param _host_index: set to override the host_index for a single
|
|
529
|
+
request; this effectively ignores the host_index
|
|
530
|
+
in the spec for a single request.
|
|
531
|
+
:type _host_index: int, optional
|
|
532
|
+
:return: Returns the result object.
|
|
533
|
+
""" # noqa: E501
|
|
534
|
+
|
|
535
|
+
_param = self._delete_decompilation_comment_serialize(
|
|
536
|
+
comment_id=comment_id,
|
|
537
|
+
function_id=function_id,
|
|
538
|
+
_request_auth=_request_auth,
|
|
539
|
+
_content_type=_content_type,
|
|
540
|
+
_headers=_headers,
|
|
541
|
+
_host_index=_host_index
|
|
542
|
+
)
|
|
543
|
+
|
|
544
|
+
_response_types_map: Dict[str, Optional[str]] = {
|
|
545
|
+
'200': "BaseResponseBool",
|
|
546
|
+
'422': "BaseResponse",
|
|
547
|
+
'403': "BaseResponse",
|
|
548
|
+
'400': "BaseResponse",
|
|
549
|
+
}
|
|
550
|
+
response_data = self.api_client.call_api(
|
|
551
|
+
*_param,
|
|
552
|
+
_request_timeout=_request_timeout
|
|
553
|
+
)
|
|
554
|
+
return response_data.response
|
|
555
|
+
|
|
556
|
+
|
|
557
|
+
def _delete_decompilation_comment_serialize(
|
|
558
|
+
self,
|
|
559
|
+
comment_id,
|
|
560
|
+
function_id,
|
|
561
|
+
_request_auth,
|
|
562
|
+
_content_type,
|
|
563
|
+
_headers,
|
|
564
|
+
_host_index,
|
|
565
|
+
) -> RequestSerialized:
|
|
566
|
+
|
|
567
|
+
_host = None
|
|
568
|
+
|
|
569
|
+
_collection_formats: Dict[str, str] = {
|
|
570
|
+
}
|
|
571
|
+
|
|
572
|
+
_path_params: Dict[str, str] = {}
|
|
573
|
+
_query_params: List[Tuple[str, str]] = []
|
|
574
|
+
_header_params: Dict[str, Optional[str]] = _headers or {}
|
|
575
|
+
_form_params: List[Tuple[str, str]] = []
|
|
576
|
+
_files: Dict[
|
|
577
|
+
str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
|
|
578
|
+
] = {}
|
|
579
|
+
_body_params: Optional[bytes] = None
|
|
580
|
+
|
|
581
|
+
# process the path parameters
|
|
582
|
+
if comment_id is not None:
|
|
583
|
+
_path_params['comment_id'] = comment_id
|
|
584
|
+
if function_id is not None:
|
|
585
|
+
_path_params['function_id'] = function_id
|
|
586
|
+
# process the query parameters
|
|
587
|
+
# process the header parameters
|
|
588
|
+
# process the form parameters
|
|
589
|
+
# process the body parameter
|
|
590
|
+
|
|
591
|
+
|
|
592
|
+
# set the HTTP header `Accept`
|
|
593
|
+
if 'Accept' not in _header_params:
|
|
594
|
+
_header_params['Accept'] = self.api_client.select_header_accept(
|
|
595
|
+
[
|
|
596
|
+
'application/json'
|
|
597
|
+
]
|
|
598
|
+
)
|
|
599
|
+
|
|
600
|
+
|
|
601
|
+
# authentication setting
|
|
602
|
+
_auth_settings: List[str] = [
|
|
603
|
+
'APIKey'
|
|
604
|
+
]
|
|
605
|
+
|
|
606
|
+
return self.api_client.param_serialize(
|
|
607
|
+
method='DELETE',
|
|
608
|
+
resource_path='/v2/functions/{function_id}/decompilation/comments/{comment_id}',
|
|
609
|
+
path_params=_path_params,
|
|
610
|
+
query_params=_query_params,
|
|
611
|
+
header_params=_header_params,
|
|
612
|
+
body=_body_params,
|
|
613
|
+
post_params=_form_params,
|
|
614
|
+
files=_files,
|
|
615
|
+
auth_settings=_auth_settings,
|
|
616
|
+
collection_formats=_collection_formats,
|
|
617
|
+
_host=_host,
|
|
618
|
+
_request_auth=_request_auth
|
|
619
|
+
)
|
|
620
|
+
|
|
621
|
+
|
|
622
|
+
|
|
623
|
+
|
|
624
|
+
@validate_call
|
|
625
|
+
def get_decompilation_comments(
|
|
626
|
+
self,
|
|
627
|
+
function_id: StrictInt,
|
|
628
|
+
_request_timeout: Union[
|
|
629
|
+
None,
|
|
630
|
+
Annotated[StrictFloat, Field(gt=0)],
|
|
631
|
+
Tuple[
|
|
632
|
+
Annotated[StrictFloat, Field(gt=0)],
|
|
633
|
+
Annotated[StrictFloat, Field(gt=0)]
|
|
634
|
+
]
|
|
635
|
+
] = None,
|
|
636
|
+
_request_auth: Optional[Dict[StrictStr, Any]] = None,
|
|
637
|
+
_content_type: Optional[StrictStr] = None,
|
|
638
|
+
_headers: Optional[Dict[StrictStr, Any]] = None,
|
|
639
|
+
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
|
|
640
|
+
) -> BaseResponseListCommentResponse:
|
|
641
|
+
"""Get comments for this function
|
|
642
|
+
|
|
643
|
+
Retrieves all comments created for a specific function. Only returns comments for resources the requesting user has access to.
|
|
644
|
+
|
|
645
|
+
:param function_id: (required)
|
|
646
|
+
:type function_id: int
|
|
647
|
+
:param _request_timeout: timeout setting for this request. If one
|
|
648
|
+
number provided, it will be total request
|
|
649
|
+
timeout. It can also be a pair (tuple) of
|
|
650
|
+
(connection, read) timeouts.
|
|
651
|
+
:type _request_timeout: int, tuple(int, int), optional
|
|
652
|
+
:param _request_auth: set to override the auth_settings for an a single
|
|
653
|
+
request; this effectively ignores the
|
|
654
|
+
authentication in the spec for a single request.
|
|
655
|
+
:type _request_auth: dict, optional
|
|
656
|
+
:param _content_type: force content-type for the request.
|
|
657
|
+
:type _content_type: str, Optional
|
|
658
|
+
:param _headers: set to override the headers for a single
|
|
659
|
+
request; this effectively ignores the headers
|
|
660
|
+
in the spec for a single request.
|
|
661
|
+
:type _headers: dict, optional
|
|
662
|
+
:param _host_index: set to override the host_index for a single
|
|
663
|
+
request; this effectively ignores the host_index
|
|
664
|
+
in the spec for a single request.
|
|
665
|
+
:type _host_index: int, optional
|
|
666
|
+
:return: Returns the result object.
|
|
667
|
+
""" # noqa: E501
|
|
668
|
+
|
|
669
|
+
_param = self._get_decompilation_comments_serialize(
|
|
670
|
+
function_id=function_id,
|
|
671
|
+
_request_auth=_request_auth,
|
|
672
|
+
_content_type=_content_type,
|
|
673
|
+
_headers=_headers,
|
|
674
|
+
_host_index=_host_index
|
|
675
|
+
)
|
|
676
|
+
|
|
677
|
+
_response_types_map: Dict[str, Optional[str]] = {
|
|
678
|
+
'200': "BaseResponseListCommentResponse",
|
|
679
|
+
'422': "BaseResponse",
|
|
680
|
+
}
|
|
681
|
+
response_data = self.api_client.call_api(
|
|
682
|
+
*_param,
|
|
683
|
+
_request_timeout=_request_timeout
|
|
684
|
+
)
|
|
685
|
+
response_data.read()
|
|
686
|
+
return self.api_client.response_deserialize(
|
|
687
|
+
response_data=response_data,
|
|
688
|
+
response_types_map=_response_types_map,
|
|
689
|
+
).data
|
|
690
|
+
|
|
691
|
+
|
|
692
|
+
@validate_call
|
|
693
|
+
def get_decompilation_comments_with_http_info(
|
|
694
|
+
self,
|
|
695
|
+
function_id: StrictInt,
|
|
696
|
+
_request_timeout: Union[
|
|
697
|
+
None,
|
|
698
|
+
Annotated[StrictFloat, Field(gt=0)],
|
|
699
|
+
Tuple[
|
|
700
|
+
Annotated[StrictFloat, Field(gt=0)],
|
|
701
|
+
Annotated[StrictFloat, Field(gt=0)]
|
|
702
|
+
]
|
|
703
|
+
] = None,
|
|
704
|
+
_request_auth: Optional[Dict[StrictStr, Any]] = None,
|
|
705
|
+
_content_type: Optional[StrictStr] = None,
|
|
706
|
+
_headers: Optional[Dict[StrictStr, Any]] = None,
|
|
707
|
+
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
|
|
708
|
+
) -> ApiResponse[BaseResponseListCommentResponse]:
|
|
709
|
+
"""Get comments for this function
|
|
710
|
+
|
|
711
|
+
Retrieves all comments created for a specific function. Only returns comments for resources the requesting user has access to.
|
|
712
|
+
|
|
713
|
+
:param function_id: (required)
|
|
714
|
+
:type function_id: int
|
|
715
|
+
:param _request_timeout: timeout setting for this request. If one
|
|
716
|
+
number provided, it will be total request
|
|
717
|
+
timeout. It can also be a pair (tuple) of
|
|
718
|
+
(connection, read) timeouts.
|
|
719
|
+
:type _request_timeout: int, tuple(int, int), optional
|
|
720
|
+
:param _request_auth: set to override the auth_settings for an a single
|
|
721
|
+
request; this effectively ignores the
|
|
722
|
+
authentication in the spec for a single request.
|
|
723
|
+
:type _request_auth: dict, optional
|
|
724
|
+
:param _content_type: force content-type for the request.
|
|
725
|
+
:type _content_type: str, Optional
|
|
726
|
+
:param _headers: set to override the headers for a single
|
|
727
|
+
request; this effectively ignores the headers
|
|
728
|
+
in the spec for a single request.
|
|
729
|
+
:type _headers: dict, optional
|
|
730
|
+
:param _host_index: set to override the host_index for a single
|
|
731
|
+
request; this effectively ignores the host_index
|
|
732
|
+
in the spec for a single request.
|
|
733
|
+
:type _host_index: int, optional
|
|
734
|
+
:return: Returns the result object.
|
|
735
|
+
""" # noqa: E501
|
|
736
|
+
|
|
737
|
+
_param = self._get_decompilation_comments_serialize(
|
|
738
|
+
function_id=function_id,
|
|
739
|
+
_request_auth=_request_auth,
|
|
740
|
+
_content_type=_content_type,
|
|
741
|
+
_headers=_headers,
|
|
742
|
+
_host_index=_host_index
|
|
743
|
+
)
|
|
744
|
+
|
|
745
|
+
_response_types_map: Dict[str, Optional[str]] = {
|
|
746
|
+
'200': "BaseResponseListCommentResponse",
|
|
747
|
+
'422': "BaseResponse",
|
|
748
|
+
}
|
|
749
|
+
response_data = self.api_client.call_api(
|
|
750
|
+
*_param,
|
|
751
|
+
_request_timeout=_request_timeout
|
|
752
|
+
)
|
|
753
|
+
response_data.read()
|
|
754
|
+
return self.api_client.response_deserialize(
|
|
755
|
+
response_data=response_data,
|
|
756
|
+
response_types_map=_response_types_map,
|
|
757
|
+
)
|
|
758
|
+
|
|
759
|
+
|
|
760
|
+
@validate_call
|
|
761
|
+
def get_decompilation_comments_without_preload_content(
|
|
762
|
+
self,
|
|
763
|
+
function_id: StrictInt,
|
|
764
|
+
_request_timeout: Union[
|
|
765
|
+
None,
|
|
766
|
+
Annotated[StrictFloat, Field(gt=0)],
|
|
767
|
+
Tuple[
|
|
768
|
+
Annotated[StrictFloat, Field(gt=0)],
|
|
769
|
+
Annotated[StrictFloat, Field(gt=0)]
|
|
770
|
+
]
|
|
771
|
+
] = None,
|
|
772
|
+
_request_auth: Optional[Dict[StrictStr, Any]] = None,
|
|
773
|
+
_content_type: Optional[StrictStr] = None,
|
|
774
|
+
_headers: Optional[Dict[StrictStr, Any]] = None,
|
|
775
|
+
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
|
|
776
|
+
) -> RESTResponseType:
|
|
777
|
+
"""Get comments for this function
|
|
778
|
+
|
|
779
|
+
Retrieves all comments created for a specific function. Only returns comments for resources the requesting user has access to.
|
|
780
|
+
|
|
781
|
+
:param function_id: (required)
|
|
782
|
+
:type function_id: int
|
|
783
|
+
:param _request_timeout: timeout setting for this request. If one
|
|
784
|
+
number provided, it will be total request
|
|
785
|
+
timeout. It can also be a pair (tuple) of
|
|
786
|
+
(connection, read) timeouts.
|
|
787
|
+
:type _request_timeout: int, tuple(int, int), optional
|
|
788
|
+
:param _request_auth: set to override the auth_settings for an a single
|
|
789
|
+
request; this effectively ignores the
|
|
790
|
+
authentication in the spec for a single request.
|
|
791
|
+
:type _request_auth: dict, optional
|
|
792
|
+
:param _content_type: force content-type for the request.
|
|
793
|
+
:type _content_type: str, Optional
|
|
794
|
+
:param _headers: set to override the headers for a single
|
|
795
|
+
request; this effectively ignores the headers
|
|
796
|
+
in the spec for a single request.
|
|
797
|
+
:type _headers: dict, optional
|
|
798
|
+
:param _host_index: set to override the host_index for a single
|
|
799
|
+
request; this effectively ignores the host_index
|
|
800
|
+
in the spec for a single request.
|
|
801
|
+
:type _host_index: int, optional
|
|
802
|
+
:return: Returns the result object.
|
|
803
|
+
""" # noqa: E501
|
|
804
|
+
|
|
805
|
+
_param = self._get_decompilation_comments_serialize(
|
|
806
|
+
function_id=function_id,
|
|
807
|
+
_request_auth=_request_auth,
|
|
808
|
+
_content_type=_content_type,
|
|
809
|
+
_headers=_headers,
|
|
810
|
+
_host_index=_host_index
|
|
811
|
+
)
|
|
812
|
+
|
|
813
|
+
_response_types_map: Dict[str, Optional[str]] = {
|
|
814
|
+
'200': "BaseResponseListCommentResponse",
|
|
815
|
+
'422': "BaseResponse",
|
|
816
|
+
}
|
|
817
|
+
response_data = self.api_client.call_api(
|
|
818
|
+
*_param,
|
|
819
|
+
_request_timeout=_request_timeout
|
|
820
|
+
)
|
|
821
|
+
return response_data.response
|
|
822
|
+
|
|
823
|
+
|
|
824
|
+
def _get_decompilation_comments_serialize(
|
|
825
|
+
self,
|
|
826
|
+
function_id,
|
|
827
|
+
_request_auth,
|
|
828
|
+
_content_type,
|
|
829
|
+
_headers,
|
|
830
|
+
_host_index,
|
|
831
|
+
) -> RequestSerialized:
|
|
832
|
+
|
|
833
|
+
_host = None
|
|
834
|
+
|
|
835
|
+
_collection_formats: Dict[str, str] = {
|
|
836
|
+
}
|
|
837
|
+
|
|
838
|
+
_path_params: Dict[str, str] = {}
|
|
839
|
+
_query_params: List[Tuple[str, str]] = []
|
|
840
|
+
_header_params: Dict[str, Optional[str]] = _headers or {}
|
|
841
|
+
_form_params: List[Tuple[str, str]] = []
|
|
842
|
+
_files: Dict[
|
|
843
|
+
str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
|
|
844
|
+
] = {}
|
|
845
|
+
_body_params: Optional[bytes] = None
|
|
846
|
+
|
|
847
|
+
# process the path parameters
|
|
848
|
+
if function_id is not None:
|
|
849
|
+
_path_params['function_id'] = function_id
|
|
850
|
+
# process the query parameters
|
|
851
|
+
# process the header parameters
|
|
852
|
+
# process the form parameters
|
|
853
|
+
# process the body parameter
|
|
854
|
+
|
|
855
|
+
|
|
856
|
+
# set the HTTP header `Accept`
|
|
857
|
+
if 'Accept' not in _header_params:
|
|
858
|
+
_header_params['Accept'] = self.api_client.select_header_accept(
|
|
859
|
+
[
|
|
860
|
+
'application/json'
|
|
861
|
+
]
|
|
862
|
+
)
|
|
863
|
+
|
|
864
|
+
|
|
865
|
+
# authentication setting
|
|
866
|
+
_auth_settings: List[str] = [
|
|
867
|
+
'APIKey'
|
|
868
|
+
]
|
|
869
|
+
|
|
870
|
+
return self.api_client.param_serialize(
|
|
871
|
+
method='GET',
|
|
872
|
+
resource_path='/v2/functions/{function_id}/decompilation/comments',
|
|
873
|
+
path_params=_path_params,
|
|
874
|
+
query_params=_query_params,
|
|
875
|
+
header_params=_header_params,
|
|
876
|
+
body=_body_params,
|
|
877
|
+
post_params=_form_params,
|
|
878
|
+
files=_files,
|
|
879
|
+
auth_settings=_auth_settings,
|
|
880
|
+
collection_formats=_collection_formats,
|
|
881
|
+
_host=_host,
|
|
882
|
+
_request_auth=_request_auth
|
|
883
|
+
)
|
|
884
|
+
|
|
885
|
+
|
|
886
|
+
|
|
887
|
+
|
|
888
|
+
@validate_call
|
|
889
|
+
def update_decompilation_comment(
|
|
890
|
+
self,
|
|
891
|
+
comment_id: Annotated[int, Field(strict=True, ge=1)],
|
|
892
|
+
function_id: StrictInt,
|
|
893
|
+
comment_update_request: CommentUpdateRequest,
|
|
894
|
+
_request_timeout: Union[
|
|
895
|
+
None,
|
|
896
|
+
Annotated[StrictFloat, Field(gt=0)],
|
|
897
|
+
Tuple[
|
|
898
|
+
Annotated[StrictFloat, Field(gt=0)],
|
|
899
|
+
Annotated[StrictFloat, Field(gt=0)]
|
|
900
|
+
]
|
|
901
|
+
] = None,
|
|
902
|
+
_request_auth: Optional[Dict[StrictStr, Any]] = None,
|
|
903
|
+
_content_type: Optional[StrictStr] = None,
|
|
904
|
+
_headers: Optional[Dict[StrictStr, Any]] = None,
|
|
905
|
+
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
|
|
906
|
+
) -> BaseResponseCommentResponse:
|
|
907
|
+
"""Update a comment
|
|
908
|
+
|
|
909
|
+
Updates the content of an existing comment. Users can only update their own comments.
|
|
910
|
+
|
|
911
|
+
:param comment_id: (required)
|
|
912
|
+
:type comment_id: int
|
|
913
|
+
:param function_id: (required)
|
|
914
|
+
:type function_id: int
|
|
915
|
+
:param comment_update_request: (required)
|
|
916
|
+
:type comment_update_request: CommentUpdateRequest
|
|
917
|
+
:param _request_timeout: timeout setting for this request. If one
|
|
918
|
+
number provided, it will be total request
|
|
919
|
+
timeout. It can also be a pair (tuple) of
|
|
920
|
+
(connection, read) timeouts.
|
|
921
|
+
:type _request_timeout: int, tuple(int, int), optional
|
|
922
|
+
:param _request_auth: set to override the auth_settings for an a single
|
|
923
|
+
request; this effectively ignores the
|
|
924
|
+
authentication in the spec for a single request.
|
|
925
|
+
:type _request_auth: dict, optional
|
|
926
|
+
:param _content_type: force content-type for the request.
|
|
927
|
+
:type _content_type: str, Optional
|
|
928
|
+
:param _headers: set to override the headers for a single
|
|
929
|
+
request; this effectively ignores the headers
|
|
930
|
+
in the spec for a single request.
|
|
931
|
+
:type _headers: dict, optional
|
|
932
|
+
:param _host_index: set to override the host_index for a single
|
|
933
|
+
request; this effectively ignores the host_index
|
|
934
|
+
in the spec for a single request.
|
|
935
|
+
:type _host_index: int, optional
|
|
936
|
+
:return: Returns the result object.
|
|
937
|
+
""" # noqa: E501
|
|
938
|
+
|
|
939
|
+
_param = self._update_decompilation_comment_serialize(
|
|
940
|
+
comment_id=comment_id,
|
|
941
|
+
function_id=function_id,
|
|
942
|
+
comment_update_request=comment_update_request,
|
|
943
|
+
_request_auth=_request_auth,
|
|
944
|
+
_content_type=_content_type,
|
|
945
|
+
_headers=_headers,
|
|
946
|
+
_host_index=_host_index
|
|
947
|
+
)
|
|
948
|
+
|
|
949
|
+
_response_types_map: Dict[str, Optional[str]] = {
|
|
950
|
+
'200': "BaseResponseCommentResponse",
|
|
951
|
+
'422': "BaseResponse",
|
|
952
|
+
'403': "BaseResponse",
|
|
953
|
+
'400': "BaseResponse",
|
|
954
|
+
}
|
|
955
|
+
response_data = self.api_client.call_api(
|
|
956
|
+
*_param,
|
|
957
|
+
_request_timeout=_request_timeout
|
|
958
|
+
)
|
|
959
|
+
response_data.read()
|
|
960
|
+
return self.api_client.response_deserialize(
|
|
961
|
+
response_data=response_data,
|
|
962
|
+
response_types_map=_response_types_map,
|
|
963
|
+
).data
|
|
964
|
+
|
|
965
|
+
|
|
966
|
+
@validate_call
|
|
967
|
+
def update_decompilation_comment_with_http_info(
|
|
968
|
+
self,
|
|
969
|
+
comment_id: Annotated[int, Field(strict=True, ge=1)],
|
|
970
|
+
function_id: StrictInt,
|
|
971
|
+
comment_update_request: CommentUpdateRequest,
|
|
972
|
+
_request_timeout: Union[
|
|
973
|
+
None,
|
|
974
|
+
Annotated[StrictFloat, Field(gt=0)],
|
|
975
|
+
Tuple[
|
|
976
|
+
Annotated[StrictFloat, Field(gt=0)],
|
|
977
|
+
Annotated[StrictFloat, Field(gt=0)]
|
|
978
|
+
]
|
|
979
|
+
] = None,
|
|
980
|
+
_request_auth: Optional[Dict[StrictStr, Any]] = None,
|
|
981
|
+
_content_type: Optional[StrictStr] = None,
|
|
982
|
+
_headers: Optional[Dict[StrictStr, Any]] = None,
|
|
983
|
+
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
|
|
984
|
+
) -> ApiResponse[BaseResponseCommentResponse]:
|
|
985
|
+
"""Update a comment
|
|
986
|
+
|
|
987
|
+
Updates the content of an existing comment. Users can only update their own comments.
|
|
988
|
+
|
|
989
|
+
:param comment_id: (required)
|
|
990
|
+
:type comment_id: int
|
|
991
|
+
:param function_id: (required)
|
|
992
|
+
:type function_id: int
|
|
993
|
+
:param comment_update_request: (required)
|
|
994
|
+
:type comment_update_request: CommentUpdateRequest
|
|
995
|
+
:param _request_timeout: timeout setting for this request. If one
|
|
996
|
+
number provided, it will be total request
|
|
997
|
+
timeout. It can also be a pair (tuple) of
|
|
998
|
+
(connection, read) timeouts.
|
|
999
|
+
:type _request_timeout: int, tuple(int, int), optional
|
|
1000
|
+
:param _request_auth: set to override the auth_settings for an a single
|
|
1001
|
+
request; this effectively ignores the
|
|
1002
|
+
authentication in the spec for a single request.
|
|
1003
|
+
:type _request_auth: dict, optional
|
|
1004
|
+
:param _content_type: force content-type for the request.
|
|
1005
|
+
:type _content_type: str, Optional
|
|
1006
|
+
:param _headers: set to override the headers for a single
|
|
1007
|
+
request; this effectively ignores the headers
|
|
1008
|
+
in the spec for a single request.
|
|
1009
|
+
:type _headers: dict, optional
|
|
1010
|
+
:param _host_index: set to override the host_index for a single
|
|
1011
|
+
request; this effectively ignores the host_index
|
|
1012
|
+
in the spec for a single request.
|
|
1013
|
+
:type _host_index: int, optional
|
|
1014
|
+
:return: Returns the result object.
|
|
1015
|
+
""" # noqa: E501
|
|
1016
|
+
|
|
1017
|
+
_param = self._update_decompilation_comment_serialize(
|
|
1018
|
+
comment_id=comment_id,
|
|
1019
|
+
function_id=function_id,
|
|
1020
|
+
comment_update_request=comment_update_request,
|
|
1021
|
+
_request_auth=_request_auth,
|
|
1022
|
+
_content_type=_content_type,
|
|
1023
|
+
_headers=_headers,
|
|
1024
|
+
_host_index=_host_index
|
|
1025
|
+
)
|
|
1026
|
+
|
|
1027
|
+
_response_types_map: Dict[str, Optional[str]] = {
|
|
1028
|
+
'200': "BaseResponseCommentResponse",
|
|
1029
|
+
'422': "BaseResponse",
|
|
1030
|
+
'403': "BaseResponse",
|
|
1031
|
+
'400': "BaseResponse",
|
|
1032
|
+
}
|
|
1033
|
+
response_data = self.api_client.call_api(
|
|
1034
|
+
*_param,
|
|
1035
|
+
_request_timeout=_request_timeout
|
|
1036
|
+
)
|
|
1037
|
+
response_data.read()
|
|
1038
|
+
return self.api_client.response_deserialize(
|
|
1039
|
+
response_data=response_data,
|
|
1040
|
+
response_types_map=_response_types_map,
|
|
1041
|
+
)
|
|
1042
|
+
|
|
1043
|
+
|
|
1044
|
+
@validate_call
|
|
1045
|
+
def update_decompilation_comment_without_preload_content(
|
|
1046
|
+
self,
|
|
1047
|
+
comment_id: Annotated[int, Field(strict=True, ge=1)],
|
|
1048
|
+
function_id: StrictInt,
|
|
1049
|
+
comment_update_request: CommentUpdateRequest,
|
|
1050
|
+
_request_timeout: Union[
|
|
1051
|
+
None,
|
|
1052
|
+
Annotated[StrictFloat, Field(gt=0)],
|
|
1053
|
+
Tuple[
|
|
1054
|
+
Annotated[StrictFloat, Field(gt=0)],
|
|
1055
|
+
Annotated[StrictFloat, Field(gt=0)]
|
|
1056
|
+
]
|
|
1057
|
+
] = None,
|
|
1058
|
+
_request_auth: Optional[Dict[StrictStr, Any]] = None,
|
|
1059
|
+
_content_type: Optional[StrictStr] = None,
|
|
1060
|
+
_headers: Optional[Dict[StrictStr, Any]] = None,
|
|
1061
|
+
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
|
|
1062
|
+
) -> RESTResponseType:
|
|
1063
|
+
"""Update a comment
|
|
1064
|
+
|
|
1065
|
+
Updates the content of an existing comment. Users can only update their own comments.
|
|
1066
|
+
|
|
1067
|
+
:param comment_id: (required)
|
|
1068
|
+
:type comment_id: int
|
|
1069
|
+
:param function_id: (required)
|
|
1070
|
+
:type function_id: int
|
|
1071
|
+
:param comment_update_request: (required)
|
|
1072
|
+
:type comment_update_request: CommentUpdateRequest
|
|
1073
|
+
:param _request_timeout: timeout setting for this request. If one
|
|
1074
|
+
number provided, it will be total request
|
|
1075
|
+
timeout. It can also be a pair (tuple) of
|
|
1076
|
+
(connection, read) timeouts.
|
|
1077
|
+
:type _request_timeout: int, tuple(int, int), optional
|
|
1078
|
+
:param _request_auth: set to override the auth_settings for an a single
|
|
1079
|
+
request; this effectively ignores the
|
|
1080
|
+
authentication in the spec for a single request.
|
|
1081
|
+
:type _request_auth: dict, optional
|
|
1082
|
+
:param _content_type: force content-type for the request.
|
|
1083
|
+
:type _content_type: str, Optional
|
|
1084
|
+
:param _headers: set to override the headers for a single
|
|
1085
|
+
request; this effectively ignores the headers
|
|
1086
|
+
in the spec for a single request.
|
|
1087
|
+
:type _headers: dict, optional
|
|
1088
|
+
:param _host_index: set to override the host_index for a single
|
|
1089
|
+
request; this effectively ignores the host_index
|
|
1090
|
+
in the spec for a single request.
|
|
1091
|
+
:type _host_index: int, optional
|
|
1092
|
+
:return: Returns the result object.
|
|
1093
|
+
""" # noqa: E501
|
|
1094
|
+
|
|
1095
|
+
_param = self._update_decompilation_comment_serialize(
|
|
1096
|
+
comment_id=comment_id,
|
|
1097
|
+
function_id=function_id,
|
|
1098
|
+
comment_update_request=comment_update_request,
|
|
1099
|
+
_request_auth=_request_auth,
|
|
1100
|
+
_content_type=_content_type,
|
|
1101
|
+
_headers=_headers,
|
|
1102
|
+
_host_index=_host_index
|
|
1103
|
+
)
|
|
1104
|
+
|
|
1105
|
+
_response_types_map: Dict[str, Optional[str]] = {
|
|
1106
|
+
'200': "BaseResponseCommentResponse",
|
|
1107
|
+
'422': "BaseResponse",
|
|
1108
|
+
'403': "BaseResponse",
|
|
1109
|
+
'400': "BaseResponse",
|
|
1110
|
+
}
|
|
1111
|
+
response_data = self.api_client.call_api(
|
|
1112
|
+
*_param,
|
|
1113
|
+
_request_timeout=_request_timeout
|
|
1114
|
+
)
|
|
1115
|
+
return response_data.response
|
|
1116
|
+
|
|
1117
|
+
|
|
1118
|
+
def _update_decompilation_comment_serialize(
|
|
1119
|
+
self,
|
|
1120
|
+
comment_id,
|
|
1121
|
+
function_id,
|
|
1122
|
+
comment_update_request,
|
|
1123
|
+
_request_auth,
|
|
1124
|
+
_content_type,
|
|
1125
|
+
_headers,
|
|
1126
|
+
_host_index,
|
|
1127
|
+
) -> RequestSerialized:
|
|
1128
|
+
|
|
1129
|
+
_host = None
|
|
1130
|
+
|
|
1131
|
+
_collection_formats: Dict[str, str] = {
|
|
1132
|
+
}
|
|
1133
|
+
|
|
1134
|
+
_path_params: Dict[str, str] = {}
|
|
1135
|
+
_query_params: List[Tuple[str, str]] = []
|
|
1136
|
+
_header_params: Dict[str, Optional[str]] = _headers or {}
|
|
1137
|
+
_form_params: List[Tuple[str, str]] = []
|
|
1138
|
+
_files: Dict[
|
|
1139
|
+
str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
|
|
1140
|
+
] = {}
|
|
1141
|
+
_body_params: Optional[bytes] = None
|
|
1142
|
+
|
|
1143
|
+
# process the path parameters
|
|
1144
|
+
if comment_id is not None:
|
|
1145
|
+
_path_params['comment_id'] = comment_id
|
|
1146
|
+
if function_id is not None:
|
|
1147
|
+
_path_params['function_id'] = function_id
|
|
1148
|
+
# process the query parameters
|
|
1149
|
+
# process the header parameters
|
|
1150
|
+
# process the form parameters
|
|
1151
|
+
# process the body parameter
|
|
1152
|
+
if comment_update_request is not None:
|
|
1153
|
+
_body_params = comment_update_request
|
|
1154
|
+
|
|
1155
|
+
|
|
1156
|
+
# set the HTTP header `Accept`
|
|
1157
|
+
if 'Accept' not in _header_params:
|
|
1158
|
+
_header_params['Accept'] = self.api_client.select_header_accept(
|
|
1159
|
+
[
|
|
1160
|
+
'application/json'
|
|
1161
|
+
]
|
|
1162
|
+
)
|
|
1163
|
+
|
|
1164
|
+
# set the HTTP header `Content-Type`
|
|
1165
|
+
if _content_type:
|
|
1166
|
+
_header_params['Content-Type'] = _content_type
|
|
1167
|
+
else:
|
|
1168
|
+
_default_content_type = (
|
|
1169
|
+
self.api_client.select_header_content_type(
|
|
1170
|
+
[
|
|
1171
|
+
'application/json'
|
|
1172
|
+
]
|
|
1173
|
+
)
|
|
1174
|
+
)
|
|
1175
|
+
if _default_content_type is not None:
|
|
1176
|
+
_header_params['Content-Type'] = _default_content_type
|
|
1177
|
+
|
|
1178
|
+
# authentication setting
|
|
1179
|
+
_auth_settings: List[str] = [
|
|
1180
|
+
'APIKey'
|
|
1181
|
+
]
|
|
1182
|
+
|
|
1183
|
+
return self.api_client.param_serialize(
|
|
1184
|
+
method='PATCH',
|
|
1185
|
+
resource_path='/v2/functions/{function_id}/decompilation/comments/{comment_id}',
|
|
1186
|
+
path_params=_path_params,
|
|
1187
|
+
query_params=_query_params,
|
|
1188
|
+
header_params=_header_params,
|
|
1189
|
+
body=_body_params,
|
|
1190
|
+
post_params=_form_params,
|
|
1191
|
+
files=_files,
|
|
1192
|
+
auth_settings=_auth_settings,
|
|
1193
|
+
collection_formats=_collection_formats,
|
|
1194
|
+
_host=_host,
|
|
1195
|
+
_request_auth=_request_auth
|
|
1196
|
+
)
|
|
1197
|
+
|
|
1198
|
+
|