Skip to content
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 3 additions & 0 deletions .openapi-generator/FILES
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@ regula/__init__.py
regula/documentreader/__init__.py
regula/documentreader/webclient/gen/__init__.py
regula/documentreader/webclient/gen/api/__init__.py
regula/documentreader/webclient/gen/api/default_api.py
regula/documentreader/webclient/gen/api/healthcheck_api.py
regula/documentreader/webclient/gen/api/process_api.py
regula/documentreader/webclient/gen/api/transaction_api.py
Expand Down Expand Up @@ -40,6 +41,8 @@ regula/documentreader/webclient/gen/models/container_list_list_inner.py
regula/documentreader/webclient/gen/models/critical.py
regula/documentreader/webclient/gen/models/cross_source_value_comparison.py
regula/documentreader/webclient/gen/models/data_module.py
regula/documentreader/webclient/gen/models/database_document.py
regula/documentreader/webclient/gen/models/database_document_list.py
regula/documentreader/webclient/gen/models/details_optical.py
regula/documentreader/webclient/gen/models/details_rfid.py
regula/documentreader/webclient/gen/models/device_info.py
Expand Down
9 changes: 9 additions & 0 deletions regula/documentreader/webclient/gen/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@

# Define package exports
__all__ = [
"DefaultApi",
"HealthcheckApi",
"ProcessApi",
"TransactionApi",
Expand Down Expand Up @@ -52,6 +53,8 @@
"Critical",
"CrossSourceValueComparison",
"DataModule",
"DatabaseDocument",
"DatabaseDocumentList",
"DetailsOptical",
"DetailsRFID",
"DeviceInfo",
Expand Down Expand Up @@ -254,6 +257,7 @@

if __import__("typing").TYPE_CHECKING:
# import apis into sdk package
from regula.documentreader.webclient.gen.api.default_api import DefaultApi as DefaultApi
from regula.documentreader.webclient.gen.api.healthcheck_api import HealthcheckApi as HealthcheckApi
from regula.documentreader.webclient.gen.api.process_api import ProcessApi as ProcessApi
from regula.documentreader.webclient.gen.api.transaction_api import TransactionApi as TransactionApi
Expand Down Expand Up @@ -300,6 +304,8 @@
from regula.documentreader.webclient.gen.models.critical import Critical as Critical
from regula.documentreader.webclient.gen.models.cross_source_value_comparison import CrossSourceValueComparison as CrossSourceValueComparison
from regula.documentreader.webclient.gen.models.data_module import DataModule as DataModule
from regula.documentreader.webclient.gen.models.database_document import DatabaseDocument as DatabaseDocument
from regula.documentreader.webclient.gen.models.database_document_list import DatabaseDocumentList as DatabaseDocumentList
from regula.documentreader.webclient.gen.models.details_optical import DetailsOptical as DetailsOptical
from regula.documentreader.webclient.gen.models.details_rfid import DetailsRFID as DetailsRFID
from regula.documentreader.webclient.gen.models.device_info import DeviceInfo as DeviceInfo
Expand Down Expand Up @@ -508,6 +514,7 @@
("__version__", __version__),
("__all__", __all__),
"""# import apis into sdk package
from regula.documentreader.webclient.gen.api.default_api import DefaultApi as DefaultApi
from regula.documentreader.webclient.gen.api.healthcheck_api import HealthcheckApi as HealthcheckApi
from regula.documentreader.webclient.gen.api.process_api import ProcessApi as ProcessApi
from regula.documentreader.webclient.gen.api.transaction_api import TransactionApi as TransactionApi
Expand Down Expand Up @@ -554,6 +561,8 @@
from regula.documentreader.webclient.gen.models.critical import Critical as Critical
from regula.documentreader.webclient.gen.models.cross_source_value_comparison import CrossSourceValueComparison as CrossSourceValueComparison
from regula.documentreader.webclient.gen.models.data_module import DataModule as DataModule
from regula.documentreader.webclient.gen.models.database_document import DatabaseDocument as DatabaseDocument
from regula.documentreader.webclient.gen.models.database_document_list import DatabaseDocumentList as DatabaseDocumentList
from regula.documentreader.webclient.gen.models.details_optical import DetailsOptical as DetailsOptical
from regula.documentreader.webclient.gen.models.details_rfid import DetailsRFID as DetailsRFID
from regula.documentreader.webclient.gen.models.device_info import DeviceInfo as DeviceInfo
Expand Down
2 changes: 2 additions & 0 deletions regula/documentreader/webclient/gen/api/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@

if __import__("typing").TYPE_CHECKING:
# import apis into api package
from regula.documentreader.webclient.gen.api.default_api import DefaultApi
from regula.documentreader.webclient.gen.api.healthcheck_api import HealthcheckApi
from regula.documentreader.webclient.gen.api.process_api import ProcessApi
from regula.documentreader.webclient.gen.api.transaction_api import TransactionApi
Expand All @@ -13,6 +14,7 @@
LazyModule(
*as_package(__file__),
"""# import apis into api package
from regula.documentreader.webclient.gen.api.default_api import DefaultApi
from regula.documentreader.webclient.gen.api.healthcheck_api import HealthcheckApi
from regula.documentreader.webclient.gen.api.process_api import ProcessApi
from regula.documentreader.webclient.gen.api.transaction_api import TransactionApi
Expand Down
270 changes: 270 additions & 0 deletions regula/documentreader/webclient/gen/api/default_api.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,270 @@
# coding: utf-8

"""
Generated by: https://openapi-generator.tech
"""
import warnings
from pydantic import validate_call, Field, StrictFloat, StrictStr, StrictInt
from typing import Any, Dict, List, Optional, Tuple, Union
from typing_extensions import Annotated

from regula.documentreader.webclient.gen.models.database_document_list import DatabaseDocumentList

from regula.documentreader.webclient.gen.api_client import ApiClient, RequestSerialized
from regula.documentreader.webclient.gen.api_response import ApiResponse
from regula.documentreader.webclient.gen.rest import RESTResponseType


class DefaultApi:
"""NOTE: This class is auto generated by OpenAPI Generator
Ref: https://openapi-generator.tech

Do not edit the class manually.
"""

def __init__(self, api_client=None) -> None:
if api_client is None:
api_client = ApiClient.get_default()
self.api_client = api_client


@validate_call
def doclist(
self,
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
Tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
_request_auth: Optional[Dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
_headers: Optional[Dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> DatabaseDocumentList:
"""Returns the list of documents stored in the database that the Web Service API is running with.


:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
:type _request_timeout: int, tuple(int, int), optional
:param _request_auth: set to override the auth_settings for an a single
request; this effectively ignores the
authentication in the spec for a single request.
:type _request_auth: dict, optional
:param _content_type: force content-type for the request.
:type _content_type: str, Optional
:param _headers: set to override the headers for a single
request; this effectively ignores the headers
in the spec for a single request.
:type _headers: dict, optional
:param _host_index: set to override the host_index for a single
request; this effectively ignores the host_index
in the spec for a single request.
:type _host_index: int, optional
:return: Returns the result object.
""" # noqa: E501

_param = self._doclist_serialize(
_request_auth=_request_auth,
_content_type=_content_type,
_headers=_headers,
_host_index=_host_index
)

_response_types_map: Dict[str, Optional[str]] = {
'200': "DatabaseDocumentList",
}
response_data = self.api_client.call_api(
*_param,
_request_timeout=_request_timeout
)
response_data.read()
return self.api_client.response_deserialize(
response_data=response_data,
response_types_map=_response_types_map,
).data


@validate_call
def doclist_with_http_info(
self,
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
Tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
_request_auth: Optional[Dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
_headers: Optional[Dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> ApiResponse[DatabaseDocumentList]:
"""Returns the list of documents stored in the database that the Web Service API is running with.


:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
:type _request_timeout: int, tuple(int, int), optional
:param _request_auth: set to override the auth_settings for an a single
request; this effectively ignores the
authentication in the spec for a single request.
:type _request_auth: dict, optional
:param _content_type: force content-type for the request.
:type _content_type: str, Optional
:param _headers: set to override the headers for a single
request; this effectively ignores the headers
in the spec for a single request.
:type _headers: dict, optional
:param _host_index: set to override the host_index for a single
request; this effectively ignores the host_index
in the spec for a single request.
:type _host_index: int, optional
:return: Returns the result object.
""" # noqa: E501

_param = self._doclist_serialize(
_request_auth=_request_auth,
_content_type=_content_type,
_headers=_headers,
_host_index=_host_index
)

_response_types_map: Dict[str, Optional[str]] = {
'200': "DatabaseDocumentList",
}
response_data = self.api_client.call_api(
*_param,
_request_timeout=_request_timeout
)
response_data.read()
return self.api_client.response_deserialize(
response_data=response_data,
response_types_map=_response_types_map,
)


@validate_call
def doclist_without_preload_content(
self,
_request_timeout: Union[
None,
Annotated[StrictFloat, Field(gt=0)],
Tuple[
Annotated[StrictFloat, Field(gt=0)],
Annotated[StrictFloat, Field(gt=0)]
]
] = None,
_request_auth: Optional[Dict[StrictStr, Any]] = None,
_content_type: Optional[StrictStr] = None,
_headers: Optional[Dict[StrictStr, Any]] = None,
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
) -> RESTResponseType:
"""Returns the list of documents stored in the database that the Web Service API is running with.


:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
:type _request_timeout: int, tuple(int, int), optional
:param _request_auth: set to override the auth_settings for an a single
request; this effectively ignores the
authentication in the spec for a single request.
:type _request_auth: dict, optional
:param _content_type: force content-type for the request.
:type _content_type: str, Optional
:param _headers: set to override the headers for a single
request; this effectively ignores the headers
in the spec for a single request.
:type _headers: dict, optional
:param _host_index: set to override the host_index for a single
request; this effectively ignores the host_index
in the spec for a single request.
:type _host_index: int, optional
:return: Returns the result object.
""" # noqa: E501

_param = self._doclist_serialize(
_request_auth=_request_auth,
_content_type=_content_type,
_headers=_headers,
_host_index=_host_index
)

_response_types_map: Dict[str, Optional[str]] = {
'200': "DatabaseDocumentList",
}
response_data = self.api_client.call_api(
*_param,
_request_timeout=_request_timeout
)
return response_data.response


def _doclist_serialize(
self,
_request_auth,
_content_type,
_headers,
_host_index,
) -> RequestSerialized:

_host = None

_collection_formats: Dict[str, str] = {
}

_path_params: Dict[str, str] = {}
_query_params: List[Tuple[str, str]] = []
_header_params: Dict[str, Optional[str]] = _headers or {}
_form_params: List[Tuple[str, str]] = []
_files: Dict[
str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
] = {}
_body_params: Optional[bytes] = None

# process the path parameters
# process the query parameters
# process the header parameters
# process the form parameters
# process the body parameter


# set the HTTP header `Accept`
if 'Accept' not in _header_params:
_header_params['Accept'] = self.api_client.select_header_accept(
[
'application/json'
]
)


# authentication setting
_auth_settings: List[str] = [
]

return self.api_client.param_serialize(
method='GET',
resource_path='/api/doclist',
path_params=_path_params,
query_params=_query_params,
header_params=_header_params,
body=_body_params,
post_params=_form_params,
files=_files,
auth_settings=_auth_settings,
collection_formats=_collection_formats,
_host=_host,
_request_auth=_request_auth
)


Loading