# Flipkart Product Scraper & Price Monitor (search, specs, stock) (`datahamster/flipkart-products`) Actor

Flipkart scraper for search results and product pages: title, brand, price, MRP, discount, rating, review counts, stock, category, specs and seller in one flat row. Also a Flipkart price tracker: monitor mode alerts on price and stock changes. Empty runs charge nothing.

- **URL**: https://apify.com/datahamster/flipkart-products.md
- **Developed by:** [Viktor Dubnytskiy](https://apify.com/datahamster) (community)
- **Categories:** E-commerce
- **Features:** Limited permissions
- **Stats:** 1 total users, 0 monthly users, 100.0% runs succeeded, 0 bookmarks
- **User rating**: No ratings yet

## Pricing

from $1.20 / 1,000 result items

This Actor is paid per event and usage. You are charged both the fixed price for specific events and for Apify platform usage.
Since this Actor supports Apify Store discounts, the price gets lower the higher subscription plan you have.

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

## Flipkart Product Scraper & Price Monitor

Search Flipkart by keyword or feed it product URLs and get one flat row per product: price, MRP, discount, rating, stock and category — with the full spec table, seller and delivery date on request. No login, no cookies, India exit so prices are the real INR prices an Indian shopper sees.

**Try it:** the prefilled example returns 20 rows in about 20 seconds and costs about $0.030. Results cost $1.50 per 1,000.

### What you get

Real rows from the example dataset (`searches: ["headphones"]`):

| title | price | mrp | discountPercent | rating | inStock |
|---|---|---|---|---|---|
| Skullcandy Crusher Bluetooth Headset with Mic | `6999` | `39999` | `82` | `4.4` (1098 ratings, 209 reviews) | `true` |

With `fetchDetails: true` the same product also gets `seller: "SuperComNet"`, `sellerRating: 4.1`, `delivery: "Delivery by Wednesday, 16 Sep"`, `highlights: ["Up to 40 hrs of Battery Life", "With Deep Bass", "Bluetooth Connectivity"]` and a 22-key `specs` dictionary.

Full row: `id`/`productId`, `url`, `title`, `brand`, `price`, `mrp`, `currency`, `discountPercent`, `rating`, `ratingCount`, `reviewCount`, `inStock`, `imageUrl`, `category`, `highlights`, `specs`, `seller`, `sellerRating`, `delivery`, `query`, `rank`, `page`, `source`, `scrapedAt`.

### Use cases

- **Price tracking** — run a saved task in `monitor` mode on a list of product URLs or a keyword; you get rows only when price, stock or rating changed, plus a webhook or Telegram message.
- **Competitor and catalogue research** — pull 120+ products for a keyword with MRP, discount and rating counts and see where a category really prices.
- **Assortment and spec sheets** — `fetchDetails` gives the full specification table as a dictionary, ready for a spreadsheet.

### Try it in 10 seconds

Hit **Start**/**Try it** — the input already works: `searches: ["headphones"]`, `maxPagesPerSearch: 1`, `maxItems: 20`, nothing required. Add `fetchDetails: true` for specs, seller and delivery date.

To track price and stock changes instead of a one-off pull: save as a task, set **Mode** to `monitor`, give it a `monitorStateId`, and schedule it (Apify → Schedules → cron `0 6 * * *` for daily) with a `webhookUrl` or Telegram target.

### Related actors

- [Amazon Price Tracker: Product Scraper by ASIN, Buy Box, Stock](https://apify.com/datahamster/amazon-product-monitor) — the same monitor pattern for Amazon listings.
- [Walmart Product Scraper & Price Monitor (stock, seller, store)](https://apify.com/datahamster/walmart-product-monitor) — same pattern for Walmart's marketplace.
- [Etsy Listings Scraper (search, shops, listing details, prices)](https://apify.com/datahamster/etsy-listings) — for handmade and vintage goods instead of mainstream retail.
- [Alibaba Scraper — Products, Suppliers, Prices & MOQ](https://apify.com/datahamster/alibaba-products) — check supplier prices upstream of the listings you're tracking.

### Input

| Field | Meaning | Default |
|---|---|---|
| `searches` | Keywords or full Flipkart search URLs | `["headphones"]` |
| `productUrls` | Product URLs or bare product ids | empty |
| `maxPagesPerSearch` | Result pages per keyword, 40 products each (1-50) | `3` |
| `fetchDetails` | Open each product page for specs, highlights, seller, delivery | `false` |
| `minPrice`, `maxPrice` | Keep only products inside this INR range | empty |
| `strictQueryMatch` | Skip result pages Flipkart fills with unrelated products | `true` |
| `maxItems` | Stop after this many rows | `100` |
| `mode` | `scrape`, or `monitor` for only new/changed rows | `scrape` |
| `monitorStateId`, `webhookUrl`, `telegramBotToken`, `telegramChatId` | Monitor-mode state key and alert targets | empty |

### Pricing

| Event | Price |
|---|---|
| result | $0.0015 per product ($1.50 per 1,000) |
| monitor-check | $0.005 per monitor run |
| change | $0.0015 per new/changed product |

You are charged only for rows actually pushed. A run that finds nothing charges no result events.

**Found it useful?** A short review on the Store page helps other people find this actor and tells us what to improve. If something is wrong with a price or stock read, open an issue on the actor page — issues are answered within a day.

### Why this actor

- Half the price per product of the other Flipkart scrapers on the Store.
- Search rows are already rich: price, MRP, discount, rating, both counts, stock and image come from the search page itself, so a 120-product sweep is 3 requests, not 123.
- Built-in monitor mode with webhook and Telegram alerts — price, stock and rating are the change fingerprint.
- The exit is pinned to India, so prices are INR and availability is the one Indian shoppers see.

### Limits (read these)

- **Flipkart never returns an empty search page.** A keyword that matches nothing gets a generic catalogue page of unrelated products. With `strictQueryMatch` on (the default) the actor recognises such a page — no breadcrumb category, and none of the first five titles containing a word of your keyword — skips it, stops paging that keyword and charges you nothing. A run like that ends with zero rows and `no_matches` in the run summary. Broad keywords whose products really do match (`birthday gift`) are kept.
- Flipkart repeats a card or two inside a page and between pages; rows are de-duplicated by product id, so a 3-page sweep usually yields a little under 120 rows. `rank` is the position Flipkart gave the card on the page, so it skips the numbers of the removed duplicates and is not a dense 1..N counter.
- `seller`, `sellerRating`, `delivery`, `specs` and `highlights` exist only on rows fetched with `fetchDetails` or from `productUrls`.
- `delivery` is the date Flipkart quotes for a generic Indian address, without a pincode; the exact date for your pincode can differ.
- Prices exclude bank/card offers and exchange discounts. `price` is the selling price, `mrp` the struck-through maximum retail price.
- No buyer reviews, no reviewer names, no seller contact details — only aggregate `rating`, `ratingCount` and `reviewCount`.

### FAQ

**Do I need a Flipkart account or cookies?** No. Every request is made as a logged-out visitor.

**Why are some prices different from what I see?** Flipkart personalises by location and shows bank-offer prices on the page; this actor returns the plain selling price from an Indian exit, without offers.

**My keyword returned nothing at all — is the actor broken?** No. Flipkart answers an unmatchable keyword with a page of unrelated products instead of an empty page; the actor drops that page rather than billing you for 40 irrelevant rows. Check your spelling, or set `strictQueryMatch: false` to see exactly what Flipkart returned.

**What happens when a product URL is dead?** Flipkart answers 200 with an empty shell. The row is skipped, not charged, and the run summary says why.

**How do I track prices?** Save the actor as a task with `mode: monitor` and your product URLs or keyword, schedule it, and set `webhookUrl` or the Telegram fields. Rows come back only when `price`, `inStock` or `rating` changed.

### Changelog

- 0.1: initial release — keyword search with 40 products per page, product-page details (specs, highlights, seller, delivery), price range filter, unrelated-result pages skipped and unbilled, monitor mode.

***

If this actor saved you time, a short review on its Store page genuinely helps other people find it. Found a bug or need a field that is missing? Open a ticket on the **Issues** tab.

# Actor input Schema

## `searches` (type: `array`):

Keywords to search Flipkart for, one per line, e.g. "headphones", "running shoes", "samsung 5g phone". A full search URL also works, e.g. "https://www.flipkart.com/search?q=air+purifier". One page returns up to 40 products.

## `productUrls` (type: `array`):

Known Flipkart product URLs or bare product ids (pid) to scrape directly, e.g. "https://www.flipkart.com/skullcandy-crusher-bluetooth-headset-mic/p/itmcb06279c54724?pid=ACCESZCHHGX9YFBN" or "ACCESZCHHGX9YFBN". These always come back with specs, highlights, seller and delivery date.

## `maxPagesPerSearch` (type: `integer`):

How many result pages to read per keyword, e.g. 3 = up to 120 products. Range 1-50.

## `fetchDetails` (type: `boolean`):

false = search rows only; they already carry price, MRP, discount, rating, counts, stock and image. true = open every product page as well for the specification table, highlights, seller name, seller rating and delivery date (one extra request per product, so runs take much longer). Example: false.

## `minPrice` (type: `integer`):

Skip products cheaper than this, e.g. 1000. Leave empty for no lower bound.

## `maxPrice` (type: `integer`):

Skip products more expensive than this, e.g. 5000. Leave empty for no upper bound.

## `strictQueryMatch` (type: `boolean`):

Flipkart never returns an empty search page: a keyword it cannot match is answered with a page of unrelated products. true = skip search pages Flipkart fills with unrelated products when the keyword has no matches, so you are not charged for them. false = keep whatever Flipkart returns. Example: true.

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

Stop after this many results (you are charged only for pushed items)

## `mode` (type: `string`):

scrape = full results; monitor = only new/changed items since the previous run of this task

## `monitorStateId` (type: `string`):

Optional state id when not running as a saved task (monitor mode)

## `webhookUrl` (type: `string`):

POST a change summary here in monitor mode

## `telegramBotToken` (type: `string`):

Optional: bot token for monitor-mode change summaries

## `telegramChatId` (type: `string`):

Optional: chat id that receives monitor-mode summaries

## Actor input object example

```json
{
  "searches": [
    "headphones"
  ],
  "productUrls": [],
  "maxPagesPerSearch": 1,
  "fetchDetails": false,
  "strictQueryMatch": true,
  "maxItems": 20,
  "mode": "scrape"
}
```

# Actor output Schema

## `results` (type: `string`):

All pushed rows (dataset, JSON)

## `resultsTable` (type: `string`):

Dataset in the Console viewer

## `runSummary` (type: `string`):

RUN_SUMMARY record

# 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 = {
    "searches": [
        "headphones"
    ],
    "maxPagesPerSearch": 1,
    "maxItems": 20
};

// Run the Actor and wait for it to finish
const run = await client.actor("datahamster/flipkart-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 = {
    "searches": ["headphones"],
    "maxPagesPerSearch": 1,
    "maxItems": 20,
}

# Run the Actor and wait for it to finish
run = client.actor("datahamster/flipkart-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 '{
  "searches": [
    "headphones"
  ],
  "maxPagesPerSearch": 1,
  "maxItems": 20
}' |
apify call datahamster/flipkart-products --silent --output-dataset

```

## MCP server setup

```json
{
    "mcpServers": {
        "apify": {
            "type": "http",
            "url": "https://mcp.apify.com/?tools=fetch-actor-details,datahamster/flipkart-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/bvnMoNt6Ok8kzV9c9/builds/Yyf1RziQ568PShNEV/openapi.json
