{
  "openapi": "3.0.1",
  "info": {
    "title": "Web Fetch API — Fetch Any URL as HTML, Text, Markdown or JSON",
    "description": "Bulk HTTP fetch for agents: returns status, headers and body (raw HTML, text, Markdown or parsed JSON), follows redirects, optional browser rendering. Unofficial Web Fetch API.",
    "version": "0.1",
    "x-build-id": "opbVnqC9iCkUVCVFb"
  },
  "servers": [
    {
      "url": "https://api.apify.com/v2"
    }
  ],
  "paths": {
    "/acts/highbrow_fame~web-fetch-api/run-sync-get-dataset-items": {
      "post": {
        "operationId": "run-sync-get-dataset-items-highbrow_fame-web-fetch-api",
        "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/highbrow_fame~web-fetch-api/runs": {
      "post": {
        "operationId": "runs-sync-highbrow_fame-web-fetch-api",
        "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/highbrow_fame~web-fetch-api/run-sync": {
      "post": {
        "operationId": "run-sync-highbrow_fame-web-fetch-api",
        "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": [
          "urls"
        ],
        "properties": {
          "urls": {
            "title": "URLs",
            "type": "array",
            "description": "Addresses to fetch, one per line: web pages, JSON APIs, feeds, text files. Each becomes one record with status, headers and body.",
            "items": {
              "type": "string"
            }
          },
          "method": {
            "title": "Method",
            "enum": [
              "GET",
              "POST",
              "HEAD",
              "PUT",
              "PATCH",
              "DELETE",
              "OPTIONS"
            ],
            "type": "string",
            "description": "HTTP method for every request.",
            "default": "GET"
          },
          "headers": {
            "title": "Headers",
            "type": "object",
            "description": "Extra request headers as a JSON object, for example {\"Accept\": \"application/json\", \"Authorization\": \"Bearer ...\"}. They replace the defaults of the same name (a browser-like User-Agent and Accept are sent by default)."
          },
          "format": {
            "title": "Body format",
            "enum": [
              "auto",
              "html",
              "text",
              "markdown",
              "json"
            ],
            "type": "string",
            "description": "How to deliver the body. `auto`: JSON answers parsed, HTML kept raw, everything else as text. `markdown` and `text` turn an HTML page into its main content (Readability); `json` parses the body.",
            "default": "auto"
          },
          "useBrowser": {
            "title": "Use a browser (JavaScript pages)",
            "type": "boolean",
            "description": "Render GET requests in headless Chromium before reading the page. Needed only for pages that build their content with JavaScript; slower and more expensive than the default plain fetch.",
            "default": false
          },
          "body": {
            "title": "Request body",
            "type": "string",
            "description": "Body for POST, PUT and PATCH requests (a string; JSON text is sent as is — set a Content-Type header if the server needs one)."
          },
          "followRedirects": {
            "title": "Follow redirects",
            "type": "boolean",
            "description": "Follow 3xx redirects and report the final URL. Off: the redirect answer itself is delivered.",
            "default": true
          },
          "timeoutSecs": {
            "title": "Timeout per request (seconds)",
            "minimum": 5,
            "maximum": 120,
            "type": "integer",
            "description": "Give up on a request after this long.",
            "default": 30
          },
          "respectRobotsTxt": {
            "title": "Respect robots.txt",
            "type": "boolean",
            "description": "Skip URLs the site's robots.txt disallows for bots (a free ROBOTS_DISALLOWED record). Turn off only for URLs you have the right to read, for example your own API.",
            "default": true
          },
          "waitUntil": {
            "title": "Browser: wait until",
            "enum": [
              "load",
              "domcontentloaded",
              "networkidle"
            ],
            "type": "string",
            "description": "With \"Use a browser\": when the page counts as loaded. `load` is the safe default; `networkidle` waits for background requests to stop.",
            "default": "load"
          },
          "mainContentOnly": {
            "title": "Main content only (text / markdown)",
            "type": "boolean",
            "description": "For the `text` and `markdown` formats: keep the main content (Readability) and drop navigation, footer and sidebars. Off: the whole page.",
            "default": true
          },
          "includeHeaders": {
            "title": "Include response headers",
            "type": "boolean",
            "description": "Deliver the response headers as an object in `headers`.",
            "default": true
          },
          "maxBodyLength": {
            "title": "Max body length",
            "minimum": 0,
            "type": "integer",
            "description": "Cut a text body after this many characters (`truncated: true` is set). 0: no limit (10 MB hard limit).",
            "default": 0
          },
          "maxConcurrency": {
            "title": "Parallel requests",
            "minimum": 1,
            "maximum": 20,
            "type": "integer",
            "description": "How many requests to make at the same time.",
            "default": 5
          },
          "proxyConfiguration": {
            "title": "Proxy",
            "type": "object",
            "description": "Used only to try again after a network error or a 5xx answer: the first try goes out directly.",
            "default": {
              "useApifyProxy": true
            }
          }
        }
      },
      "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
                  }
                }
              }
            }
          }
        }
      }
    }
  }
}