{
  "openapi": "3.0.1",
  "info": {
    "title": "Bulk HTTP Request Runner – API calls for Clay, n8n & Make",
    "description": "Send one or thousands of HTTP requests (GET, POST, PUT, PATCH, DELETE) with headers, JSON body and query params. Get status, headers and parsed JSON. Pay only for 2xx responses.",
    "version": "0.1",
    "x-build-id": "xumbBdpkTsMIluqhv"
  },
  "servers": [
    {
      "url": "https://api.apify.com/v2"
    }
  ],
  "paths": {
    "/acts/lundrik~bulk-http-request/run-sync-get-dataset-items": {
      "post": {
        "operationId": "run-sync-get-dataset-items-lundrik-bulk-http-request",
        "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/lundrik~bulk-http-request/runs": {
      "post": {
        "operationId": "runs-sync-lundrik-bulk-http-request",
        "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/lundrik~bulk-http-request/run-sync": {
      "post": {
        "operationId": "run-sync-lundrik-bulk-http-request",
        "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": {
          "url": {
            "title": "URL (single request)",
            "type": "string",
            "description": "One endpoint to call. Use `requests` instead for a batch.",
            "default": "https://jsonplaceholder.typicode.com/posts/1"
          },
          "method": {
            "title": "Method",
            "enum": [
              "GET",
              "POST",
              "PUT",
              "PATCH",
              "DELETE",
              "HEAD",
              "OPTIONS"
            ],
            "type": "string",
            "description": "Default method. A request in `requests` can override it.",
            "default": "GET"
          },
          "headers": {
            "title": "Headers",
            "type": "object",
            "description": "Default headers, e.g. {\"Authorization\": \"Bearer …\", \"Content-Type\": \"application/json\"}. A JSON string is also accepted. Headers are never written to the log and are not sent to another domain after a redirect."
          },
          "json": {
            "title": "JSON body",
            "type": "object",
            "description": "Default JSON body for POST/PUT/PATCH/DELETE. Sent with Content-Type: application/json (unless you set another one)."
          },
          "body": {
            "title": "Raw body (text)",
            "type": "string",
            "description": "Default raw body, sent as is (e.g. form data a=1&b=2 or XML). If it is valid JSON and no Content-Type is set, application/json is added. Ignored when `json` is given."
          },
          "queryParams": {
            "title": "Query parameters",
            "type": "object",
            "description": "Added to every URL, e.g. {\"page\": 2, \"limit\": 100}."
          },
          "requests": {
            "title": "Requests (batch)",
            "type": "array",
            "description": "List of URLs or request objects: {\"url\": \"…\", \"method\": \"POST\", \"headers\": {…}, \"body\": {…}, \"queryParams\": {…}, \"id\": \"row-17\"}. Up to 10,000 per run. Duplicates are NOT removed – each item is sent and returned as its own row (`requestId` = your id or req-1, req-2…)."
          },
          "extract": {
            "title": "Extract JSON fields",
            "type": "object",
            "description": "Optional. Copy values from a JSON response into `extracted`, e.g. {\"id\": \"data.items[0].id\", \"total\": \"meta.total\"}. Missing paths give null."
          },
          "responseFormat": {
            "title": "Response body format",
            "enum": [
              "auto",
              "json",
              "text",
              "base64",
              "none"
            ],
            "type": "string",
            "description": "auto: JSON is parsed, text stays text, binary files become base64. none: only status and headers (smallest output).",
            "default": "auto"
          },
          "maxResponseSizeKb": {
            "title": "Max response size (KB)",
            "minimum": 1,
            "maximum": 6144,
            "type": "integer",
            "description": "Larger bodies are cut at this size (`bodyTruncated: true`).",
            "default": 2048
          },
          "timeoutSecs": {
            "title": "Timeout per request (seconds)",
            "minimum": 1,
            "maximum": 300,
            "type": "integer",
            "description": "A request that gets no response in time fails with TIMEOUT (free of charge).",
            "default": 30
          },
          "followRedirects": {
            "title": "Follow redirects",
            "type": "boolean",
            "description": "Off: a 3xx response is returned as the result (and counts as a success).",
            "default": true
          },
          "maxRetries": {
            "title": "Max retries",
            "minimum": 0,
            "maximum": 5,
            "type": "integer",
            "description": "Free retries on 429 and 503 (honouring Retry-After, up to 30 s). 502/504 and connection errors are retried only for GET, HEAD, PUT, DELETE and OPTIONS – never for POST/PATCH, so nothing is sent twice by accident.",
            "default": 2
          },
          "includeResponseHeaders": {
            "title": "Include response headers",
            "type": "boolean",
            "description": "Adds `responseHeaders` to each row (Set-Cookie is always left out).",
            "default": true
          },
          "maxConcurrency": {
            "title": "Max concurrency",
            "minimum": 0,
            "maximum": 8,
            "type": "integer",
            "description": "How many requests run in parallel. 0 = automatic (5). Lower it if the API has strict rate limits.",
            "default": 0
          }
        }
      },
      "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
                  }
                }
              }
            }
          }
        }
      }
    }
  }
}