{
  "openapi": "3.0.1",
  "info": {
    "title": "Macy's Scraper",
    "description": "Scrape Macy's product catalog and Macy's Inc. news in one actor. Extract prices, variants, SKUs/UPCs, color & size options, images, ratings and reviews from search, category, trending and product URLs. Fast, clean, normalized JSON.",
    "version": "0.1",
    "x-build-id": "Yg8H8MwPliGi4rw5S"
  },
  "servers": [
    {
      "url": "https://api.apify.com/v2"
    }
  ],
  "paths": {
    "/acts/autofacts~macy-s-scraper/run-sync-get-dataset-items": {
      "post": {
        "operationId": "run-sync-get-dataset-items-autofacts-macy-s-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/autofacts~macy-s-scraper/runs": {
      "post": {
        "operationId": "runs-sync-autofacts-macy-s-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/autofacts~macy-s-scraper/run-sync": {
      "post": {
        "operationId": "run-sync-autofacts-macy-s-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": {
          "startUrls": {
            "title": "Start URLs",
            "type": "array",
            "description": "Paste any Macy's link — each one is recognized automatically:<br>• a <b>product</b> page: <code>macys.com/shop/product/…?ID=…</code><br>• a <b>category</b> page with its <code>?id=</code>: <code>macys.com/shop/…?id=…</code><br>• a <b>featured</b> or <b>trending</b> page: <code>macys.com/shop/featured/…</code><br>• a Macy's Inc. <b>news</b> article, or the newsroom page or press-release feed for the latest news: <code>https://www.macysinc.com/rss/pressrelease.aspx</code><br><br>Mix any of them in one run, alongside a search query.",
            "items": {
              "type": "object",
              "required": [
                "url"
              ],
              "properties": {
                "url": {
                  "type": "string",
                  "title": "URL of a web page",
                  "format": "uri"
                }
              }
            }
          },
          "query": {
            "title": "Search query",
            "type": "string",
            "description": "A keyword to search Macy's for, as you would type it on macys.com — e.g. <code>women shoes</code>. Runs alongside any Start URLs."
          },
          "scrapeType": {
            "title": "Scrape type (legacy)",
            "pattern": "^(search|category|trending|news|all)$",
            "type": "string",
            "description": "Legacy, not shown in the form: kept so tasks and API calls from before the form was simplified behave as they did. Leave it unset, and every Start URL and the Search query are used together. When set, Start URLs are still always used, but only the input matching the type is added — <code>search</code>: Search query; <code>category</code>: Category IDs; <code>trending</code>: Trending URLs, or Macy's trending page when there are none; <code>news</code>: News URLs, or the Macy's Inc. press-release feed when there are none; <code>all</code>: all of them."
          },
          "categoryIds": {
            "title": "Macy's category IDs (legacy)",
            "type": "array",
            "description": "Legacy, not shown in the form. Macy's category IDs such as <code>5449</code> — put the category's URL in Start URLs instead, e.g. <code>https://www.macys.com/shop/womens-clothing/womens-dresses?id=5449</code>.",
            "items": {
              "type": "string"
            }
          },
          "maxResults": {
            "title": "Max result records",
            "minimum": 0,
            "type": "integer",
            "description": "The maximum number of records — products and news articles — saved to the dataset. Each record is one billed result, so this is also the run's cost cap. The scraper stops as soon as it has that many. <br><br>If set to <code>0</code>, there is no limit — use the run's <b>Max total charge</b> setting to bound spend instead.",
            "default": 20
          },
          "maxPages": {
            "title": "Max listing pages per source",
            "minimum": 0,
            "maximum": 500,
            "type": "integer",
            "description": "Advanced, not shown in the form: how many listing pages to read for each start URL or search. <code>0</code> (the default) means no page limit — Max result records decides when to stop. Pass a number in the JSON input to spread a run across many sources, e.g. <code>1</code> to take only the first page of each.",
            "default": 0
          },
          "maxRequestsPerCrawl": {
            "title": "Max requests per crawl",
            "minimum": 0,
            "type": "integer",
            "description": "Advanced, not shown in the form: a hard cap on HTTP requests, as a safety net. <code>0</code> (the default) means no cap — Max result records already bounds the run.",
            "default": 0
          },
          "minResults": {
            "title": "Minimum output records",
            "minimum": 0,
            "type": "integer",
            "description": "Advanced, not shown in the form: fail the run when it produces fewer records than this. Useful for smoke tests.",
            "default": 0
          },
          "includeProductDetails": {
            "title": "Full product details (variants, SKUs, descriptions)",
            "type": "boolean",
            "description": "Read each product's own page for its description, every color and size with its UPC barcode, the full image gallery, and the complete ratings & reviews breakdown. Costs one extra request per product, and is not billed separately. Turn it off for faster listing-level records: name, brand, price, main image and rating.",
            "default": true
          },
          "proxy": {
            "title": "Proxy configuration",
            "type": "object",
            "description": "Every request goes through a proxy, so it can't be switched off. Apify residential proxies in the US (the default) work best; datacenter IPs are blocked more often."
          },
          "maxConcurrency": {
            "title": "Max concurrency",
            "minimum": 1,
            "maximum": 50,
            "type": "integer",
            "description": "Advanced, not shown in the form: how many requests run at once. The default of 3 suits Macy's rate limits — higher values mostly add blocks, not speed.",
            "default": 3
          },
          "debugSaveHtml": {
            "title": "Save debug snapshots",
            "type": "boolean",
            "description": "For development only, not shown in the form: saves every fetched response to the default key-value store.",
            "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
                  },
                  "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
                  }
                }
              }
            }
          }
        }
      }
    }
  }
}