Skip to content
Merged
Show file tree
Hide file tree
Changes from 5 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
2 changes: 2 additions & 0 deletions .openapi-generator-ignore
Original file line number Diff line number Diff line change
Expand Up @@ -11,3 +11,5 @@ README.md
.gitignore
setup.py
regula/documentreader/webclient/__init__.py
pyproject.toml
.github/workflows/python.yml
126 changes: 103 additions & 23 deletions .openapi-generator/FILES

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion .openapi-generator/VERSION
Original file line number Diff line number Diff line change
@@ -1 +1 @@
5.0.0
7.12.0
8 changes: 6 additions & 2 deletions Pipfile
Original file line number Diff line number Diff line change
Expand Up @@ -6,18 +6,22 @@ name = "pypi"
[packages]
certifi = ">=2024.07.04"
six = ">=1.10"
python-dateutil = ">=2.5.3"
urllib3 = ">=1.26.19"
python-dateutil = ">=2.8.2"
urllib3 = ">=1.25.3, <3.0.0"
vistir = ">=0.4.0, <=0.6.1"
idna = "==3.7"
requests = ">=2.32.3"
pydantic = ">=2"
typing-extensions = ">=4.7.1"

[dev-packages]
setuptools = "==74.1.1"
wheel = "*"
twine = "*"
chardet = "*"
packaging = ">=22.0"
types-python-dateutil = ">=2.8.19.14"
mypy = ">=1.5"

[requires]
python_version = "3.8"
758 changes: 506 additions & 252 deletions Pipfile.lock

Large diffs are not rendered by default.

9 changes: 3 additions & 6 deletions example/example-rcl.py
Original file line number Diff line number Diff line change
Expand Up @@ -22,8 +22,8 @@
api.license = regula_license

params = ProcessParams(
scenario=Scenario.FULL_PROCESS,
result_type_output=[
scenario=Scenario.FULLPROCESS,
resultTypeOutput=[
# actual results
Result.STATUS, Result.AUTHENTICITY, Result.TEXT, Result.IMAGES,
Result.DOCUMENT_TYPE, Result.DOCUMENT_TYPE_CANDIDATES, Result.IMAGE_QUALITY,
Expand All @@ -36,10 +36,7 @@
)
request = RecognitionRequest(
process_params=params,
container_list=ContainerList([
LicenseRequest(license_),
EncryptedRCLRequest(encrypted_rcl)
])
container_list=ContainerList(List = [LicenseRequest(license_), EncryptedRCLRequest(encrypted_rcl)])
)
response = api.process(request)

Expand Down
6 changes: 3 additions & 3 deletions example/example.py
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@
"X-CLIENT-KEY": "123",
"Authorization": "Bearer 123"
}
params = ProcessParams(already_cropped=True, scenario=Scenario.FULL_PROCESS)
params = ProcessParams(alreadyCropped=True, scenario=Scenario.FULLPROCESS)

# Add license to request
# request = RecognitionRequest(system_info=ProcessSystemInfo(license=base64.b64encode(regula_license).decode()), process_params=params, images=[
Expand All @@ -38,8 +38,8 @@
])
response = api.process(request)

request_json = request.json # example for request & response raw json
response_json = response.json
request_json = request.to_json() # example for request & response raw json
response_json = response.to_json()

# status examples
response_status = response.status
Expand Down
6 changes: 5 additions & 1 deletion generator-config.json
Original file line number Diff line number Diff line change
@@ -1,4 +1,8 @@
{
"packageName": "regula.documentreader.webclient.gen",
"extPackageName": "regula.documentreader.webclient.ext"
"extPackageName": "regula.documentreader.webclient.ext",
"typeMappings" : {
"ContainerListListInner": "ResultItem",
"AuthenticityCheckResultListInner": "AuthenticityCheckResultItem"
}
}
Loading