{
  "openapi": "3.0.1",
  "info": {
    "title": "WCGW Safety Engineer",
    "description": "AI-assisted safety-engineering agent that turns system descriptions into structured hazard analyses. Investigates losses, unsafe conditions, safety constraints, and missing evidence using systems safety methods. Produces traceable findings, assumptions, and recommendations for human review.",
    "version": "0.1",
    "x-build-id": "3LJIrVjrBRkeijYS1"
  },
  "servers": [
    {
      "url": "https://api.apify.com/v2"
    }
  ],
  "paths": {
    "/acts/vwnb~wcgw-safety-engineer/run-sync-get-dataset-items": {
      "post": {
        "operationId": "run-sync-get-dataset-items-vwnb-wcgw-safety-engineer",
        "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/vwnb~wcgw-safety-engineer/runs": {
      "post": {
        "operationId": "runs-sync-vwnb-wcgw-safety-engineer",
        "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/vwnb~wcgw-safety-engineer/run-sync": {
      "post": {
        "operationId": "run-sync-vwnb-wcgw-safety-engineer",
        "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": [
          "systemName",
          "systemDescription"
        ],
        "properties": {
          "systemName": {
            "title": "System name",
            "maxLength": 200,
            "type": "string",
            "description": "Short name of the system, product or machine being analysed."
          },
          "systemDescription": {
            "title": "System description",
            "minLength": 40,
            "maxLength": 8000,
            "type": "string",
            "description": "What the system is and does: main components, energy sources and motion, controllers and software, sensors and feedback, operators and other people nearby, existing protective measures. 40 to 8,000 characters. Do not include credentials or personal data."
          },
          "operatingEnvironment": {
            "title": "Operating environment",
            "maxLength": 3000,
            "type": "string",
            "description": "Where and when the system operates: site, shifts, climate, nearby traffic, people present, maintenance situations."
          },
          "intendedUse": {
            "title": "Intended use",
            "maxLength": 3000,
            "type": "string",
            "description": "What the system is meant to be used for, by whom, and foreseeable misuse you already know about."
          },
          "boundaries": {
            "title": "Analysis boundary",
            "maxLength": 3000,
            "type": "string",
            "description": "What is inside the analysis and what is not, including interfaces to other systems."
          },
          "components": {
            "title": "Components",
            "maxItems": 30,
            "type": "array",
            "description": "Optional list of the main components (up to 30).",
            "items": {
              "type": "string"
            },
            "default": []
          },
          "knownHazards": {
            "title": "Known hazards",
            "maxItems": 20,
            "type": "array",
            "description": "Optional hazards you already know about (up to 20). Each becomes a hazard marked as stated by you.",
            "items": {
              "type": "string"
            },
            "default": []
          },
          "targetStandards": {
            "title": "Standards to trace against",
            "uniqueItems": true,
            "type": "array",
            "description": "Optional. Enables WCGW's traceability checks associated with these standards. The checks count links in the proposed model; they are not a compliance assessment.",
            "items": {
              "type": "string",
              "enum": [
                "ISO_26262",
                "IEC_61508",
                "ISO_13849",
                "ISO_14971",
                "IEC_61800"
              ],
              "enumTitles": [
                "ISO 26262",
                "IEC 61508",
                "ISO 13849",
                "ISO 14971",
                "IEC 61800-5-2"
              ]
            },
            "default": []
          },
          "targetAsil": {
            "title": "Stated ASIL (ISO 26262)",
            "enum": [
              "QM",
              "ASIL_A",
              "ASIL_B",
              "ASIL_C",
              "ASIL_D"
            ],
            "type": "string",
            "description": "Optional. Only if you have already determined it; the agent never assigns integrity levels."
          },
          "targetSil": {
            "title": "Stated SIL (IEC 61508)",
            "enum": [
              "SIL_1",
              "SIL_2",
              "SIL_3",
              "SIL_4"
            ],
            "type": "string",
            "description": "Optional. Only if you have already determined it; the agent never assigns integrity levels."
          },
          "targetPl": {
            "title": "Stated PL (ISO 13849)",
            "enum": [
              "PL_A",
              "PL_B",
              "PL_C",
              "PL_D",
              "PL_E"
            ],
            "type": "string",
            "description": "Optional. Only if you have already determined it; the agent never assigns integrity levels."
          },
          "anthropicApiKey": {
            "title": "Your Anthropic API key (optional)",
            "type": "string",
            "description": "Optional. When set, every model call of this run (draft, reviews and the agent) uses your Anthropic account instead of the Actor's. The key is stored encrypted by Apify, used only for this run, and never written to the outputs or logs."
          },
          "maxAgentSteps": {
            "title": "Maximum agent steps",
            "minimum": 1,
            "maximum": 25,
            "type": "integer",
            "description": "How many refinement operations the agent may run after the initial draft (1 to 25). The draft, the checks and the final review always run.",
            "default": 10
          },
          "maxRuntimeMinutes": {
            "title": "Maximum runtime (minutes)",
            "minimum": 10,
            "maximum": 60,
            "type": "integer",
            "description": "Wall-clock limit for the analysis (10 to 60). The agent stops refining early enough to run the final review. The run timeout in run options must be at least this long.",
            "default": 25
          },
          "maxModelTokens": {
            "title": "Maximum planner tokens",
            "minimum": 100000,
            "maximum": 3000000,
            "type": "integer",
            "description": "Inference budget for the agent's planner, in tokens processed (100,000 to 3,000,000). It does not change the price.",
            "default": 800000
          }
        }
      },
      "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
                  }
                }
              }
            }
          }
        }
      }
    }
  }
}