Weighbridge Automation: Container OCR API
Sync physical container weight with digital records instantly. Upload your local weighbridge CCTV captures to test our extraction accuracy for free, ensuring rapid truck processing.

The Weighbridge Data Bottleneck
Weighbridges are critical chokepoints in logistics yards. When trucks mount the scale, manual data entry of the container number creates unnecessary delays, increases driver dwell time, and introduces human error that corrupts VGM (Verified Gross Mass) records. Standard OCR solutions often fail here due to skewed camera angles from scale-side pillars and heavy shadowing. To see how our engine cuts through these baseline visual challenges, you can upload a test image to explore our core Container OCR capabilities completely free.
Instant Extraction, Zero SDK Bloat
Delivered strictly as a high-performance REST API to ensure seamless integration into any language without heavy SDK dependencies, this endpoint is powered by our Logistics Container OCR engine[cite: 2]. It processes incoming weighbridge captures in milliseconds across our global Cloudflare infrastructure. The engine applies strict ISO 6346 validation to verify the owner code and calculate the check digit, guaranteeing data integrity before it reaches your scale management software[cite: 2].
Live Demo: Container OCR
No registration required. Upload a file to test the extraction.
Drop files here or click to browse
JPG · PNG · WebP · up to 500 files · max 4.5 MB each
Weighbridge & Scale Scenarios
Automated VGM Compliance
Ensure SOLAS VGM compliance by automatically binding the accurately extracted ISO 6346 code to the measured gross mass weight without human intervention. Ready to scale your operations? View flexible pricing to secure maximum processing limits, supporting modern frictionless payment rails like USDT/USDC.
Fraud & Swap Prevention
Mitigate logistics fraud by visually confirming the container ID on the scale matches the expected manifest, preventing unauthorized container swapping before departure.
Unmanned Scale Kiosks
Enable drivers to process their own loads 24/7. The OCR API verifies the container in the background while the driver scans their paperwork, lifting the exit barrier automatically.
TOS & ERP Synchronization
Push perfectly validated container records directly from the scale software into your Terminal Operating System (TOS) or freight forwarder ERP in real-time.
Technical Specs
- Validation: Built-in ISO 6346 checksum verification eliminates weight ticket mismatches[cite: 2].
- Edge Optimization: Deployed purely on Cloudflare's edge network, ensuring ultra-low t1/t2 latency so trucks aren't left waiting on the scale.
- Input Versatility: Fully supports raw Base64 strings, direct multipart file uploads, and public image URLs—ideal for offline or intranet scale environments[cite: 2].
- Angle Correction: Algorithms specifically tuned to handle the low-angle, skewed perspectives common to ground-mounted weighbridge cameras.
Key Features
- Free Image Testing: Instantly upload images from your actual weighbridge cameras to test extraction accuracy before writing any integration code.
- Standardized Output: Returns a unified `container_number` string while perfectly isolating the 3-letter Owner Code, 1-letter Category, 6-digit Serial, and Check Digit in a parsed object.
- Harsh Environment Tolerance: Advanced filtering mitigates deep shadows from corrugated metal, rust, dirt, and intense direct sunlight common in port environments[cite: 2].
Integration & AI Prompts
Call the endpoint directly via HTTP. The API flexibly accepts standard image URLs, direct multipart file uploads, or Base64-encoded strings to minimize network latency on edge networks[cite: 2].
import requests
import base64
# Prepare Base64 Image from local weighbridge CCTV capture
with open("scale_lane_2_capture.jpg", "rb") as image_file:
base64_image = base64.b64encode(image_file.read()).decode('utf-8')
url = "https://api.structocr.com/v1/container"
headers = {
"x-api-key": "YOUR_API_KEY",
"Content-Type": "application/json"
}
payload = {
"img": base64_image
}
try:
print("Scanning Weighbridge Capture...")
response = requests.post(url, headers=headers, json=payload)
result = response.json()
if result.get('success'):
data = result['data']
print("✅ Container Code Extracted!")
print(f"Full Number: {data.get('container_number')}")
print(f"Valid ISO: {data.get('is_valid')}")
print(f"Confidence: {data.get('confidence')}")
else:
print(f"❌ Extraction Failed: {result.get('error')} - {result.get('message')}")
except Exception as e:
print(f"An error occurred: {e}")Standardized JSON Output
The API returns a cleanly parsed payload providing the full consolidated container number, validating the check digit, and breaking down the ISO 6346 components.
{
"success": true,
"data": {
"container_number": "ZCSU8921655",
"is_valid": true,
"confidence": "High",
"parsed": {
"owner_code": "ZCS",
"category": "U",
"serial_number": "892165",
"check_digit": "5"
}
}
}Frequently Asked Questions
Can I test the API with my own weighbridge camera images for free?
Absolutely. You can upload images directly on our platform to test the OCR engine's performance against your specific scale's camera angles and lighting conditions completely free of charge.
Do we need to expose our scale CCTV images to public URLs to use this API?
No. The API is designed for secure, local integration, natively accepting direct file uploads and Base64-encoded strings so your sensitive cargo images never need to be hosted publicly[cite: 2].
How does the API format the extracted data?
It returns a standard JSON payload containing the complete `container_number` string for immediate use in your weight ticket, alongside a `parsed` object that separates the owner code, serial number, and check digit.
Explore More Container Solutions
Choosing the Right Container OCR System Provider
Evaluating a container OCR system provider? Compare our high-concurrency API infrastructure. Upload your image for a free test to see our extraction accuracy.
Intermodal Rail OCR API for North America
Automate high-speed intermodal rail scanning across North America. Extract container numbers from moving trains natively. Upload your image for a free test.
ISO 6346 Validation: Container OCR API
Parse and validate ISO 6346 container codes with our high-accuracy OCR API. Upload images to test extraction and automatic check-digit calculation for free.
Industrial Shipping Container Number Scanner API
Looking for a shipping container number scanner? Turn any mobile device or CCTV camera into an industrial container scanner via our REST API. Upload an image for a free test.
BIC Code Extraction: Container OCR API
Extract BIC Owner Codes from shipping containers instantly. Upload your images to test our high-accuracy BIC Code OCR API for free and automate equipment tracking.
How to Build a Container Recognition Scanner App
Step-by-step developer guide on how to build a custom container recognition scanner using a lightweight API. Test your image payloads for free today.
Check Digit Calculator: Container OCR API
Automate container check digit calculation with our high-accuracy OCR API. Upload images to test ISO 6346 validation for free and prevent manual data entry errors.
Enterprise Container Code Reader Software API
Integrate industrial container code reader software into your TOS or WMS via a lightweight REST API. Upload your images for a free accuracy test today.
Container OCR API for Canadian Terminals
High-accuracy ISO 6346 container number extraction built for extreme Canadian weather. Overcome snow, ice, and glare. Upload an image for a free test today.
Automated Crane Tally: Container OCR API
Automate crane tally operations with our Container OCR API. Upload STS or RTG crane camera captures to test our ISO 6346 extraction for free. Handles 180-degree rotations effortlessly.
Technical Comparisons & Integrations
Explore platform integrations and competitive analysis
Add Container OCR using Cursor in 5 Minutes
Step-by-step guide to integrating the StructOCR shipping container API using the Cursor AI code editor. Build logistics and yard management tools rapidly.
Google Cloud Vision vs. StructOCR API for Shipping Containers
Comparing generic enterprise OCR solutions like Google Cloud Vision against StructOCR's purpose-built API for ISO 6346 shipping container recognition.
Add Container OCR to Your Lovable.dev App in 5 Minutes
Step-by-step guide to integrating the StructOCR shipping container API into a Lovable.dev app. Build logistics and yard management tools with zero backend.
Manual TOS Entry vs. Container OCR Automation API
Analyzing the ROI and operational efficiency of replacing manual gate checkers with an automated Container OCR API in logistics yards.
Add Container OCR to Your Replit App in 5 Minutes
Step-by-step guide to integrating the StructOCR shipping container API into a Replit application. Build logistics and yard management tools using Replit Agent and Secrets.
Tesseract OCR vs. StructOCR API for ISO 6346 Container Numbers
A technical comparison for developers evaluating open-source Tesseract vs. a dedicated cloud API for extracting shipping container numbers.
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.