# SmartBuyGlasses (`maximedupre/smartbuyglasses`) Actor

Collect public SmartBuyGlasses product data, including prices, stock status, brands, frame and lens details, and product page links. Choose a store and a way to find products: a catalogue, brand or category pages, product pages, or keywords. Each product is saved as one dataset row.

- **URL**: https://apify.com/maximedupre/smartbuyglasses.md
- **Developed by:** [Maxime Dupré](https://apify.com/maximedupre) (community)
- **Categories:** E-commerce, Business, Marketing
- **Stats:** 2 total users, 1 monthly users, 100.0% runs succeeded, 0 bookmarks
- **User rating**: No ratings yet

## Pricing

from $0.80 / 1,000 products

This Actor is paid per event. You are not charged for the Apify platform usage, but only a fixed price for specific events.
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

### 👓 Collect SmartBuyGlasses prices, stock, and frame details

This Actor is for eyewear sellers, price researchers, and catalogue teams who need SmartBuyGlasses product data in one place. It covers sunglasses, prescription eyeglasses, and contact lenses. It reads public product pages and saves one dataset row for each product. You get a structured list to compare, without copying each product page by hand.

Use it to:

- Compare the current prices of designer frames with **[Designer Glasses Online](https://apify.com/maximedupre/smartbuyglasses/examples/designer-glasses-online)**.
- Build a price list of prescription glasses from a UK store with **[Best Online Prescription Glasses UK](https://apify.com/maximedupre/smartbuyglasses/examples/best-online-prescription-glasses-uk)**.
- Gather a UK glasses catalogue with prices and stock status using **[UK Glasses Online](https://apify.com/maximedupre/smartbuyglasses/examples/uk-glasses-online)**.
- Pull contact lens products with prices and stock status using **[Contact Lenses Online](https://apify.com/maximedupre/smartbuyglasses/examples/contact-lenses-online)**.
- Find polarized sunglasses and read their lens details with **[Polarized Sunglasses](https://apify.com/maximedupre/smartbuyglasses/examples/polarized-sunglasses)**.
- Collect kids' glasses and any sizes the store lists with **[Kids Glasses](https://apify.com/maximedupre/smartbuyglasses/examples/kids-glasses)**.
- Check pilot sunglasses and their frame measurements with **[Pilot Sunglasses](https://apify.com/maximedupre/smartbuyglasses/examples/pilot-sunglasses)**.

#### 📦 What each product row includes

Each row is one product from the store you choose. Every row has a product name and a product page link. Other fields depend on what the store shows for that product, such as the brand, price, stock status, frame and lens details, measurements, ratings, and barcodes. Fields the store does not show are left out of the row.

#### ▶️ Run a product search

1. Choose how to find products in **Find products by**.
2. Pick a store address in **Regional storefront URL**. Prices use that store's currency.
3. Fill in only the section that matches your choice. The other sections are ignored.
4. Add filters if you need them. Leave **Maximum products** empty to collect all available results until the source is exhausted, or enter a number to stop early.
5. Start the run, then open the dataset when it finishes.

For a quick test, keep the default input. It collects three products from a Ray-Ban brand page.

#### ⚙️ Input

Choose one way to find products, then fill in its matching section. The store, catalogue, and filters apply to every choice.

**Input fields**

| Field | Type | What it does |
|---|---|---|
| **Find products by** (`findProductsBy`) | string | Pick how to find products: **Brand or category pages**, **Product or search pages**, **Keywords or brand names**, or **Catalogue**. |
| **Brand or category page URLs** (`brandOrCategoryPageUrls`) | array of objects | Public brand or category page links to read. |
| **Product or search page URLs** (`productOrSearchPageUrls`) | array of objects | Public product page links or search-results page links to read. A single product link returns that product. |
| **Keywords or brand names** (`searchTerms`) | array of strings | Keywords or brand names to search for in the store. |
| **Regional storefront URL** (`regionalStorefront`) | string | The full HTTPS address of the SmartBuyGlasses store to read, such as `https://www.smartbuyglasses.com/`. Page links must use the same store. Prices use its currency. |
| **Catalogue** (`catalogue`) | string | Choose all catalogues, or only sunglasses, prescription eyeglasses, or contact lenses. |
| **Minimum price** (`minimumPrice`) | number | Keep products at or above this listed price, in the store's currency. Leave blank for no lower limit. |
| **Maximum price** (`maximumPrice`) | number | Keep products at or below this listed price, in the store's currency. Leave blank for no upper limit. |
| **Available only** (`availableOnly`) | boolean | Keep only products the store marks as available. Turn it off to include all products, including sold-out ones. |
| **Frame shape** (`frameShape`) | string | Filter sunglasses and prescription eyeglasses by frame shape, such as `Square`. Type other shapes exactly as the store writes them. |
| **Lens type** (`lensType`) | string | Filter sunglasses and prescription eyeglasses by lens type, such as `Polarized`. Type the name exactly as the store writes it. |
| **Intended wearer** (`intendedWearer`) | string | Filter sunglasses and prescription eyeglasses for `Men`, `Women`, or `Kids`. |
| **Frame color** (`frameColor`) | string | Filter sunglasses and prescription eyeglasses by frame color, such as `Black`. Type other colors using the store's color label. |
| **Frame material** (`frameMaterial`) | string | Filter sunglasses and prescription eyeglasses by frame material, such as `Acetate`. Type other materials using the store's material label. |
| **Rim style** (`frameType`) | string | Filter sunglasses and prescription eyeglasses by rim style, such as Full Rim or Rimless. |
| **Deal sections** (`dealSections`) | array of strings | Add `cheap-glasses`, `clearance`, or `outlet` to limit results to those sections. Leave empty for all sections. It does not change a single product link. |
| **Order results by** (`sortOrder`) | string | Choose price low to high, price high to low, most popular, largest discount, newest first, or product name A to Z. Leave blank to keep the store order. |
| **Maximum products** (`maxItems`) | integer | Stop after this many products. Leave blank to collect all available results until the source is exhausted, meaning the store has no more matching products. |

**Example input**

```json
{
  "findProductsBy": "brand-category-pages",
  "brandOrCategoryPageUrls": [
    {
      "url": "https://www.smartbuyglasses.com/designer-sunglasses/ray-ban/"
    }
  ],
  "regionalStorefront": "https://www.smartbuyglasses.com/",
  "catalogue": "all",
  "maxItems": 3
}
```

This is the default input from a successful test run. It collects three products.

#### 🧾 Output

Each run saves one dataset row for each product. Sunglasses and prescription eyeglasses rows can include frame and lens details. Contact lens rows use a shorter set of fields.

**Sunglasses and prescription eyeglasses rows**

| Field | Type | What it does |
|---|---|---|
| `name` | string | Product name shown by the store. |
| `url` | string | Public product page link. |
| `brand` | string | Brand name shown by the store. |
| `model` | string | Model name shown by the store. |
| `variant` | string | Variant shown by the store, such as a color. |
| `productId` | string | Product ID given by the store. |
| `sku` | string | Product SKU given by the store. |
| `imageUrls` | array of strings | Links to product images shown by the store. |
| `description` | string | Product description shown by the store. |
| `currentPrice` | number | Current price shown by the store, in the currency in `currency`. |
| `referencePrice` | number | Reference price shown by the store, when there is one. |
| `currency` | string | Currency used for the listed prices. |
| `availability` | string | Availability status shown by the store, such as `https://schema.org/InStock`. |
| `remainingStock` | integer | Remaining stock count shown by the store, when it is shown. |
| `frame` | object | Frame details shown by the store, when available. Its fields are listed below. |
| `frame.shape` | string | Frame shape, such as Wayfarer. |
| `frame.color` | string | Frame color. |
| `frame.style` | string | Frame style, such as Full Rim. |
| `frame.type` | string | Frame type shown by the store. |
| `frame.materials` | array of strings | Frame materials listed by the store. |
| `frame.sizes` | array of strings | Frame sizes listed by the store, such as M or L. |
| `frame.fitFeatures` | array of strings | Frame fit features listed by the store. |
| `frame.measurements` | array of objects | Frame measurements listed by the store. Each item has `name`, `value`, and `unit`. |
| `frame.measurements[].name` | string | Measurement name, such as `bridgeWidth`. |
| `frame.measurements[].value` | number | Measurement value. |
| `frame.measurements[].unit` | string | Unit for the measurement, such as `mm`. |
| `frame.faceShapes` | array of strings | Face shapes the store recommends the frame for. |
| `lens` | object | Lens details shown by the store, when available. Its fields are listed below. |
| `lens.type` | string | Lens type shown by the store. |
| `lens.color` | string | Lens color shown by the store. |
| `lens.materials` | array of strings | Lens materials listed by the store. |
| `lens.attributes` | array of strings | Lens attributes listed by the store. |
| `lens.prescriptionCompatibility` | array of strings | Prescription details the store lists for the lens. |
| `lens.lensCompatibility` | array of strings | Lens compatibility details listed by the store, such as Progressive or Reading. |
| `lens.progressiveEligible` | boolean | Whether the store marks the product as eligible for progressive lenses. |
| `lens.pupillaryDistance` | string | Pupillary distance range shown by the store. |
| `lens.uvProtection` | string | UV protection detail shown by the store. |
| `rating` | number | Star rating shown by the store. |
| `reviewCount` | integer | Number of reviews shown by the store. |
| `category` | string | Product category shown by the store, such as Sunglasses. |
| `barcodes` | array of strings | UPC or GTIN codes listed for the product. |
| `manufacturer` | string | Manufacturer information listed for the product. |
| `collection` | string | Collection name listed for the product. |
| `releaseYear` | integer | Model release year listed by the store. |
| `intendedWearers` | array of strings | Who the store lists the product for, such as Women, Unisex, or Kids. |
| `features` | array of strings | Product features listed by the store. |
| `badges` | array of strings | Labels the store uses to promote the product, such as Virtual Try-On. |

**Example sunglasses row**

This row is from the default-input test run. Its `description` is shortened here.

```json
{
  "name": "Ray-Ban RB2132 New Wayfarer 901",
  "url": "https://www.smartbuyglasses.com/designer-sunglasses/Ray-Ban/Ray-Ban-RB2132-New-Wayfarer-901-8028.html",
  "brand": "Ray-Ban",
  "model": "Ray-Ban RB2132 New Wayfarer",
  "variant": "Black",
  "productId": "8028",
  "sku": "SUN-8028-52",
  "imageUrls": [
    "https://www.smartbuyglasses.com/image4/1/14/8028_1679652642962.jpg",
    "https://www.smartbuyglasses.com/image4/1/14/8028_1679652642962.jpg?width=900&height=450&q=90",
    "https://www.smartbuyglasses.com/image4/1/14/8028_side_1_1681977873132.jpg?width=1200&height=600",
    "https://www.smartbuyglasses.com/image4/1/14/8028_side_2_1681977873133.jpg?width=78&height=39&q=90"
  ],
  "description": "...",
  "currentPrice": 178,
  "currency": "USD",
  "availability": "https://schema.org/InStock",
  "remainingStock": 6,
  "frame": {
    "shape": "Wayfarer",
    "color": "Black",
    "style": "Full Rim",
    "type": "Full Rim",
    "materials": [
      "Nylon"
    ],
    "sizes": [
      "M",
      "L"
    ],
    "measurements": [
      {
        "name": "frameWidth",
        "value": 137,
        "unit": "mm"
      },
      {
        "name": "lensDepth",
        "value": 35,
        "unit": "mm"
      },
      {
        "name": "lensWidth",
        "value": 52,
        "unit": "mm"
      },
      {
        "name": "bridgeWidth",
        "value": 18,
        "unit": "mm"
      },
      {
        "name": "armLength",
        "value": 145,
        "unit": "mm"
      }
    ],
    "faceShapes": [
      "Heart",
      "Oval",
      "Triangle"
    ]
  },
  "lens": {
    "type": "Multifocal/Progressive",
    "color": "Green",
    "materials": [
      "Crystal"
    ],
    "prescriptionCompatibility": [
      "SPH: -8.00 to +7.00 CYL: -4.00 to +4.00"
    ],
    "lensCompatibility": [
      "Progressive",
      "Reading",
      "Distance",
      "Fashion",
      "Computer"
    ],
    "progressiveEligible": true,
    "pupillaryDistance": "58.00 to 82.00 mm",
    "uvProtection": "Category 3"
  },
  "rating": 5,
  "reviewCount": 89,
  "category": "Sunglasses",
  "barcodes": [
    "805289048527"
  ],
  "manufacturer": "Luxottica Italia srl",
  "collection": "Wayfarer",
  "releaseYear": 2007,
  "intendedWearers": [
    "Unisex"
  ],
  "features": [
    "Prescription",
    "Top 100"
  ],
  "badges": [
    "Virtual Try-On"
  ]
}
```

**Contact lens rows**

Contact lens rows do not include frame or lens details.

| Field | Type | What it does |
|---|---|---|
| `name` | string | Product name shown by the store. |
| `url` | string | Public product page link. |
| `brand` | string | Brand name shown by the store. |
| `model` | string | Model name shown by the store. |
| `productId` | string | Product ID given by the store. |
| `imageUrls` | array of strings | Links to product images shown by the store. |
| `description` | string | Product description shown by the store. |
| `currentPrice` | number | Current price shown by the store. |
| `currency` | string | Currency used for the listed price. |
| `availability` | string | Availability status shown by the store, such as `https://schema.org/InStock`. |
| `rating` | number | Star rating shown by the store. |
| `reviewCount` | integer | Number of reviews shown by the store. |
| `category` | string | Product category shown by the store, such as Contact Lens. |
| `manufacturer` | string | Manufacturer information listed for the product. |

**Example contact lens row**

This row is from a contact lens test run on a French store. Its `description` is shortened here.

```json
{
  "name": "1-Day Acuvue Moist 30 Pack 30 Lentilles par boîte | Journalières | Sphériques",
  "url": "https://www.easylunettes.fr/lentilles-de-contact/daily-disposable-lenses/1-Day-Acuvue-Moist-30-Pack/442.html",
  "brand": "Acuvue",
  "model": "1-Day Acuvue Moist 30 Pack",
  "productId": "442",
  "imageUrls": [
    "https://www.easylunettes.fr/image4/3/235/442_1689758659558.jpg",
    "https://www.easylunettes.fr/image4/3/235/442_1689758659558.jpg?width=900&q=90"
  ],
  "description": "...",
  "currentPrice": 31.45,
  "currency": "EUR",
  "availability": "https://schema.org/InStock",
  "rating": 5,
  "reviewCount": 3,
  "category": "Contact Lens"
}
```

#### 💳 Pricing

This Actor uses pay-per-event pricing. You pay for each product result saved to your dataset. Runs that save no products have no product results to pay for. Check the Pricing tab on this Actor's Store page for the current rates.

#### 🔌 Integrations

Results are saved to an Apify dataset. You can open the dataset in Apify, export it, or read it through the Apify API.

Watch this video for more on Apify integrations:

https://www.youtube.com/watch?v=bNACk1_S_6w\&list=PLObrtcm1Kw6MUrlLNDbK9QRg8VDJg0gOW\&index=4

#### ❓ FAQ

##### Why does a filter return nothing?

Some filters need the store's exact label: frame shape, lens type, frame color, and frame material. Type the label the way the chosen store writes it. For frame shape, frame color, and frame material, you can also pick a suggested value.

##### Why did my run save no products?

Check the section that matches your **Find products by** choice. The other sections are ignored. Also check that the store address, catalogue, and filters match the products you want. A narrow filter can leave no matches.

##### Why is a field missing from a row?

The store decides what it shows. Fields the store does not show are left out of the row. For example, a product may have no remaining stock count, and contact lens rows do not include frame details.

##### Can I use a product page link?

Yes. Choose **Product or search pages** in **Find products by**, then add the link under **Product or search page URLs**. A single product link returns that product.

##### Can I search by keyword?

Yes. Choose **Keywords or brand names**, then add one or more keywords or brand names. The Actor searches the store address you choose.

##### Does it convert prices to my currency?

No. Prices stay in the currency of the store you pick. The Actor does not convert currencies.

##### Is there a limit on how many products it collects?

No fixed maximum is set. Leave **Maximum products** empty to collect all available results until the source is exhausted. Enter a number to stop after that many products.

##### Does it track price changes or send alerts?

No. The Actor does not keep history, compare runs, or send price-change alerts. Each run saves its own rows, so you can compare runs yourself.

##### Does it need a SmartBuyGlasses login?

No. It reads public product pages. It does not sign in or use a customer account.

##### Are prices and stock up to date?

Each run reads the store pages when it runs. The rows show what the store showed at that time. Run the Actor again to get newer values.

##### Are the reviews real?

The Actor saves the star rating and review count that the store shows for each product. It does not check whether those reviews are real.

##### Does it find promo codes or return policies?

No. It does not look up promo codes or the store's return policy.

##### Can this Actor tell me if SmartBuyGlasses is legit?

No. It saves product data from public product pages. It does not judge whether the store is trustworthy.

##### Is this the official SmartBuyGlasses website?

No. This Actor is not the store's website. It reads public pages from the store address you enter, and it does not place orders or change anything on the store.

### 📝 Changelog

**v0.0** (16-10-2026)

- Initial release.

### 🆘 Support

For issues, questions, or feature requests, [file a ticket](https://console.apify.com/actors/maximedupre~smartbuyglasses/issues) and I'll fix or implement it in less than 24h 🫡

### 🔗 Related Actors

- [Google Shopping Scraper - Prices & Offers](https://apify.com/maximedupre/google-shopping-offers-scraper): Match a SmartBuyGlasses product by its UPC or GTIN code and compare its offers from other merchants.
- [SmartBuyGlasses \[$1💰\] Eyewear Prices, Brands & Stock](https://apify.com/memo23/smartbuyglasses-scraper): Compare another SmartBuyGlasses scraper's fields and prices with this Actor's rows.
- [SmartBuyGlasses Scraper](https://apify.com/solidcode/smartbuyglasses-scraper): Compare the rows from a second SmartBuyGlasses scraper with this Actor's rows for the same brand page.
- [Lenskart Scraper: Eyewear Prices, Specs & Variants](https://apify.com/getascraper/lenskart-scraper): Compare eyewear prices, frame specs, and color variants from another eyewear retailer.
- [Edel Optics Scraper: Eyewear Prices, Stock Levels & Frame Specs](https://apify.com/getascraper/edel-optics-scraper): Compare frame prices, stock levels, and EAN or GTIN codes from another eyewear store.

**Made with ❤️ by Maxime Dupré**

# Actor input Schema

## `findProductsBy` (type: `string`):

Choose how to find products. For Catalogue, choose a store and catalogue below. For other choices, fill in the matching section; other sections are ignored.

## `brandOrCategoryPageUrls` (type: `array`):

Add public URLs for the brand or category pages to read.

## `productOrSearchPageUrls` (type: `array`):

Add public URLs for individual product pages or search-results pages.

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

Add one or more keywords or brand names to search for.

## `regionalStorefront` (type: `string`):

Enter the full HTTPS address of the SmartBuyGlasses country store you want, such as https://www.smartbuyglasses.com/ or https://visiondirect.com.au/. Page URLs must use this same store. Prices use its currency.

## `catalogue` (type: `string`):

Choose one catalogue or all catalogues sold by this storefront.

## `minimumPrice` (type: `number`):

Leave blank for no lower price limit. Otherwise, keep products at or above this listed price, in the selected storefront's currency.

## `maximumPrice` (type: `number`):

Leave blank for no upper price limit. Otherwise, keep products at or below this listed price, in the selected storefront's currency.

## `availableOnly` (type: `boolean`):

Turn this on to keep only products the storefront marks as available. Leave it off to include all products, including sold-out ones.

## `frameShape` (type: `string`):

Leave blank for any shape. Otherwise, filter sunglasses and prescription eyeglasses by frame shape. Pick a suggested shape, or type another shape exactly as the store writes it. This does not filter contact lenses.

## `lensType` (type: `string`):

Leave blank for any lens type. Otherwise, filter sunglasses and prescription eyeglasses by lens type, such as Single Vision, Polarized, or Blue Light Glasses. Type the name exactly as the chosen store writes it. This does not filter contact lenses.

## `intendedWearer` (type: `string`):

Leave blank for any wearer. Otherwise, pick Men, Women, or Kids to filter sunglasses and prescription eyeglasses for that wearer. Kids is the store's label for children. This does not filter contact lenses.

## `frameColor` (type: `string`):

Leave blank for any color. Otherwise, filter sunglasses and prescription eyeglasses by frame color. Pick a suggested color, or type another color using the label the store's color filter uses. This does not filter contact lenses.

## `frameMaterial` (type: `string`):

Leave blank for any material. Otherwise, filter sunglasses and prescription eyeglasses by frame material. Pick a suggested material, or type another material using the label the store's material filter uses. This does not filter contact lenses.

## `frameType` (type: `string`):

Leave blank for any rim style. Otherwise, filter sunglasses and prescription eyeglasses by rim style, such as full rim or rimless. This does not filter contact lenses.

## `dealSections` (type: `array`):

Leave blank for all sections. Otherwise, add cheap-glasses, clearance, or outlet sections. This applies to Catalogue, Brand or category pages, search-result pages under Product or search pages, and Keywords or brand names. It does not change a single product URL.

## `sortOrder` (type: `string`):

Leave blank to keep the store order. Choose the order for Catalogue, Brand or category pages, search-result pages under Product or search pages, and Keywords or brand names. A single product URL still returns that product.

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

Stop after this many products. Leave blank to collect all available products for your chosen inputs and filters until the source is exhausted, meaning the store has no more matching products.

## Actor input object example

```json
{
  "findProductsBy": "brand-category-pages",
  "brandOrCategoryPageUrls": [
    {
      "url": "https://www.smartbuyglasses.com/designer-sunglasses/ray-ban/"
    }
  ],
  "regionalStorefront": "https://www.smartbuyglasses.com/",
  "catalogue": "all",
  "maxItems": 3
}
```

# Actor output Schema

## `products` (type: `string`):

Open the product rows from this run.

# 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 = {
    "findProductsBy": "brand-category-pages",
    "brandOrCategoryPageUrls": [
        {
            "url": "https://www.smartbuyglasses.com/designer-sunglasses/ray-ban/"
        }
    ],
    "regionalStorefront": "https://www.smartbuyglasses.com/",
    "catalogue": "all",
    "maxItems": 3
};

// Run the Actor and wait for it to finish
const run = await client.actor("maximedupre/smartbuyglasses").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 = {
    "findProductsBy": "brand-category-pages",
    "brandOrCategoryPageUrls": [{ "url": "https://www.smartbuyglasses.com/designer-sunglasses/ray-ban/" }],
    "regionalStorefront": "https://www.smartbuyglasses.com/",
    "catalogue": "all",
    "maxItems": 3,
}

# Run the Actor and wait for it to finish
run = client.actor("maximedupre/smartbuyglasses").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 '{
  "findProductsBy": "brand-category-pages",
  "brandOrCategoryPageUrls": [
    {
      "url": "https://www.smartbuyglasses.com/designer-sunglasses/ray-ban/"
    }
  ],
  "regionalStorefront": "https://www.smartbuyglasses.com/",
  "catalogue": "all",
  "maxItems": 3
}' |
apify call maximedupre/smartbuyglasses --silent --output-dataset

```

## MCP server setup

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

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/1bGQw2EmLLECavGHu/builds/rK7HnHAzd8CadoaEb/openapi.json
