{
  "openapi": "3.0.1",
  "info": {
    "title": "Bulk File & Image Downloader",
    "description": "Download files and pictures in bulk: paste file links, or give web pages and get every picture, PDF, video or other file on them. Each file is stored with a shareable link, its size, type and SHA-256, plus an optional ZIP of everything.",
    "version": "1.0",
    "x-build-id": "7GUsJF2APPfKEaFOo"
  },
  "servers": [
    {
      "url": "https://api.apify.com/v2"
    }
  ],
  "paths": {
    "/acts/cyber1nj3ct0r~bulk-file-downloader/run-sync-get-dataset-items": {
      "post": {
        "operationId": "run-sync-get-dataset-items-cyber1nj3ct0r-bulk-file-downloader",
        "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/cyber1nj3ct0r~bulk-file-downloader/runs": {
      "post": {
        "operationId": "runs-sync-cyber1nj3ct0r-bulk-file-downloader",
        "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/cyber1nj3ct0r~bulk-file-downloader/run-sync": {
      "post": {
        "operationId": "run-sync-cyber1nj3ct0r-bulk-file-downloader",
        "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": {
          "urls": {
            "title": "File addresses",
            "type": "array",
            "description": "Direct links to files, for example <code>https://www.example.com/report.pdf</code> or a picture's address. Add them one by one, paste many at once with <b>Bulk edit</b>, or link a text file (or a Google Sheet published as CSV) that holds them. Each address is downloaded once, as given.",
            "items": {
              "type": "object",
              "required": [
                "url"
              ],
              "properties": {
                "url": {
                  "type": "string",
                  "title": "URL of a web page",
                  "format": "uri"
                }
              }
            }
          },
          "pageUrls": {
            "title": "Pages to collect files from",
            "type": "array",
            "description": "Web pages whose pictures and files you want. The tool reads each page, finds the files of the kinds chosen below (also the large version of pictures in <code>srcset</code> and lazy-loaded pictures) and downloads them. Pages, and the files found on them, are read only where the site's robots.txt allows it.",
            "items": {
              "type": "object",
              "required": [
                "url"
              ],
              "properties": {
                "url": {
                  "type": "string",
                  "title": "URL of a web page",
                  "format": "uri"
                }
              }
            }
          },
          "fileTypes": {
            "title": "Files to collect from pages",
            "type": "array",
            "description": "Which files to take from the pages. Pictures include the page's preview image and icons; the other kinds are recognised by their file ending (.pdf, .mp3, .mp4, .zip and so on) or by the video and audio tags of the page.",
            "items": {
              "type": "string",
              "enum": [
                "images",
                "documents",
                "audio",
                "video",
                "archives"
              ],
              "enumTitles": [
                "Pictures",
                "Documents (PDF, Word, Excel, CSV ...)",
                "Audio",
                "Video",
                "Archives (ZIP ...)"
              ]
            },
            "default": [
              "images"
            ]
          },
          "extensions": {
            "title": "Other file endings",
            "type": "array",
            "description": "More file endings to collect from pages, for example <code>dwg</code> or <code>stl</code>, without the dot.",
            "items": {
              "type": "string"
            }
          },
          "sameSiteOnly": {
            "title": "Only files on the page's own site",
            "type": "boolean",
            "description": "Skip files that sit on other sites, for example pictures on an image service or a shop's CDN. Off by default, because many sites keep their pictures elsewhere.",
            "default": false
          },
          "maxFilesPerPage": {
            "title": "Files per page",
            "minimum": 1,
            "maximum": 10000,
            "type": "integer",
            "description": "At most this many files are taken from each page, in the order they appear on it.",
            "default": 100
          },
          "maxFiles": {
            "title": "Files in all",
            "minimum": 1,
            "maximum": 100000,
            "type": "integer",
            "description": "At most this many files are downloaded in one run, the listed addresses first. Your spending limit for the run also stops it.",
            "default": 1000
          },
          "maxFileSizeMb": {
            "title": "Largest file",
            "minimum": 1,
            "maximum": 2000,
            "type": "integer",
            "description": "Files larger than this are not downloaded. When a server does not say how big a file is, the download stops at this size. 1 MB is 1,000,000 bytes.",
            "default": 50
          },
          "zip": {
            "title": "Also pack all files into one ZIP",
            "type": "boolean",
            "description": "Adds <code>files.zip</code> with every downloaded file to the run's storage, linked from the run summary. Disk space is twice the run's memory: give the run more memory for very large ZIPs.",
            "default": false
          },
          "maxConcurrency": {
            "title": "Downloads at the same time",
            "minimum": 1,
            "maximum": 32,
            "type": "integer",
            "description": "How many files are downloaded at once in all.",
            "default": 8
          },
          "perHostConcurrency": {
            "title": "Downloads at the same time per website",
            "minimum": 1,
            "maximum": 16,
            "type": "integer",
            "description": "How many files of the same website are downloaded at once. Keep it low for sites you do not run.",
            "default": 4
          },
          "requestTimeoutSecs": {
            "title": "Time limit per file",
            "minimum": 10,
            "maximum": 900,
            "type": "integer",
            "description": "How long one download may take, from the request to the last byte.",
            "default": 120
          },
          "userAgent": {
            "title": "User-Agent",
            "type": "string",
            "description": "The name the tool sends with each request. Leave empty to use the tool's own name, which tells site owners what is visiting. Set your own only for sites you run or have permission to use."
          }
        }
      },
      "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
                  }
                }
              }
            }
          }
        }
      }
    }
  }
}