restpki-ng-python-client 0.9.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.
- restpki_ng_python_client/__init__.py +200 -0
- restpki_ng_python_client/api/__init__.py +17 -0
- restpki_ng_python_client/api/authentication_api.py +2041 -0
- restpki_ng_python_client/api/cades_signature_api.py +2376 -0
- restpki_ng_python_client/api/document_keys_api.py +1199 -0
- restpki_ng_python_client/api/documents_api.py +868 -0
- restpki_ng_python_client/api/pades_signature_api.py +1797 -0
- restpki_ng_python_client/api/pades_visual_positioning_presets_api.py +869 -0
- restpki_ng_python_client/api/pdf_api.py +334 -0
- restpki_ng_python_client/api/signature_api.py +624 -0
- restpki_ng_python_client/api/signature_inspection_api.py +337 -0
- restpki_ng_python_client/api/signature_sessions_api.py +891 -0
- restpki_ng_python_client/api/timestamp_api.py +654 -0
- restpki_ng_python_client/api/upload_api.py +1124 -0
- restpki_ng_python_client/api/xml_signature_api.py +1781 -0
- restpki_ng_python_client/api_client.py +741 -0
- restpki_ng_python_client/api_response.py +21 -0
- restpki_ng_python_client/configuration.py +426 -0
- restpki_ng_python_client/exceptions.py +166 -0
- restpki_ng_python_client/file_utils.py +122 -0
- restpki_ng_python_client/models/__init__.py +165 -0
- restpki_ng_python_client/models/allocate_document_key_batch_request.py +96 -0
- restpki_ng_python_client/models/allocate_document_key_request.py +93 -0
- restpki_ng_python_client/models/attribute_certificate_model.py +141 -0
- restpki_ng_python_client/models/audit_package_options.py +90 -0
- restpki_ng_python_client/models/authentication_failures.py +45 -0
- restpki_ng_python_client/models/authentication_get_response.py +92 -0
- restpki_ng_python_client/models/authentication_post_request.py +116 -0
- restpki_ng_python_client/models/authentication_post_response.py +98 -0
- restpki_ng_python_client/models/authentications_post_request.py +95 -0
- restpki_ng_python_client/models/authentications_post_response.py +114 -0
- restpki_ng_python_client/models/authentications_post_signed_bytes_request.py +99 -0
- restpki_ng_python_client/models/authentications_post_signed_bytes_response.py +98 -0
- restpki_ng_python_client/models/auto_positioning_horizontal_directions.py +45 -0
- restpki_ng_python_client/models/auto_positioning_vertical_directions.py +45 -0
- restpki_ng_python_client/models/blockchains.py +45 -0
- restpki_ng_python_client/models/cades_signature_model.py +123 -0
- restpki_ng_python_client/models/cades_signature_post_request_v1.py +137 -0
- restpki_ng_python_client/models/cades_signature_post_request_v2.py +152 -0
- restpki_ng_python_client/models/cades_signature_post_request_v3.py +149 -0
- restpki_ng_python_client/models/cades_signature_post_response.py +120 -0
- restpki_ng_python_client/models/cades_signature_post_signed_bytes_request.py +92 -0
- restpki_ng_python_client/models/cades_signature_post_signed_bytes_response.py +106 -0
- restpki_ng_python_client/models/cades_signer_model.py +159 -0
- restpki_ng_python_client/models/cades_timestamp_model.py +140 -0
- restpki_ng_python_client/models/certificate_model.py +197 -0
- restpki_ng_python_client/models/certificate_reference_model.py +99 -0
- restpki_ng_python_client/models/certificate_requirement.py +95 -0
- restpki_ng_python_client/models/certificate_requirement_types.py +45 -0
- restpki_ng_python_client/models/certificate_summary.py +142 -0
- restpki_ng_python_client/models/certified_attribute_model.py +94 -0
- restpki_ng_python_client/models/certified_attribute_types.py +44 -0
- restpki_ng_python_client/models/cms_content_types.py +50 -0
- restpki_ng_python_client/models/cms_signature_options.py +109 -0
- restpki_ng_python_client/models/color_model.py +98 -0
- restpki_ng_python_client/models/commitment_type_model.py +99 -0
- restpki_ng_python_client/models/complete_authentication_request.py +93 -0
- restpki_ng_python_client/models/complete_authentication_response.py +103 -0
- restpki_ng_python_client/models/complete_signature_request.py +95 -0
- restpki_ng_python_client/models/complete_signature_request_v2.py +91 -0
- restpki_ng_python_client/models/create_signature_session_request.py +161 -0
- restpki_ng_python_client/models/create_signature_session_response.py +95 -0
- restpki_ng_python_client/models/digest_algorithm_and_value_model.py +103 -0
- restpki_ng_python_client/models/digest_algorithms.py +49 -0
- restpki_ng_python_client/models/document_file_model.py +137 -0
- restpki_ng_python_client/models/document_key_model.py +100 -0
- restpki_ng_python_client/models/document_key_query_response.py +110 -0
- restpki_ng_python_client/models/document_key_summary.py +100 -0
- restpki_ng_python_client/models/document_model.py +150 -0
- restpki_ng_python_client/models/document_query_response.py +93 -0
- restpki_ng_python_client/models/document_status.py +47 -0
- restpki_ng_python_client/models/document_summary.py +128 -0
- restpki_ng_python_client/models/error_model_v2.py +120 -0
- restpki_ng_python_client/models/file_model.py +114 -0
- restpki_ng_python_client/models/file_reference_model.py +137 -0
- restpki_ng_python_client/models/full_xml_signature_post_request.py +136 -0
- restpki_ng_python_client/models/general_name_choices.py +52 -0
- restpki_ng_python_client/models/general_name_model.py +108 -0
- restpki_ng_python_client/models/holder_types.py +45 -0
- restpki_ng_python_client/models/inspect_signature_failures.py +44 -0
- restpki_ng_python_client/models/inspect_signature_request.py +127 -0
- restpki_ng_python_client/models/inspect_signature_response.py +131 -0
- restpki_ng_python_client/models/multipart_upload_begin_response.py +95 -0
- restpki_ng_python_client/models/multipart_upload_end_request.py +95 -0
- restpki_ng_python_client/models/name_model.py +205 -0
- restpki_ng_python_client/models/namespace_model.py +99 -0
- restpki_ng_python_client/models/open_cades_signature_request_model.py +147 -0
- restpki_ng_python_client/models/open_signature_request_model.py +145 -0
- restpki_ng_python_client/models/open_xml_signature_request_model.py +151 -0
- restpki_ng_python_client/models/other_name_model.py +107 -0
- restpki_ng_python_client/models/pades_certification_level.py +47 -0
- restpki_ng_python_client/models/pades_horizontal_align.py +46 -0
- restpki_ng_python_client/models/pades_measurement_units.py +45 -0
- restpki_ng_python_client/models/pades_page_optimization_model.py +98 -0
- restpki_ng_python_client/models/pades_signature_model.py +113 -0
- restpki_ng_python_client/models/pades_signature_post_request_v1.py +167 -0
- restpki_ng_python_client/models/pades_signature_post_request_v2.py +171 -0
- restpki_ng_python_client/models/pades_signature_post_response.py +120 -0
- restpki_ng_python_client/models/pades_signature_post_signed_bytes_request.py +92 -0
- restpki_ng_python_client/models/pades_signature_post_signed_bytes_response.py +106 -0
- restpki_ng_python_client/models/pades_signer_model.py +168 -0
- restpki_ng_python_client/models/pades_size_model.py +89 -0
- restpki_ng_python_client/models/pades_text_horizontal_align.py +45 -0
- restpki_ng_python_client/models/pades_vertical_align.py +46 -0
- restpki_ng_python_client/models/pades_visual_auto_positioning_model.py +106 -0
- restpki_ng_python_client/models/pades_visual_image_model.py +105 -0
- restpki_ng_python_client/models/pades_visual_positioning_model.py +109 -0
- restpki_ng_python_client/models/pades_visual_rectangle_model.py +127 -0
- restpki_ng_python_client/models/pades_visual_representation_model.py +103 -0
- restpki_ng_python_client/models/pades_visual_text_model.py +111 -0
- restpki_ng_python_client/models/page_orientations.py +46 -0
- restpki_ng_python_client/models/paper_sizes.py +56 -0
- restpki_ng_python_client/models/pdf_add_marks_request.py +117 -0
- restpki_ng_python_client/models/pdf_add_marks_response.py +91 -0
- restpki_ng_python_client/models/pdf_container_definition.py +208 -0
- restpki_ng_python_client/models/pdf_helper.py +43 -0
- restpki_ng_python_client/models/pdf_mark_element_model.py +230 -0
- restpki_ng_python_client/models/pdf_mark_element_type.py +46 -0
- restpki_ng_python_client/models/pdf_mark_image_model.py +98 -0
- restpki_ng_python_client/models/pdf_mark_model.py +168 -0
- restpki_ng_python_client/models/pdf_mark_page_options.py +47 -0
- restpki_ng_python_client/models/pdf_signature_options.py +101 -0
- restpki_ng_python_client/models/pdf_text_section_model.py +125 -0
- restpki_ng_python_client/models/pdf_text_style.py +46 -0
- restpki_ng_python_client/models/pki_brazil_certificate_model.py +159 -0
- restpki_ng_python_client/models/pki_brazil_certificate_types.py +54 -0
- restpki_ng_python_client/models/pki_italy_certificate_model.py +103 -0
- restpki_ng_python_client/models/pki_italy_certificate_types.py +46 -0
- restpki_ng_python_client/models/prepare_authentication_request.py +100 -0
- restpki_ng_python_client/models/prepare_authentication_response.py +99 -0
- restpki_ng_python_client/models/prepare_signature_failures.py +46 -0
- restpki_ng_python_client/models/prepare_signature_request.py +133 -0
- restpki_ng_python_client/models/prepare_signature_response.py +116 -0
- restpki_ng_python_client/models/resource_content_or_reference.py +107 -0
- restpki_ng_python_client/models/role_attribute_model.py +114 -0
- restpki_ng_python_client/models/session_completion_status.py +89 -0
- restpki_ng_python_client/models/signature_algorithm_and_value_model.py +106 -0
- restpki_ng_python_client/models/signature_algorithm_identifier.py +88 -0
- restpki_ng_python_client/models/signature_algorithms.py +48 -0
- restpki_ng_python_client/models/signature_b_stamp_model.py +135 -0
- restpki_ng_python_client/models/signature_policy_identifier_model.py +105 -0
- restpki_ng_python_client/models/signature_result_model.py +105 -0
- restpki_ng_python_client/models/signature_session_document_data.py +128 -0
- restpki_ng_python_client/models/signature_session_document_summary.py +138 -0
- restpki_ng_python_client/models/signature_session_model.py +126 -0
- restpki_ng_python_client/models/signature_session_status.py +49 -0
- restpki_ng_python_client/models/signature_types.py +46 -0
- restpki_ng_python_client/models/signer_b_stamp_model.py +132 -0
- restpki_ng_python_client/models/signer_model.py +187 -0
- restpki_ng_python_client/models/signer_summary.py +94 -0
- restpki_ng_python_client/models/timestamp_issue_response.py +99 -0
- restpki_ng_python_client/models/validation_item_model.py +111 -0
- restpki_ng_python_client/models/validation_item_types.py +91 -0
- restpki_ng_python_client/models/validation_results_model.py +131 -0
- restpki_ng_python_client/models/webhook_event_model.py +94 -0
- restpki_ng_python_client/models/webhook_event_types.py +44 -0
- restpki_ng_python_client/models/xml_attribute_model.py +107 -0
- restpki_ng_python_client/models/xml_element_location_model.py +111 -0
- restpki_ng_python_client/models/xml_element_model.py +115 -0
- restpki_ng_python_client/models/xml_element_signature_post_request.py +145 -0
- restpki_ng_python_client/models/xml_id_attribute_model.py +96 -0
- restpki_ng_python_client/models/xml_id_resolution_table_model.py +123 -0
- restpki_ng_python_client/models/xml_insertion_options.py +47 -0
- restpki_ng_python_client/models/xml_node_name_model.py +96 -0
- restpki_ng_python_client/models/xml_signature_model.py +154 -0
- restpki_ng_python_client/models/xml_signature_options.py +102 -0
- restpki_ng_python_client/models/xml_signature_post_response.py +120 -0
- restpki_ng_python_client/models/xml_signature_post_signed_bytes_request.py +92 -0
- restpki_ng_python_client/models/xml_signature_post_signed_bytes_response.py +106 -0
- restpki_ng_python_client/models/xml_signature_response_model.py +113 -0
- restpki_ng_python_client/models/xml_signature_types.py +47 -0
- restpki_ng_python_client/models/xml_signed_entity_types.py +46 -0
- restpki_ng_python_client/py.typed +0 -0
- restpki_ng_python_client/rest.py +231 -0
- restpki_ng_python_client/restpki_ng_client.py +458 -0
- restpki_ng_python_client/standard_signature_policies.py +24 -0
- restpki_ng_python_client/utils.py +80 -0
- restpki_ng_python_client-0.9.0.dist-info/METADATA +16 -0
- restpki_ng_python_client-0.9.0.dist-info/RECORD +181 -0
- restpki_ng_python_client-0.9.0.dist-info/WHEEL +5 -0
- restpki_ng_python_client-0.9.0.dist-info/top_level.txt +1 -0
|
@@ -0,0 +1,1199 @@
|
|
|
1
|
+
# coding: utf-8
|
|
2
|
+
|
|
3
|
+
"""
|
|
4
|
+
Rest PKI Core API
|
|
5
|
+
|
|
6
|
+
<b><i>Para Português, <a href=\"https://docs.lacunasoftware.com/pt-br/articles/rest-pki/core/integration/get-started\">clique aqui</a></i></b> <p> <a href=\"https://docs.lacunasoftware.com/en-us/articles/rest-pki/core/\">Rest PKI Core</a> is an upcoming version of <a href=\"https://docs.lacunasoftware.com/en-us/articles/rest-pki/\">Rest PKI</a> that will have extended compatibility with environments and databases. </p> <p> In addition to Windows Server (which is already supported by Rest PKI), Rest PKI Core will also run on <b>Linux</b> (Debian- and RedHat-based distributions) and on <b>Docker</b>. As for database servers, in addition to SQL Server, <b>PostgreSQL</b> will also be supported. </p> <p> <b>Before getting started, see the integration overview on the <a href=\"https://docs.lacunasoftware.com/en-us/articles/rest-pki/core/integration/\">Integration Guide</a></b> </p> <p> For questions regarding the usage of this API, please reach us at <a href=\"https://lacuna.help/\">lacuna.help</a> </p> <h2>Parameters</h2> <p> You will need the following parameters: </p> <ul> <li><b>Endpoint</b>: address of the Rest PKI Core instance that will be used</li> <li><b>API Key</b>: authorization key for using the API</li> </ul> <p> The <span class=\"model\">endpoint</span> must be prefixed to all relative URLs mentioned here. As for the <span class=\"model\">API Key</span>, see how to use it below. </p> <h2>Authentication</h2> <p> The API key must be sent on the <span class=\"model\">X-Api-Key</span> header on each request: </p> <!-- unfortunately, class \"example microlight\" doesn't seem to work here --> <pre style=\"font-size: 12px; padding: 10px; border-radius: 4px; background: #41444e; font-weight: 600; color: #fff;\"> X-Api-Key: yourapp|xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx </pre> <h2>HTTP Codes</h2> <p> The APIs will return the following HTTP codes: </p> <table> <thead> <tr> <th>Code</th> <th>Description</th> </tr> </thead> <tbody> <tr> <td><strong class=\"model-title\">200 (OK)</strong></td> <td>Request processed successfully. The response is different for each API, please refer to the operation's documentation</td> </tr> <tr> <td><strong class=\"model-title\">400 (Bad Request)</strong></td> <td>Syntax error. For instance, when a required field was not provided</td> </tr> <tr> <td><strong class=\"model-title\">401 (Unauthorized)</strong></td> <td>API key not provided or invalid</td> </tr> <tr> <td><strong class=\"model-title\">403 (Forbidden)</strong></td> <td>API key is valid, but the application has insufficient permissions to complete the requested operation</td> </tr> <tr> <td><strong class=\"model-title\">422 (Unprocessable Entity)</strong></td> <td>API error. The response body is an <a href=\"#model-ErrorModelV2\" class=\"model\">ErrorModelV2</a> </tr> <tr> <td><strong class=\"model-title\">500 (Internal Server Error)</strong></td> <td>An unexpected error occurred. The <span class=\"model\">exceptionCode</span> contained on the response body may be of help for our support team during diagnostic.</td> </tr> </tbody> </table> <h3>Error Codes</h3> <p> Some of the error codes returned in the <span class=\"model\">code</span> field of an <a href=\"#model-ErrorModelV2\" class=\"model\">ErrorModelV2</a> (body of responses with HTTP status code 422) are provided below*: </p> <table> <thead> <tr> <th>Code</th> <th>Description</th> </tr> </thead> <tbody> <tr> <td class=\"model\">DocumentNotFound</td> <td>A referenced document was not found (check the document ID)</td> </tr> <tr> <td class=\"model\">SecurityContextNotFound</td> <td>A referenced security context was not found (check the security context ID)</td> </tr> <tr> <td class=\"model\">SignatureSessionNotFound</td> <td>A referenced signature session was not found (check the signature session ID)</td> </tr> <tr> <td class=\"model\">BadSignatureSessionOperation</td> <td>The operation is invalid for the current signature session or document status. For instance, trying to await the session's completion if it is still <span class=\"model\">Pending</span> results in this error</td> </tr> <tr> <td class=\"model\">BackgroundProcessing</td> <td>The operation cannot be completed at this time because the resource is being processed in background</td> </tr> <tr> <td class=\"model\">SignatureSessionTokenRequired</td> <td>The signature session token was not passed on the <span class=\"model\">X-Signature-Session-Token</span> request header</td> </tr> <tr> <td class=\"model\">BadSignatureSessionToken</td> <td>An invalid signature session token was passed on the <span class=\"model\">X-Signature-Session-Token</span> request header. Check your application for possible corruption of the session token, which may contain characters <span class=\"code\">-</span> (hyphen) and <span class=\"code\">_</span> (underscore)</td> </tr> <tr> <td class=\"model\">ExpiredSignatureSessionToken</td> <td>An expired signature session token was passed on the <span class=\"model\">X-Signature-Session-Token</span> request header. Signature session tokens are normally valid for 4 hours.</td> </tr> </tbody> </table> <p style=\"font-size: 0.9em\"> *The codes shown above are the most common error codes. Nonetheless, this list is not comprehensive. New codes may be added anytime without previous warning. </p> <h2>Culture / Internationalization (i18n)</h2> <p>The <span class=\"model\">Accept-Language</span> request header is observed by this API. The following cultures are supported:</p> <ul> <li><span class=\"code\">en-US</span> (or simply <span class=\"code\">en</span>)</li> <li><span class=\"code\">pt-BR</span> (or simply <span class=\"code\">pt</span>)</li> </ul> <p><i>Notice: error messages are not affected by this header and therefore should not be displayed to users, being better suited for logging.</i></p>
|
|
7
|
+
|
|
8
|
+
The version of the OpenAPI document: 2.1.2
|
|
9
|
+
Generated by OpenAPI Generator (https://openapi-generator.tech)
|
|
10
|
+
|
|
11
|
+
Do not edit the class manually.
|
|
12
|
+
""" # noqa: E501
|
|
13
|
+
|
|
14
|
+
|
|
15
|
+
import io
|
|
16
|
+
import warnings
|
|
17
|
+
|
|
18
|
+
from pydantic import validate_call, Field, StrictFloat, StrictStr, StrictInt
|
|
19
|
+
from typing import Dict, List, Optional, Tuple, Union, Any
|
|
20
|
+
|
|
21
|
+
try:
|
|
22
|
+
from typing import Annotated
|
|
23
|
+
except ImportError:
|
|
24
|
+
from typing_extensions import Annotated
|
|
25
|
+
|
|
26
|
+
from pydantic import StrictStr
|
|
27
|
+
|
|
28
|
+
from typing import List, Optional
|
|
29
|
+
|
|
30
|
+
from restpki_ng_python_client.models.allocate_document_key_batch_request import AllocateDocumentKeyBatchRequest
|
|
31
|
+
from restpki_ng_python_client.models.allocate_document_key_request import AllocateDocumentKeyRequest
|
|
32
|
+
from restpki_ng_python_client.models.document_key_model import DocumentKeyModel
|
|
33
|
+
from restpki_ng_python_client.models.document_key_query_response import DocumentKeyQueryResponse
|
|
34
|
+
from restpki_ng_python_client.models.document_key_summary import DocumentKeySummary
|
|
35
|
+
|
|
36
|
+
from restpki_ng_python_client.api_client import ApiClient
|
|
37
|
+
from restpki_ng_python_client.api_response import ApiResponse
|
|
38
|
+
from restpki_ng_python_client.rest import RESTResponseType
|
|
39
|
+
|
|
40
|
+
|
|
41
|
+
class DocumentKeysApi:
|
|
42
|
+
"""NOTE: This class is auto generated by OpenAPI Generator
|
|
43
|
+
Ref: https://openapi-generator.tech
|
|
44
|
+
|
|
45
|
+
Do not edit the class manually.
|
|
46
|
+
"""
|
|
47
|
+
|
|
48
|
+
def __init__(self, api_client=None) -> None:
|
|
49
|
+
if api_client is None:
|
|
50
|
+
api_client = ApiClient.get_default()
|
|
51
|
+
self.api_client = api_client
|
|
52
|
+
|
|
53
|
+
|
|
54
|
+
@validate_call
|
|
55
|
+
def api_document_keys_batch_post(
|
|
56
|
+
self,
|
|
57
|
+
allocate_document_key_batch_request: Optional[AllocateDocumentKeyBatchRequest] = None,
|
|
58
|
+
_request_timeout: Union[
|
|
59
|
+
None,
|
|
60
|
+
Annotated[StrictFloat, Field(gt=0)],
|
|
61
|
+
Tuple[
|
|
62
|
+
Annotated[StrictFloat, Field(gt=0)],
|
|
63
|
+
Annotated[StrictFloat, Field(gt=0)]
|
|
64
|
+
]
|
|
65
|
+
] = None,
|
|
66
|
+
_request_auth: Optional[Dict[StrictStr, Any]] = None,
|
|
67
|
+
_content_type: Optional[StrictStr] = None,
|
|
68
|
+
_headers: Optional[Dict[StrictStr, Any]] = None,
|
|
69
|
+
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
|
|
70
|
+
) -> List[DocumentKeyModel]:
|
|
71
|
+
"""Allocates a batch of document keys to be used later on document signatures
|
|
72
|
+
|
|
73
|
+
At most 100 keys may be allocated on each request. Limitations on the total number of unused document keys allocated may apply.
|
|
74
|
+
|
|
75
|
+
:param allocate_document_key_batch_request:
|
|
76
|
+
:type allocate_document_key_batch_request: AllocateDocumentKeyBatchRequest
|
|
77
|
+
:param _request_timeout: timeout setting for this request. If one
|
|
78
|
+
number provided, it will be total request
|
|
79
|
+
timeout. It can also be a pair (tuple) of
|
|
80
|
+
(connection, read) timeouts.
|
|
81
|
+
:type _request_timeout: int, tuple(int, int), optional
|
|
82
|
+
:param _request_auth: set to override the auth_settings for an a single
|
|
83
|
+
request; this effectively ignores the
|
|
84
|
+
authentication in the spec for a single request.
|
|
85
|
+
:type _request_auth: dict, optional
|
|
86
|
+
:param _content_type: force content-type for the request.
|
|
87
|
+
:type _content_type: str, Optional
|
|
88
|
+
:param _headers: set to override the headers for a single
|
|
89
|
+
request; this effectively ignores the headers
|
|
90
|
+
in the spec for a single request.
|
|
91
|
+
:type _headers: dict, optional
|
|
92
|
+
:param _host_index: set to override the host_index for a single
|
|
93
|
+
request; this effectively ignores the host_index
|
|
94
|
+
in the spec for a single request.
|
|
95
|
+
:type _host_index: int, optional
|
|
96
|
+
:return: Returns the result object.
|
|
97
|
+
""" # noqa: E501
|
|
98
|
+
|
|
99
|
+
_param = self._api_document_keys_batch_post_serialize(
|
|
100
|
+
allocate_document_key_batch_request=allocate_document_key_batch_request,
|
|
101
|
+
_request_auth=_request_auth,
|
|
102
|
+
_content_type=_content_type,
|
|
103
|
+
_headers=_headers,
|
|
104
|
+
_host_index=_host_index
|
|
105
|
+
)
|
|
106
|
+
|
|
107
|
+
_response_types_map: Dict[str, Optional[str]] = {
|
|
108
|
+
'200': "List[DocumentKeyModel]",
|
|
109
|
+
'400': None,
|
|
110
|
+
'401': None,
|
|
111
|
+
'403': None,
|
|
112
|
+
'422': None
|
|
113
|
+
|
|
114
|
+
}
|
|
115
|
+
response_data = self.api_client.call_api(
|
|
116
|
+
*_param,
|
|
117
|
+
_request_timeout=_request_timeout
|
|
118
|
+
)
|
|
119
|
+
response_data.read()
|
|
120
|
+
return self.api_client.response_deserialize(
|
|
121
|
+
response_data=response_data,
|
|
122
|
+
response_types_map=_response_types_map,
|
|
123
|
+
).data
|
|
124
|
+
|
|
125
|
+
|
|
126
|
+
@validate_call
|
|
127
|
+
def api_document_keys_batch_post_with_http_info(
|
|
128
|
+
self,
|
|
129
|
+
allocate_document_key_batch_request: Optional[AllocateDocumentKeyBatchRequest] = None,
|
|
130
|
+
_request_timeout: Union[
|
|
131
|
+
None,
|
|
132
|
+
Annotated[StrictFloat, Field(gt=0)],
|
|
133
|
+
Tuple[
|
|
134
|
+
Annotated[StrictFloat, Field(gt=0)],
|
|
135
|
+
Annotated[StrictFloat, Field(gt=0)]
|
|
136
|
+
]
|
|
137
|
+
] = None,
|
|
138
|
+
_request_auth: Optional[Dict[StrictStr, Any]] = None,
|
|
139
|
+
_content_type: Optional[StrictStr] = None,
|
|
140
|
+
_headers: Optional[Dict[StrictStr, Any]] = None,
|
|
141
|
+
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
|
|
142
|
+
) -> ApiResponse[List[DocumentKeyModel]]:
|
|
143
|
+
"""Allocates a batch of document keys to be used later on document signatures
|
|
144
|
+
|
|
145
|
+
At most 100 keys may be allocated on each request. Limitations on the total number of unused document keys allocated may apply.
|
|
146
|
+
|
|
147
|
+
:param allocate_document_key_batch_request:
|
|
148
|
+
:type allocate_document_key_batch_request: AllocateDocumentKeyBatchRequest
|
|
149
|
+
:param _request_timeout: timeout setting for this request. If one
|
|
150
|
+
number provided, it will be total request
|
|
151
|
+
timeout. It can also be a pair (tuple) of
|
|
152
|
+
(connection, read) timeouts.
|
|
153
|
+
:type _request_timeout: int, tuple(int, int), optional
|
|
154
|
+
:param _request_auth: set to override the auth_settings for an a single
|
|
155
|
+
request; this effectively ignores the
|
|
156
|
+
authentication in the spec for a single request.
|
|
157
|
+
:type _request_auth: dict, optional
|
|
158
|
+
:param _content_type: force content-type for the request.
|
|
159
|
+
:type _content_type: str, Optional
|
|
160
|
+
:param _headers: set to override the headers for a single
|
|
161
|
+
request; this effectively ignores the headers
|
|
162
|
+
in the spec for a single request.
|
|
163
|
+
:type _headers: dict, optional
|
|
164
|
+
:param _host_index: set to override the host_index for a single
|
|
165
|
+
request; this effectively ignores the host_index
|
|
166
|
+
in the spec for a single request.
|
|
167
|
+
:type _host_index: int, optional
|
|
168
|
+
:return: Returns the result object.
|
|
169
|
+
""" # noqa: E501
|
|
170
|
+
|
|
171
|
+
_param = self._api_document_keys_batch_post_serialize(
|
|
172
|
+
allocate_document_key_batch_request=allocate_document_key_batch_request,
|
|
173
|
+
_request_auth=_request_auth,
|
|
174
|
+
_content_type=_content_type,
|
|
175
|
+
_headers=_headers,
|
|
176
|
+
_host_index=_host_index
|
|
177
|
+
)
|
|
178
|
+
|
|
179
|
+
_response_types_map: Dict[str, Optional[str]] = {
|
|
180
|
+
'200': "List[DocumentKeyModel]",
|
|
181
|
+
'400': None,
|
|
182
|
+
'401': None,
|
|
183
|
+
'403': None,
|
|
184
|
+
'422': None
|
|
185
|
+
|
|
186
|
+
}
|
|
187
|
+
response_data = self.api_client.call_api(
|
|
188
|
+
*_param,
|
|
189
|
+
_request_timeout=_request_timeout
|
|
190
|
+
)
|
|
191
|
+
response_data.read()
|
|
192
|
+
return self.api_client.response_deserialize(
|
|
193
|
+
response_data=response_data,
|
|
194
|
+
response_types_map=_response_types_map,
|
|
195
|
+
)
|
|
196
|
+
|
|
197
|
+
|
|
198
|
+
@validate_call
|
|
199
|
+
def api_document_keys_batch_post_without_preload_content(
|
|
200
|
+
self,
|
|
201
|
+
allocate_document_key_batch_request: Optional[AllocateDocumentKeyBatchRequest] = None,
|
|
202
|
+
_request_timeout: Union[
|
|
203
|
+
None,
|
|
204
|
+
Annotated[StrictFloat, Field(gt=0)],
|
|
205
|
+
Tuple[
|
|
206
|
+
Annotated[StrictFloat, Field(gt=0)],
|
|
207
|
+
Annotated[StrictFloat, Field(gt=0)]
|
|
208
|
+
]
|
|
209
|
+
] = None,
|
|
210
|
+
_request_auth: Optional[Dict[StrictStr, Any]] = None,
|
|
211
|
+
_content_type: Optional[StrictStr] = None,
|
|
212
|
+
_headers: Optional[Dict[StrictStr, Any]] = None,
|
|
213
|
+
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
|
|
214
|
+
) -> RESTResponseType:
|
|
215
|
+
"""Allocates a batch of document keys to be used later on document signatures
|
|
216
|
+
|
|
217
|
+
At most 100 keys may be allocated on each request. Limitations on the total number of unused document keys allocated may apply.
|
|
218
|
+
|
|
219
|
+
:param allocate_document_key_batch_request:
|
|
220
|
+
:type allocate_document_key_batch_request: AllocateDocumentKeyBatchRequest
|
|
221
|
+
:param _request_timeout: timeout setting for this request. If one
|
|
222
|
+
number provided, it will be total request
|
|
223
|
+
timeout. It can also be a pair (tuple) of
|
|
224
|
+
(connection, read) timeouts.
|
|
225
|
+
:type _request_timeout: int, tuple(int, int), optional
|
|
226
|
+
:param _request_auth: set to override the auth_settings for an a single
|
|
227
|
+
request; this effectively ignores the
|
|
228
|
+
authentication in the spec for a single request.
|
|
229
|
+
:type _request_auth: dict, optional
|
|
230
|
+
:param _content_type: force content-type for the request.
|
|
231
|
+
:type _content_type: str, Optional
|
|
232
|
+
:param _headers: set to override the headers for a single
|
|
233
|
+
request; this effectively ignores the headers
|
|
234
|
+
in the spec for a single request.
|
|
235
|
+
:type _headers: dict, optional
|
|
236
|
+
:param _host_index: set to override the host_index for a single
|
|
237
|
+
request; this effectively ignores the host_index
|
|
238
|
+
in the spec for a single request.
|
|
239
|
+
:type _host_index: int, optional
|
|
240
|
+
:return: Returns the result object.
|
|
241
|
+
""" # noqa: E501
|
|
242
|
+
|
|
243
|
+
_param = self._api_document_keys_batch_post_serialize(
|
|
244
|
+
allocate_document_key_batch_request=allocate_document_key_batch_request,
|
|
245
|
+
_request_auth=_request_auth,
|
|
246
|
+
_content_type=_content_type,
|
|
247
|
+
_headers=_headers,
|
|
248
|
+
_host_index=_host_index
|
|
249
|
+
)
|
|
250
|
+
|
|
251
|
+
_response_types_map: Dict[str, Optional[str]] = {
|
|
252
|
+
'200': "List[DocumentKeyModel]",
|
|
253
|
+
'400': None,
|
|
254
|
+
'401': None,
|
|
255
|
+
'403': None,
|
|
256
|
+
'422': None
|
|
257
|
+
|
|
258
|
+
}
|
|
259
|
+
response_data = self.api_client.call_api(
|
|
260
|
+
*_param,
|
|
261
|
+
_request_timeout=_request_timeout
|
|
262
|
+
)
|
|
263
|
+
return response_data.response
|
|
264
|
+
|
|
265
|
+
|
|
266
|
+
def _api_document_keys_batch_post_serialize(
|
|
267
|
+
self,
|
|
268
|
+
allocate_document_key_batch_request,
|
|
269
|
+
_request_auth,
|
|
270
|
+
_content_type,
|
|
271
|
+
_headers,
|
|
272
|
+
_host_index,
|
|
273
|
+
) -> Tuple:
|
|
274
|
+
|
|
275
|
+
_host = None
|
|
276
|
+
|
|
277
|
+
_collection_formats: Dict[str, str] = {
|
|
278
|
+
|
|
279
|
+
}
|
|
280
|
+
|
|
281
|
+
_path_params: Dict[str, str] = {}
|
|
282
|
+
_query_params: List[Tuple[str, str]] = []
|
|
283
|
+
_header_params: Dict[str, Optional[str]] = _headers or {}
|
|
284
|
+
_form_params: List[Tuple[str, str]] = []
|
|
285
|
+
_files: Dict[str, str] = {}
|
|
286
|
+
_body_params: Optional[bytes] = None
|
|
287
|
+
|
|
288
|
+
# process the path parameters
|
|
289
|
+
# process the query parameters
|
|
290
|
+
# process the header parameters
|
|
291
|
+
# process the form parameters
|
|
292
|
+
# process the body parameter
|
|
293
|
+
if allocate_document_key_batch_request is not None:
|
|
294
|
+
_body_params = allocate_document_key_batch_request
|
|
295
|
+
|
|
296
|
+
|
|
297
|
+
# set the HTTP header `Accept`
|
|
298
|
+
_header_params['Accept'] = self.api_client.select_header_accept(
|
|
299
|
+
[
|
|
300
|
+
'text/plain',
|
|
301
|
+
'application/json',
|
|
302
|
+
'text/json'
|
|
303
|
+
]
|
|
304
|
+
)
|
|
305
|
+
|
|
306
|
+
# set the HTTP header `Content-Type`
|
|
307
|
+
if _content_type:
|
|
308
|
+
_header_params['Content-Type'] = _content_type
|
|
309
|
+
else:
|
|
310
|
+
_default_content_type = (
|
|
311
|
+
self.api_client.select_header_content_type(
|
|
312
|
+
[
|
|
313
|
+
'application/json-patch+json',
|
|
314
|
+
'application/json',
|
|
315
|
+
'text/json',
|
|
316
|
+
'application/*+json'
|
|
317
|
+
]
|
|
318
|
+
)
|
|
319
|
+
)
|
|
320
|
+
if _default_content_type is not None:
|
|
321
|
+
_header_params['Content-Type'] = _default_content_type
|
|
322
|
+
|
|
323
|
+
# authentication setting
|
|
324
|
+
_auth_settings: List[str] = [
|
|
325
|
+
]
|
|
326
|
+
|
|
327
|
+
return self.api_client.param_serialize(
|
|
328
|
+
method='POST',
|
|
329
|
+
resource_path='/api/document-keys/batch',
|
|
330
|
+
path_params=_path_params,
|
|
331
|
+
query_params=_query_params,
|
|
332
|
+
header_params=_header_params,
|
|
333
|
+
body=_body_params,
|
|
334
|
+
post_params=_form_params,
|
|
335
|
+
files=_files,
|
|
336
|
+
auth_settings=_auth_settings,
|
|
337
|
+
collection_formats=_collection_formats,
|
|
338
|
+
_host=_host,
|
|
339
|
+
_request_auth=_request_auth
|
|
340
|
+
)
|
|
341
|
+
|
|
342
|
+
|
|
343
|
+
|
|
344
|
+
|
|
345
|
+
@validate_call
|
|
346
|
+
def api_document_keys_key_get(
|
|
347
|
+
self,
|
|
348
|
+
key: StrictStr,
|
|
349
|
+
_request_timeout: Union[
|
|
350
|
+
None,
|
|
351
|
+
Annotated[StrictFloat, Field(gt=0)],
|
|
352
|
+
Tuple[
|
|
353
|
+
Annotated[StrictFloat, Field(gt=0)],
|
|
354
|
+
Annotated[StrictFloat, Field(gt=0)]
|
|
355
|
+
]
|
|
356
|
+
] = None,
|
|
357
|
+
_request_auth: Optional[Dict[StrictStr, Any]] = None,
|
|
358
|
+
_content_type: Optional[StrictStr] = None,
|
|
359
|
+
_headers: Optional[Dict[StrictStr, Any]] = None,
|
|
360
|
+
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
|
|
361
|
+
) -> DocumentKeyQueryResponse:
|
|
362
|
+
"""Queries documents by key
|
|
363
|
+
|
|
364
|
+
The key may be given either in formatted form (e.g. *XXXX-XXXX-XXXX-XXXX*) or unformatted (e.g. *XXXXXXXXXXXXXXXX*) If a document with the given key is not found, the response is a `200 (Success)` with `\"found\": false`. If the given key has been allocated in advance but is not yet associated with a document, the response is a `200 (Success)` with `\"found\": true` and `\"hasDocument\": false`. In this case, the field `provisionalMetadata` contains any provisional metadata passed during the document key allocation, which serves as an indicative of the metadata that a future document will likely have. Only if `\"found\": true` **and** `\"hasDocument\": true` is the field `document` filled. In this case, `provisionalMetadata` is not filled.
|
|
365
|
+
|
|
366
|
+
:param key: (required)
|
|
367
|
+
:type key: str
|
|
368
|
+
:param _request_timeout: timeout setting for this request. If one
|
|
369
|
+
number provided, it will be total request
|
|
370
|
+
timeout. It can also be a pair (tuple) of
|
|
371
|
+
(connection, read) timeouts.
|
|
372
|
+
:type _request_timeout: int, tuple(int, int), optional
|
|
373
|
+
:param _request_auth: set to override the auth_settings for an a single
|
|
374
|
+
request; this effectively ignores the
|
|
375
|
+
authentication in the spec for a single request.
|
|
376
|
+
:type _request_auth: dict, optional
|
|
377
|
+
:param _content_type: force content-type for the request.
|
|
378
|
+
:type _content_type: str, Optional
|
|
379
|
+
:param _headers: set to override the headers for a single
|
|
380
|
+
request; this effectively ignores the headers
|
|
381
|
+
in the spec for a single request.
|
|
382
|
+
:type _headers: dict, optional
|
|
383
|
+
:param _host_index: set to override the host_index for a single
|
|
384
|
+
request; this effectively ignores the host_index
|
|
385
|
+
in the spec for a single request.
|
|
386
|
+
:type _host_index: int, optional
|
|
387
|
+
:return: Returns the result object.
|
|
388
|
+
""" # noqa: E501
|
|
389
|
+
|
|
390
|
+
_param = self._api_document_keys_key_get_serialize(
|
|
391
|
+
key=key,
|
|
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': "DocumentKeyQueryResponse",
|
|
400
|
+
'400': None,
|
|
401
|
+
'401': None,
|
|
402
|
+
'403': None,
|
|
403
|
+
'422': None
|
|
404
|
+
|
|
405
|
+
}
|
|
406
|
+
response_data = self.api_client.call_api(
|
|
407
|
+
*_param,
|
|
408
|
+
_request_timeout=_request_timeout
|
|
409
|
+
)
|
|
410
|
+
response_data.read()
|
|
411
|
+
return self.api_client.response_deserialize(
|
|
412
|
+
response_data=response_data,
|
|
413
|
+
response_types_map=_response_types_map,
|
|
414
|
+
).data
|
|
415
|
+
|
|
416
|
+
|
|
417
|
+
@validate_call
|
|
418
|
+
def api_document_keys_key_get_with_http_info(
|
|
419
|
+
self,
|
|
420
|
+
key: StrictStr,
|
|
421
|
+
_request_timeout: Union[
|
|
422
|
+
None,
|
|
423
|
+
Annotated[StrictFloat, Field(gt=0)],
|
|
424
|
+
Tuple[
|
|
425
|
+
Annotated[StrictFloat, Field(gt=0)],
|
|
426
|
+
Annotated[StrictFloat, Field(gt=0)]
|
|
427
|
+
]
|
|
428
|
+
] = None,
|
|
429
|
+
_request_auth: Optional[Dict[StrictStr, Any]] = None,
|
|
430
|
+
_content_type: Optional[StrictStr] = None,
|
|
431
|
+
_headers: Optional[Dict[StrictStr, Any]] = None,
|
|
432
|
+
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
|
|
433
|
+
) -> ApiResponse[DocumentKeyQueryResponse]:
|
|
434
|
+
"""Queries documents by key
|
|
435
|
+
|
|
436
|
+
The key may be given either in formatted form (e.g. *XXXX-XXXX-XXXX-XXXX*) or unformatted (e.g. *XXXXXXXXXXXXXXXX*) If a document with the given key is not found, the response is a `200 (Success)` with `\"found\": false`. If the given key has been allocated in advance but is not yet associated with a document, the response is a `200 (Success)` with `\"found\": true` and `\"hasDocument\": false`. In this case, the field `provisionalMetadata` contains any provisional metadata passed during the document key allocation, which serves as an indicative of the metadata that a future document will likely have. Only if `\"found\": true` **and** `\"hasDocument\": true` is the field `document` filled. In this case, `provisionalMetadata` is not filled.
|
|
437
|
+
|
|
438
|
+
:param key: (required)
|
|
439
|
+
:type key: str
|
|
440
|
+
:param _request_timeout: timeout setting for this request. If one
|
|
441
|
+
number provided, it will be total request
|
|
442
|
+
timeout. It can also be a pair (tuple) of
|
|
443
|
+
(connection, read) timeouts.
|
|
444
|
+
:type _request_timeout: int, tuple(int, int), optional
|
|
445
|
+
:param _request_auth: set to override the auth_settings for an a single
|
|
446
|
+
request; this effectively ignores the
|
|
447
|
+
authentication in the spec for a single request.
|
|
448
|
+
:type _request_auth: dict, optional
|
|
449
|
+
:param _content_type: force content-type for the request.
|
|
450
|
+
:type _content_type: str, Optional
|
|
451
|
+
:param _headers: set to override the headers for a single
|
|
452
|
+
request; this effectively ignores the headers
|
|
453
|
+
in the spec for a single request.
|
|
454
|
+
:type _headers: dict, optional
|
|
455
|
+
:param _host_index: set to override the host_index for a single
|
|
456
|
+
request; this effectively ignores the host_index
|
|
457
|
+
in the spec for a single request.
|
|
458
|
+
:type _host_index: int, optional
|
|
459
|
+
:return: Returns the result object.
|
|
460
|
+
""" # noqa: E501
|
|
461
|
+
|
|
462
|
+
_param = self._api_document_keys_key_get_serialize(
|
|
463
|
+
key=key,
|
|
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': "DocumentKeyQueryResponse",
|
|
472
|
+
'400': None,
|
|
473
|
+
'401': None,
|
|
474
|
+
'403': None,
|
|
475
|
+
'422': None
|
|
476
|
+
|
|
477
|
+
}
|
|
478
|
+
response_data = self.api_client.call_api(
|
|
479
|
+
*_param,
|
|
480
|
+
_request_timeout=_request_timeout
|
|
481
|
+
)
|
|
482
|
+
response_data.read()
|
|
483
|
+
return self.api_client.response_deserialize(
|
|
484
|
+
response_data=response_data,
|
|
485
|
+
response_types_map=_response_types_map,
|
|
486
|
+
)
|
|
487
|
+
|
|
488
|
+
|
|
489
|
+
@validate_call
|
|
490
|
+
def api_document_keys_key_get_without_preload_content(
|
|
491
|
+
self,
|
|
492
|
+
key: StrictStr,
|
|
493
|
+
_request_timeout: Union[
|
|
494
|
+
None,
|
|
495
|
+
Annotated[StrictFloat, Field(gt=0)],
|
|
496
|
+
Tuple[
|
|
497
|
+
Annotated[StrictFloat, Field(gt=0)],
|
|
498
|
+
Annotated[StrictFloat, Field(gt=0)]
|
|
499
|
+
]
|
|
500
|
+
] = None,
|
|
501
|
+
_request_auth: Optional[Dict[StrictStr, Any]] = None,
|
|
502
|
+
_content_type: Optional[StrictStr] = None,
|
|
503
|
+
_headers: Optional[Dict[StrictStr, Any]] = None,
|
|
504
|
+
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
|
|
505
|
+
) -> RESTResponseType:
|
|
506
|
+
"""Queries documents by key
|
|
507
|
+
|
|
508
|
+
The key may be given either in formatted form (e.g. *XXXX-XXXX-XXXX-XXXX*) or unformatted (e.g. *XXXXXXXXXXXXXXXX*) If a document with the given key is not found, the response is a `200 (Success)` with `\"found\": false`. If the given key has been allocated in advance but is not yet associated with a document, the response is a `200 (Success)` with `\"found\": true` and `\"hasDocument\": false`. In this case, the field `provisionalMetadata` contains any provisional metadata passed during the document key allocation, which serves as an indicative of the metadata that a future document will likely have. Only if `\"found\": true` **and** `\"hasDocument\": true` is the field `document` filled. In this case, `provisionalMetadata` is not filled.
|
|
509
|
+
|
|
510
|
+
:param key: (required)
|
|
511
|
+
:type key: str
|
|
512
|
+
:param _request_timeout: timeout setting for this request. If one
|
|
513
|
+
number provided, it will be total request
|
|
514
|
+
timeout. It can also be a pair (tuple) of
|
|
515
|
+
(connection, read) timeouts.
|
|
516
|
+
:type _request_timeout: int, tuple(int, int), optional
|
|
517
|
+
:param _request_auth: set to override the auth_settings for an a single
|
|
518
|
+
request; this effectively ignores the
|
|
519
|
+
authentication in the spec for a single request.
|
|
520
|
+
:type _request_auth: dict, optional
|
|
521
|
+
:param _content_type: force content-type for the request.
|
|
522
|
+
:type _content_type: str, Optional
|
|
523
|
+
:param _headers: set to override the headers for a single
|
|
524
|
+
request; this effectively ignores the headers
|
|
525
|
+
in the spec for a single request.
|
|
526
|
+
:type _headers: dict, optional
|
|
527
|
+
:param _host_index: set to override the host_index for a single
|
|
528
|
+
request; this effectively ignores the host_index
|
|
529
|
+
in the spec for a single request.
|
|
530
|
+
:type _host_index: int, optional
|
|
531
|
+
:return: Returns the result object.
|
|
532
|
+
""" # noqa: E501
|
|
533
|
+
|
|
534
|
+
_param = self._api_document_keys_key_get_serialize(
|
|
535
|
+
key=key,
|
|
536
|
+
_request_auth=_request_auth,
|
|
537
|
+
_content_type=_content_type,
|
|
538
|
+
_headers=_headers,
|
|
539
|
+
_host_index=_host_index
|
|
540
|
+
)
|
|
541
|
+
|
|
542
|
+
_response_types_map: Dict[str, Optional[str]] = {
|
|
543
|
+
'200': "DocumentKeyQueryResponse",
|
|
544
|
+
'400': None,
|
|
545
|
+
'401': None,
|
|
546
|
+
'403': None,
|
|
547
|
+
'422': None
|
|
548
|
+
|
|
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 _api_document_keys_key_get_serialize(
|
|
558
|
+
self,
|
|
559
|
+
key,
|
|
560
|
+
_request_auth,
|
|
561
|
+
_content_type,
|
|
562
|
+
_headers,
|
|
563
|
+
_host_index,
|
|
564
|
+
) -> Tuple:
|
|
565
|
+
|
|
566
|
+
_host = None
|
|
567
|
+
|
|
568
|
+
_collection_formats: Dict[str, str] = {
|
|
569
|
+
|
|
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[str, str] = {}
|
|
577
|
+
_body_params: Optional[bytes] = None
|
|
578
|
+
|
|
579
|
+
# process the path parameters
|
|
580
|
+
if key is not None:
|
|
581
|
+
_path_params['key'] = key
|
|
582
|
+
# process the query parameters
|
|
583
|
+
# process the header parameters
|
|
584
|
+
# process the form parameters
|
|
585
|
+
# process the body parameter
|
|
586
|
+
|
|
587
|
+
|
|
588
|
+
# set the HTTP header `Accept`
|
|
589
|
+
_header_params['Accept'] = self.api_client.select_header_accept(
|
|
590
|
+
[
|
|
591
|
+
'text/plain',
|
|
592
|
+
'application/json',
|
|
593
|
+
'text/json'
|
|
594
|
+
]
|
|
595
|
+
)
|
|
596
|
+
|
|
597
|
+
|
|
598
|
+
# authentication setting
|
|
599
|
+
_auth_settings: List[str] = [
|
|
600
|
+
]
|
|
601
|
+
|
|
602
|
+
return self.api_client.param_serialize(
|
|
603
|
+
method='GET',
|
|
604
|
+
resource_path='/api/document-keys/{key}',
|
|
605
|
+
path_params=_path_params,
|
|
606
|
+
query_params=_query_params,
|
|
607
|
+
header_params=_header_params,
|
|
608
|
+
body=_body_params,
|
|
609
|
+
post_params=_form_params,
|
|
610
|
+
files=_files,
|
|
611
|
+
auth_settings=_auth_settings,
|
|
612
|
+
collection_formats=_collection_formats,
|
|
613
|
+
_host=_host,
|
|
614
|
+
_request_auth=_request_auth
|
|
615
|
+
)
|
|
616
|
+
|
|
617
|
+
|
|
618
|
+
|
|
619
|
+
|
|
620
|
+
@validate_call
|
|
621
|
+
def api_document_keys_post(
|
|
622
|
+
self,
|
|
623
|
+
allocate_document_key_request: Optional[AllocateDocumentKeyRequest] = None,
|
|
624
|
+
_request_timeout: Union[
|
|
625
|
+
None,
|
|
626
|
+
Annotated[StrictFloat, Field(gt=0)],
|
|
627
|
+
Tuple[
|
|
628
|
+
Annotated[StrictFloat, Field(gt=0)],
|
|
629
|
+
Annotated[StrictFloat, Field(gt=0)]
|
|
630
|
+
]
|
|
631
|
+
] = None,
|
|
632
|
+
_request_auth: Optional[Dict[StrictStr, Any]] = None,
|
|
633
|
+
_content_type: Optional[StrictStr] = None,
|
|
634
|
+
_headers: Optional[Dict[StrictStr, Any]] = None,
|
|
635
|
+
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
|
|
636
|
+
) -> DocumentKeyModel:
|
|
637
|
+
"""Allocates a document key to be used later on a document signature
|
|
638
|
+
|
|
639
|
+
To allocate a number of document keys at once, use the `POST /api/document-keys/batch` API instead. Limitations on the total number of unused document keys allocated may apply.
|
|
640
|
+
|
|
641
|
+
:param allocate_document_key_request:
|
|
642
|
+
:type allocate_document_key_request: AllocateDocumentKeyRequest
|
|
643
|
+
:param _request_timeout: timeout setting for this request. If one
|
|
644
|
+
number provided, it will be total request
|
|
645
|
+
timeout. It can also be a pair (tuple) of
|
|
646
|
+
(connection, read) timeouts.
|
|
647
|
+
:type _request_timeout: int, tuple(int, int), optional
|
|
648
|
+
:param _request_auth: set to override the auth_settings for an a single
|
|
649
|
+
request; this effectively ignores the
|
|
650
|
+
authentication in the spec for a single request.
|
|
651
|
+
:type _request_auth: dict, optional
|
|
652
|
+
:param _content_type: force content-type for the request.
|
|
653
|
+
:type _content_type: str, Optional
|
|
654
|
+
:param _headers: set to override the headers for a single
|
|
655
|
+
request; this effectively ignores the headers
|
|
656
|
+
in the spec for a single request.
|
|
657
|
+
:type _headers: dict, optional
|
|
658
|
+
:param _host_index: set to override the host_index for a single
|
|
659
|
+
request; this effectively ignores the host_index
|
|
660
|
+
in the spec for a single request.
|
|
661
|
+
:type _host_index: int, optional
|
|
662
|
+
:return: Returns the result object.
|
|
663
|
+
""" # noqa: E501
|
|
664
|
+
|
|
665
|
+
_param = self._api_document_keys_post_serialize(
|
|
666
|
+
allocate_document_key_request=allocate_document_key_request,
|
|
667
|
+
_request_auth=_request_auth,
|
|
668
|
+
_content_type=_content_type,
|
|
669
|
+
_headers=_headers,
|
|
670
|
+
_host_index=_host_index
|
|
671
|
+
)
|
|
672
|
+
|
|
673
|
+
_response_types_map: Dict[str, Optional[str]] = {
|
|
674
|
+
'200': "DocumentKeyModel",
|
|
675
|
+
'400': None,
|
|
676
|
+
'401': None,
|
|
677
|
+
'403': None,
|
|
678
|
+
'422': None
|
|
679
|
+
|
|
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 api_document_keys_post_with_http_info(
|
|
694
|
+
self,
|
|
695
|
+
allocate_document_key_request: Optional[AllocateDocumentKeyRequest] = None,
|
|
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[DocumentKeyModel]:
|
|
709
|
+
"""Allocates a document key to be used later on a document signature
|
|
710
|
+
|
|
711
|
+
To allocate a number of document keys at once, use the `POST /api/document-keys/batch` API instead. Limitations on the total number of unused document keys allocated may apply.
|
|
712
|
+
|
|
713
|
+
:param allocate_document_key_request:
|
|
714
|
+
:type allocate_document_key_request: AllocateDocumentKeyRequest
|
|
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._api_document_keys_post_serialize(
|
|
738
|
+
allocate_document_key_request=allocate_document_key_request,
|
|
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': "DocumentKeyModel",
|
|
747
|
+
'400': None,
|
|
748
|
+
'401': None,
|
|
749
|
+
'403': None,
|
|
750
|
+
'422': None
|
|
751
|
+
|
|
752
|
+
}
|
|
753
|
+
response_data = self.api_client.call_api(
|
|
754
|
+
*_param,
|
|
755
|
+
_request_timeout=_request_timeout
|
|
756
|
+
)
|
|
757
|
+
response_data.read()
|
|
758
|
+
return self.api_client.response_deserialize(
|
|
759
|
+
response_data=response_data,
|
|
760
|
+
response_types_map=_response_types_map,
|
|
761
|
+
)
|
|
762
|
+
|
|
763
|
+
|
|
764
|
+
@validate_call
|
|
765
|
+
def api_document_keys_post_without_preload_content(
|
|
766
|
+
self,
|
|
767
|
+
allocate_document_key_request: Optional[AllocateDocumentKeyRequest] = None,
|
|
768
|
+
_request_timeout: Union[
|
|
769
|
+
None,
|
|
770
|
+
Annotated[StrictFloat, Field(gt=0)],
|
|
771
|
+
Tuple[
|
|
772
|
+
Annotated[StrictFloat, Field(gt=0)],
|
|
773
|
+
Annotated[StrictFloat, Field(gt=0)]
|
|
774
|
+
]
|
|
775
|
+
] = None,
|
|
776
|
+
_request_auth: Optional[Dict[StrictStr, Any]] = None,
|
|
777
|
+
_content_type: Optional[StrictStr] = None,
|
|
778
|
+
_headers: Optional[Dict[StrictStr, Any]] = None,
|
|
779
|
+
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
|
|
780
|
+
) -> RESTResponseType:
|
|
781
|
+
"""Allocates a document key to be used later on a document signature
|
|
782
|
+
|
|
783
|
+
To allocate a number of document keys at once, use the `POST /api/document-keys/batch` API instead. Limitations on the total number of unused document keys allocated may apply.
|
|
784
|
+
|
|
785
|
+
:param allocate_document_key_request:
|
|
786
|
+
:type allocate_document_key_request: AllocateDocumentKeyRequest
|
|
787
|
+
:param _request_timeout: timeout setting for this request. If one
|
|
788
|
+
number provided, it will be total request
|
|
789
|
+
timeout. It can also be a pair (tuple) of
|
|
790
|
+
(connection, read) timeouts.
|
|
791
|
+
:type _request_timeout: int, tuple(int, int), optional
|
|
792
|
+
:param _request_auth: set to override the auth_settings for an a single
|
|
793
|
+
request; this effectively ignores the
|
|
794
|
+
authentication in the spec for a single request.
|
|
795
|
+
:type _request_auth: dict, optional
|
|
796
|
+
:param _content_type: force content-type for the request.
|
|
797
|
+
:type _content_type: str, Optional
|
|
798
|
+
:param _headers: set to override the headers for a single
|
|
799
|
+
request; this effectively ignores the headers
|
|
800
|
+
in the spec for a single request.
|
|
801
|
+
:type _headers: dict, optional
|
|
802
|
+
:param _host_index: set to override the host_index for a single
|
|
803
|
+
request; this effectively ignores the host_index
|
|
804
|
+
in the spec for a single request.
|
|
805
|
+
:type _host_index: int, optional
|
|
806
|
+
:return: Returns the result object.
|
|
807
|
+
""" # noqa: E501
|
|
808
|
+
|
|
809
|
+
_param = self._api_document_keys_post_serialize(
|
|
810
|
+
allocate_document_key_request=allocate_document_key_request,
|
|
811
|
+
_request_auth=_request_auth,
|
|
812
|
+
_content_type=_content_type,
|
|
813
|
+
_headers=_headers,
|
|
814
|
+
_host_index=_host_index
|
|
815
|
+
)
|
|
816
|
+
|
|
817
|
+
_response_types_map: Dict[str, Optional[str]] = {
|
|
818
|
+
'200': "DocumentKeyModel",
|
|
819
|
+
'400': None,
|
|
820
|
+
'401': None,
|
|
821
|
+
'403': None,
|
|
822
|
+
'422': None
|
|
823
|
+
|
|
824
|
+
}
|
|
825
|
+
response_data = self.api_client.call_api(
|
|
826
|
+
*_param,
|
|
827
|
+
_request_timeout=_request_timeout
|
|
828
|
+
)
|
|
829
|
+
return response_data.response
|
|
830
|
+
|
|
831
|
+
|
|
832
|
+
def _api_document_keys_post_serialize(
|
|
833
|
+
self,
|
|
834
|
+
allocate_document_key_request,
|
|
835
|
+
_request_auth,
|
|
836
|
+
_content_type,
|
|
837
|
+
_headers,
|
|
838
|
+
_host_index,
|
|
839
|
+
) -> Tuple:
|
|
840
|
+
|
|
841
|
+
_host = None
|
|
842
|
+
|
|
843
|
+
_collection_formats: Dict[str, str] = {
|
|
844
|
+
|
|
845
|
+
}
|
|
846
|
+
|
|
847
|
+
_path_params: Dict[str, str] = {}
|
|
848
|
+
_query_params: List[Tuple[str, str]] = []
|
|
849
|
+
_header_params: Dict[str, Optional[str]] = _headers or {}
|
|
850
|
+
_form_params: List[Tuple[str, str]] = []
|
|
851
|
+
_files: Dict[str, str] = {}
|
|
852
|
+
_body_params: Optional[bytes] = None
|
|
853
|
+
|
|
854
|
+
# process the path parameters
|
|
855
|
+
# process the query parameters
|
|
856
|
+
# process the header parameters
|
|
857
|
+
# process the form parameters
|
|
858
|
+
# process the body parameter
|
|
859
|
+
if allocate_document_key_request is not None:
|
|
860
|
+
_body_params = allocate_document_key_request
|
|
861
|
+
|
|
862
|
+
|
|
863
|
+
# set the HTTP header `Accept`
|
|
864
|
+
_header_params['Accept'] = self.api_client.select_header_accept(
|
|
865
|
+
[
|
|
866
|
+
'text/plain',
|
|
867
|
+
'application/json',
|
|
868
|
+
'text/json'
|
|
869
|
+
]
|
|
870
|
+
)
|
|
871
|
+
|
|
872
|
+
# set the HTTP header `Content-Type`
|
|
873
|
+
if _content_type:
|
|
874
|
+
_header_params['Content-Type'] = _content_type
|
|
875
|
+
else:
|
|
876
|
+
_default_content_type = (
|
|
877
|
+
self.api_client.select_header_content_type(
|
|
878
|
+
[
|
|
879
|
+
'application/json-patch+json',
|
|
880
|
+
'application/json',
|
|
881
|
+
'text/json',
|
|
882
|
+
'application/*+json'
|
|
883
|
+
]
|
|
884
|
+
)
|
|
885
|
+
)
|
|
886
|
+
if _default_content_type is not None:
|
|
887
|
+
_header_params['Content-Type'] = _default_content_type
|
|
888
|
+
|
|
889
|
+
# authentication setting
|
|
890
|
+
_auth_settings: List[str] = [
|
|
891
|
+
]
|
|
892
|
+
|
|
893
|
+
return self.api_client.param_serialize(
|
|
894
|
+
method='POST',
|
|
895
|
+
resource_path='/api/document-keys',
|
|
896
|
+
path_params=_path_params,
|
|
897
|
+
query_params=_query_params,
|
|
898
|
+
header_params=_header_params,
|
|
899
|
+
body=_body_params,
|
|
900
|
+
post_params=_form_params,
|
|
901
|
+
files=_files,
|
|
902
|
+
auth_settings=_auth_settings,
|
|
903
|
+
collection_formats=_collection_formats,
|
|
904
|
+
_host=_host,
|
|
905
|
+
_request_auth=_request_auth
|
|
906
|
+
)
|
|
907
|
+
|
|
908
|
+
|
|
909
|
+
|
|
910
|
+
|
|
911
|
+
@validate_call
|
|
912
|
+
def api_document_keys_unused_get(
|
|
913
|
+
self,
|
|
914
|
+
metadata_name: Optional[StrictStr] = None,
|
|
915
|
+
metadata_value: Optional[StrictStr] = None,
|
|
916
|
+
_request_timeout: Union[
|
|
917
|
+
None,
|
|
918
|
+
Annotated[StrictFloat, Field(gt=0)],
|
|
919
|
+
Tuple[
|
|
920
|
+
Annotated[StrictFloat, Field(gt=0)],
|
|
921
|
+
Annotated[StrictFloat, Field(gt=0)]
|
|
922
|
+
]
|
|
923
|
+
] = None,
|
|
924
|
+
_request_auth: Optional[Dict[StrictStr, Any]] = None,
|
|
925
|
+
_content_type: Optional[StrictStr] = None,
|
|
926
|
+
_headers: Optional[Dict[StrictStr, Any]] = None,
|
|
927
|
+
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
|
|
928
|
+
) -> List[DocumentKeySummary]:
|
|
929
|
+
"""Queries unused document keys
|
|
930
|
+
|
|
931
|
+
|
|
932
|
+
:param metadata_name:
|
|
933
|
+
:type metadata_name: str
|
|
934
|
+
:param metadata_value:
|
|
935
|
+
:type metadata_value: str
|
|
936
|
+
:param _request_timeout: timeout setting for this request. If one
|
|
937
|
+
number provided, it will be total request
|
|
938
|
+
timeout. It can also be a pair (tuple) of
|
|
939
|
+
(connection, read) timeouts.
|
|
940
|
+
:type _request_timeout: int, tuple(int, int), optional
|
|
941
|
+
:param _request_auth: set to override the auth_settings for an a single
|
|
942
|
+
request; this effectively ignores the
|
|
943
|
+
authentication in the spec for a single request.
|
|
944
|
+
:type _request_auth: dict, optional
|
|
945
|
+
:param _content_type: force content-type for the request.
|
|
946
|
+
:type _content_type: str, Optional
|
|
947
|
+
:param _headers: set to override the headers for a single
|
|
948
|
+
request; this effectively ignores the headers
|
|
949
|
+
in the spec for a single request.
|
|
950
|
+
:type _headers: dict, optional
|
|
951
|
+
:param _host_index: set to override the host_index for a single
|
|
952
|
+
request; this effectively ignores the host_index
|
|
953
|
+
in the spec for a single request.
|
|
954
|
+
:type _host_index: int, optional
|
|
955
|
+
:return: Returns the result object.
|
|
956
|
+
""" # noqa: E501
|
|
957
|
+
|
|
958
|
+
_param = self._api_document_keys_unused_get_serialize(
|
|
959
|
+
metadata_name=metadata_name,
|
|
960
|
+
metadata_value=metadata_value,
|
|
961
|
+
_request_auth=_request_auth,
|
|
962
|
+
_content_type=_content_type,
|
|
963
|
+
_headers=_headers,
|
|
964
|
+
_host_index=_host_index
|
|
965
|
+
)
|
|
966
|
+
|
|
967
|
+
_response_types_map: Dict[str, Optional[str]] = {
|
|
968
|
+
'200': "List[DocumentKeySummary]",
|
|
969
|
+
'400': None,
|
|
970
|
+
'401': None,
|
|
971
|
+
'403': None,
|
|
972
|
+
'422': None
|
|
973
|
+
|
|
974
|
+
}
|
|
975
|
+
response_data = self.api_client.call_api(
|
|
976
|
+
*_param,
|
|
977
|
+
_request_timeout=_request_timeout
|
|
978
|
+
)
|
|
979
|
+
response_data.read()
|
|
980
|
+
return self.api_client.response_deserialize(
|
|
981
|
+
response_data=response_data,
|
|
982
|
+
response_types_map=_response_types_map,
|
|
983
|
+
).data
|
|
984
|
+
|
|
985
|
+
|
|
986
|
+
@validate_call
|
|
987
|
+
def api_document_keys_unused_get_with_http_info(
|
|
988
|
+
self,
|
|
989
|
+
metadata_name: Optional[StrictStr] = None,
|
|
990
|
+
metadata_value: Optional[StrictStr] = None,
|
|
991
|
+
_request_timeout: Union[
|
|
992
|
+
None,
|
|
993
|
+
Annotated[StrictFloat, Field(gt=0)],
|
|
994
|
+
Tuple[
|
|
995
|
+
Annotated[StrictFloat, Field(gt=0)],
|
|
996
|
+
Annotated[StrictFloat, Field(gt=0)]
|
|
997
|
+
]
|
|
998
|
+
] = None,
|
|
999
|
+
_request_auth: Optional[Dict[StrictStr, Any]] = None,
|
|
1000
|
+
_content_type: Optional[StrictStr] = None,
|
|
1001
|
+
_headers: Optional[Dict[StrictStr, Any]] = None,
|
|
1002
|
+
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
|
|
1003
|
+
) -> ApiResponse[List[DocumentKeySummary]]:
|
|
1004
|
+
"""Queries unused document keys
|
|
1005
|
+
|
|
1006
|
+
|
|
1007
|
+
:param metadata_name:
|
|
1008
|
+
:type metadata_name: str
|
|
1009
|
+
:param metadata_value:
|
|
1010
|
+
:type metadata_value: str
|
|
1011
|
+
:param _request_timeout: timeout setting for this request. If one
|
|
1012
|
+
number provided, it will be total request
|
|
1013
|
+
timeout. It can also be a pair (tuple) of
|
|
1014
|
+
(connection, read) timeouts.
|
|
1015
|
+
:type _request_timeout: int, tuple(int, int), optional
|
|
1016
|
+
:param _request_auth: set to override the auth_settings for an a single
|
|
1017
|
+
request; this effectively ignores the
|
|
1018
|
+
authentication in the spec for a single request.
|
|
1019
|
+
:type _request_auth: dict, optional
|
|
1020
|
+
:param _content_type: force content-type for the request.
|
|
1021
|
+
:type _content_type: str, Optional
|
|
1022
|
+
:param _headers: set to override the headers for a single
|
|
1023
|
+
request; this effectively ignores the headers
|
|
1024
|
+
in the spec for a single request.
|
|
1025
|
+
:type _headers: dict, optional
|
|
1026
|
+
:param _host_index: set to override the host_index for a single
|
|
1027
|
+
request; this effectively ignores the host_index
|
|
1028
|
+
in the spec for a single request.
|
|
1029
|
+
:type _host_index: int, optional
|
|
1030
|
+
:return: Returns the result object.
|
|
1031
|
+
""" # noqa: E501
|
|
1032
|
+
|
|
1033
|
+
_param = self._api_document_keys_unused_get_serialize(
|
|
1034
|
+
metadata_name=metadata_name,
|
|
1035
|
+
metadata_value=metadata_value,
|
|
1036
|
+
_request_auth=_request_auth,
|
|
1037
|
+
_content_type=_content_type,
|
|
1038
|
+
_headers=_headers,
|
|
1039
|
+
_host_index=_host_index
|
|
1040
|
+
)
|
|
1041
|
+
|
|
1042
|
+
_response_types_map: Dict[str, Optional[str]] = {
|
|
1043
|
+
'200': "List[DocumentKeySummary]",
|
|
1044
|
+
'400': None,
|
|
1045
|
+
'401': None,
|
|
1046
|
+
'403': None,
|
|
1047
|
+
'422': None
|
|
1048
|
+
|
|
1049
|
+
}
|
|
1050
|
+
response_data = self.api_client.call_api(
|
|
1051
|
+
*_param,
|
|
1052
|
+
_request_timeout=_request_timeout
|
|
1053
|
+
)
|
|
1054
|
+
response_data.read()
|
|
1055
|
+
return self.api_client.response_deserialize(
|
|
1056
|
+
response_data=response_data,
|
|
1057
|
+
response_types_map=_response_types_map,
|
|
1058
|
+
)
|
|
1059
|
+
|
|
1060
|
+
|
|
1061
|
+
@validate_call
|
|
1062
|
+
def api_document_keys_unused_get_without_preload_content(
|
|
1063
|
+
self,
|
|
1064
|
+
metadata_name: Optional[StrictStr] = None,
|
|
1065
|
+
metadata_value: Optional[StrictStr] = None,
|
|
1066
|
+
_request_timeout: Union[
|
|
1067
|
+
None,
|
|
1068
|
+
Annotated[StrictFloat, Field(gt=0)],
|
|
1069
|
+
Tuple[
|
|
1070
|
+
Annotated[StrictFloat, Field(gt=0)],
|
|
1071
|
+
Annotated[StrictFloat, Field(gt=0)]
|
|
1072
|
+
]
|
|
1073
|
+
] = None,
|
|
1074
|
+
_request_auth: Optional[Dict[StrictStr, Any]] = None,
|
|
1075
|
+
_content_type: Optional[StrictStr] = None,
|
|
1076
|
+
_headers: Optional[Dict[StrictStr, Any]] = None,
|
|
1077
|
+
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
|
|
1078
|
+
) -> RESTResponseType:
|
|
1079
|
+
"""Queries unused document keys
|
|
1080
|
+
|
|
1081
|
+
|
|
1082
|
+
:param metadata_name:
|
|
1083
|
+
:type metadata_name: str
|
|
1084
|
+
:param metadata_value:
|
|
1085
|
+
:type metadata_value: str
|
|
1086
|
+
:param _request_timeout: timeout setting for this request. If one
|
|
1087
|
+
number provided, it will be total request
|
|
1088
|
+
timeout. It can also be a pair (tuple) of
|
|
1089
|
+
(connection, read) timeouts.
|
|
1090
|
+
:type _request_timeout: int, tuple(int, int), optional
|
|
1091
|
+
:param _request_auth: set to override the auth_settings for an a single
|
|
1092
|
+
request; this effectively ignores the
|
|
1093
|
+
authentication in the spec for a single request.
|
|
1094
|
+
:type _request_auth: dict, optional
|
|
1095
|
+
:param _content_type: force content-type for the request.
|
|
1096
|
+
:type _content_type: str, Optional
|
|
1097
|
+
:param _headers: set to override the headers for a single
|
|
1098
|
+
request; this effectively ignores the headers
|
|
1099
|
+
in the spec for a single request.
|
|
1100
|
+
:type _headers: dict, optional
|
|
1101
|
+
:param _host_index: set to override the host_index for a single
|
|
1102
|
+
request; this effectively ignores the host_index
|
|
1103
|
+
in the spec for a single request.
|
|
1104
|
+
:type _host_index: int, optional
|
|
1105
|
+
:return: Returns the result object.
|
|
1106
|
+
""" # noqa: E501
|
|
1107
|
+
|
|
1108
|
+
_param = self._api_document_keys_unused_get_serialize(
|
|
1109
|
+
metadata_name=metadata_name,
|
|
1110
|
+
metadata_value=metadata_value,
|
|
1111
|
+
_request_auth=_request_auth,
|
|
1112
|
+
_content_type=_content_type,
|
|
1113
|
+
_headers=_headers,
|
|
1114
|
+
_host_index=_host_index
|
|
1115
|
+
)
|
|
1116
|
+
|
|
1117
|
+
_response_types_map: Dict[str, Optional[str]] = {
|
|
1118
|
+
'200': "List[DocumentKeySummary]",
|
|
1119
|
+
'400': None,
|
|
1120
|
+
'401': None,
|
|
1121
|
+
'403': None,
|
|
1122
|
+
'422': None
|
|
1123
|
+
|
|
1124
|
+
}
|
|
1125
|
+
response_data = self.api_client.call_api(
|
|
1126
|
+
*_param,
|
|
1127
|
+
_request_timeout=_request_timeout
|
|
1128
|
+
)
|
|
1129
|
+
return response_data.response
|
|
1130
|
+
|
|
1131
|
+
|
|
1132
|
+
def _api_document_keys_unused_get_serialize(
|
|
1133
|
+
self,
|
|
1134
|
+
metadata_name,
|
|
1135
|
+
metadata_value,
|
|
1136
|
+
_request_auth,
|
|
1137
|
+
_content_type,
|
|
1138
|
+
_headers,
|
|
1139
|
+
_host_index,
|
|
1140
|
+
) -> Tuple:
|
|
1141
|
+
|
|
1142
|
+
_host = None
|
|
1143
|
+
|
|
1144
|
+
_collection_formats: Dict[str, str] = {
|
|
1145
|
+
|
|
1146
|
+
}
|
|
1147
|
+
|
|
1148
|
+
_path_params: Dict[str, str] = {}
|
|
1149
|
+
_query_params: List[Tuple[str, str]] = []
|
|
1150
|
+
_header_params: Dict[str, Optional[str]] = _headers or {}
|
|
1151
|
+
_form_params: List[Tuple[str, str]] = []
|
|
1152
|
+
_files: Dict[str, str] = {}
|
|
1153
|
+
_body_params: Optional[bytes] = None
|
|
1154
|
+
|
|
1155
|
+
# process the path parameters
|
|
1156
|
+
# process the query parameters
|
|
1157
|
+
if metadata_name is not None:
|
|
1158
|
+
|
|
1159
|
+
_query_params.append(('metadataName', metadata_name))
|
|
1160
|
+
|
|
1161
|
+
if metadata_value is not None:
|
|
1162
|
+
|
|
1163
|
+
_query_params.append(('metadataValue', metadata_value))
|
|
1164
|
+
|
|
1165
|
+
# process the header parameters
|
|
1166
|
+
# process the form parameters
|
|
1167
|
+
# process the body parameter
|
|
1168
|
+
|
|
1169
|
+
|
|
1170
|
+
# set the HTTP header `Accept`
|
|
1171
|
+
_header_params['Accept'] = self.api_client.select_header_accept(
|
|
1172
|
+
[
|
|
1173
|
+
'text/plain',
|
|
1174
|
+
'application/json',
|
|
1175
|
+
'text/json'
|
|
1176
|
+
]
|
|
1177
|
+
)
|
|
1178
|
+
|
|
1179
|
+
|
|
1180
|
+
# authentication setting
|
|
1181
|
+
_auth_settings: List[str] = [
|
|
1182
|
+
]
|
|
1183
|
+
|
|
1184
|
+
return self.api_client.param_serialize(
|
|
1185
|
+
method='GET',
|
|
1186
|
+
resource_path='/api/document-keys/unused',
|
|
1187
|
+
path_params=_path_params,
|
|
1188
|
+
query_params=_query_params,
|
|
1189
|
+
header_params=_header_params,
|
|
1190
|
+
body=_body_params,
|
|
1191
|
+
post_params=_form_params,
|
|
1192
|
+
files=_files,
|
|
1193
|
+
auth_settings=_auth_settings,
|
|
1194
|
+
collection_formats=_collection_formats,
|
|
1195
|
+
_host=_host,
|
|
1196
|
+
_request_auth=_request_auth
|
|
1197
|
+
)
|
|
1198
|
+
|
|
1199
|
+
|