OCR
>-
Extract text and structure from a document or image as markdown using an OCR model.
Authorization
bearerAuth AuthorizationBearer <token>
Bearer token authentication using API keys
In: header
Request Body
application/json
TypeScript Definitions
Use the request body type in TypeScript.
Response Body
application/json
application/json
application/json
application/json
application/json
application/json
application/json
application/json
application/json
application/json
application/json
application/json
curl -X POST "https://example.com/v1/ocr" \ -H "Content-Type: application/json" \ -d '{ "model": "mistral-ocr-latest", "document": { "type": "document_url", "document_url": "https://arxiv.org/pdf/2201.04234" } }'{
"pages": [
{
"index": 0,
"markdown": "string",
"images": [
{
"property1": null,
"property2": null
}
],
"dimensions": {
"property1": null,
"property2": null
}
}
],
"model": "string",
"document_annotation": "string",
"usage_info": {
"pages_processed": 0,
"doc_size_bytes": 0
}
}{
"error": {
"message": "string",
"type": "string",
"param": "string",
"code": "string"
}
}{
"error": {
"message": "string",
"type": "string",
"param": "string",
"code": "string"
}
}{
"error": {
"message": "string",
"type": "string",
"param": "string",
"code": "string"
}
}{
"error": {
"message": "string",
"type": "string",
"param": "string",
"code": "string"
}
}{
"error": {
"message": "string",
"type": "string",
"param": "string",
"code": "string"
}
}{
"error": {
"message": "string",
"type": "string",
"param": "string",
"code": "string"
}
}{
"error": {
"message": "string",
"type": "string",
"param": "string",
"code": "string"
}
}{
"error": {
"message": "string",
"type": "string",
"param": "string",
"code": "string"
}
}{
"error": {
"message": "string",
"type": "string",
"param": "string",
"code": "string"
}
}{
"error": {
"message": "string",
"type": "string",
"param": "string",
"code": "string"
}
}{
"error": {
"message": "string",
"type": "string",
"param": "string",
"code": "string"
}
}How is this guide?
Last updated on