{
  "openapi": "3.0.1",
  "info": {
    "title": "HTTP Request & Bulk API Calls — Clay, n8n, Webhooks · $1/1k",
    "description": "Send HTTP requests to any API: one call (Clay-ready, with callback) or thousands from a list, CSV, Google Sheet or Apify dataset with {{column}} templates. Retries, rate limits, JSON field extraction, pagination and webhooks. $1 per 1,000 requests.",
    "version": "1.0",
    "x-build-id": "Ae7noqlFmyCufADg3"
  },
  "servers": [
    {
      "url": "https://api.apify.com/v2"
    }
  ],
  "paths": {
    "/acts/tidydata~http-request/run-sync-get-dataset-items": {
      "post": {
        "operationId": "run-sync-get-dataset-items-tidydata-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/tidydata~http-request/runs": {
      "post": {
        "operationId": "runs-sync-tidydata-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/tidydata~http-request/run-sync": {
      "post": {
        "operationId": "run-sync-tidydata-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",
            "type": "string",
            "description": "The API endpoint or page to call, e.g. https://api.example.com/v1/users/{{id}}. With rows (dataset, CSV, Google Sheet) write {{column}} placeholders: values are URL-encoded, slashes kept ({{column|raw}} to insert as is). Leave empty for a free demo."
          },
          "method": {
            "title": "Method",
            "enum": [
              "GET",
              "POST",
              "PUT",
              "PATCH",
              "DELETE",
              "HEAD",
              "OPTIONS"
            ],
            "type": "string",
            "description": "HTTP method.",
            "default": "GET"
          },
          "headers": {
            "title": "Headers",
            "type": "object",
            "description": "Request headers as JSON, e.g. {\"Authorization\": \"Bearer YOUR_KEY\", \"Accept\": \"application/json\"}. Values can use {{column}}. Put secrets here: the input is private to your account."
          },
          "params": {
            "title": "Query parameters",
            "type": "object",
            "description": "Added to the URL as ?key=value (URL-encoded for you), e.g. {\"q\": \"{{company}}\", \"limit\": 10}."
          },
          "data": {
            "title": "Body (data)",
            "type": "object",
            "description": "Request body for POST/PUT/PATCH. A JSON object is sent as application/json (or as a form with Body type = form). A field that is exactly \"{{column}}\" keeps the column's type (number, list, object)."
          },
          "bodyType": {
            "title": "Body type",
            "enum": [
              "auto",
              "json",
              "form",
              "text"
            ],
            "type": "string",
            "description": "How the body is encoded.",
            "default": "auto"
          },
          "lookupKey": {
            "title": "Lookup key (Clay)",
            "type": "string",
            "description": "Any text returned unchanged in the result and in the callback, so Clay, n8n or Make can match the answer to the right row."
          },
          "requests": {
            "title": "Several requests (list)",
            "type": "array",
            "description": "A list of requests, each like {\"url\": \"…\", \"method\": \"POST\", \"headers\": {…}, \"params\": {…}, \"data\": {…}, \"lookupKey\": \"row-1\"}. Missing fields use the values above. Plain URLs work too."
          },
          "urls": {
            "title": "Or a list of URLs",
            "type": "array",
            "description": "One URL per line, all sent with the method, headers, params and body above.",
            "items": {
              "type": "string"
            }
          },
          "datasetIds": {
            "title": "Or one request per row of an Apify dataset",
            "type": "array",
            "description": "Pick datasets from your storages (or paste their IDs): the URL, headers, params and body above are filled with each row's {{columns}}. As an integration after another Actor use {{resource.defaultDatasetId}}."
          },
          "fileUrls": {
            "title": "Or rows from CSV, Excel, JSON or Google Sheets",
            "type": "array",
            "description": "Public links to .csv, .xlsx or .json files, or Google Sheets shared as 'Anyone with the link can view'. One request per row.",
            "items": {
              "type": "string"
            }
          },
          "rows": {
            "title": "Or rows as JSON",
            "type": "array",
            "description": "Rows typed directly, e.g. [{\"id\": 1}, {\"id\": 2}]. One request per row."
          },
          "maxRows": {
            "title": "Max rows",
            "minimum": 1,
            "maximum": 1000000,
            "type": "integer",
            "description": "Safety limit on rows read from datasets and files.",
            "default": 100000
          },
          "parseJson": {
            "title": "Parse JSON responses",
            "type": "boolean",
            "description": "Return JSON responses as data (not as text).",
            "default": true
          },
          "extract": {
            "title": "Extract fields into columns",
            "type": "object",
            "description": "New column → path in the JSON response, e.g. {\"price\": \"data.items[0].price\", \"total\": \"meta.total\"}. Great for clean tables and Clay columns."
          },
          "itemsPath": {
            "title": "One row per item (path to the list)",
            "type": "string",
            "description": "If the response contains a list (e.g. data.results), give its path to get one dataset row per item. Use . when the response itself is a list."
          },
          "dropResponse": {
            "title": "Drop the full response when extracting",
            "type": "boolean",
            "description": "Keep only the extracted columns (smaller, cleaner rows).",
            "default": false
          },
          "keepInputFields": {
            "title": "Keep the row's own fields",
            "type": "boolean",
            "description": "With rows from a dataset/file, copy each row's fields into its result (enrichment). Same-name fields get an input_ prefix.",
            "default": true
          },
          "includeHeaders": {
            "title": "Include response headers",
            "type": "boolean",
            "description": "Add the response headers to each result.",
            "default": false
          },
          "maxResponseKb": {
            "title": "Max response size (KB)",
            "minimum": 1,
            "maximum": 20480,
            "type": "integer",
            "description": "Longer responses are cut (marked truncated). 2 MB max through residential proxies.",
            "default": 1024
          },
          "saveFiles": {
            "title": "Save binary responses (images, PDFs…)",
            "type": "boolean",
            "description": "Store non-text responses in the run's key-value store and return a fileUrl.",
            "default": false
          },
          "paginate": {
            "title": "Pagination",
            "enum": [
              "none",
              "page",
              "next",
              "cursor"
            ],
            "type": "string",
            "description": "Follow the API's pages automatically. Each page is one request (one event).",
            "default": "none"
          },
          "pageParam": {
            "title": "Page parameter",
            "type": "string",
            "description": "Query parameter for the page number (or write {{page}} in the URL).",
            "default": "page"
          },
          "pageStart": {
            "title": "First page",
            "type": "integer",
            "description": "First page number (use 0 for zero-based APIs, or an offset).",
            "default": 1
          },
          "pageStep": {
            "title": "Page step",
            "minimum": 1,
            "type": "integer",
            "description": "Add this to the page number each time (e.g. 100 for offset pagination).",
            "default": 1
          },
          "nextUrlPath": {
            "title": "Next-page URL path",
            "type": "string",
            "description": "Path of the next page's URL in the JSON, e.g. next or links.next. Empty = use the Link header (GitHub style)."
          },
          "nextCursorPath": {
            "title": "Next cursor path",
            "type": "string",
            "description": "Path of the next cursor in the JSON, e.g. meta.next_cursor (cursor pagination)."
          },
          "cursorParam": {
            "title": "Cursor parameter",
            "type": "string",
            "description": "Query parameter that receives the cursor.",
            "default": "cursor"
          },
          "stopWhenEmptyPath": {
            "title": "Stop when this list is empty",
            "type": "string",
            "description": "Path of the list that ends the pagination when empty (defaults to the items path)."
          },
          "maxPages": {
            "title": "Max pages per request",
            "minimum": 1,
            "maximum": 1000,
            "type": "integer",
            "description": "Safety limit of pages per starting request.",
            "default": 10
          },
          "maxConcurrency": {
            "title": "Parallel requests",
            "minimum": 1,
            "maximum": 100,
            "type": "integer",
            "description": "How many requests run at the same time.",
            "default": 10
          },
          "perHostPerSecond": {
            "title": "Max requests per second per host",
            "minimum": 0,
            "maximum": 100,
            "type": "integer",
            "description": "Be kind to APIs and avoid 429 errors (0 = no limit).",
            "default": 10
          },
          "timeoutSecs": {
            "title": "Timeout per request (seconds)",
            "minimum": 1,
            "maximum": 300,
            "type": "integer",
            "description": "Give up on a request after this time.",
            "default": 30
          },
          "maxRetries": {
            "title": "Retries",
            "minimum": 0,
            "maximum": 10,
            "type": "integer",
            "description": "Retries on network errors, 429 and 5xx answers, with back-off and Retry-After. GET, HEAD, PUT, DELETE and OPTIONS only, unless you allow POST/PATCH below.",
            "default": 2
          },
          "retryUnsafe": {
            "title": "Also retry POST and PATCH",
            "type": "boolean",
            "description": "Only if repeating the call is safe for your API (it may create duplicates).",
            "default": false
          },
          "followRedirects": {
            "title": "Follow redirects",
            "type": "boolean",
            "description": "Follow 301/302/307/308 redirects (up to 10).",
            "default": true
          },
          "ignoreTlsErrors": {
            "title": "Ignore TLS certificate errors",
            "type": "boolean",
            "description": "Only for test servers with self-signed certificates.",
            "default": false
          },
          "failOnErrorStatus": {
            "title": "Mark the run as failed on errors",
            "type": "boolean",
            "description": "Fail the run if any request got an HTTP error or no response (useful to trigger alerts). Results are saved anyway.",
            "default": false
          },
          "callbackUrl": {
            "title": "Callback URL (Clay, n8n, Make, Zapier)",
            "type": "string",
            "description": "Each result is also POSTed as JSON to this URL (e.g. a Clay webhook table, n8n/Make/Zapier webhook, Slack or Discord incoming webhook)."
          },
          "callbackHeaders": {
            "title": "Callback headers",
            "type": "object",
            "description": "Extra headers for the callback, e.g. {\"x-clay-webhook-auth\": \"…\"}."
          },
          "proxyConfiguration": {
            "title": "Proxy",
            "type": "object",
            "description": "Optional: send the requests through Apify Proxy (datacenter or residential, by country) or your own proxies. Datacenter and residential requests have their own small extra price.",
            "default": {
              "useApifyProxy": false
            }
          }
        }
      },
      "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
                  }
                }
              }
            }
          }
        }
      }
    }
  }
}