Bestseller
HTML to PDF
Supports converting web pages to PDF
Efficient PDF GenerationProvides Permanent Links
Web Tool | File Processing | PDF
Data & API 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);
- Fully compatible with Apple ATS;
- National multi-node CDN deployment;
- Interface response is extremely fast, and multiple servers build API interface load balancing.
API Document
HTTP Protocol:HTTPS
HTTP Method:POST
HTTP Endpoint:https://api.gugudata.io/v1/imagerecognition/html2pdf
Response Type:application/json; charset=utf-8
DEMO Endpoint:https://api.gugudata.io/v1/imagerecognition/html2pdf/demo
API Request Parameters
Name | Type | Is Required | Default Value | Remark |
---|---|---|---|---|
appkey | string | true | YOUR_APPKEY | APPKEY obtained after payment |
type | string | true | YOUR_VALUE | 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 | true | YOUR_VALUE | 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 | false | 0 | Controls whether the generated PDF is in landscape page mode. Pass 1 to control landscape rendering mode, default is 0 |
API Response Parameters
Name | Type | Remark |
---|---|---|
DataStatus.StatusCode | int | Interface return status code |
DataStatus.StatusDescription | string | Interface return status description |
DataStatus.ResponseDateTime | string | Interface data return time |
DataStatus.DataTotalCount | int | Total data volume under this condition, generally used for pagination calculation |
Data | string | Permanent link to the converted PDF |
API Response Status Codes
Status Code | Explanation of Status Code | Remarks |
---|---|---|
200 | API responding normally | For business status codes, see below under API Custom Status Codes |
403 | Request rate exceeded | The CDN layer makes an intelligent judgment based on the frequency of IP requests. General high-frequency requests will not trigger this status code. |
200 | Normal return | |
400 | Parameter error | |
429 | Request rate limited | Requests cannot exceed 100 times per second |
403 | Account overdue | Please pay attention to the E-mail reminders about order expiration |
402 | APPKEY error | Please check whether the APPKEY provided is the one obtained from the developer center |
500 | API response error |
Code Snippets
Others also bought
![Data and API Description](https://cdn.gugudata.io/cdn-cgi/image/width=500,quality=95/https://cdn.gugudata.io/api-covers%2Fapi-covers_api_cover_favicon.jpg)
4.93
Website Tools
- Parses the site's title and favicon
![Data and API Description](https://cdn.gugudata.io/cdn-cgi/image/width=500,quality=95/https://cdn.gugudata.io/api-covers%2Fapi-covers_api_cover_readability.png)
4.98
Website Tools
- Intelligently extracts key elements of articles
![Data and API Description](https://cdn.gugudata.io/cdn-cgi/image/width=500,quality=95/https://cdn.gugudata.io/api-covers%2Fapi-covers_api_cover_sslcertinfo.png)
4.97
Website Tools
- Provides domain SSL certificate information parsing