{
  "openapi": "3.0.1",
  "info": {
    "title": "Armored AI Web Scraper | RAG Data Protection",
    "description": "Protect agent memory and RAG ingestion from slow-stream tarpits, repetitive crawl mazes and invisible token bloat. Fetch inspected text with source hashes, injection flags and token accounting. API, MCP and n8n ready. Pay for delivered pages; failed and quarantined pages carry no page charge.",
    "version": "0.4",
    "x-build-id": "f2ilIObaegNzb9ODj"
  },
  "servers": [
    {
      "url": "https://api.apify.com/v2"
    }
  ],
  "paths": {
    "/acts/apricot_blackberry~armored-ai-web-scraper/run-sync-get-dataset-items": {
      "post": {
        "operationId": "run-sync-get-dataset-items-apricot_blackberry-armored-ai-web-scraper",
        "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/apricot_blackberry~armored-ai-web-scraper/runs": {
      "post": {
        "operationId": "runs-sync-apricot_blackberry-armored-ai-web-scraper",
        "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/apricot_blackberry~armored-ai-web-scraper/run-sync": {
      "post": {
        "operationId": "run-sync-apricot_blackberry-armored-ai-web-scraper",
        "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": "Page URL",
            "type": "string",
            "description": "Fetch one public HTTP(S) page. For batches, use Start URLs or urls. All three forms are merged and deduplicated."
          },
          "startUrls": {
            "title": "Start URLs",
            "type": "array",
            "description": "1-100 public HTTP(S) URLs. URL objects only; no credentials, uploaded URL lists or request queues.",
            "items": {
              "type": "object",
              "required": [
                "url"
              ],
              "properties": {
                "url": {
                  "type": "string",
                  "title": "URL of a web page",
                  "format": "uri"
                }
              }
            }
          },
          "maxPages": {
            "title": "Maximum attempted pages",
            "minimum": 1,
            "maximum": 100,
            "type": "integer",
            "description": "Hard cap on attempted pages, including diagnostic and quarantined records. Useful for predictable agent runs.",
            "default": 20
          },
          "maxDepth": {
            "title": "Maximum crawl depth",
            "minimum": 0,
            "maximum": 10,
            "type": "integer",
            "description": "0 fetches only supplied URLs. 1 also follows their links. Discovery stays on the starting origins.",
            "default": 2
          },
          "maxOutputChars": {
            "title": "Maximum text characters per record",
            "minimum": 1,
            "maximum": 200000,
            "type": "integer",
            "description": "Maximum cleaned text per record. Truncation is flagged and is never counted as token savings.",
            "default": 40000
          },
          "maxOutputTokens": {
            "title": "Maximum output tokens per record",
            "minimum": 1,
            "maximum": 50000,
            "type": "integer",
            "description": "Hard output-token cap for the selected tokenizer, in addition to the character cap. Truncation is reported and excluded from normalization savings.",
            "default": 8192
          },
          "maxRunSecs": {
            "title": "Crawl time budget (seconds)",
            "minimum": 1,
            "maximum": 300,
            "type": "number",
            "description": "Wall-clock work budget across fetching and inspection. Partial output remains available when reached.",
            "default": 120
          },
          "onSuspectedInjection": {
            "title": "Suspected instruction policy",
            "enum": [
              "quarantine",
              "report"
            ],
            "type": "string",
            "description": "Quarantine withholds text and outgoing links when an implemented instruction pattern matches. Report returns the flagged text as untrusted data. Quoted HTML instruction examples are redacted, with telemetry. Detection is heuristic and can miss attacks or flag benign text.",
            "default": "quarantine"
          },
          "respectRobotsTxt": {
            "title": "Respect robots.txt",
            "type": "boolean",
            "description": "Read once per origin; 404 permits crawling, 401/403 deny, other failures produce diagnostic records.",
            "default": true
          },
          "minBytesPerSecond": {
            "title": "Minimum stream bytes per second",
            "minimum": 0,
            "maximum": 1048576,
            "type": "number",
            "description": "Stop HTTP streams below this rate after the grace/window interval. 0 disables only this rate check.",
            "default": 32
          },
          "gracePeriodSecs": {
            "title": "Initial stream grace period (seconds)",
            "minimum": 0.1,
            "maximum": 10,
            "type": "number",
            "description": "Time before throughput rejection can begin. Increase for genuinely slow sites.",
            "default": 2
          },
          "throughputWindowSecs": {
            "title": "Throughput window (seconds)",
            "minimum": 0.1,
            "maximum": 10,
            "type": "number",
            "description": "Sliding time window used to measure received bytes. Detection starts after both window and grace have elapsed.",
            "default": 2
          },
          "requestTimeoutSecs": {
            "title": "Absolute page request timeout (seconds)",
            "minimum": 0.2,
            "maximum": 60,
            "type": "number",
            "description": "Absolute timeout per HTTP request, including headers and body. Always active.",
            "default": 20
          },
          "maxResponseBytes": {
            "title": "Maximum wire and decoded response bytes",
            "minimum": 1024,
            "maximum": 2097152,
            "type": "integer",
            "description": "Maximum bytes for both compressed and decompressed response bodies. Oversize bodies produce diagnostics.",
            "default": 2097152
          },
          "maxLinksPerPage": {
            "title": "Maximum links considered per page",
            "minimum": 0,
            "maximum": 100,
            "type": "integer",
            "description": "Caps outgoing links considered on each page; prevents link explosions.",
            "default": 50
          },
          "tokenEncoding": {
            "title": "Tokenizer encoding",
            "enum": [
              "cl100k_base",
              "o200k_base"
            ],
            "type": "string",
            "description": "Counts are exact for this encoding and the documented extracted text, not universal model billing.",
            "default": "cl100k_base"
          },
          "stripJoiners": {
            "title": "Strip all Unicode joiners",
            "type": "boolean",
            "description": "False preserves contextual language and emoji joiners; ASCII obfuscation and long runs are still removed. True may alter natural-language text.",
            "default": false
          },
          "inputTokenUsdPerMillion": {
            "title": "Your input-token price (USD per million)",
            "minimum": 0,
            "maximum": 1000,
            "type": "number",
            "description": "Optional caller-supplied price. Without it, dollar savings are null. Only normalization reductions are credited."
          },
          "urls": {
            "title": "URL strings for API clients",
            "type": "array",
            "description": "Agent-friendly batch form, for example [\"https://docs.python.org/3/tutorial/datastructures.html\"]. Combined maximum is 100 submitted URLs.",
            "items": {
              "type": "string"
            }
          }
        }
      },
      "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
                  }
                }
              }
            }
          }
        }
      }
    }
  }
}