How to PDF make searchable API in cURL and PDF.co Web API
How to write a robust code in cURL to PDF make searchable API with this step-by-step tutorial
The sample shows instructions and algorithm of how to PDF make searchable API and how to make it run in your cURL application. PDF.co Web API is the Web API with a set of tools for documents manipulation, data conversion, data extraction, splitting and merging of documents. Includes image recognition, built-in OCR, barcode generation and barcode decoders to decode bar codes from scans, pictures and pdf. It can be applied to PDF make searchable API using cURL.
The following code snippet for PDF.co Web API works best when you need to quickly PDF make searchable API in your cURL application. This cURL sample code is all you need for your app. Just copy and paste the code, add references (if needs to) and you are all set! Applying cURL application mostly includes various stages of the software development so even if the functionality works please test it with your data and the production environment.
You can download free trial version of PDF.co Web API from our website with this and other source code samples for cURL.
@echo off :: Path of the cURL executable set CURL="curl.exe" :: The authentication key (API Key). :: Get your own by registering at https://app.pdf.co/documentation/api set API_KEY=xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx :: PDF file. set SOURCE_FILE=sample.pdf :: Comma-separated list of page indices (or ranges) to process. Leave empty for all pages. Example: '0,2-5,7-'. set PAGES= :: PDF document password. Leave empty for unprotected documents. set PASSWORD= :: OCR language. "eng", "fra", "deu", "spa" supported currently. Let us know if you need more. set LANGUAGE=eng :: Result PDF file name set RESULT_FILE_NAME=result.pdf :: Prepare URL for `Make Searchable PDF` API call set QUERY="https://api.pdf.co/v1/pdf/makesearchable?name=%RESULT_FILE_NAME%&password=%PASSWORD%&pages=%PAGES%&lang=%LANGUAGE%" echo %QUERY% :: Perform request and save response to a file %CURL% -# -X GET -H "x-api-key: %API_KEY%" -F "file=@%SOURCE_FILE%" %QUERY% >response.json :: Display the response type response.json :: Use any convenient way to parse JSON response and get URL of generated file(s) echo. pause
ON-PREMISE OFFLINE SDK
ON-DEMAND REST WEB API
Get Your API Key