tencent cloud

Feedback

PhilippinesSssIDOCR

Last updated: 2023-09-05 15:21:42

    1. API Description

    Domain name for API request: ocr.tencentcloudapi.com.

    This API is used to recognize a Philippine SSSID/UMID card.

    A maximum of 20 requests can be initiated per second for this API.

    We recommend you to use API Explorer
    Try it
    API Explorer provides a range of capabilities, including online call, signature authentication, SDK code generation, and API quick search. It enables you to view the request, response, and auto-generated examples.

    2. Input Parameters

    The following request parameter list only provides API request parameters and some common parameters. For the complete common parameter list, see Common Request Parameters.

    Parameter Name Required Type Description
    Action Yes String Common Params. The value used for this API: RecognizePhilippinesSssIDOCR.
    Version Yes String Common Params. The value used for this API: 2018-11-19.
    Region No String Common Params. This parameter is not required for this API.
    ReturnHeadImage Yes Boolean Whether to return the identity photo.
    ImageBase64 No String The Base64-encoded value of an image.
    Supported image formats: PNG, JPG, and JPEG. GIF is currently not supported.
    Supported image size: The downloaded image after Base64 encoding can be up to 7 MB. The download time of the image cannot exceed 3s.
    Either the ImageUrl or ImageBase64 of the image must be provided. If both are provided, only ImageUrl will be used.
    ImageUrl No String The URL of the image.
    Supported image formats: PNG, JPG, and JPEG. GIF is currently not supported.
    Supported image size: The downloaded image after Base64 encoding can be up to 7 MB. The download time of the image cannot exceed 3s.
    We recommend that you store the image in Tencent Cloud for higher download speed and stability.
    For a non-Tencent Cloud URL, the download speed and stability may be affected.

    3. Output Parameters

    Parameter Name Type Description
    HeadPortrait TextDetectionResult The Base64-encoded identity photo.
    LicenseNumber TextDetectionResult The common reference number (CRN).
    FullName TextDetectionResult The full name.
    Birthday TextDetectionResult The date of birth.
    RequestId String The unique request ID, which is returned for each request. RequestId is required for locating a problem.

    4. Example

    Example1 Recognizing a Philippine SSSID/UMID card

    This example shows you how to recognize a Philippine SSSID/UMID card.

    Input Example

    https://ocr.tencentcloudapi.com/?Action=RecognizePhilippinesSssIDOCR
    &ImageUrl=https://xx/a.jpg
    &ReturnHeadImage=false
    &<Common request parameters>
    

    Output Example

    {
        "Response": {
            "Birthday": {
                "Polygon": [
                    {
                        "X": 543,
                        "Y": 805
                    },
                    {
                        "X": 754,
                        "Y": 805
                    },
                    {
                        "X": 754,
                        "Y": 842
                    },
                    {
                        "X": 543,
                        "Y": 842
                    }
                ],
                "Value": "JULY 7,1980"
            },
            "FullName": {
                "Polygon": [
                    {
                        "X": 540,
                        "Y": 609
                    },
                    {
                        "X": 1094,
                        "Y": 609
                    },
                    {
                        "X": 1094,
                        "Y": 664
                    },
                    {
                        "X": 540,
                        "Y": 664
                    }
                ],
                "Value": "JEFFREY"
            },
            "HeadPortrait": {
                "Polygon": [],
                "Value": ""
            },
            "LicenseNumber": {
                "Polygon": [
                    {
                        "X": 533,
                        "Y": 736
                    },
                    {
                        "X": 1014,
                        "Y": 739
                    },
                    {
                        "X": 1014,
                        "Y": 816
                    },
                    {
                        "X": 533,
                        "Y": 813
                    }
                ],
                "Value": "33-111111-1"
            },
            "RequestId": "11111-11111-11111-11111"
        }
    }
    

    5. Developer Resources

    SDK

    TencentCloud API 3.0 integrates SDKs that support various programming languages to make it easier for you to call APIs.

    Command Line Interface

    6. Error Code

    The following only lists the error codes related to the API business logic. For other error codes, see Common Error Codes.

    Error Code Description
    FailedOperation.DownLoadError File download failed.
    FailedOperation.ImageDecodeFailed Image decoding failed.
    FailedOperation.OcrFailed OCR failed.
    FailedOperation.UnKnowError Unknown error.
    FailedOperation.UnOpenError The service is not activated.
    InvalidParameter.EngineImageDecodeFailed Image decoding failed.
    InvalidParameterValue.InvalidParameterValueLimit Incorrect parameter value.
    LimitExceeded.TooLargeFileError The file is too large.
    ResourcesSoldOut.ChargeStatusException Exceptional billing status.