{
  "openapi": "3.0.1",
  "info": {
    "title": "Sitemap Extractor: Every URL from XML Sitemaps",
    "description": "Sitemap extractor: every URL of a website from its XML sitemaps (found in robots.txt, indexes and .gz followed) with lastmod, images, videos, news and hreflang. Filter by URL pattern or date, get only new URLs, check each URL's HTTP status. Export to JSON, CSV or Excel, or via API.",
    "version": "1.0",
    "x-build-id": "mI4LCljWPj9tF0YaB"
  },
  "servers": [
    {
      "url": "https://api.apify.com/v2"
    }
  ],
  "paths": {
    "/acts/steadyscrape~sitemap-extractor/run-sync-get-dataset-items": {
      "post": {
        "operationId": "run-sync-get-dataset-items-steadyscrape-sitemap-extractor",
        "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/steadyscrape~sitemap-extractor/runs": {
      "post": {
        "operationId": "runs-sync-steadyscrape-sitemap-extractor",
        "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/steadyscrape~sitemap-extractor/run-sync": {
      "post": {
        "operationId": "run-sync-steadyscrape-sitemap-extractor",
        "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": [
          "startUrls"
        ],
        "properties": {
          "startUrls": {
            "title": "Websites, robots.txt or sitemap links",
            "minItems": 1,
            "maxItems": 5000,
            "type": "array",
            "description": "One per line: a domain (<code>example.com</code>) or any page of the site, whose sitemaps are found in its robots.txt, its home page or the usual paths (<code>/sitemap.xml</code>, <code>/sitemap_index.xml</code>, <code>/wp-sitemap.xml</code>, <code>.xml.gz</code>, <code>/sitemap.txt</code>); a robots.txt link; or a sitemap link (XML, sitemap index, .gz, RSS/Atom feed or a text list of URLs) to read just that file and the sitemaps it points to. Up to 5,000 per run.",
            "items": {
              "type": "string"
            }
          },
          "maxUrlsPerSite": {
            "title": "Most URLs per site",
            "minimum": 1,
            "maximum": 1000000,
            "type": "integer",
            "description": "Reading stops once a site gave this many URLs (after the filters below). Each URL is one row and one charged event.",
            "default": 100000
          },
          "includeUrlPatterns": {
            "title": "Keep only URLs matching",
            "type": "array",
            "description": "Keep a URL when it matches any of these. Text keeps URLs containing it (<code>/blog/</code>, <code>/products/</code>); <code>*</code> is a wildcard over the whole URL (<code>https://shop.com/products/*</code>, <code>*.pdf</code>); <code>re:</code> starts a regular expression (<code>re:/p/\\d+$</code>). Case is ignored. Leave empty to keep every URL.",
            "items": {
              "type": "string"
            }
          },
          "excludeUrlPatterns": {
            "title": "Leave out URLs matching",
            "type": "array",
            "description": "Leave a URL out when it matches any of these, written the same way as above (<code>/tag/</code>, <code>*?page=*</code>). An excluded URL is never charged.",
            "items": {
              "type": "string"
            }
          },
          "lastmodWithinDays": {
            "title": "Modified within the last N days",
            "minimum": 1,
            "maximum": 3650,
            "type": "integer",
            "description": "Keep only URLs whose sitemap <code>lastmod</code> date falls within this many days before the run, in whole days (7 keeps everything changed since midnight UTC seven days ago, so a date written without a time that day counts). URLs whose sitemap gives no lastmod are left out when this is set, and counted in the status message. Leave empty for every date."
          },
          "onlyNewUrls": {
            "title": "Only URLs not delivered before",
            "type": "boolean",
            "description": "Remember every URL delivered for each site (and these URL patterns) in your own key-value store <code>steadyscrape-sitemap-extractor-state</code>, and on later runs deliver only URLs not seen before: a competitor's new pages, products or articles. The first run delivers (and charges) everything; schedule the next ones.",
            "default": false
          },
          "checkStatus": {
            "title": "Check each URL's HTTP status",
            "type": "boolean",
            "description": "Ask every URL (a HEAD request, GET when the server refuses HEAD) and add its status code, the final URL after redirects, the final status code and the content type: broken links, redirects and removed pages in a sitemap. robots.txt is honoured for each page. Charged as url-with-status instead of url.",
            "default": false
          },
          "statusChecksPerSecond": {
            "title": "Status checks per second, per site",
            "minimum": 1,
            "maximum": 20,
            "type": "integer",
            "description": "The pace of the status check on each site's host, so no site is hammered (1 to 20). 5 checks 10,000 URLs in about 35 minutes.",
            "default": 5
          },
          "maxSitemapsPerSite": {
            "title": "Most sitemap files per site",
            "minimum": 1,
            "maximum": 10000,
            "type": "integer",
            "description": "Sitemap files read per site, indexes and probes of the usual paths included (1 to 10,000).",
            "default": 1000
          },
          "maxSitemapDepth": {
            "title": "Most nested sitemap index levels",
            "minimum": 0,
            "maximum": 10,
            "type": "integer",
            "description": "How deep sitemap indexes that point to other indexes are followed (0 reads only the files given or found, without following their indexes).",
            "default": 5
          }
        }
      },
      "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
                  }
                }
              }
            }
          }
        }
      }
    }
  }
}