Vision OCR API, REST: TextRecognitionAsync.getRecognition
To get recognition results.
HTTP request
GET https://ocr.api.cloud.yandex.net/ocr/v1/getRecognition
Query parameters
Parameter | Description |
---|---|
operationId | Required. Operation ID of async recognition request. The maximum string length in characters is 50. |
Response
HTTP Code: 200 - OK
{
"textAnnotation": {
"width": "string",
"height": "string",
"blocks": [
{
"boundingBox": {
"vertices": [
{
"x": "string",
"y": "string"
}
]
},
"lines": [
{
"boundingBox": {
"vertices": [
{
"x": "string",
"y": "string"
}
]
},
"text": "string",
"words": [
{
"boundingBox": {
"vertices": [
{
"x": "string",
"y": "string"
}
]
},
"text": "string",
"entityIndex": "string",
"textSegments": [
{
"startIndex": "string",
"length": "string"
}
]
}
],
"textSegments": [
{
"startIndex": "string",
"length": "string"
}
],
"orientation": "string"
}
],
"languages": [
{
"languageCode": "string"
}
],
"textSegments": [
{
"startIndex": "string",
"length": "string"
}
]
}
],
"entities": [
{
"name": "string",
"text": "string"
}
],
"tables": [
{
"boundingBox": {
"vertices": [
{
"x": "string",
"y": "string"
}
]
},
"rowCount": "string",
"columnCount": "string",
"cells": [
{
"boundingBox": {
"vertices": [
{
"x": "string",
"y": "string"
}
]
},
"rowIndex": "string",
"columnIndex": "string",
"columnSpan": "string",
"rowSpan": "string",
"text": "string",
"textSegments": [
{
"startIndex": "string",
"length": "string"
}
]
}
]
}
],
"fullText": "string",
"rotate": "string"
},
"page": "string"
}
Field | Description |
---|---|
textAnnotation | object Recognized text blocks in page or text from entities. |
textAnnotation. width |
string (int64) Page width in pixels. |
textAnnotation. height |
string (int64) Page height in pixels. |
textAnnotation. blocks[] |
object Recognized text blocks in this page. |
textAnnotation. blocks[]. boundingBox |
object Area on the page where the text block is located. |
textAnnotation. blocks[]. boundingBox. vertices[] |
object The bounding polygon vertices. |
textAnnotation. blocks[]. boundingBox. vertices[]. x |
string (int64) X coordinate in pixels. |
textAnnotation. blocks[]. boundingBox. vertices[]. y |
string (int64) Y coordinate in pixels. |
textAnnotation. blocks[]. lines[] |
object Recognized lines in this block. |
textAnnotation. blocks[]. lines[]. boundingBox |
object Area on the page where the line is located. |
textAnnotation. blocks[]. lines[]. boundingBox. vertices[] |
object The bounding polygon vertices. |
textAnnotation. blocks[]. lines[]. boundingBox. vertices[]. x |
string (int64) X coordinate in pixels. |
textAnnotation. blocks[]. lines[]. boundingBox. vertices[]. y |
string (int64) Y coordinate in pixels. |
textAnnotation. blocks[]. lines[]. text |
string Recognized text. |
textAnnotation. blocks[]. lines[]. words[] |
object Recognized words. |
textAnnotation. blocks[]. lines[]. words[]. boundingBox |
object Area on the page where the word is located. |
textAnnotation. blocks[]. lines[]. words[]. boundingBox. vertices[] |
object The bounding polygon vertices. |
textAnnotation. blocks[]. lines[]. words[]. boundingBox. vertices[]. x |
string (int64) X coordinate in pixels. |
textAnnotation. blocks[]. lines[]. words[]. boundingBox. vertices[]. y |
string (int64) Y coordinate in pixels. |
textAnnotation. blocks[]. lines[]. words[]. text |
string Recognized word value. |
textAnnotation. blocks[]. lines[]. words[]. entityIndex |
string (int64) ID of the recognized word in entities array. |
textAnnotation. blocks[]. lines[]. words[]. textSegments[] |
object Word position from full_text string. |
textAnnotation. blocks[]. lines[]. words[]. textSegments[]. startIndex |
string (int64) Start character position from full_text string. |
textAnnotation. blocks[]. lines[]. words[]. textSegments[]. length |
string (int64) Text segment length. |
textAnnotation. blocks[]. lines[]. textSegments[] |
object Line position from full_text string. |
textAnnotation. blocks[]. lines[]. textSegments[]. startIndex |
string (int64) Start character position from full_text string. |
textAnnotation. blocks[]. lines[]. textSegments[]. length |
string (int64) Text segment length. |
textAnnotation. blocks[]. lines[]. orientation |
string Angle of line rotation. |
textAnnotation. blocks[]. languages[] |
object A list of detected languages |
textAnnotation. blocks[]. languages[]. languageCode |
string Detected language code. |
textAnnotation. blocks[]. textSegments[] |
object Block position from full_text string. |
textAnnotation. blocks[]. textSegments[]. startIndex |
string (int64) Start character position from full_text string. |
textAnnotation. blocks[]. textSegments[]. length |
string (int64) Text segment length. |
textAnnotation. entities[] |
object Recognized entities. |
textAnnotation. entities[]. name |
string Entity name. |
textAnnotation. entities[]. text |
string Recognized entity text. |
textAnnotation. tables[] |
object |
textAnnotation. tables[]. boundingBox |
object Area on the page where the table is located. |
textAnnotation. tables[]. boundingBox. vertices[] |
object The bounding polygon vertices. |
textAnnotation. tables[]. boundingBox. vertices[]. x |
string (int64) X coordinate in pixels. |
textAnnotation. tables[]. boundingBox. vertices[]. y |
string (int64) Y coordinate in pixels. |
textAnnotation. tables[]. rowCount |
string (int64) Number of rows in table. |
textAnnotation. tables[]. columnCount |
string (int64) Number of columns in table. |
textAnnotation. tables[]. cells[] |
object Table cells. |
textAnnotation. tables[]. cells[]. boundingBox |
object Area on the page where the table cell is located. |
textAnnotation. tables[]. cells[]. boundingBox. vertices[] |
object The bounding polygon vertices. |
textAnnotation. tables[]. cells[]. boundingBox. vertices[]. x |
string (int64) X coordinate in pixels. |
textAnnotation. tables[]. cells[]. boundingBox. vertices[]. y |
string (int64) Y coordinate in pixels. |
textAnnotation. tables[]. cells[]. rowIndex |
string (int64) Row index. |
textAnnotation. tables[]. cells[]. columnIndex |
string (int64) Column index. |
textAnnotation. tables[]. cells[]. columnSpan |
string (int64) Column span. |
textAnnotation. tables[]. cells[]. rowSpan |
string (int64) Row span. |
textAnnotation. tables[]. cells[]. text |
string Text in cell. |
textAnnotation. tables[]. cells[]. textSegments[] |
object Table cell position from full_text string. |
textAnnotation. tables[]. cells[]. textSegments[]. startIndex |
string (int64) Start character position from full_text string. |
textAnnotation. tables[]. cells[]. textSegments[]. length |
string (int64) Text segment length. |
textAnnotation. fullText |
string Full text recognized from image. |
textAnnotation. rotate |
string Angle of image rotation. |
page | string (int64) Page number in PDF file. |