API Documents - GuGuData | Production-Ready APIs Built for Developers
  1. Image Recognition
API Documents - GuGuData | Production-Ready APIs Built for Developers
  • GuGuData API documents
  • Metadata
    • DEMO
      • [DEMO] Global QS World University Rankings
      • [DEMO] Global University
      • [DEMO] Chinese Poem
    • Global QS World University Rankings
      GET
    • Global University
      GET
    • Chinese Poem
      GET
  • Website Tools
    • DEMO
      • [DEMO] Webpage Readable Content Extraction
      • [DEMO] Domain SSL Certificate Information Parsing
      • [DEMO] Domain DNS Information Query
      • [DEMO] Query Website Favicon and Title
      • [DEMO] Format International Phone
      • [DEMO] URL to static HTML
      • [DEMO] URL to Image
      • [DEMO] URL to Markdown
      • [DEMO] Get URL links
      • [DEMO] Website Snapshot
      • [DEMO] Domain Whois
      • [DEMO] IP Address
      • [DEMO] Article Extract
      • [DEMO] Geographic Coordinate System Converter
      • [DEMO] Extract Structured JSON from Webpage
    • Webpage Readable Content Extraction
      POST
    • Domain SSL Certificate Information Parsing
      GET
    • Domain DNS Information Query
      GET
    • Query Website Favicon and Title
      GET
    • Format International Phone
      GET
    • URL to static HTML
      POST
    • URL to Image
      GET
    • URL to Markdown
      POST
    • Get URL links
      GET
    • Website Snapshot
      POST
    • Domain Whois
      GET
    • IP Address
      GET
    • Article Extract
      POST
    • Geographic Coordinate System Converter
      GET
    • Extract Structured JSON from Webpage
      POST
  • Image Recognition
    • DEMO
      • [DEMO] HTML to PDF
      • [DEMO] Image OCR
      • [DEMO] PDF to Format
      • [DEMO] PDF Splitting
      • [DEMO] Markdown to PDF
      • [DEMO] PPT to Images
      • [DEMO] PDF to HTML
      • [DEMO] PDF Summary
      • [DEMO] Image Compress
      • [DEMO] Word to HTML
    • HTML to PDF
      POST
    • Image OCR
      POST
    • PDF to Format
      POST
    • PDF Splitting
      POST
    • Markdown to PDF
      POST
    • PPT to Images
      POST
    • PDF to HTML
      POST
    • PDF Summary
      POST
    • Image Compress
      POST
    • Word to HTML
      POST
  • QRcode and Barcode
    • DEMO
      • [DEMO] QR Code
      • [DEMO] Wifi QR Code
      • [DEMO] Bar Code
    • QR Code
    • Wifi QR Code
    • Bar Code
  • Text Tools
    • DEMO
      • [DEMO] Simplified and Traditional Chinese Converter
      • [DEMO] Text Similarity Calculator
    • Simplified and Traditional Chinese Converter
    • Text Similarity Calculator
  • healthcheck
    GET
  1. Image Recognition

HTML to PDF

POST
https://api.gugudata.io/v1/imagerecognition/html2pdf
Last modified:2026-02-11 09:08:02
HTML/URL to PDF
Supports converting web pages to PDF
Method: POST
Path: /v1/imagerecognition/html2pdf?appkey={{appkey}}
Demo: https://api.gugudata.io/v1/imagerecognition/html2pdf/demo
Request Parameters:
appkey (string, required): APPKEY obtained after payment
type (string, required): Optional parameters are HTML or URL (Note: when the type is URL, ensure that the page can be requested normally. Our interface does not handle requests for encrypted pages, anti-crawling pages, etc., that cannot return HTML normally)
content (string, required): Content body. If type=HTML, pass HTML content; if type=URL, pass the URL of the site to be stored as a PDF
landscape (int, optional): Controls whether the generated PDF is in landscape page mode. Pass 1 to control landscape rendering mode, default is 0
Response Fields Count: 5
Response Field Examples:
DataStatus.StatusCode: Interface return status code
DataStatus.StatusDescription: Interface return status description
DataStatus.ResponseDateTime: Interface data return time
DataStatus.DataTotalCount: Total data volume under this condition, generally used for pagination calculation
Data: Permanent link to the converted PDF
Key Features:
Superior performance conversion efficiency
Supports converting passed HTML to PDF, supports converting CSS format in HTML
Supports passing website URL, directly converting page to corresponding PDF file
The converted PDF provides a permanent storage file address
Full interface supports HTTPS (TLS v1.0 / v1.1 / v1.2 / v1.3)
Details:
https://gugudata.io/details/html2pdf

Request

Query Params

Body Params application/json

Example
{
    "content": "https://www.google.com/",
    "type": "URL",
    "landscape": 0
}

Request Code Samples

Shell
JavaScript
Java
Swift
Go
PHP
Python
HTTP
C
C#
Objective-C
Ruby
OCaml
Dart
R
Request Request Example
Shell
JavaScript
Java
Swift
curl --location -g --request POST 'https://api.gugudata.io/v1/imagerecognition/html2pdf?appkey=sk-******' \
--header 'Content-Type: application/json' \
--data-raw '{
    "content": "https://www.google.com/",
    "type": "URL",
    "landscape": 0
}'

Responses

⚪0
application/json
Body

Example
{
  "Data": "string",
  "DataStatus": {
    "StatusCode": 0,
    "StatusDescription": "string",
    "ResponseDateTime": "string",
    "DataTotalCount": 0
  }
}
Modified at 2026-02-11 09:08:02
Previous
[DEMO] Word to HTML
Next
Image OCR
Built with