Everything you need to integrate TextFlow into your application
Extract text from documents with a single API call. TextFlow automatically routes your request to the nearest region for optimal latency.
TextFlow supports the following file formats:
JPG/JPEG,
PNG, and
PDF.
For optimal performance, using the imageUrl parameter
is preferable to file uploads as it eliminates upload time and reduces overall latency.
https://api.textflow.dev/v2/extract
Include your API key in the
Authorization header
as a Bearer token.
Authorization: Bearer YOUR_API_KEY
curl -X POST https://api.textflow.dev/v2/extract \
-H "Authorization: Bearer YOUR_API_KEY" \
-H "Content-Type: multipart/form-data" \
-F "file=@receipt.jpg" \
-F "model=fast-precise" \
-F "hint=receipt"
curl -X POST https://api.textflow.dev/v2/extract \
-H "Authorization: Bearer YOUR_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"imageUrl": "https://example.com/receipt.jpg",
"model": "fast-precise",
"hint": "receipt"
}'
{
"store": {
"name": "",
"address": { "street": "", "city": "", "state": "", "zip": "" }
},
"receipt_details": {
"store_number": "4",
"transaction_number": "485",
"time": "08:13:56 AM"
},
"items": [
{ "name": "Sausage Egg McMuffin", "quantity": 2, "price": 3.99 },
{ "name": "2 Burritos EVM", "quantity": 1, "price": 6.99 }
],
"subtotal": 13.18,
"tax": 0.66,
"total": 13.84,
"payment_method": "CREDIT CARD",
"usage": {
"processing_time": 1.17,
"pages": 1,
"cost": 0.29
}
}