Yandex Cloud
Поиск
Связаться с намиПодключиться
  • Документация
  • Блог
  • Все сервисы
  • Статус работы сервисов
    • Популярные
    • Инфраструктура и сеть
    • Платформа данных
    • Контейнеры
    • Инструменты разработчика
    • Бессерверные вычисления
    • Безопасность
    • Мониторинг и управление ресурсами
    • Машинное обучение
    • Бизнес-инструменты
  • Все решения
    • По отраслям
    • По типу задач
    • Экономика платформы
    • Безопасность
    • Техническая поддержка
    • Каталог партнёров
    • Обучение и сертификация
    • Облако для стартапов
    • Облако для крупного бизнеса
    • Центр технологий для общества
    • Облако для интеграторов
    • Поддержка IT-бизнеса
    • Облако для фрилансеров
    • Обучение и сертификация
    • Блог
    • Документация
    • Контент-программа
    • Мероприятия и вебинары
    • Контакты, чаты и сообщества
    • Идеи
    • Истории успеха
    • Тарифы Yandex Cloud
    • Промоакции и free tier
    • Правила тарификации
  • Документация
  • Блог
Проект Яндекса
© 2025 ООО «Яндекс.Облако»
Yandex Vision OCR
  • Начало работы
  • Управление доступом
  • Правила тарификации
    • Аутентификация в API
        • Overview
          • Overview
          • Recognize
          • GetRecognition
  • История изменений
  • Вопросы и ответы

В этой статье:

  • HTTP request
  • Query parameters
  • Response
  • TextAnnotation
  • Block
  • Polygon
  • Vertex
  • Line
  • Word
  • TextSegments
  • DetectedLanguage
  • Entity
  • Table
  • TableCell
  1. Справочники API
  2. OCR API (англ.)
  3. REST
  4. TextRecognitionAsync
  5. GetRecognition

Vision OCR API, REST: TextRecognitionAsync.GetRecognition

Статья создана
Yandex Cloud
Обновлена 26 ноября 2024 г.
  • HTTP request
  • Query parameters
  • Response
  • TextAnnotation
  • Block
  • Polygon
  • Vertex
  • Line
  • Word
  • TextSegments
  • DetectedLanguage
  • Entity
  • Table
  • TableCell

To get recognition results.

HTTP requestHTTP request

GET https://ocr.api.cloud.yandex.net/ocr/v1/getRecognition

Query parametersQuery parameters

Field

Description

operationId

string

Required field. Operation ID of async recognition request.

ResponseResponse

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

TextAnnotation

Recognized text blocks in page or text from entities.

page

string (int64)

Page number in PDF file.

TextAnnotationTextAnnotation

Field

Description

width

string (int64)

Page width in pixels.

height

string (int64)

Page height in pixels.

blocks[]

Block

Recognized text blocks in this page.

entities[]

Entity

Recognized entities.

tables[]

Table

fullText

string

Full text recognized from image.

rotate

enum (Angle)

Angle of image rotation.

  • ANGLE_UNSPECIFIED
  • ANGLE_0
  • ANGLE_90
  • ANGLE_180
  • ANGLE_270

BlockBlock

Field

Description

boundingBox

Polygon

Area on the page where the text block is located.

lines[]

Line

Recognized lines in this block.

languages[]

DetectedLanguage

A list of detected languages

textSegments[]

TextSegments

Block position from full_text string.

PolygonPolygon

Field

Description

vertices[]

Vertex

The bounding polygon vertices.

VertexVertex

Field

Description

x

string (int64)

X coordinate in pixels.

y

string (int64)

Y coordinate in pixels.

LineLine

Field

Description

boundingBox

Polygon

Area on the page where the line is located.

text

string

Recognized text.

words[]

Word

Recognized words.

textSegments[]

TextSegments

Line position from full_text string.

orientation

enum (Angle)

Angle of line rotation.

  • ANGLE_UNSPECIFIED
  • ANGLE_0
  • ANGLE_90
  • ANGLE_180
  • ANGLE_270

WordWord

Field

Description

boundingBox

Polygon

Area on the page where the word is located.

text

string

Recognized word value.

entityIndex

string (int64)

ID of the recognized word in entities array.

textSegments[]

TextSegments

Word position from full_text string.

TextSegmentsTextSegments

Field

Description

startIndex

string (int64)

Start character position from full_text string.

length

string (int64)

Text segment length.

DetectedLanguageDetectedLanguage

Field

Description

languageCode

string

Detected language code.

EntityEntity

Field

Description

name

string

Entity name.

text

string

Recognized entity text.

TableTable

Field

Description

boundingBox

Polygon

Area on the page where the table is located.

rowCount

string (int64)

Number of rows in table.

columnCount

string (int64)

Number of columns in table.

cells[]

TableCell

Table cells.

TableCellTableCell

Field

Description

boundingBox

Polygon

Area on the page where the table cell is located.

rowIndex

string (int64)

Row index.

columnIndex

string (int64)

Column index.

columnSpan

string (int64)

Column span.

rowSpan

string (int64)

Row span.

text

string

Text in cell.

textSegments[]

TextSegments

Table cell position from full_text string.

Была ли статья полезна?

Предыдущая
Recognize
Следующая
Overview
Проект Яндекса
© 2025 ООО «Яндекс.Облако»