Split a Multi-Invoice PDF and Extract Its Data Using PDF.co and Zapier
7 MIN READ
4 MIN READ
This tutorial shows you how to use PDF.co’s OCR-enabled PDF-to-Text API to extract text from a scanned PDF in Postman.
Open Postman and create a new HTTP request.
Configure it as follows:
POSThttps://api.pdf.co/v1/pdf/convert/to/textAdd these headers:
x-api-key: Your PDF.co API keyContent-Type: application/jsonOpen the Body tab, select raw, and choose JSON.
Enter the following request:
{
"url": "https://example.com/scanned-document.pdf",
"pages": "0-",
"lang": "eng",
"inline": true,
"async": false,
"profiles": "{ 'OCRMode': 'TextFromImagesOnly', 'OCRResolution': 300 }"
}Replace the example URL with a direct link to your scanned PDF. The URL must be accessible to PDF.co. You can also use a filetoken:// link from PDF.co File Storage.
The request uses these settings:
0- processes every page.eng selects English for OCR. Change it when processing another language.true returns the extracted text directly in the response.false waits for the conversion to finish before returning the result.TextFromImagesOnly extracts text from page images.300 uses the default 300 DPI OCR resolution.PDF.co also supports Auto OCR mode for documents that may contain a mixture of scanned images and existing text. Review the PDF-to-Text documentation and Profiles documentation for the current OCR modes, preprocessing filters, resolution settings, rotation options, and other extraction parameters.
Select Send in Postman.
A successful response resembles:
{
"body": "Extracted text from the scanned PDF...",
"pageCount": 1,
"error": false,
"status": 200,
"name": "scanned-document.txt",
"remainingCredits": 1000
}Confirm that:
error is false.status is 200.body contains the extracted text.pageCount matches the number of processed pages.To receive a downloadable text file, change:
"inline": false
Send the request again. The response will contain a temporary URL to the generated text file:
{
"url": "https://pdf-temp-files.s3.amazonaws.com/.../scanned-document.txt",
"error": false,
"status": 200
}Open the URL to download the file. Save it to permanent storage if it must remain available because PDF.co output links are temporary.
You have extracted text from a scanned PDF using Postman and PDF.co’s OCR-enabled PDF-to-Text endpoint. You can adjust the language, OCR mode, resolution, page range, and preprocessing options for different document types by using the parameters listed in the PDF.co documentation.
7 MIN READ
7 MIN READ

6 MIN READ

2 MIN READ
Create an account, get an API key and test a request.