Skip to content

Image To Text API

Image To Text API uses advanced machines to recognize and extract text from images. It supports multiple languages and returns the raw text along with a confidence score.

POST /api/v1/ocr

The following parameters are accepted in the request body:

FieldTypeRequiredDescription
urlstringYesDirect URL to the image file (JPG, PNG, BMP).
langstringOptionalLanguage code (default: eng).
Terminal window
curl -X POST https://heavstal.com.ng/api/v1/ocr \
-H "Content-Type: application/json" \
-H "x-api-key: <YOUR_API_KEY>" \
-d '{"url": "https://i.imgur.com/example.png", "lang": "eng"}'
{
"status": "success",
"creator": "HEAVSTAL TECH",
"data": {
"confidence": 92.5,
"text": "HEAVSTAL TECH\nBuilding the future."
}
}