{
  "openapi": "3.0.1",
  "info": {
    "title": "Scraper/Crawler for grocery marketplace data",
    "description": "This Actor is an independent tool and is not affiliated with, endorsed by, or sponsored by Instacart or any of its subsidiaries. All trademarks mentioned are the property of their respective owners. Scrape grocery shops, products, collections, hubs, ETA and search in US/CA. Export Excel/CSV/JSON.",
    "version": "0.1",
    "x-build-id": "bmGw0tFAWNlFmyZ7S"
  },
  "servers": [
    {
      "url": "https://api.apify.com/v2"
    }
  ],
  "paths": {
    "/acts/lentic_clockss~instacart-scraper/run-sync-get-dataset-items": {
      "post": {
        "operationId": "run-sync-get-dataset-items-lentic_clockss-instacart-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/lentic_clockss~instacart-scraper/runs": {
      "post": {
        "operationId": "runs-sync-lentic_clockss-instacart-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/lentic_clockss~instacart-scraper/run-sync": {
      "post": {
        "operationId": "run-sync-lentic_clockss-instacart-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": {
          "mode": {
            "title": "Mode",
            "enum": [
              "nearMe",
              "discoverRetailers",
              "storefront",
              "collection",
              "discoverCollections",
              "product",
              "enrich",
              "search",
              "hub",
              "category",
              "eta",
              "startUrls"
            ],
            "type": "string",
            "description": "nearMe | discoverRetailers | storefront | collection | discoverCollections | product | enrich | search | hub | category | eta | startUrls",
            "default": "nearMe"
          },
          "country": {
            "title": "Country",
            "enum": [
              "us",
              "ca"
            ],
            "type": "string",
            "description": "Instacart market us (.com) or ca (.ca)",
            "default": "us"
          },
          "locale": {
            "title": "Locale (alias of country)",
            "enum": [
              "us",
              "ca"
            ],
            "type": "string",
            "description": "Alias of country (us or ca)",
            "default": "us"
          },
          "language": {
            "title": "Language",
            "type": "string",
            "description": "Optional UI language (fr / fr-CA for Quebec)"
          },
          "city": {
            "title": "City preset",
            "type": "string",
            "description": "sf, nyc, la, chicago, seattle, austin, miami, denver, toronto, vancouver, montreal, calgary, ottawa"
          },
          "postalCode": {
            "title": "Postal / ZIP",
            "type": "string",
            "description": "Delivery postal code (defaults by country / city if empty)"
          },
          "latitude": {
            "title": "Latitude",
            "type": "number",
            "description": "Optional map latitude"
          },
          "longitude": {
            "title": "Longitude",
            "type": "number",
            "description": "Optional map longitude"
          },
          "retailerSlug": {
            "title": "Retailer slug",
            "type": "string",
            "description": "e.g. costco, sprouts, walmart"
          },
          "collectionSlug": {
            "title": "Collection slug",
            "type": "string",
            "description": "e.g. produce — any DiscoverNav / collections slug"
          },
          "hubSlug": {
            "title": "Hub slug",
            "type": "string",
            "description": "Required for mode=hub — deals_tab, alcohol, convenience, pharmacy, pet, baby"
          },
          "categoryId": {
            "title": "SEO category ID",
            "type": "string",
            "description": "Required for mode=category — numeric id in /categories/{id}-{slug}"
          },
          "categorySlug": {
            "title": "SEO category slug",
            "type": "string",
            "description": "Optional slug segment for SEO category URL"
          },
          "productId": {
            "title": "Product ID",
            "type": "string",
            "description": "Numeric Instacart productId for mode=product / enrich"
          },
          "productUrl": {
            "title": "Product URL",
            "type": "string",
            "description": "Full /products/{id}-{slug} URL"
          },
          "productIds": {
            "title": "Product IDs (batch enrich)",
            "type": "array",
            "description": "Batch productIds for mode=enrich",
            "items": {
              "type": "string"
            }
          },
          "shopId": {
            "title": "Shop ID",
            "type": "string",
            "description": "Optional; resolved from storefront when omitted"
          },
          "zoneId": {
            "title": "Zone ID",
            "type": "string",
            "description": "Optional delivery zoneId"
          },
          "query": {
            "title": "Search query",
            "type": "string",
            "description": "Required for mode=search"
          },
          "startUrls": {
            "title": "Start URLs",
            "type": "array",
            "description": "Instacart storefront / collection / hub / category / product / search URLs",
            "items": {
              "type": "string"
            }
          },
          "enrichDetails": {
            "title": "Enrich product details",
            "type": "boolean",
            "description": "After listing modes, open PDP for up to enrichLimit products",
            "default": true
          },
          "enrichLimit": {
            "title": "Enrich limit",
            "minimum": 0,
            "maximum": 50,
            "type": "integer",
            "description": "Max products to open for PDP enrichment (0–50)",
            "default": 10
          },
          "includeEta": {
            "title": "Include ETA",
            "type": "boolean",
            "description": "Attach GetAccurateRetailerEtas when available",
            "default": false
          },
          "maxPages": {
            "title": "Max collection pages",
            "minimum": 1,
            "maximum": 50,
            "type": "integer",
            "description": "CollectionProducts pagination budget",
            "default": 10
          },
          "maxResults": {
            "title": "Max results",
            "minimum": 1,
            "maximum": 500,
            "type": "integer",
            "description": "1–500 (free plan capped at 200)",
            "default": 1
          },
          "proxyCountry": {
            "title": "Proxy country",
            "type": "string",
            "description": "Usually US or CA; worker-owned proxy by default"
          },
          "workerBaseUrl": {
            "title": "Worker base URL override",
            "type": "string",
            "description": "Optional HTTPS Cloud Run override (allowlisted hosts only)"
          }
        }
      },
      "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
                  },
                  "PROXY_UNBLOCKER_UNITS": {
                    "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
                  },
                  "PROXY_UNBLOCKER_UNITS": {
                    "type": "integer",
                    "example": 0
                  }
                }
              }
            }
          }
        }
      }
    }
  }
}