Quickstart

Send your first handwriting OCR request in under 2 minutes.

Quickstart

Get from zero to recognized text in three steps.

1. Get an API key

Sign up at inkscan.app and create an API key from your dashboard. New accounts get 100 free credits ($1.00 value) — 1 credit = 1 page.

2. Send a recognition request

cURL

curl -X POST https://api.inkscan.app/v1/recognize \
  -H "Authorization: Bearer $INKSCAN_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{"image_base64": "'$(base64 -w0 handwritten-notes.jpg)'"}'

Python

import requests, base64

with open("handwritten-notes.jpg", "rb") as f:
    image_base64 = base64.b64encode(f.read()).decode()

response = requests.post(
    "https://api.inkscan.app/v1/recognize",
    headers={"Authorization": "Bearer YOUR_API_KEY"},
    json={"image_base64": image_base64},
)

result = response.json()
print(result["text"])
print(result["markdown"])

Node.js

import { readFileSync } from "fs";

const image_base64 = readFileSync("handwritten-notes.jpg", "base64");

const response = await fetch("https://api.inkscan.app/v1/recognize", {
  method: "POST",
  headers: {
    Authorization: "Bearer YOUR_API_KEY",
    "Content-Type": "application/json",
  },
  body: JSON.stringify({ image_base64 }),
});

const result = await response.json();
console.log(result.text);
console.log(result.markdown);

3. Read the response

{
  "text": "Meeting notes from March 15th. Finalize transcript export flow and send revised copy to design.",
  "markdown": "**Meeting notes** from March 15th. Finalize transcript export flow and send revised copy to design.",
  "regions": [
    {
      "text": "Meeting notes from March 15th.",
      "bbox": [42, 18, 580, 52],
      "type": "text",
      "page": 1
    },
    {
      "text": "Finalize transcript export flow and send revised copy to design.",
      "bbox": [42, 60, 590, 94],
      "type": "text",
      "page": 1
    }
  ],
  "pages": 1,
  "usage": {
    "credits_used": 1,
    "credits_remaining": 99
  }
}

Response fields

Field Type Description
text string Full recognized text (plain)
markdown string Recognized text with Markdown formatting
regions array Per-region results with bounding boxes
regions[].text string Text for this region
regions[].bbox array Bounding box [x, y, width, height] in pixels
regions[].type string Region type: text, table, formula, or image
regions[].page number 1-based page index
pages number Total page count
usage object Credit usage for this request

Next steps