Link Search Menu Expand Document

Read PDF Form Information - Python

PDF Forms Info Reader sample in Python demonstrating ‘Read PDF Form Information’
import os
import requests # pip install requests

# The authentication key (API Key).
# Get your own by registering at
API_KEY = "***************************"

# Base URL for Web API requests

# Source PDF file url. You can also upload your own file into and use it as url. Check "Upload File" samples for code snippets:
SourceFileURL = " "
Async = "False"

# Destination PDF file name
DestinationFile = ".\\result.pdf"

parameters = {}
parameters["async"] = Async
parameters["name"] = os.path.basename(DestinationFile)
parameters["url"] = SourceFileURL
# Prepare URL for 'Info Fields' API request
url = "{}/pdf/info/fields".format(BASE_URL)

response =, data=parameters, headers={ "x-api-key": API_KEY })
if (response.status_code == 200):
    json = response.json()
for field in json["info"]["FieldsInfo"]["Fields"]:print(field["FieldName"] + "=>" + field["Value"]) Web API: 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.

Get your API key here!

Download Source Code (.zip)

return to the previous page explore PDF Forms Info Reader endpoint