Tatvora Face Detection AI
Detect human faces inside images and video frames.
Locate human faces in an image or camera frame and return their position as bounding boxes.
Turn documents into usable data.
Tatvora OCR AI converts unstructured documents into data your application can act on. Send an image, a scanned page, a multi-page PDF or a DOCX file and receive clean, machine-readable text and structured fields in a predictable JSON response. It removes the manual data-entry step that sits between a document arriving and a business process being able to continue.
curl -X POST https://api.tatvora.comPOST /api/v1/ocr \
-H "Authorization: Bearer $TATVORA_API_KEY" \
-F "document=@invoice.pdf"
import os
import requests
with open("invoice.pdf", "rb") as f1:
response = requests.post(
"https://api.tatvora.comPOST /api/v1/ocr",
headers={"Authorization": f"Bearer {os.environ['TATVORA_API_KEY']}"},
files={"document": f1},
timeout=30,
)
response.raise_for_status()
print(response.json())
const form = new FormData();
form.append("document", documentFile); // File or Blob
const response = await fetch("https://api.tatvora.comPOST /api/v1/ocr", {
method: "POST",
headers: { Authorization: `Bearer ${process.env.TATVORA_API_KEY}` },
body: form,
});
if (!response.ok) {
throw new Error(`Tatvora API error ${response.status}`);
}
const result = await response.json();
console.log(result);
using System.Net.Http.Headers;
var apiKey = Environment.GetEnvironmentVariable("TATVORA_API_KEY");
using var client = new HttpClient();
client.DefaultRequestHeaders.Authorization = new AuthenticationHeaderValue("Bearer", apiKey);
using var form = new MultipartFormDataContent();
using var stream1 = File.OpenRead("invoice.pdf");
var part1 = new StreamContent(stream1);
part1.Headers.ContentType = new MediaTypeHeaderValue("application/octet-stream");
form.Add(part1, "document", "invoice.pdf");
using var response = await client.PostAsync("https://api.tatvora.comPOST /api/v1/ocr", form);
response.EnsureSuccessStatusCode();
Console.WriteLine(await response.Content.ReadAsStringAsync());
// Prefer IHttpClientFactory over `new HttpClient()` in ASP.NET Core apps:
// builder.Services.AddHttpClient("OcrClient", c =>
// c.BaseAddress = new Uri("https://api.tatvora.com"));
import java.io.IOException;
import java.net.URI;
import java.net.http.HttpClient;
import java.net.http.HttpRequest;
import java.net.http.HttpResponse;
import java.nio.file.Files;
import java.nio.file.Path;
import java.util.ArrayList;
import java.util.LinkedHashMap;
import java.util.List;
import java.util.Map;
import java.util.UUID;
public class OcrExample {
public static void main(String[] args) throws Exception {
Map<String, Path> files = new LinkedHashMap<>();
files.put("document", Path.of("invoice.pdf"));
String boundary = "tatvora-" + UUID.randomUUID();
HttpRequest request = HttpRequest.newBuilder(URI.create("https://api.tatvora.comPOST /api/v1/ocr"))
.header("Authorization", "Bearer " + System.getenv("TATVORA_API_KEY"))
.header("Content-Type", "multipart/form-data; boundary=" + boundary)
.POST(multipart(boundary, files))
.build();
HttpResponse<String> response = HttpClient.newHttpClient()
.send(request, HttpResponse.BodyHandlers.ofString());
System.out.println(response.statusCode() + " " + response.body());
}
private static HttpRequest.BodyPublisher multipart(String boundary, Map<String, Path> files)
throws IOException {
List<byte[]> parts = new ArrayList<>();
for (Map.Entry<String, Path> file : files.entrySet()) {
parts.add(("--" + boundary + "\r\n"
+ "Content-Disposition: form-data; name=\"" + file.getKey()
+ "\"; filename=\"" + file.getValue().getFileName() + "\"\r\n"
+ "Content-Type: application/octet-stream\r\n\r\n").getBytes());
parts.add(Files.readAllBytes(file.getValue()));
parts.add("\r\n".getBytes());
}
parts.add(("--" + boundary + "--\r\n").getBytes());
return HttpRequest.BodyPublishers.ofByteArrays(parts);
}
}
A worked example of a single OCR AI call, end to end.
1 · You send
JPG · PNG · PDF · DOCX · scanned pages
2 · We process
3 · You receive
{
"success": true,
"invoice_number": "INV-1024",
"date": "2026-08-10",
"customer": "Example Company",
"total": 12850
}
Sample data for illustration. Fields returned depend on the document you submit. The document is processed in memory and discarded when the response is sent — nothing is stored.
Authenticate with a bearer API key over HTTPS.
Upload
a file
as multipart/form-data and receive a JSON response.
Request fields
document — file part, multipart/form-dataAuthorization: Bearer YOUR_API_KEY — required headerEndpoints and payloads shown on this site are illustrative examples of the published interface. Never expose a secret API key in client-side code.
{
"success": true,
"request_id": "req_8f2c41d0",
"pages": 3,
"text": "Extracted document content...",
"fields": {
"invoice_number": "INV-2043",
"invoice_date": "2026-03-14",
"total": "1,248.00"
},
"processing_time_ms": 412
}
Detect human faces inside images and video frames.
Locate human faces in an image or camera frame and return their position as bounding boxes.
Recognise identities using intelligent facial analysis.
Match a captured face against the identity set your application supplies to determine who the person is.
Verify whether two faces belong to the same person.
Compare a reference image against a live capture and receive a match or no-match decision with a similarity score.
Request an evaluation key and validate the model against your own data before choosing a plan.