{
  "openapi": "3.0.1",
  "info": {
    "title": "Actor Compliance Scanner — PII, GDPR & TOS Risk Audit",
    "description": "Actor Compliance Scanner. Available on the Apify Store with pay-per-event pricing.",
    "version": "1.0",
    "x-build-id": "c2H63E3D3L5feUfqF"
  },
  "servers": [
    {
      "url": "https://api.apify.com/v2"
    }
  ],
  "paths": {
    "/acts/ryanclinton~actor-compliance-scanner/run-sync-get-dataset-items": {
      "post": {
        "operationId": "run-sync-get-dataset-items-ryanclinton-actor-compliance-scanner",
        "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/ryanclinton~actor-compliance-scanner/runs": {
      "post": {
        "operationId": "runs-sync-ryanclinton-actor-compliance-scanner",
        "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/ryanclinton~actor-compliance-scanner/run-sync": {
      "post": {
        "operationId": "run-sync-ryanclinton-actor-compliance-scanner",
        "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": {
          "targetActorId": {
            "title": "Target Actor ID",
            "pattern": "^$|^[\\w.-]+\\/[\\w.-]+$|^\\w{10,32}$",
            "type": "string",
            "description": "Apify actor ID or username/actor-name to scan (e.g. ryanclinton/website-contact-scraper). Leave blank to run a fleet-wide scan across every actor you own."
          },
          "fleetScan": {
            "title": "Scan entire fleet",
            "type": "boolean",
            "description": "Scan every actor you own and emit a fleet-wide compliance report. Overrides Target Actor ID when enabled.",
            "default": false
          },
          "maxActors": {
            "title": "Max actors to scan (fleet mode)",
            "minimum": 1,
            "maximum": 1000,
            "type": "integer",
            "description": "Upper bound on how many actors are scanned in fleet mode. Default 250, max 1000. Reduce for faster scans on large accounts.",
            "default": 250
          },
          "includeDocumentationChecks": {
            "title": "Include documentation-quality checks",
            "type": "boolean",
            "description": "Audit the target actor's README for required sections (Methodology, Limitations, FAQ, Responsible use, Decision rubric, Troubleshooting). Scoped to trust/decision clarity. Does NOT assess SEO or narrative style. Disable to skip.",
            "default": true
          },
          "includeSchemaChecks": {
            "title": "Include schema-completeness checks",
            "type": "boolean",
            "description": "Audit whether input + dataset schemas exist and have field-level descriptions. Scoped to existence + description quality. Does NOT perform runtime output validation or drift detection — use Output Guard for that.",
            "default": true
          },
          "includeAgenticReadiness": {
            "title": "Include agentic-readiness checks",
            "type": "boolean",
            "description": "Audit whether the target actor is structured-output friendly for Apify MCP consumers — typed schemas, stable enums, declared categories, changelog reference, predictable error records.",
            "default": true
          },
          "includeChangeSignals": {
            "title": "Include change/regression detection",
            "type": "boolean",
            "description": "Compare against the previous scan of this actor (stored in KV). Emits regressionSignals[] and improvementSignals[]. First run stores a baseline.",
            "default": true
          },
          "strictMode": {
            "title": "Strict mode",
            "type": "boolean",
            "description": "Raises sensitivity when metadata is sparse or wording is ambiguous. Use for enterprise/compliance-heavy environments. Example: a description with only 'scrapes business data and contact info' would score MEDIUM in normal mode and HIGH + act_now in strict mode because the ambiguous 'contact info' wording is treated as likely PII.",
            "default": false
          },
          "previousSnapshotKey": {
            "title": "Previous snapshot KV key (optional)",
            "pattern": "^[\\w.-]{1,100}$",
            "type": "string",
            "description": "Override the default KV key for the prior-scan snapshot. Default: SNAPSHOT_<actorId>. Useful if you want to compare against a specific named baseline instead of the most recent run."
          },
          "emitSignals": {
            "title": "Emit portable fleet signals",
            "type": "boolean",
            "description": "Write a portable signals[] array to KV under the SIGNALS key for consumption by Fleet Analytics. Disable for ad-hoc runs.",
            "default": true
          },
          "apifyToken": {
            "title": "Apify API token (optional)",
            "type": "string",
            "description": "Overrides the auto-injected run token. Leave blank to use the token of the account running this actor."
          }
        }
      },
      "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
                  }
                }
              },
              "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
                  }
                }
              }
            }
          }
        }
      }
    }
  }
}