How to read barcode from file for barcode reader API in cURL and Web API

Step-by-step tutorial:How to read barcode from file to have barcode reader API in cURL

Every ByteScout tool includes sample cURL source codes that you can find here or in the folder with installed ByteScout product. Barcode reader API in cURL can be applied with Web API. Web API is the Rest API that provides set of data extraction functions, tools for documents manipulation, splitting and merging of pdf files. Includes built-in OCR, images recognition, can generate and read barcodes from images, scans and pdf.

This simple and easy to understand sample source code in cURL for Web API contains different functions and options you should do calling the API to implement barcode reader API. This sample code in cURL is all you need. Just copy-paste it to the code editor, then add a reference to Web API and you are ready to try it! This basic programming language sample code for cURL will do the whole work for you in implementing barcode reader API in your app. Web API – free trial version is available on our website. Also, there are other code samples to help you with your cURL application included into trial version.

On-demand (REST Web API) version:
 Web API (on-demand version)

On-premise offline SDK for Windows:
 60 Day Free Trial (on-premise)


@echo off :: Path of the cURL executable set CURL="curl.exe" :: The authentication key (API Key). :: Get your own by registering at set API_KEY=xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx :: Source file to search barcodes in. set SOURCE_FILE=sample.pdf :: Comma-separated list of barcode types to search. :: See valid barcode types in the documentation set BARCODE_TYPES=Code128,Code39,Interleaved2of5,EAN13 :: Comma-separated list of page indices (or ranges) to process. Leave empty for all pages. Example: '0,2-5,7-'. set PAGES= :: Prepare URL for `Barcode Reader` API endpoint set QUERY="" 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 information about decoded barcodes. echo. pause



Get 60 Day Free Trial

See also:


Get Your API Key

See also:

Related Samples: