S
S
Solvio
Search
K

Math and Text OCR

Digitize an image containing math and text content. The output is a LaTeX expression by default (other formats coming soon).
Get started with Solvio's Math and Text OCR API easily by downloading the Postman Collection attached below. To learn more about Postman Collections click here.
Solvio Math and Text OCR.postman_collection.json
115KB
Code
post
https://developer.trysolvio.ai/api
/ocr
Math and Text OCR

Code Samples

JavaScript
Python
Java
const headers = {
'content-type': 'application/json',
// Paste your token here
'authorization': 'Bearer eyJhbGciOiJSUzI1...'
}
const body = {
src: "data:image/png;base64,iVBOR..."
}
fetch("https://developer.trysolvio.ai/api/text/digital", {
method: 'POST',
headers,
body: JSON.stringify(body)
}).then(res => {
return res.json()
}).then(data => {
console.log(data);
})
import requests
import json
url = "https://developer.trysolvio.ai/api/text/digital"
payload = json.dumps({
src : "data:image/png;base64,iVBOR..."
})
headers = {
'content-type' : 'application/json',
# Add your token here
'authorization' : 'Bearer eyJhbGciOiJSUzI1...'
}
response = requests.post(url, headers=headers, data=payload)
print(response.json())
JSONObject obj = new JSONObject();
// Put your base64 encoded image here
obj.put("src", "data:image/png;base64,iVBOR...");
OkHttpClient client = new OkHttpClient();
MediaType mediaType = MediaType.parse("application/json; charset=utf-8");
String body = obj.toString().toRequestBody(mediaType);
// Make sure to put the correct token in the Authorization header
Request request: Request = Request.Builder()
.url("https://developer.trysolvio.ai/api/text/digital")
.addHeader("Authorization", "Bearer eyJhbGciOiJSUzI1...")
.post(body)
.build();
Response response = client.newCall(request).execute();
// You can convert the string to JSONObject if needed
System.out.println(response.body().string());
If you have a feature request, please write to us at [email protected].