# Web Page Content Readability API Documentation


# Webpage Readable Content Extraction API

> **Category**: Web Tools  
> **Endpoint**: `/v1/websitetools/readability`  
> **Method**: `POST`  
> **Description**: Intelligently extracts key elements from web articles to deliver refined, reader-focused content.

## Overview

The **Webpage Readable Content Extraction API** offered by [GuGuData](https://gugudata.io/) provides an efficient and precise way to **parse, clean, and extract essential article information** from any web page. This API streamlines the process of retrieving the **title, author, excerpt, main text, language**, and other critical metadata. Whether you're looking to **enhance SEO**, perform **text analytics**, or build **content-driven applications**, this API enables you to focus on the core readable sections of an article without distractions such as ads, scripts, or complex HTML structures.

With **second-level parsing performance** and **nationwide multi-node CDN deployment**, the API ensures both reliability and high concurrency support, making it suitable for **enterprise-grade** text analysis, **automated news aggregation**, or **content curation** tools.

Key advantages include:

- **Intelligent Extraction**: Automatically identifies and retrieves main article content, including metadata such as publication time and byline.
- **HTML or URL Input**: Submit raw HTML directly or specify a webpage URL for parsing.
- **Various Elements Retrieval**: Get everything from article title and content to excerpt, language, and website name.
- **High Concurrency**: Handle large volumes of requests with minimal latency.
- **HTTPS/TLS Ready**: End-to-end encryption and compatibility with Apple ATS standards.

## Request URL

```
POST https://api.gugudata.io/v1/websitetools/readability
```

### Demo URL

Try out our live demo endpoint to see how the **Readability** API works:

```
https://api.gugudata.io/v1/websitetools/readability/demo
```

## Request Parameters

Below are the key parameters needed to use the **Readability** API effectively:

| **Parameter** | **Type** | **Required** | **Default Value** | **Description**                                                                                                                                                       |
| :-----------: | :------: | :----------: | :---------------: | :-------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
|   `appkey`    | `string` |     Yes      |   `YOUR_APPKEY`   | The APPKEY obtained from GuGuData's Developer Center.                                                                                                                 |
|    `html`     | `string` |      No      |   `YOUR_VALUE`    | **Optional**. Raw HTML content of the webpage you want to process. You must provide either `html` or `url`.                                                           |
|     `url`     | `string` |      No      |   `YOUR_VALUE`    | **Optional**. The URL of the webpage you want to process. You must provide either `html` or `url`. For pages with anti-crawling measures, content retrieval may fail. |

> **Note**: If both `html` and `url` are provided, the API will prioritize one parameter according to internal rules (generally taking `html` as primary).

## Response Parameters

When your request is successful, you'll receive a JSON response containing metadata and extracted content. Below is a summary of the main fields:

|         **Parameter**          |  **Type**  | **Required** | **Description**                                                                |
| :----------------------------: | :--------: | :----------: | :----------------------------------------------------------------------------- |
| `DataStatus.RequestParameter`  |  `string`  |     Yes      | The parameters you passed to the API.                                          |
|    `DataStatus.StatusCode`     |   `int`    |     Yes      | The API response status code.                                                  |
| `DataStatus.StatusDescription` |  `string`  |     Yes      | A brief message describing the status code.                                    |
| `DataStatus.ResponseDateTime`  |  `string`  |     Yes      | The timestamp when the data is returned.                                       |
|  `DataStatus.DataTotalCount`   |   `int`    |     Yes      | Total data count under this condition, mainly for pagination.                  |
|          `Data.Title`          |  `string`  |     Yes      | Extracted article title.                                                       |
|         `Data.Byline`          |  `string`  |     Yes      | Identified author or byline.                                                   |
|           `Data.Dir`           |  `string`  |     Yes      | Detected direction of the text (e.g., `ltr`, `rtl`).                           |
|          `Data.Lang`           |  `string`  |     Yes      | Language code of the extracted content.                                        |
|         `Data.Content`         |  `string`  |     Yes      | The refined HTML content of the article.                                       |
|       `Data.TextContent`       |  `string`  |     Yes      | Plain text of the article content, divided into paragraphs, without HTML tags. |
|         `Data.Length`          |   `int`    |     Yes      | Total length of the extracted content.                                         |
|         `Data.Excerpt`         |  `string`  |     Yes      | A short excerpt or summary of the article.                                     |
|        `Data.SiteName`         |  `string`  |     Yes      | Name of the website where the content was extracted.                           |
|      `Data.PublishedTime`      | `string[]` |     Yes      | Potential article publication times, if found.                                 |

## Error Codes

Below are common error codes you may encounter while using this API:

| **Error Code** |     **Error Content**     | **Notes**                                                      |
| :------------: | :-----------------------: | :------------------------------------------------------------- |
|     `200`      |       Normal return       | Request was successful.                                        |
|     `400`      |      Parameter error      | One or more parameters are invalid or missing.                 |
|     `429`      | Request frequency limited | Exceeded the max allowed requests (100 per second).            |
|     `403`      |    Account in arrears     | Your account is suspended due to payment issues.               |
|     `402`      |       APPKEY error        | Check if the APPKEY matches the one from the Developer Center. |
|     `500`      |    API response error     | A general error indicating an unexpected issue with the API.   |

## Features

1. **Intelligently extracts readable content** – Eliminates unnecessary HTML, scripts, and ads.
2. **Provides HTML code of readable segments** – Ensures your application can display or process content seamlessly.
3. **HTML or URL input** – Offers flexibility for direct HTML submission or standard URL-based parsing.
4. **Retrieves multiple metadata points** – Title, author, language, excerpt, published time, and more.
5. **Second-level parsing performance** – Delivers rapid extraction, supporting high concurrency.
6. **HTTPS/TLS support** – Fully compatible with TLS v1.0 to v1.3 and Apple ATS security standards.
7. **Nationwide multi-node CDN** – Boosts response times and reliability with distributed infrastructure.
8. **Load-balanced architecture** – Handles large volumes of requests without downtime.

## Additional Notes for Developers

- **Choose the right parameter**: If the source URL is behind heavy anti-crawling or requires a login, consider sending the cleaned `html` directly.
- **Focus on SEO & analytics**: Extracted data can be used for advanced content analysis, SEO audits, or natural language processing.
- **High concurrency**: The multi-node CDN and load balancing let you scale quickly and handle spikes in traffic.

## Getting Started

1. **Sign up at [GuGuData.io](https://gugudata.io/)** – Register to get your `appkey`.
2. **Send a POST request** – Provide necessary parameters (`html` or `url`) along with `appkey`.
3. **Parse the response** – Access the refined content and metadata in JSON format.
4. **Integrate** – Incorporate this extracted data into CMS tools, analytics platforms, or mobile apps.

## About GuGuData

[**GuGuData**](https://gugudata.io/) is a **leading data solutions** provider with nearly a decade of experience in delivering comprehensive APIs. Our offerings range from [SSL Certificate Information](https://gugudata.io/) to advanced [Image Recognition](https://gugudata.io/) functionalities. Throughout the years, we've maintained a commitment to **organizing, cleaning, and integrating** massive volumes of data, ensuring that developers, analysts, and businesses can effortlessly harness powerful data insights.

**Key Highlights**:

- **Nine years in business** – Tested, resilient services trusted by global enterprises.
- **4.2k+ APIs** – A constantly growing library of specialized data and functionalities.
- **95% happy customers** – Recognized for reliability, performance, and innovation.

Whether you're extracting readable text for **content creation**, analyzing user engagement, or performing **text-based research**, GuGuData's **Webpage Readable Content Extraction API** is your gateway to consistent, high-quality data. Visit our [official website](https://gugudata.io/) to explore more APIs and start optimizing your web content today.

