# Namshi Product Scraper (`rl1987/namshi-api-scraper`) Actor

Scrapes Namshi (UAE/GCC fashion) product listings — name, brand, price, discount, sizes, colours, images and product URL — for a search term or category, via the reversed Namshi mobile catalog API. No account needed.

- **URL**: https://apify.com/rl1987/namshi-api-scraper.md
- **Developed by:** [R.L.](https://apify.com/rl1987) (community)
- **Features:** Limited permissions
- **Stats:** 8 total users, 4 monthly users, 100.0% runs succeeded, 0 bookmarks
- **User rating**: No ratings yet

## Pricing

from $1.00 / 1,000 products

This Actor is paid per event and usage. You are charged both the fixed price for specific events and for Apify platform usage.

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

## Namshi Product Scraper

Scrape product listings from [Namshi](https://www.namshi.com) — the UAE/GCC fashion retailer —
for a **search term** or a **category path**. Returns name, brand, price, discount, sizes,
colours, images and the product URL as structured dataset rows. Talks to Namshi's mobile catalog
API directly (reversed from the `com.namshi.android` app); the catalog endpoints are
unauthenticated, so no account or API key is required.

### Input

| Field | Type | Notes |
|-------|------|-------|
| `searchTerm` | string | A product query, e.g. `adidas samba`. Use this OR a category path. |
| `categoryPath` | string | A category/brand path, e.g. `women/dresses`. Takes precedence over the search term. |
| `department` | select | Scope a search to Women/Men/Kids/Home/Beauty (ignored for category paths). |
| `includeSizes` | boolean | Fetch available sizes per product (one extra call each). Default `true`. |
| `locale` | select | Storefront/currency — `en-ae` (UAE/AED) by default, plus SA/KW/BH/OM/QA. |
| `maxItems` | integer | Max products. `0` = all pages. |
| `proxyConfiguration` | proxy | **Residential proxy required** (see below). Defaults to Apify Proxy RESIDENTIAL. |

#### Example input

```json
{
  "searchTerm": "adidas samba",
  "department": "men",
  "includeSizes": true,
  "maxItems": 100,
  "proxyConfiguration": { "useApifyProxy": true, "apifyProxyGroups": ["RESIDENTIAL"] }
}
```

### Output

Each dataset row is one product:

```json
{
  "name": "Samba OG Shoes",
  "brand": "adidas Originals",
  "sku": "V1234567A",
  "price": 399,
  "original_price": 499,
  "currency": "AED",
  "discount_percent": 20,
  "sizes": ["40", "41", "42", "43"],
  "colors": ["Black", "White"],
  "product_url": "https://www.namshi.com/uae-en/buy-adidas-...",
  "image_urls": ["https://f.nooncdn.com/p/..."]
}
```

### Why a residential proxy is required

Namshi's catalog sits behind Akamai, which Access-Denies datacenter egress IPs and non-browser
TLS fingerprints. The client already presents a Chrome TLS fingerprint (`curl_cffi`), and this
actor supplies the IP through a **residential** proxy, drawing a fresh exit IP per page. A
datacenter proxy or no proxy will be Access-Denied. The input defaults to Apify Proxy RESIDENTIAL.

### Pricing

The current price of every event is on the **Pricing** tab of this Actor's page in Apify Store. That tab is generated from the Actor's own pricing record, so it is always current, and your plan's rung is applied automatically. A figure repeated here would be a second copy that drifts out of date.

You can cap what any single run may spend with **Max total charge**.

### Notes & limitations

- Prices are in the storefront currency selected by `locale` (default AED for `en-ae`).
- This is an unofficial client and is not affiliated with or endorsed by Namshi.

### Listing vs details (PLP/PDP)

By default the actor returns fast **listing (PLP)** rows. Set `includeDetails: true` to also fetch each product's **detail page (PDP)** — adding sizes, full description and attributes — billed as a separate `product-details` event. Namshi is behind Akamai: use the RESIDENTIAL proxy (default, fast) or the **UNBLOCKER** group for maximum reliability.

# Actor input Schema

## `searchTerm` (type: `string`):

A product search query, e.g. "adidas samba" or "summer dress". Use this OR a category path.

## `categoryPath` (type: `string`):

A category/brand path instead of a search, e.g. "women/dresses" or "men/nike". Takes precedence over the search term when set.

## `department` (type: `string`):

Scope a search to a department. Ignored for category paths.

## `locale` (type: `string`):

Namshi storefront/currency. en-ae = UAE (AED), en-sa = Saudi (SAR), etc.

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

Maximum products to return. 0 = all pages.

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

Namshi sits behind Akamai, which Access-Denies datacenter IPs. Use Apify RESIDENTIAL (default, fast) or the UNBLOCKER group (slower per request but auto-solves the anti-bot for maximum reliability).

## `includeDetails` (type: `boolean`):

Fetch each product’s detail page (one extra request each) to add sizes, full description and attributes. Off by default — listing (PLP) rows are much faster. Billed separately.

## Actor input object example

```json
{
  "searchTerm": "adidas samba",
  "categoryPath": "",
  "department": "",
  "locale": "en-ae",
  "maxItems": 100,
  "proxyConfiguration": {
    "useApifyProxy": true,
    "apifyProxyGroups": [
      "RESIDENTIAL"
    ]
  },
  "includeDetails": false
}
```

# Actor output Schema

## `results` (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 = {
    "searchTerm": "adidas samba",
    "categoryPath": "",
    "proxyConfiguration": {
        "useApifyProxy": true,
        "apifyProxyGroups": [
            "RESIDENTIAL"
        ]
    }
};

// Run the Actor and wait for it to finish
const run = await client.actor("rl1987/namshi-api-scraper").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 = {
    "searchTerm": "adidas samba",
    "categoryPath": "",
    "proxyConfiguration": {
        "useApifyProxy": True,
        "apifyProxyGroups": ["RESIDENTIAL"],
    },
}

# Run the Actor and wait for it to finish
run = client.actor("rl1987/namshi-api-scraper").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 '{
  "searchTerm": "adidas samba",
  "categoryPath": "",
  "proxyConfiguration": {
    "useApifyProxy": true,
    "apifyProxyGroups": [
      "RESIDENTIAL"
    ]
  }
}' |
apify call rl1987/namshi-api-scraper --silent --output-dataset

```

## MCP server setup

```json
{
    "mcpServers": {
        "apify": {
            "type": "http",
            "url": "https://mcp.apify.com/?tools=fetch-actor-details,rl1987/namshi-api-scraper"
        }
    }
}
```

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/gOFmiqX6MX4dTYOKZ/builds/MRC2v4FKWlA4cSgSI/openapi.json
