Uzbekistan ID Karta OCR Python SDK

Instantly extract data and MRZ from Uzbek IDs using our native Python library.

Parsing ID Karta Challenges

Uzbekistan ID Kartas present unique OCR challenges. Firstly, the mix of Latin and Cyrillic scripts within the same document requires specialized language models. Secondly, varying print quality and inconsistent lighting conditions often degrade image quality, leading to inaccurate data extraction.

Why StructOCR for Uzbekistan

Our model is specifically trained on a large dataset of Uzbekistan ID Kartas, accounting for script variations and image quality issues. The Python SDK provides a simple, streamlined interface for developers, abstracting away the complexities of OCR and delivering structured data with minimal coding effort. This ensures accurate extraction of the 14 digits structure and full Machine Readable Zone (MRZ) from ID cards, making it ideal for kyc automation workflows. Leverage our id parsing api to integrate Uzbekistan ID data extraction seamlessly into your applications.

Common Use Cases in Uzbekistan

  • Digital Onboarding: Verify users for Fintech apps in Uzbekistan.
  • Telecom Registration: Automate SIM card registration with ID Karta and MRZ cross-check.
  • Hotel Check-in: Speed up guest registration workflows.
Need more testing? Create a free account to get 200 free credits (equals 100 National ID scans).

Python SDK Integration

Install the SDK via pip: `pip install structocr`. Then use the following code.

Prerequisite: Python 3.6+ and `structocr` library installed.

from structocr import StructOCR

# Get 200 free credits:
# 👉 https://structocr.com/register
# Initialize with your API Key
client = StructOCR("YOUR_API_KEY_HERE")

def scan_uzbekistan_id():
    # Note: Supports JPG, PNG, WebP (Max 4.5MB)
    # Target: ID Karta
    image_path = "uzbekistan_national_id.jpg"

    try:
        print(f"Scanning {image_path}...")
        
        # The SDK handles file upload and API communication
        # It automatically detects that this is a Uzbek document
        result = client.scan_national_id(image_path)

        # Check success flag (SDK returns a dict matching the JSON response)
        if result.get('success'):
            data = result['data']
            print("✅ Uzbekistan Extraction Successful!\n")
            
            # Basic Identity
            print(f"Region:      {data.get('country_code')} (Series: {data.get('card_series')})")
            print(f"Name:        {data.get('given_names')} {data.get('surname')}")
            print(f"ID Number:   {data.get('document_number')}")
            
            # Critical Field: Personal Identity Number (CNP/CPF/NIN)
            print(f"Personal #:  {data.get('personal_number')}")
            
            # Demographics
            print(f"DOB:         {data.get('date_of_birth')} ({data.get('sex')})")
            print(f"Address:     {data.get('address')}")
            
            # Extract MRZ from additional_fields
            additional = data.get('additional_fields', {})
            if additional.get('mrz_line_1'):
                print("\n--- MRZ Data ---")
                print(additional.get('mrz_line_1'))
                print(additional.get('mrz_line_2'))
                print(additional.get('mrz_line_3'))
        else:
            print(f"❌ Extraction Failed: {result.get('error')}")

    except Exception as e:
        # Handle SDK or Network errors
        print(f"An error occurred: {e}")

if __name__ == "__main__":
    scan_uzbekistan_id()

Technical Specs

  • •Latency: < 4s (Average)
  • •Availability: Served from Cloudflare's global edge network
  • •Security: AES-256 Encryption & SOC2 Compliant
  • •Input: JPG, PNG, WebP (Max 4.5MB)
  • •Output: JSON (Structured Data with MRZ)

Key Features

  • •Native Script Support: Reads English and local characters.
  • •MRZ Extraction: Seamlessly parses the 3-line Machine Readable Zone (MRZ) for automated cross-verification.
  • •Blur Detection: Automatically rejects blurry images.
  • •Fraud Check: Validates ID Karta number format.
  • •Smart Crop: Removes background noise automatically.

JSON Response Example

The SDK returns a Python dictionary matching this JSON structure, including the full MRZ data.

{
  "success": true,
  "data": {
    "type": "national_id",
    "country_code": "UZB",
    "nationality": "UZBEKISTAN",
    "document_number": "AA1234567",
    "card_series": "",
    "personal_number": "30101901234567",
    "surname": "ABDULLAYEV",
    "given_names": "JAMSHID",
    "sex": "M",
    "date_of_birth": "1990-05-15",
    "place_of_birth": "TASHKENT",
    "address": "Amir Temur ko'chasi, 10-uy, Toshkent",
    "date_of_issue": "2020-01-01",
    "date_of_expiry": "2030-01-01",
    "issuing_authority": "IIB",
    "additional_fields": {
      "phone_number": null,
      "tramite_number": null,
      "ejemplar": null,
      "mrz_line_1": "I<UZBAA12345674<<<<<<<<<<<<<<<",
      "mrz_line_2": "9005156M3001018UZB<<<<<<<<<<<4",
      "mrz_line_3": "ABDULLAYEV<<JAMSHID<<<<<<<<<<<"
    }
  }
}

Frequently Asked Questions

Does the Python SDK handle image uploads?

Yes, the SDK automatically handles base64 encoding and file uploads.

Can it read the MRZ on the back of the ID Karta?

Yes, our API automatically extracts all three MRZ lines if the back of the card is provided.

Is data stored?

Only briefly. Uploaded images and results are kept for at most 24 hours for quality spot-checks, then deleted.

How to handle errors?

The SDK result dictionary contains a 'success' boolean and an 'error' message if failed.

You May Also Like

Related tutorials, platform guides, and comparisons

Country Tutorial

Uzbekistan Passport OCR with Python SDK

Use the official StructOCR Python SDK and FastAPI to extract structured MRZ and VIZ data from Uzbekistan passports with a server-side integration.

Python · Passport
Country Tutorial

Ethiopia Fayda ID OCR Python SDK

Python Tutorial: Automate KYC in Ethiopia. Extract data from Fayda ID using StructOCR Python SDK. Supports native text.

Python · fayda id
Country Tutorial

South Africa Smart ID Card OCR Python SDK

Python Tutorial: Automate KYC in South Africa. Extract data from Smart ID Card using StructOCR Python SDK. Supports native text and MRZ extraction.

Python · smart id card
Country Tutorial

Chile Cédula OCR Python SDK

Python Tutorial: Automate KYC in Chile. Extract data from the Chilean Cédula de Identidad using StructOCR Python SDK. Supports RUN/RUT extraction and native Spanish text parsing.

Python · cédula de identidad
Country Tutorial

Tanzania NIDA Card OCR Python SDK

Python Tutorial: Automate KYC in Tanzania. Extract data from NIDA Card using StructOCR Python SDK. Supports native text and MRZ extraction.

Python · National ID
Country Tutorial

Malaysia MyKad OCR Python SDK

Python Tutorial: Automate KYC in Malaysia. Extract data from the Malaysian Identity Card (MyKad) using StructOCR Python SDK. Supports NRIC extraction and multi-line address parsing.

Python · mykad
Tutorial

Python Receipt OCR API SDK

Tutorial: Extract merchants, line items, and totals from receipts using the StructOCR Python SDK. Upload an image for a free test! Ideal for fintech ETL pipelines, AI accounting, and Pandas dataframes.

Python · Receipt
Tutorial

Python Weighbridge Ticket OCR API Tutorial

Build a Python weighbridge ticket OCR workflow. Extract ticket, vehicle, material, gross, tare, and net weights into validated JSON with the StructOCR SDK.

Python · Weighbridge Ticket
Tutorial

C# Weighbridge Ticket OCR API Tutorial

Integrate weighbridge ticket OCR in C# and .NET. Send a Base64 image and extract vehicle, material, gross, tare, net, and validation fields as JSON.

C# · Weighbridge Ticket
Tutorial

C# Receipt OCR API

Upload an image for a free test! Integrate a robust Receipt OCR API into your C# .NET app. Accurately extract merchants, line items, taxes, and totals from crumpled thermal receipts.

C# · Receipt

Technical Comparisons & Integrations

Explore platform integrations and competitive analysis

From tutorial to production in 5 minutes.

You've seen the code. Now get your API key, grab your 200 free credits, and see it work with your own images. No credit card required.

Instant Access Cancel Anytime No Credit Card