{
  "openapi": "3.0.1",
  "info": {
    "title": "Lenskart Scraper: Eyewear Prices, Specs & Variants",
    "description": "Download Lenskart's complete eyewear catalog: prices, discounts, frame shapes, color options, ratings, and stock levels per product. Covers India, Singapore, UAE, and US stores. Built for price tracking, competitor research, and product analysis. $4.99 per 1,000 products.",
    "version": "0.1",
    "x-build-id": "yIChs3HoyftRqgOoH"
  },
  "servers": [
    {
      "url": "https://api.apify.com/v2"
    }
  ],
  "paths": {
    "/acts/getascraper~lenskart-scraper/run-sync-get-dataset-items": {
      "post": {
        "operationId": "run-sync-get-dataset-items-getascraper-lenskart-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/getascraper~lenskart-scraper/runs": {
      "post": {
        "operationId": "runs-sync-getascraper-lenskart-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/getascraper~lenskart-scraper/run-sync": {
      "post": {
        "operationId": "run-sync-getascraper-lenskart-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",
        "properties": {
          "category": {
            "title": "Category",
            "enum": [
              "eyeglasses",
              "contact-lenses"
            ],
            "type": "string",
            "description": "Common Lenskart category to scrape. For any category not listed here, leave this empty and use Category ID instead.",
            "default": "eyeglasses"
          },
          "categoryId": {
            "title": "Category ID (advanced)",
            "minimum": 1,
            "type": "integer",
            "description": "Numeric Lenskart category id. Overrides Category. Use this to scrape any category: open a Lenskart category page, the id is in its page data (e.g. 3363 = Eyeglasses, 30531 = Contact Lenses)."
          },
          "brand": {
            "title": "Brand",
            "type": "string",
            "description": "Keep only products whose brand contains this text, e.g. Ray-Ban, John Jacobs, Vincent Chase, Oakley."
          },
          "gender": {
            "title": "Gender",
            "enum": [
              "men",
              "women",
              "kids",
              "unisex"
            ],
            "type": "string",
            "description": "Keep only products for this audience. Men and Women also include Unisex frames."
          },
          "frameShape": {
            "title": "Frame shape",
            "type": "string",
            "description": "Keep only this frame shape, e.g. Aviator, Round, Square, Wayfarer, Cat Eye. Turns on full specifications automatically."
          },
          "frameMaterial": {
            "title": "Frame material",
            "type": "string",
            "description": "Keep only this frame material, e.g. Acetate, TR90, Metal, Stainless Steel. Turns on full specifications automatically."
          },
          "frameSize": {
            "title": "Frame size",
            "enum": [
              "Extra Narrow",
              "Narrow",
              "Medium",
              "Wide",
              "Extra Wide"
            ],
            "type": "string",
            "description": "Keep only this frame size: Extra Narrow, Narrow, Medium, Wide, Extra Wide."
          },
          "minPrice": {
            "title": "Minimum price",
            "minimum": 0,
            "type": "integer",
            "description": "Keep only products with an effective price at or above this value (in the selected currency)."
          },
          "maxPrice": {
            "title": "Maximum price",
            "minimum": 0,
            "type": "integer",
            "description": "Keep only products with an effective price at or below this value."
          },
          "minRating": {
            "title": "Minimum rating",
            "minimum": 0,
            "maximum": 5,
            "type": "integer",
            "description": "Keep only products with an average rating at or above this value (0 to 5)."
          },
          "inStockOnly": {
            "title": "In stock only",
            "type": "boolean",
            "description": "Keep only products that are currently in stock.",
            "default": false
          },
          "maxItems": {
            "title": "Max products",
            "minimum": 1,
            "maximum": 50000,
            "type": "integer",
            "description": "Maximum number of products to collect. The full catalog of a category can be several thousand items.",
            "default": 500
          },
          "country": {
            "title": "Country",
            "enum": [
              "IN",
              "SG",
              "AE",
              "US"
            ],
            "type": "string",
            "description": "Storefront country (sets currency and catalog). India has the largest catalog.",
            "default": "IN"
          },
          "scrapeProductDetails": {
            "title": "Fetch full specifications",
            "type": "boolean",
            "description": "Fetch each product's detail to fill frame shape, material, rim type, lens dimensions, weight and more. On by default. Turn off for a faster, lighter run with listing fields only (price, brand, model, color, size, rating).",
            "default": true
          },
          "dedupeByModel": {
            "title": "One row per model",
            "type": "boolean",
            "description": "Collapse color variants so each model appears once. Off by default (each color variant is its own row).",
            "default": false
          },
          "proxyConfiguration": {
            "title": "Proxy configuration",
            "type": "object",
            "description": "Defaults to Apify shared datacenter proxy, which is all this actor needs. The Lenskart API sets locale by parameter, not by IP, so residential proxies are not required.",
            "default": {
              "useApifyProxy": true,
              "apifyProxyGroups": []
            }
          },
          "debugLogging": {
            "title": "Debug logging",
            "type": "boolean",
            "description": "Enable verbose debug logs.",
            "default": false
          }
        }
      },
      "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
                  }
                }
              }
            }
          }
        }
      }
    }
  }
}