{
  "openapi": "3.0.1",
  "info": {
    "title": "HTTP Request Runner (no user code)",
    "description": "Send a batch of HTTP requests you supply and get status, headers, body, timing and errors in a dataset. No user code is executed. Private, loopback and metadata addresses are blocked. Each attempted request is billed, including failures; input errors and pre-send blocks are free.",
    "version": "0.1",
    "x-build-id": "fHXYV23gd82TwZqib"
  },
  "servers": [
    {
      "url": "https://api.apify.com/v2"
    }
  ],
  "paths": {
    "/acts/gramsesh~http-runner/run-sync-get-dataset-items": {
      "post": {
        "operationId": "run-sync-get-dataset-items-gramsesh-http-runner",
        "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/gramsesh~http-runner/runs": {
      "post": {
        "operationId": "runs-sync-gramsesh-http-runner",
        "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/gramsesh~http-runner/run-sync": {
      "post": {
        "operationId": "run-sync-gramsesh-http-runner",
        "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": [
          "requests"
        ],
        "properties": {
          "requests": {
            "title": "Requests",
            "type": "array",
            "description": "List of HTTP requests to send. Each item needs a url. Optional fields: method (GET, POST, PUT, PATCH, DELETE, HEAD, OPTIONS), headers, body, timeoutSecs (cannot exceed the run timeout cap).",
            "items": {
              "type": "object",
              "properties": {
                "url": {
                  "type": "string",
                  "title": "URL",
                  "description": "The http(s) URL to request. Private, loopback, link-local and metadata addresses are blocked."
                },
                "method": {
                  "type": "string",
                  "title": "Method",
                  "description": "HTTP method. One of GET, POST, PUT, PATCH, DELETE, HEAD, OPTIONS. Default GET."
                },
                "headers": {
                  "type": "object",
                  "title": "Headers",
                  "description": "Optional request headers. Host, Content-Length, Transfer-Encoding and Connection are ignored. Authorization and Cookie are sent but redacted in logs."
                },
                "body": {
                  "title": "Body",
                  "description": "Optional request body (string or JSON). Must be within the request-body cap.",
                  "type": "string"
                },
                "timeoutSecs": {
                  "type": "integer",
                  "title": "Timeout (seconds)",
                  "description": "Optional per-request timeout in seconds. Cannot exceed the run timeout cap."
                }
              }
            }
          },
          "concurrency": {
            "title": "Concurrency",
            "minimum": 1,
            "maximum": 10,
            "type": "integer",
            "description": "Maximum number of requests in flight. Default 5, hard maximum 10.",
            "default": 5
          },
          "perHostRatePerSecond": {
            "title": "Per-host rate (requests per second)",
            "minimum": 0.1,
            "maximum": 5,
            "type": "number",
            "description": "Maximum requests per second to any one host. Default 2, hard maximum 5. Use this to avoid flooding a site.",
            "default": 2
          },
          "retries": {
            "title": "Retries",
            "minimum": 0,
            "maximum": 5,
            "type": "integer",
            "description": "Extra attempts after a network error or HTTP 429/5xx. Default 2, hard maximum 5. 4xx (except 429), blocks and oversize bodies are not retried.",
            "default": 2
          },
          "timeoutSecs": {
            "title": "Timeout per request (seconds)",
            "minimum": 1,
            "maximum": 10,
            "type": "integer",
            "description": "Default 8, hard maximum 10. A per-request timeoutSecs cannot exceed this. The run also stops at a 30-second wall-clock cap.",
            "default": 8
          },
          "maxRedirects": {
            "title": "Max redirects",
            "minimum": 0,
            "maximum": 10,
            "type": "integer",
            "description": "Each hop is re-checked for SSRF. Default 5, hard maximum 10.",
            "default": 5
          },
          "maxRequestsPerRun": {
            "title": "Max requests per run",
            "minimum": 1,
            "maximum": 200,
            "type": "integer",
            "description": "Further requests are skipped and are free. Default 100, hard maximum 200.",
            "default": 100
          },
          "maxRequestBodyBytes": {
            "title": "Max request body (bytes)",
            "minimum": 0,
            "maximum": 1048576,
            "type": "integer",
            "description": "Larger bodies are not sent and the row is failed (free). Default 262144 (256 KiB), hard maximum 1048576 (1 MiB).",
            "default": 262144
          },
          "maxResponseBodyBytes": {
            "title": "Max response body (bytes)",
            "minimum": 0,
            "maximum": 2097152,
            "type": "integer",
            "description": "The body is truncated at this size and marked truncated. Default 1048576 (1 MiB), hard maximum 2097152 (2 MiB).",
            "default": 1048576
          },
          "responseFormat": {
            "title": "Response body format",
            "enum": [
              "auto",
              "text",
              "json",
              "base64",
              "none"
            ],
            "type": "string",
            "description": "auto picks JSON, text or base64 from the content type and size. none stores headers only.",
            "default": "auto"
          },
          "revealSensitiveHeaders": {
            "title": "Include Authorization and Cookie values in the dataset",
            "type": "boolean",
            "description": "Off by default. Logs never include these values, even when this is on. Use only if you need them in the output and accept the risk.",
            "default": 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
                  }
                }
              }
            }
          }
        }
      }
    }
  }
}