How to Use QR Reader with our API Platform

8 Minutes Read

The QR Code Reader Web API can decode QR Codes from images and PDF documents. It can read QR Codes individually or in batches. The QR Code Reader Web API can narrow down its search to only return the QR Code values when other barcode types are present in a document.

Web API engines work in any programming language: PHP, Javascript, C#, .NET and ASP.NET, Java, Visual Basic, and many others.

Our QR Code Reader Web API is secure. To learn more, please check out our Security page.

Benefits of Using Our Barcode Reader API

Read Multiple QR Codes

The QR Code Web API can decode single or multiple QR Codes in a document. It can read QR Codes file by file or use automation to batch read the QR Codes from several documents.

Read Protected Files

The Web API can decode QR Codes from protected files. It supports documents that require HTTP username and password authentication.

Read Specific Page(s)

The Web API supports page(s) and page range(s) selection. This will not only read QR Codes from those specific pages but also help with faster document processing.

Read Skewed QR Codes

The QR Code Web API can read skewed QR Codes. The engine can detect the QR Code rotation without specifying the angle. Check out our demo below.

Web API Supports Multiple Languages

PDF.co platform can be used by software developers from programming languages such as PHP, Javascript, .NET and ASP.NET, C#, Java, Visual Basic, and many others. Find source code samples in our API documentation.

Easy Integration

Our QR code online scanner includes a built-in OCR, and it includes Zapier, IntegromatUiPath, and BluePrism plugins. You can easily connect with the most popular applications through our 300+ API integrations.

QR Code Scanning Large Files

To use our QR code reader to scan large files without getting a timeout error, you must run the scans in async mode. However, if you want to scan a barcode or barcodes from 100 pages or fewer, then you can run the QR reader API in sync mode.

The Sync mode runs for 25 seconds or less, while the async mode runs for more than 25 seconds, and is in the background. It then outputs the QR scan output after it successfully scans all the barcodes.

How to Run to Use Online QR Scanner

In this demonstration, we will read 50 QR Codes in a PNG. Some of these QR Codes are skewed to test the engine’s ability to read QR Codes. We will use the /v1/barcode/read/from/url endpoint to decode all the QR Codes. Below is the image of the input PNG and the decoded values.

50 QR Codes
50 QR Codes

Using CURL we can do the following:

curl --location --request POST 'https://api.pdf.co/v1/barcode/read/from/url' 
--header 'x-api-key: YOUR_API_KEY' 
--header 'Content-Type: application/json' 
--data-raw '{
    "url": "https://raw.githubusercontent.com/bytescout/ByteScout-SDK-SourceCode/master/BarCode%20Reader%20SDK/C%23/Read%2050%20Barcodes%20from%20picture/50_QrCodes.png",
    "types": "QRCode",
    "pages": "0"
}'

Or with JavaScript do:

let data = {
            "url": "https://raw.githubusercontent.com/bytescout/ByteScout-SDK-SourceCode/master/BarCode%20Reader%20SDK/C%23/Read%2050%20Barcodes%20from%20picture/50_QrCodes.png",
            "types": "QRCode",
            "pages": "0"
          }

fetch('https://api.pdf.co/v1/barcode/read/from/url', {
    method: 'POST',
    headers: {
        'Accept': 'application/json',
        'Content-Type': 'application/json',
        'x-api-key': 'YOUR_API_KEY'
    },
    body: JSON.stringify(data)
})
   .then(response => response.json())
   .then(response => console.log(JSON.stringify(response)))

Once run, the code above would read the input image of the barcode QR codes and then output the results for all 50 barcodes.

Further code samples are also available in the Code Samples area for this API.

Frequently Asked Questions

Can you scan a QR code without an app?

Yes, you can scan a QR code without an app, just by using our Barcode Reader Web API.

You will need a Web API like ours to scan your QR codes and barcodes in bulk. Our barcode scanner API is very powerful to scan QR codes faster.

How do I scan QR codes?

You can scan a QR code by using QR Code Reader API or its integration. The scanner’s app then extracts data from a QR code and presents it to you.

What Does QR Code Stand For?

QR stands for “Quick Response Code”, and they provide businesses with an easy way to store product data while making it easily accessible. They are indispensable at Points of Sale, because of their ease of use, and reliability.

Is QR Code Safe?

Yes, a QR code is safe to use, if you receive it from a reliable source. However, you must be careful when using it to access a website that asks for sensitive information, such as a bank account, or your home address.

If the website’s URL is different from what you expected to see, then you must close your browser tab immediately.

Who Owns QR Code?

Denso’s Engineer Hara Masahiro, from Aichi, Japan, invented the QR code. The motivation was to replace the barcodes, which could only store a limited amount of data.

One QR code can store as much information as 200 barcodes. That makes it efficient to use when you need to store and scan large amounts of information at once.

Related Tutorials

See Related Tutorials