Skip to main content

Vehicle Registration Book OCR

Extract Vehicle Registration Book information from an image or PDF.


description: Extract Vehicle Registration Book Information

Vehicle Registration Book OCR

Extract Vehicle Registration Book information from an image or PDF.

Request Body Parameters

KeyTypeDescription
imagestrInput base64 images encoded utf-8

Response Keys

KeyTypeDescription
statusstrThe summary status.
errorList[Union[ErrorObjectV3, None]]The list of errors that occurred while extracting information from each image or page.
dataList[Union[ObjClassV3, EmptyDict]]The per-page response payload; empty dictionaries represent pages that did not return data.

Field Schema

ObjClassV3

KeyTypeDescription
valueOptional[str]The string value of a given field.
bboxesOptional[List[List[List[int]]]]The OCR bounding boxes associated with the detected field.
bboxes_normOptional[List[List[List[float]]]]Bounding boxes normalized to a [0, 1] scale.
confidenceOptional[float]The OCR confidence level.

ErrorObjectV3

KeyTypeDescription
objectstrThe error object label.
codeOptional[str]The code representing the type of error.
messageOptional[str]The human-readable description of the error.

EmptyDict refers to an empty object {} used as a placeholder when a page returns no OCR payload.

Response Definition

HTTP StatusCodeMessageDescription
200--OCR success.
206206Partial contentSome page of the request is invalid.
400400Bad requestThe API cannot recognize the supplied image as a vehicle registration book.
41320000The request image base64 is too large.Image must not exceed 10 MB in size and 10000 x 10000 pixels in dimensions.
42220002Cannot read specified imageThe API cannot convert the provided base64 string into an image.
50040001Internal ErrorAn error occurs within a downstream sub-service.
50340000Internal ErrorThe required sub-service is currently unavailable.
206 / 400*400Internal process error during extract image page: {page}The API could not extract information from the specified page.
206 / 400*30000Internal error during extract image page: {page}.The page referenced in the error message caused an undefined error.
206 / 400*30001Internal process error during extract page: {page}The page referenced in the error message caused an undefined error.

* Indicates per-page errors when at least one page in a multi-page request fails.

Extract Vehicle Registration Book Information

POST https://api.aigen.online/aiscript/vehicle-registration-book/v3

Request Body

NameTypeDescription
image*StringInput base64 images encoded utf-8
{
"status": "success",
"error": [],
"data": [
{
"ownership": {
"value": "ไอเจ็น จำกัด",
"bboxes": [
[
[289, 1305],
[571, 1305],
[571, 1351],
[289, 1351]
]
],
"bboxes_norm": [
[
[0.1748, 0.5579],
[0.3454, 0.5579],
[0.3454, 0.5776],
[0.1748, 0.5776]
]
],
"confidence": 0.9860
},
"model": {
"value": "BAYARFAY10EHA1",
"bboxes": [
[
[747, 575],
[1014, 575],
[1014, 607],
[747, 607]
]
],
"bboxes_norm": [
[
[0.4519, 0.2458],
[0.6134, 0.2458],
[0.6134, 0.2595],
[0.4519, 0.2595]
]
],
"confidence": 0.9978
}
}
]
}
import requests

api = "https://api.aigen.online/aiscript/vehicle-registration-book/v3"
headers = {"x-aigen-key": "<key>"}
data = {"image": "<base64_string>"}

res = requests.post(api, json=data, headers=headers)
print(res.json())