Skip to main content

Command Palette

Search for a command to run...

PDF to Multiple Formats Conversion API Documentation

Published
4 min readView as Markdown
PDF to Multiple Formats Conversion API Documentation

PDF Parsing and Formatted Output API

Category: Image Recognition
Endpoint: POST https://api.gugudata.io/v1/imagerecognition/pdf2format?appkey={{appkey}}&type={{type}}
Description: Supports output in TEXT, HTML, XML, and TAG formats.

Overview

The PDF Parsing and Formatted Output API by GuGuData provides a convenient way to convert PDF documents into multiple output formats. Whether you need TEXT, HTML, XML, or TAG files, this API offers millisecond-level parsing performance for standard PDF files. Backed by machine learning, it continuously refines its recognition accuracy and handles files up to at least 1M with impressive speed.

Key highlights:

  • Multiple format support – Convert PDF to TEXT, HTML, XML, or TAG.
  • High accuracy – Machine learning-driven improvements over time.
  • Fast performance – Millisecond-level handling for typical PDF file sizes.
  • HTTPS/TLS – Compatible with TLS v1.0–v1.3, fully Apple ATS-ready.
  • Nationwide multi-node CDN – Ensures rapid response and reliability.

Demo URL

https://api.gugudata.io/v1/imagerecognition/pdf2format/demo

Request Parameters

Send a POST request to the endpoint, including both appkey and type in the query string, and attach the PDF file in the form-data body.

ParameterTypeRequiredDefault ValueDescription
appkeystringYesYOUR_APPKEYYour APPKEY obtained from GuGuData's Developer Center (passed in query string).
typestringYesYOUR_VALUEThe output format: text, html, xml, or tag (passed in query string).
pdffilefileYesYOUR_VALUEThe PDF file you wish to parse, uploaded in form-data.

Example:

POST https://api.gugudata.io/v1/imagerecognition/pdf2format?appkey={{appkey}}&type={{type}}

Then attach the PDF file in the request body as form-data with the field name pdffile.

Response Parameters

A successful request returns JSON with status info and parsed results. Key fields include:

ParameterTypeRequiredDescription
DataStatus.statusCodeintYesThe API response status code.
DataStatus.statusDescriptionstringYesA short description of the response status.
DataStatus.responseDateTimestringYesThe timestamp for when the data was returned.
DataStatus.dataTotalCountintYesThe total data count for this request, often used for pagination.
Data.resultstringYesThe parsed PDF data, in the format specified by the type parameter.

Error Codes

The table below lists potential error codes and their implications:

Error CodeError ContentNotes
100Normal responseRequest successful.
101Parameter errorCheck for missing or invalid parameters (e.g., pdffile missing).
102Request rate limitedExceeded 100 requests per second limit.
103Account overdueRequires payment or account reactivation.
104Invalid APPKEYVerify the APPKEY from your Developer Center.
110API response errorA general error indicating unexpected API behavior.

Features

  1. General recognition API – Compatible with standard PDF files.
  2. Multiple format output – TEXT, HTML, XML, or TAG.
  3. Perfect formatting in HTML – Preserves layout for web-based usage.
  4. Machine learning – Improved recognition accuracy over time.
  5. Fast recognition – Processes 1M files in milliseconds.
  6. HTTPS (TLS 1.0–1.3) – Secure data transmission.
  7. Apple ATS compatibility – Ideal for iOS/macOS integrations.
  8. Multi-node CDN – Consistent performance across diverse regions.
  9. Load-balanced – Ensures swift responses even under heavy load.

Additional Notes for Developers

  • File size: For large PDFs, consider splitting them or optimizing them beforehand.
  • Formatting: The HTML output provides near-original layout, making it ideal for display or conversions.
  • Mixed content: Some PDFs contain images or vector text. Depending on the content, an OCR approach may be needed if the PDF lacks embedded text.

Getting Started

  1. Sign up at GuGuData.io – Acquire your appkey.
  2. Construct a POST request – Include appkey and type in the query parameters; attach the PDF as pdffile in form-data.
  3. Parse the JSON response – Read Data.result for the extracted data in your chosen format.
  4. Integrate – Incorporate the parsed output into your data pipelines or applications.

About GuGuData

GuGuData offers enterprise-grade data solutions and powerful APIs for a global audience. From OCR services to SSL Certificate Parsing, our infrastructure handles large-scale requests with speed and precision.

Key Highlights:

  • Nine years in business – Trusted by thousands of developers and organizations.
  • 4.2k+ APIs – A growing library of data-driven functionalities.
  • 95% customer satisfaction – Emphasis on reliability, performance, and user-centered design.

Use the PDF Parsing and Formatted Output API to streamline your PDF document workflows with immediate format-specific results. Visit our official site to discover more data solutions from GuGuData.

More from this blog

网页转 JSON API 怎么接:从 Prompt 到可校验的结构化数据

把网页内容变成 JSON,真正困难的部分通常不是“得到一段看起来像 JSON 的文本”,而是让字段含义、数据类型、缺失值、来源和更新规则都能被程序稳定处理。 语义化获取站点 JSON 结构内容 API 可以根据网页 URL 和自然语言 Prompt 提取自定义结构。它适合商品列表、文章索引、表格内容、站点研究和自动化数据准备等场景,但接口返回成功并不代表所有字段都已经过事实验证。生产接入仍需要本地

Aug 27, 20265 min read

地址逆编码接口 API

此文章对开放数据接口 API 之「地址逆编码接口 API」进行了功能介绍、使用场景介绍以及调用方法的说明,供用户在使用数据接口时参考之用,并且在目前更新的微信小程序实战开发项目中的使用场景。 1. 产品功能 此次开放了精准的地址坐标逆编码在线接口,用于对提供的 GPS 坐标转换为文字地址信息。 提供精准、高效的地理坐标逆编码接口; 返回的地址包含详细的位置信息; 一次可返回坐标周边的 10

Aug 3, 20261 min read

中英文排版规范化 API

此文章对开放数据接口 API 之「中英文排版规范化 API」进行了功能介绍、使用场景介绍以及调用方法的说明,供用户在使用数据接口时参考之用。 1. 产品功能 此次开放了中英文排版规范化在线接口,用于自动中英文排版、标点符号格式化,中英混排格式化 / 标点修正。 支持中英文混排格式化; 自动在汉字与英文字符、英文标点、数字间添加空格; 中文标点符号自动规范化,遵从 [标点符号用法 GB/T

Aug 3, 20261 min read

为阿里云站点部署免费 HTTPS

本文记录了部署在阿里云的站点,在申请了免费的 SSL 证书后如何正确的部署到站点上,让站点支持 HTTPS 访问。 阿里云引入了沃通作为 CA 证书供应商,并开放了免费 SSL 申请的页面,之前一直想给 咕咕监控 部署上全站 HTTPS,所以就申请了一个,但是部署的过程中遇到了些问题,所以记录下来备忘。 1. 证书申请 在阿里云后台的 CA 管理页面,填写相关的信息后就可以申请到一张免费的 CA

Aug 3, 20261 min read

GuGuData

178 posts