{
  "openapi": "3.0.1",
  "info": {
    "title": "Sitemap Scraper",
    "description": "Extract all URLs from any website's sitemap.xml with robots.txt discovery, gzip support, full metadata, and automatic retries",
    "version": "0.1",
    "x-build-id": "hLU11AK4W10JAgxvh"
  },
  "servers": [
    {
      "url": "https://api.apify.com/v2"
    }
  ],
  "paths": {
    "/acts/clintsa~sitemap-scraper/run-sync-get-dataset-items": {
      "post": {
        "operationId": "run-sync-get-dataset-items-clintsa-sitemap-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/clintsa~sitemap-scraper/runs": {
      "post": {
        "operationId": "runs-sync-clintsa-sitemap-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/clintsa~sitemap-scraper/run-sync": {
      "post": {
        "operationId": "run-sync-clintsa-sitemap-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",
        "required": [
          "targets"
        ],
        "properties": {
          "targets": {
            "title": "Website URLs",
            "type": "array",
            "description": "Required. One or more website base URLs (e.g. `https://example.com`). The actor automatically discovers sitemaps via robots.txt and common paths (`/sitemap.xml`, `/sitemap_index.xml`). You can also paste direct sitemap URLs like `https://example.com/sitemap.xml`. URLs are normalized automatically.",
            "items": {
              "type": "string"
            }
          },
          "maxItemsPerTarget": {
            "title": "Maximum URLs per target",
            "minimum": 0,
            "type": "integer",
            "description": "Limit the number of URLs returned per target. Set to `0` for all URLs. The prefilled health-check input returns one URL.",
            "default": 0
          },
          "maxDepth": {
            "title": "Maximum sitemap recursion depth",
            "minimum": 1,
            "maximum": 20,
            "type": "integer",
            "description": "How deep to follow nested sitemap indexes. `1` = only the top-level sitemap. `3` = up to 3 levels of sitemap indexes. Increase for sites with deeply nested sitemap structures.",
            "default": 5
          },
          "maxSitemaps": {
            "title": "Maximum sitemaps to process",
            "minimum": 0,
            "maximum": 10000,
            "type": "integer",
            "description": "Safety limit on the total number of sitemap files to fetch per target. Prevents runaway on sites with thousands of nested sitemaps. Set to `0` for unlimited.",
            "default": 100
          },
          "timeoutMillis": {
            "title": "Request timeout (milliseconds)",
            "minimum": 5000,
            "maximum": 120000,
            "type": "integer",
            "description": "Timeout per HTTP request in milliseconds. Increase for slow sites.",
            "default": 30000
          },
          "concurrency": {
            "title": "Concurrent requests",
            "minimum": 1,
            "maximum": 10,
            "type": "integer",
            "description": "Number of concurrent HTTP requests for fetching sitemaps. Higher is faster but may trigger rate limits. `1` is safest.",
            "default": 3
          },
          "includeStatusCheck": {
            "title": "Include HTTP status check",
            "type": "boolean",
            "description": "When enabled, performs an HTTP HEAD request for each extracted URL to get the HTTP status code. Adds the `statusCode` field to output. Slower but useful for finding broken URLs.",
            "default": false
          },
          "monitorId": {
            "title": "Change monitor ID",
            "type": "string",
            "description": "Persistent namespace for change tracking. Keep the same value for the same targets and filters. Use another value for an independent monitor or schedule.",
            "default": "default"
          },
          "onlyChangesSince": {
            "title": "Return only changes since",
            "pattern": "^\\d{4}-\\d{2}-\\d{2}T.*$",
            "type": "string",
            "description": "Optional ISO 8601 timestamp such as `2026-08-01T00:00:00.000Z`. When set, the dataset contains only records detected as new, updated, or removed since that time. The first run creates the baseline."
          },
          "useApifyProxy": {
            "title": "Use Apify Proxy",
            "type": "boolean",
            "description": "Sitemaps are public XML and normally work without a proxy. Enable only as a network fallback if you encounter IP-based blocking.",
            "default": false
          },
          "proxyConfiguration": {
            "title": "Apify Proxy configuration",
            "type": "object",
            "description": "Optional proxy configuration used only when `useApifyProxy` is enabled."
          }
        }
      },
      "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
                  }
                }
              }
            }
          }
        }
      }
    }
  }
}