# HKTVmall Product & Price Scraper (Hong Kong) (`superslowsloth/hktvmall-products`) Actor

HKTVmall scraper: search terms to one row per product with HKD price, list price, discount percent, stock, rating, reviews, brand, category, country of origin, store, product link and image. For Hong Kong daily price and stock watching.

- **URL**: https://apify.com/superslowsloth/hktvmall-products.md
- **Developed by:** [Superslow Sloth](https://apify.com/superslowsloth) (community)
- **Categories:** E-commerce, Automation
- **Features:** Limited permissions
- **Stats:** 3 total users, 2 monthly users, 100.0% runs succeeded, 0 bookmarks
- **User rating**: No ratings yet

## Pricing

from $2.10 / 1,000 product scrapeds

This Actor is paid per event. You are not charged for the Apify platform usage, but only a fixed price for specific events.

Learn more: https://docs.apify.com/actors/running/actors-in-store.md#pay-per-event

## What's an Apify Actor?

An Actor is a serverless cloud program that runs on the Apify platform. It has two run modes.
In Batch mode, an Actor accepts a well-defined JSON input, performs an action which can take anything from a few seconds to a few hours,
and optionally produces a well-defined JSON output, datasets with results, or files in key-value store.
In Standby mode, an Actor provides a web server which can be used as a website, API, or an MCP server.

Apify vocabulary and the platform model are defined once, in the agent quickstart at https://apify.com/agents.md.

## How to integrate an Actor?

If asked about integration, you help developers integrate Actors into their projects.
You adapt to their stack and deliver integrations that are safe, well-documented, and production-ready.

Do not guess an integration path. Every one of them is in the agent quickstart at https://apify.com/agents.md: the Apify MCP server, Agent Skills with the Apify CLI, the JavaScript and Python clients, the REST API, and the account-free path for an agent with no human to sign in. It also carries the rule on stating cost before the first paid run.

For examples already wired to this Actor's own input schema, see the [API](#api) section below.

Each client library has reference documentation the quickstart does not restate: [JavaScript/TypeScript](https://docs.apify.com/api/client/js/docs.md) (`npm install apify-client`) and [Python](https://docs.apify.com/api/client/python/docs.md) (`pip install apify-client`).

# README

## HKTVmall Product & Price Scraper (Hong Kong)

Search [HKTVmall](https://www.hktvmall.com) (Hong Kong's largest online mall) by
keyword, in English or Chinese, and get one flat row per product: the current
price in **HKD**, the list price before the reduction, the **discount percent**,
whether it is in stock, the star rating and review count, brand, category,
country of origin, the selling store, the product link and the photo. Run it on a
schedule and diff the dataset to get a **daily Hong Kong price, discount and
stock watch** per keyword: which milk, iPhone or shampoo listings were cut since
yesterday, and which sold out.

No account, no API key, no login, no browser. One request returns up to 100
products.

### Input

| Field | Notes |
|---|---|
| `searchTerms` | One or more search terms, one per line (`milk`, `iphone`, `雞蛋`). English and Chinese terms both work. A product found by two terms is returned once, under the first. |
| `maxItems` | Products to read per term (default 100, up to 1,000). HKTVmall's search never returns more than the first 1,000 matches of a term. |
| `proxyConfiguration` | Apify datacenter proxy by default. |

Example input:

```json
{
  "searchTerms": ["milk", "nintendo switch"],
  "maxItems": 200
}
```

### Output

Prices are numbers in Hong Kong dollars; `currency` is `HKD`.

| Field | Notes |
|---|---|
| `query`, `position` | The search term that first found the product, and its place in HKTVmall's list for that term (1 is first). |
| `product_code`, `url` | HKTVmall's product code (`H0888001_S_10143099A`) and the product link (`https://www.hktvmall.com/hktv/en/main/...`). |
| `name_en`, `name_zh` | The English and Chinese names as the merchant wrote them. Either is null when the listing has none. |
| `brand`, `brand_zh` | Brand in English and Chinese. Null for an unbranded listing. |
| `price` | What the product costs now (`sellingPrice`). |
| `list_price` | The price before the reduction. Equal to `price` when nothing is reduced. |
| `discount_price` | The reduced price as the listing carries it. Null when the listing has no reduction entry. |
| `discount_percent` | `(1 - price / list_price) * 100`, one decimal place. Worked out from the two prices, not sent. Null when the product is not reduced. |
| `on_sale` | True when `price` is below `list_price`. |
| `in_stock` | The mall's stock flag: true when it shows the product in stock. |
| `rating`, `review_count` | Average stars out of 5 and the number of reviews. |
| `category` | The deepest category path given, `Supermarket > Beverages > Milk & Soy Milk`. |
| `country_of_origin`, `packing_spec`, `store_name` | Country of origin (null when the listing says `N/A`), pack size as written (`250ML x 6 x 2`) and the selling store. |
| `image_url` | The primary photo. |

Example row (real values, 2026-11-11):

```json
{
  "query": "milk",
  "position": 1,
  "product_code": "H0888001_S_10143099A",
  "name_en": "VitaOat Oat Milk 250ML 6 PACK x 2 (Random delivery of old & new packings) #lowsugar #plantmilk",
  "name_zh": "維他奶 VitaOat 燕麥奶 250亳升6包裝 x 2 (新舊包裝隨機發送)",
  "brand": "Vitasoy",
  "brand_zh": "維他奶",
  "currency": "HKD",
  "price": 36.0,
  "list_price": 64.0,
  "discount_price": 36.0,
  "discount_percent": 43.8,
  "on_sale": true,
  "in_stock": true,
  "rating": 4.5,
  "review_count": 262,
  "category": "Supermarket > Beverages > Milk & Soy Milk",
  "country_of_origin": "China",
  "packing_spec": "250ML x 6 x 2",
  "store_name": "VITASOY / VITA",
  "url": "https://www.hktvmall.com/hktv/en/main/VITASOY/s/H1077001/Supermarket/Supermarket/Beverages/Milk-%26-Soy-Milk/VitaOat-Oat-Milk-250ML-6-PACK-x-2-Random-delivery-of-old-new-packings-lowsugar-plantmilk/p/H0888001_S_10143099A",
  "image_url": "https://cdn-media.hktvmall.com/hktv-mms/HKTV/mms/uploadProductImage/ed83/2b7b/3a9d/XmqtyYUAhG20250721101556_300.png"
}
```

#### Honest nulls

A field the service did not send is `null`, never `0` or `""`.

- **A product with no reviews has `rating` null.** The service sends 0.0 for it,
  which is not a rating. `review_count` is then 0, a real count.
- **`discount_percent` is null for a product that is not reduced**, not 0.
- **Member prices are not in the rows.** Some listings carry VIP, senior or
  frequent-buyer prices; `price` is the price anyone sees, and `on_sale` ignores
  the member tiers.

### Pricing

Pay per event:

- **$0.002** per run (`actor-start`), charged only after your input is
  validated, so a run that fails on bad input costs nothing.
- **$0.0021** per product row written (`product-scraped`), i.e. $2.10 per
  1,000 products. A row that is not written is not charged: repeats of a
  product another term already returned are free.

### How it fetches

HKTVmall's search page is rendered in the browser and holds no product list. The
list comes from the Algolia search service behind the site's own search box
(index `hktvProduct`, with the search-only key the site sends every visitor).
This actor calls that service directly and asks it for only the fields the rows
need, which makes a 100-product page about 170 KB instead of 2.4 MB. Measured
2026-11-11: the service answered JSON with no cookie from a plain home connection
and from an Apify datacenter address (10 of 10), the residential group (8 of 10)
and the platform's own address (10 of 10). A refusal (403, 429, 5xx), a 200 that
is not the service's JSON, or a dropped connection is treated as the address
being blocked, and the actor rotates to a fresh one and retries.

Things worth knowing, all measured:

- **At most 1,000 products per term.** The service reads the first 1,000 hits of
  a query whatever the match count says (`milk` matches about 16,700); a page
  past that is an empty answer with a message. The run logs a warning when a term
  has more matches than it can read. Narrow the term (`oat milk`, `vitasoy milk`)
  to reach the rest.
- **No sort option.** HKTVmall's price and sales sorts live in separate indexes
  that the public key may not read (HTTP 403, `Index not allowed with this API
  key`), so rows come in HKTVmall's own relevance order and `position` says where.
- **Match counts drift.** `nbHits` for the same term moved between requests, so
  the totals in the log are approximate.
- **Search ranking is HKTVmall's.** For some terms the service boosts a category
  (`milk` leads with soy and oat milk). Rows keep that order.
- **Chinese terms work.** `雞蛋` matched about 11,100 products; names and brands
  come in both languages.

If HKTVmall changes its search service or its fields, the run fails with a
message instead of returning empty rows.

# Actor input Schema

## `searchTerms` (type: `array`):

What you would type into the HKTVmall search box, one term per line, in English or Chinese (for example milk, iphone, shampoo or 雞蛋). Each term is read separately. A product that two terms both find is returned once, under the first.

## `maxItems` (type: `integer`):

Read at most this many products for each search term. HKTVmall's search never returns more than the first 1,000 matches of a term, so 1,000 is the most you can ask for.

## `proxyConfiguration` (type: `object`):

Use Apify's automatic datacenter proxy (the default). HKTVmall's search service answered Apify datacenter addresses 10 of 10 when this actor was built; the residential group was not needed. A refused request is retried from a fresh address.

## Actor input object example

```json
{
  "searchTerms": [
    "milk"
  ],
  "maxItems": 20,
  "proxyConfiguration": {
    "useApifyProxy": true
  }
}
```

# Actor output Schema

## `items` (type: `string`):

No description

# API

You can run this Actor programmatically using our API. Below are code examples in JavaScript, Python, and CLI, as well as the OpenAPI specification and MCP server setup.

## JavaScript example

```javascript
import { ApifyClient } from 'apify-client';

// Initialize the ApifyClient with your Apify API token
// Replace the '<YOUR_API_TOKEN>' with your token
const client = new ApifyClient({
    token: '<YOUR_API_TOKEN>',
});

// Prepare Actor input
const input = {
    "searchTerms": [
        "milk"
    ],
    "maxItems": 20,
    "proxyConfiguration": {
        "useApifyProxy": true
    }
};

// Run the Actor and wait for it to finish
const run = await client.actor("superslowsloth/hktvmall-products").call(input);

// Fetch and print Actor results from the run's dataset (if any)
console.log('Results from dataset');
console.log(`💾 Check your data here: https://console.apify.com/storage/datasets/${run.defaultDatasetId}`);
const { items } = await client.dataset(run.defaultDatasetId).listItems();
items.forEach((item) => {
    console.dir(item);
});

// 📚 Want to learn more 📖? Go to → https://docs.apify.com/api/client/js/docs

```

## Python example

```python
from apify_client import ApifyClient

# Initialize the ApifyClient with your Apify API token
# Replace '<YOUR_API_TOKEN>' with your token.
client = ApifyClient("<YOUR_API_TOKEN>")

# Prepare the Actor input
run_input = {
    "searchTerms": ["milk"],
    "maxItems": 20,
    "proxyConfiguration": { "useApifyProxy": True },
}

# Run the Actor and wait for it to finish
run = client.actor("superslowsloth/hktvmall-products").call(run_input=run_input)

# Fetch and print Actor results from the run's dataset (if there are any)
print(f"💾 Check your data here: https://console.apify.com/storage/datasets/{run.default_dataset_id}")
for item in client.dataset(run.default_dataset_id).iterate_items():
    print(item)

# 📚 Want to learn more 📖? Go to → https://docs.apify.com/api/client/python/docs/quick-start

```

## CLI example

```bash
echo '{
  "searchTerms": [
    "milk"
  ],
  "maxItems": 20,
  "proxyConfiguration": {
    "useApifyProxy": true
  }
}' |
apify call superslowsloth/hktvmall-products --silent --output-dataset

```

## MCP server setup

```json
{
    "mcpServers": {
        "apify": {
            "type": "http",
            "url": "https://mcp.apify.com/?tools=fetch-actor-details,superslowsloth/hktvmall-products"
        }
    }
}
```

The hosted server signs you in with OAuth on first connect, so no API token belongs in this config. Clients without OAuth support can send an `Authorization: Bearer <APIFY_API_TOKEN>` header instead, using a token from API & Integrations in Apify Console (https://console.apify.com/settings/integrations).

## OpenAPI specification

Download the OpenAPI definition: https://api.apify.com/v2/actors/GflxeVTvZ8LwrtovL/builds/yAgmXkaG6L2B7zXSc/openapi.json
