Skip to content
Merged
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
2 changes: 1 addition & 1 deletion Pipfile
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ verify_ssl = true
name = "pypi"

[packages]
certifi = "==2022.6.15.1"
certifi = "==2022.12.7"
six = ">=1.10"
python-dateutil = ">=2.5.3"
urllib3 = ">=1.15.1"
Expand Down
319 changes: 153 additions & 166 deletions Pipfile.lock

Large diffs are not rendered by default.

3 changes: 3 additions & 0 deletions example/example.py
Original file line number Diff line number Diff line change
Expand Up @@ -43,6 +43,9 @@
])
response = api.process(request)

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

# status examples
response_status = response.status
doc_overall_status = "valid" if response_status.overall_status == CheckResult.OK else "not valid"
Expand Down
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
import json
import base64
from typing import List, Union

Expand Down Expand Up @@ -80,3 +81,7 @@ def __init__(
process_param=process_params, container_list=container_list,
system_info=ProcessSystemInfo(), tag=tag
)

@property
def json(self) -> str:
return json.dumps(self.to_dict())
Original file line number Diff line number Diff line change
@@ -1,3 +1,5 @@
import base64
import json
from typing import Optional, List
from regula.documentreader.webclient import ImageQualityCheckList, OneCandidate
from regula.documentreader.webclient.ext.models.authenticity.authenticity_check_list import AuthenticityCheckList
Expand All @@ -21,6 +23,10 @@ def text(self) -> Optional[Text]:
return result.text
return None

@property
def json(self) -> str:
return json.dumps(self.low_lvl_response.to_dict())

@property
def status(self) -> Optional[Status]:
result = self.result_by_type(Result.STATUS)
Expand Down
4 changes: 3 additions & 1 deletion regula/documentreader/webclient/gen/models/scenario.py
Original file line number Diff line number Diff line change
Expand Up @@ -40,6 +40,8 @@ class Scenario(object):

MRZ_AND_LOCATE = "MrzAndLocate"

BARCODE_AND_LOCATE = "BarcodeAndLocate"

MRZ_OR_OCR = "MrzOrOcr"

MRZ_OR_BARCODE_OR_OCR = "MrzOrBarcodeOrOcr"
Expand All @@ -60,7 +62,7 @@ class Scenario(object):

CAPTURE = "Capture"

allowable_values = [MRZ, BARCODE, LOCATE, OCR, DOCTYPE, MRZ_OR_BARCODE, MRZ_OR_LOCATE, MRZ_AND_LOCATE, MRZ_OR_OCR, MRZ_OR_BARCODE_OR_OCR, LOCATE_VISUAL_AND_MRZ_OR_OCR, FULL_PROCESS, FULL_AUTH, ID3RUS, RUS_STAMP, OCR_FREE, CREDIT_CARD, CAPTURE] # noqa: E501
allowable_values = [MRZ, BARCODE, LOCATE, OCR, DOCTYPE, MRZ_OR_BARCODE, MRZ_OR_LOCATE, MRZ_AND_LOCATE, BARCODE_AND_LOCATE, MRZ_OR_OCR, MRZ_OR_BARCODE_OR_OCR, LOCATE_VISUAL_AND_MRZ_OR_OCR, FULL_PROCESS, FULL_AUTH, ID3RUS, RUS_STAMP, OCR_FREE, CREDIT_CARD, CAPTURE] # noqa: E501

"""
Attributes:
Expand Down