# Sephora Scraper (`getdataforme/sephora-scraper`)

A Sephora scraper automatically extracts beauty product data from Sephora.com, including prices, brand information, reviews, ingredients, stock status, and promotional offers. It helps track beauty trends, monitor competitor pricing, and analyze customer sentiment for market research.

- **URL**: https://beta-securitybyobscurity.apify.com/getdataforme/sephora-scraper.md
- **Developed by:** [GetDataForMe](https://beta-securitybyobscurity.apify.com/getdataforme) (community)
- **Categories:** E-commerce
- **Stats:** 29 total users, 6 monthly users, 100.0% runs succeeded, NaN bookmarks
- **User rating**: No ratings yet

## Pricing

$25.00/month + usage

To use this Actor, you pay a monthly rental fee to the developer. The rent is subtracted from your prepaid usage every month after the free trial period.
You also pay for the Apify platform usage, which gets cheaper the higher Apify subscription plan you have.

Learn more: https://docs.apify.com/platform/actors/running/actors-in-store#rental-actors

# README

## Sephora Scraper Documentation

### Overview

The **Sephora Scraper** is an Apify actor designed to extract comprehensive product information from Sephora.com. By providing a list of product URLs as input, the scraper retrieves details such as product name, brand, pricing, availability, reviews, and more.

***

### Input Configuration

The input for the Sephora Scraper should be a JSON object containing the following keys:

- `proxyConfiguration`: Specifies the proxy settings. Use the Apify residential proxy group for optimal performance.
- `urls`: An array of Sephora product URLs to scrape.

#### Input Example

```json
{
    "proxyConfiguration": {
        "useApifyProxy": true,
        "apifyProxyGroups": [
            "RESIDENTIAL"
        ]
    },
    "urls": [
        "https://www.sephora.com/product/rare-beauty-by-selena-gomez-soft-pinch-liquid-blush-P97989778?skuId=2362085&icid2=homepage_productlist_chosenforyou_us_rwd_092022"
    ]
}
```

***

### Output

The scraper returns a JSON array of objects, where each object contains detailed information about the product, including:

- `url`: The product URL provided in the input.
- `name`: The name of the product.
- `brand`: The brand of the product.
- `product_offers`: An array of pricing and availability details for different SKUs, including:
  - `price`: The product price.
  - `priceCurrency`: The currency of the price.
  - `availability`: Availability status (e.g., InStock, OutOfStock).
  - `sku`: Stock Keeping Unit (SKU) identifier.
  - `image`: URL of the product image.
  - `seller`: The seller's name.
- `aggregateRating`: Overall rating details, including:
  - `reviewCount`: Total number of reviews.
  - `bestRating`: The highest possible rating.
  - `ratingValue`: The average rating value.
- `reviewCount`: Total number of reviews.
- `description`: A brief description of the product.
- `image`: An array of product images.
- `reviews`: An array of review details, including:
  - `id`: Review ID.
  - `name`: Reviewer's name.
  - `datePublished`: Date the review was published.
  - `description`: Content of the review.
  - `reviewRating`: Rating details, including `bestRating`, `ratingValue`, and `itemReviewed`.

#### Output Example

```json
[
    {
        "url": "https://www.sephora.com/product/rare-beauty-by-selena-gomez-soft-pinch-liquid-blush-P97989778",
        "name": "Soft Pinch Liquid Blush",
        "brand": "Rare Beauty by Selena Gomez",
        "product_offers": [
            {
                "price": "25.0",
                "priceCurrency": "USD",
                "availability": "http://schema.org/InStock",
                "sku": "2362143",
                "image": "https://www.sephora.com/productimages/sku/s2362143-main-hero.jpg",
                "seller": "Sephora"
            },
            {
                "price": "15.0",
                "priceCurrency": "USD",
                "availability": "http://schema.org/OutOfStock",
                "sku": "2761989",
                "image": "https://www.sephora.com/productimages/sku/s2761989-main-hero.jpg",
                "seller": "Sephora"
            }
        ],
        "aggregateRating": {
            "reviewCount": "12262",
            "bestRating": "5",
            "ratingValue": "4.5402",
            "itemReviewed": {
                "name": "Soft Pinch Liquid Blush"
            }
        },
        "reviewCount": "12262",
        "description": "Shop Rare Beauty’s Soft Pinch Liquid Blush at Sephora. This weightless, long-lasting liquid blush blends and builds beautifully for a soft, healthy flush.",
        "image": [
            "https://www.sephora.com/productimages/sku/s2362085-main-hero.jpg"
        ],
        "reviews": [
            {
                "id": "330906076",
                "name": ["vickyyvick"],
                "datePublished": ["2025-01-02"],
                "description": ["After using this product, it’s very nice on the skin. But, I will say that it leaves the mark of the liquid and it’s a little hard to blend 😭. So, take that as you will, but the product is good overall. I got it in the color ‘Bliss’."],
                "reviewRating": {
                    "bestRating": "5",
                    "ratingValue": "3",
                    "itemReviewed": "Soft Pinch Liquid Blush"
                }
            }
        ]
    }
]
```

***

### Usage Instructions

1. **Input Preparation**: Create a JSON file with the `proxyConfiguration` and `urls` array containing the product URLs to scrape.
2. **Actor Execution**: Run the Sephora Scraper actor on the Apify platform, providing the input JSON file.
3. **Retrieve Results**: After the execution, download the output JSON containing the scraped data.

***

### Support

For custom outputs, simplified formats, or to report any issues, please contact:

- **Email**: <support@getdataforme.com>
- **Contact Form**: <https://getdataforme.com/contact/>

When reaching out, please include a clear subject line and a detailed description of your request or issue.

***

Thank you for using the Sephora Scraper!

# Actor input Schema

## `urls` (type: `array`):

A list of URLs of the web pages you want to scrape data from.

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

Specifies proxy servers that will be used by the scraper in order to hide its origin.

## Actor input object example

```json
{
  "urls": [
    "https://www.sephora.com/product/rare-beauty-by-selena-gomez-soft-pinch-liquid-blush-P97989778?skuId=2362085&icid2=homepage_productlist_chosenforyou_us_rwd_092022"
  ],
  "proxyConfiguration": {
    "useApifyProxy": true,
    "apifyProxyGroups": [
      "RESIDENTIAL"
    ]
  }
}
```

# 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 = {
    "urls": [
        "https://www.sephora.com/product/rare-beauty-by-selena-gomez-soft-pinch-liquid-blush-P97989778?skuId=2362085&icid2=homepage_productlist_chosenforyou_us_rwd_092022"
    ],
    "proxyConfiguration": {
        "useApifyProxy": true,
        "apifyProxyGroups": [
            "RESIDENTIAL"
        ]
    }
};

// Run the Actor and wait for it to finish
const run = await client.actor("getdataforme/sephora-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 = {
    "urls": ["https://www.sephora.com/product/rare-beauty-by-selena-gomez-soft-pinch-liquid-blush-P97989778?skuId=2362085&icid2=homepage_productlist_chosenforyou_us_rwd_092022"],
    "proxyConfiguration": {
        "useApifyProxy": True,
        "apifyProxyGroups": ["RESIDENTIAL"],
    },
}

# Run the Actor and wait for it to finish
run = client.actor("getdataforme/sephora-scraper").call(run_input=run_input)

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

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

```

## CLI example

```bash
echo '{
  "urls": [
    "https://www.sephora.com/product/rare-beauty-by-selena-gomez-soft-pinch-liquid-blush-P97989778?skuId=2362085&icid2=homepage_productlist_chosenforyou_us_rwd_092022"
  ],
  "proxyConfiguration": {
    "useApifyProxy": true,
    "apifyProxyGroups": [
      "RESIDENTIAL"
    ]
  }
}' |
apify call getdataforme/sephora-scraper --silent --output-dataset

```

## MCP server setup

```json
{
    "mcpServers": {
        "apify": {
            "command": "npx",
            "args": [
                "mcp-remote",
                "https://mcp.apify.com/?tools=getdataforme/sephora-scraper",
                "--header",
                "Authorization: Bearer <YOUR_API_TOKEN>"
            ]
        }
    }
}

```

## OpenAPI specification

```json
{
    "openapi": "3.0.1",
    "info": {
        "title": "Sephora Scraper",
        "description": "A Sephora scraper automatically extracts beauty product data from Sephora.com, including prices, brand information, reviews, ingredients, stock status, and promotional offers. It helps track beauty trends, monitor competitor pricing, and analyze customer sentiment for market research.",
        "version": "0.0",
        "x-build-id": "thJNdScHPZyWGFz0k"
    },
    "servers": [
        {
            "url": "https://api.apify.com/v2"
        }
    ],
    "paths": {
        "/acts/getdataforme~sephora-scraper/run-sync-get-dataset-items": {
            "post": {
                "operationId": "run-sync-get-dataset-items-getdataforme-sephora-scraper",
                "x-openai-isConsequential": false,
                "summary": "Executes an Actor, waits for its completion, and returns Actor's dataset items in response.",
                "tags": [
                    "Run Actor"
                ],
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/inputSchema"
                            }
                        }
                    }
                },
                "parameters": [
                    {
                        "name": "token",
                        "in": "query",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Enter your Apify token here"
                    }
                ],
                "responses": {
                    "200": {
                        "description": "OK"
                    }
                }
            }
        },
        "/acts/getdataforme~sephora-scraper/runs": {
            "post": {
                "operationId": "runs-sync-getdataforme-sephora-scraper",
                "x-openai-isConsequential": false,
                "summary": "Executes an Actor and returns information about the initiated run in response.",
                "tags": [
                    "Run Actor"
                ],
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/inputSchema"
                            }
                        }
                    }
                },
                "parameters": [
                    {
                        "name": "token",
                        "in": "query",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Enter your Apify token here"
                    }
                ],
                "responses": {
                    "200": {
                        "description": "OK",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/runsResponseSchema"
                                }
                            }
                        }
                    }
                }
            }
        },
        "/acts/getdataforme~sephora-scraper/run-sync": {
            "post": {
                "operationId": "run-sync-getdataforme-sephora-scraper",
                "x-openai-isConsequential": false,
                "summary": "Executes an Actor, waits for completion, and returns the OUTPUT from Key-value store in response.",
                "tags": [
                    "Run Actor"
                ],
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/inputSchema"
                            }
                        }
                    }
                },
                "parameters": [
                    {
                        "name": "token",
                        "in": "query",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Enter your Apify token here"
                    }
                ],
                "responses": {
                    "200": {
                        "description": "OK"
                    }
                }
            }
        }
    },
    "components": {
        "schemas": {
            "inputSchema": {
                "type": "object",
                "required": [
                    "urls"
                ],
                "properties": {
                    "urls": {
                        "title": "List of URLs of the Snapklik pages",
                        "type": "array",
                        "description": "A list of URLs of the web pages you want to scrape data from.",
                        "items": {
                            "type": "string"
                        }
                    },
                    "proxyConfiguration": {
                        "title": "Proxy configuration",
                        "type": "object",
                        "description": "Specifies proxy servers that will be used by the scraper in order to hide its origin.",
                        "default": {
                            "useApifyProxy": true,
                            "apifyProxyGroups": [
                                "RESIDENTIAL"
                            ]
                        }
                    }
                }
            },
            "runsResponseSchema": {
                "type": "object",
                "properties": {
                    "data": {
                        "type": "object",
                        "properties": {
                            "id": {
                                "type": "string"
                            },
                            "actId": {
                                "type": "string"
                            },
                            "userId": {
                                "type": "string"
                            },
                            "startedAt": {
                                "type": "string",
                                "format": "date-time",
                                "example": "2025-01-08T00:00:00.000Z"
                            },
                            "finishedAt": {
                                "type": "string",
                                "format": "date-time",
                                "example": "2025-01-08T00:00:00.000Z"
                            },
                            "status": {
                                "type": "string",
                                "example": "READY"
                            },
                            "meta": {
                                "type": "object",
                                "properties": {
                                    "origin": {
                                        "type": "string",
                                        "example": "API"
                                    },
                                    "userAgent": {
                                        "type": "string"
                                    }
                                }
                            },
                            "stats": {
                                "type": "object",
                                "properties": {
                                    "inputBodyLen": {
                                        "type": "integer",
                                        "example": 2000
                                    },
                                    "rebootCount": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "restartCount": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "resurrectCount": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "computeUnits": {
                                        "type": "integer",
                                        "example": 0
                                    }
                                }
                            },
                            "options": {
                                "type": "object",
                                "properties": {
                                    "build": {
                                        "type": "string",
                                        "example": "latest"
                                    },
                                    "timeoutSecs": {
                                        "type": "integer",
                                        "example": 300
                                    },
                                    "memoryMbytes": {
                                        "type": "integer",
                                        "example": 1024
                                    },
                                    "diskMbytes": {
                                        "type": "integer",
                                        "example": 2048
                                    }
                                }
                            },
                            "buildId": {
                                "type": "string"
                            },
                            "defaultKeyValueStoreId": {
                                "type": "string"
                            },
                            "defaultDatasetId": {
                                "type": "string"
                            },
                            "defaultRequestQueueId": {
                                "type": "string"
                            },
                            "buildNumber": {
                                "type": "string",
                                "example": "1.0.0"
                            },
                            "containerUrl": {
                                "type": "string"
                            },
                            "usage": {
                                "type": "object",
                                "properties": {
                                    "ACTOR_COMPUTE_UNITS": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "DATASET_READS": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "DATASET_WRITES": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "KEY_VALUE_STORE_READS": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "KEY_VALUE_STORE_WRITES": {
                                        "type": "integer",
                                        "example": 1
                                    },
                                    "KEY_VALUE_STORE_LISTS": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "REQUEST_QUEUE_READS": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "REQUEST_QUEUE_WRITES": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "DATA_TRANSFER_INTERNAL_GBYTES": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "DATA_TRANSFER_EXTERNAL_GBYTES": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "PROXY_RESIDENTIAL_TRANSFER_GBYTES": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "PROXY_SERPS": {
                                        "type": "integer",
                                        "example": 0
                                    }
                                }
                            },
                            "usageTotalUsd": {
                                "type": "number",
                                "example": 0.00005
                            },
                            "usageUsd": {
                                "type": "object",
                                "properties": {
                                    "ACTOR_COMPUTE_UNITS": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "DATASET_READS": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "DATASET_WRITES": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "KEY_VALUE_STORE_READS": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "KEY_VALUE_STORE_WRITES": {
                                        "type": "number",
                                        "example": 0.00005
                                    },
                                    "KEY_VALUE_STORE_LISTS": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "REQUEST_QUEUE_READS": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "REQUEST_QUEUE_WRITES": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "DATA_TRANSFER_INTERNAL_GBYTES": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "DATA_TRANSFER_EXTERNAL_GBYTES": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "PROXY_RESIDENTIAL_TRANSFER_GBYTES": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "PROXY_SERPS": {
                                        "type": "integer",
                                        "example": 0
                                    }
                                }
                            }
                        }
                    }
                }
            }
        }
    }
}
```
