# Mercari.com Scraper (`dtrungtin/mercari-com-scraper`) Actor

Extracting all templates from the template list page.

- **URL**: https://apify.com/dtrungtin/mercari-com-scraper.md
- **Developed by:** [Tin](https://apify.com/dtrungtin) (community)
- **Categories:** E-commerce
- **Stats:** 31 total users, 5 monthly users, 96.7% runs succeeded, 0 bookmarks
- **User rating**: No ratings yet

## Pricing

from $10.00 / 1,000 results

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?

Actors are web data automations that power AI and operations. They run on the Apify platform to scrape websites, process data, connect APIs, and automate workflows.
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.
Actors are written with capital "A".

## 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.
The best way to integrate Actors is as follows.

- **AI agents and MCP clients** — the [Apify MCP server](https://docs.apify.com/integrations/mcp.md) at `https://mcp.apify.com` (remote, streamable HTTP, OAuth on first use).
- **Agentic workflows and local Actor development** — [Agent Skills](https://apify.com/.well-known/agent-skills/index.json) with the [Apify CLI](https://docs.apify.com/cli/docs.md): `npm install -g apify-cli`, then `apify login`.
- **JavaScript/TypeScript projects** — the official [JS/TS client](https://docs.apify.com/api/client/js/docs.md): `npm install apify-client`.
- **Python projects** — the official [Python client](https://docs.apify.com/api/client/python/docs.md): `pip install apify-client`.
- **Any other language** — the [REST API](https://docs.apify.com/api/v2.md).

For usage examples, see the [API](#api) section below.

For more details, see Apify documentation as [Markdown index](https://docs.apify.com/llms.txt) and [Markdown full-text](https://docs.apify.com/llms-full.txt).

# README

## Mercari.com Scraper

Mercari.com Scraper extracts all and any items from any category page on Mercari or by a specific keyword, provided you copy & paste the search URL. Download your data as HTML or Excel table, as well as in JSON, CSV, or XML format.

**How to use the data extracted from Mercari:**

- **Automated price and listing monitoring** – Scan dozens of e-commerce items and products in real time to adjust your own buying or pricing strategies.
- **Track competitors' prices** – Track listings, product, and sales data from Mercari to compare with competitor prices and back up your decision-making process with real data.
- **Facilitate market analysis** – Scan and analyze Mercari for images, products, related keywords, new categories, and more to stay ahead of emerging trends and consumer habits.
- **Optimize performance and implement lightweight automation** – Collect product data easily and non-manually, whether for market research, machine learning, or new product development.

For more ideas on how to use data extracted from Mercari, check out [industries pages](https://apify.com/industries) which describe **at least 12 ways** web scraping data is used across projects and businesses, especially in [retail and e-commerce](https://apify.com/industries/ecommerce-and-retail).

### Cost of usage

It is more efficient to run one longer scrape (at least one minute) than several short ones, due to startup time. On average, this scraper will cost you around **0.06 USD** per 1000 items. For more details, see the [platform pricing page](https://apify.com/pricing/actors). To check your usage and limits, visit *Settings → Usage and Billing* in [your Console](https://console.apify.com/). The easiest way to estimate CU usage is to *perform a test run*.

### Input Parameters

This actor needs only two settings from you – **a link** and a **proxy**:

- **startUrls** *(required)*: List of [Request objects](https://sdk.apify.com/docs/api/request#docsNav), specifying the search queries/categories you want to scrape. The URL can be any search/category page on Mercari.
- **maxPages** *(required)*: Limit of pages to be scraped.
- **proxyConfiguration** *(required)*: Specifies the proxy settings used while running the actor. When running this actor on the platform, the proxy setting must always be set on. The default value is `{ "useApifyProxy": true }`

#### Example

```json
{
  "startUrls": [
    {
      "url": "https://www.mercari.com/search/?keyword=phone"
    },
    {
      "url": "https://www.mercari.com/category/electronics/"
    }
  ],
  "maxPages": 10,
  "proxyConfig": {
    "useApifyProxy": true
  }
}
```

### Output

After the Mercari actor finishes the scraping run, it will store the scraped results in a dataset and show them to you as output results. The results can be downloaded in various formats.

#### Output example:

```json
[
  {
    "url": "https://www.mercari.com/us/item/m1234567890/",
    "name": "iPhone 12 Pro Max 128GB",
    "image": "https://static.mercdn.net/item/detail/orig/photos/m1234567890_1.jpg",
    "priceShow": "$799",
    "location": "California",
    "description": [
      "Excellent condition, unlocked, includes original box and charger."
    ],
    "sellerName": "BestSeller123",
    "brandName": "Apple",
    "price": "799",
    "inStock": true,
    "originalPrice": "999",
    "listUrl": "https://www.mercari.com/search/?keyword=phone"
  }
]
```

Note: Search results may vary depending on your location. We recommend using proxies for consistent results from the same region.

### Proxy usage

This actor, like many scrapers in the [retail industry](https://apify.com/industries/ecommerce-and-retail), requires **Proxy servers** to function properly. For more than a few results, subscribe to the [Apify platform](https://console.apify.com/sign-up) for access to a large pool of proxies.

### Supported countries

This actor is designed for scraping the US version of Mercari:

- 🇺🇸 **US** – https://www.mercari.com

If you need support for other Mercari domains (e.g., Japan), please contact us.

### Related Actors you might like

Speed up your whole scraping workflow with these companion tools from the same developer:

- **[AI Dataset Search](https://apify.com/dtrungtin/ai-dataset-search)** — Search and explore your scraped datasets in plain English. Ask questions and instantly surface the profiles or records you need from the output of this and other Actors, without writing manual filters.
- **[AI Scraper Input Generator](https://apify.com/dtrungtin/ai-scraper-input-generator)** — Turn a plain-language description of what you want to scrape into a ready-to-run input configuration, so you can set up Actor runs in seconds instead of hand-editing JSON.

Together with **Mercari.com Scraper**, they cover the full loop: generate the input, run the scrape, then search the results.

### Other e-commerce scrapers

We have many more e-commerce and retail scrapers available. See the [E-commerce Category in Apify Store](https://apify.com/store?category=ECOMMERCE).

### Need to find product pairs between Mercari and another online shop?

Use the [AI Product Matcher](https://apify.com/equidem/ai-product-matcher) to compare items from different web stores, identify exact matches, and compare real-time data obtained via web scraping. See [this guide](https://blog.apify.com/product-matching-ai-pricing-intelligence-web-scraping/) for details.

# Actor input Schema

## `startUrls` (type: `array`):

List of URLs that will be scraped or crawled.

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

Limit of items to be scraped

## Actor input object example

```json
{
  "startUrls": [
    {
      "url": "https://www.mercari.com/search/?keyword=xiaomi%2014"
    }
  ],
  "maxItems": 10
}
```

# 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 = {
    "startUrls": [
        {
            "url": "https://www.mercari.com/search/?keyword=xiaomi%2014"
        }
    ]
};

// Run the Actor and wait for it to finish
const run = await client.actor("dtrungtin/mercari-com-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 = { "startUrls": [{ "url": "https://www.mercari.com/search/?keyword=xiaomi%2014" }] }

# Run the Actor and wait for it to finish
run = client.actor("dtrungtin/mercari-com-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 '{
  "startUrls": [
    {
      "url": "https://www.mercari.com/search/?keyword=xiaomi%2014"
    }
  ]
}' |
apify call dtrungtin/mercari-com-scraper --silent --output-dataset

```

## MCP server setup

```json
{
    "mcpServers": {
        "apify": {
            "type": "http",
            "url": "https://mcp.apify.com/?tools=fetch-actor-details,dtrungtin/mercari-com-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/12YE2yPaVgH2xhyHl/builds/WNWIqKSciktLZkmJw/openapi.json
