{
  "openapi": "3.0.1",
  "info": {
    "title": "Vendor SLA Attainment and Credit-Claim Report",
    "description": "Turn a vendor's public status page into one number for the billing period. For each vendor: the uptime percentage, the downtime minutes split by severity, the incident count, the longest outage, the breach flag against your contracted threshold, the claim",
    "version": "0.1",
    "x-build-id": "qimGkHWwYFdxNe8f5"
  },
  "servers": [
    {
      "url": "https://api.apify.com/v2"
    }
  ],
  "paths": {
    "/acts/kingii98~vendor-sla-attainment-and-credit-claim-report/run-sync-get-dataset-items": {
      "post": {
        "operationId": "run-sync-get-dataset-items-kingii98-vendor-sla-attainment-and-credit-claim-report",
        "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/kingii98~vendor-sla-attainment-and-credit-claim-report/runs": {
      "post": {
        "operationId": "runs-sync-kingii98-vendor-sla-attainment-and-credit-claim-report",
        "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/kingii98~vendor-sla-attainment-and-credit-claim-report/run-sync": {
      "post": {
        "operationId": "run-sync-kingii98-vendor-sla-attainment-and-credit-claim-report",
        "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": [
          "vendors"
        ],
        "properties": {
          "vendors": {
            "title": "Vendors",
            "minItems": 1,
            "maxItems": 50,
            "type": "array",
            "description": "1 to 50 vendors. Each entry is an object with 'name', 'status_json_url', 'sla_threshold_pct' and 'excluded_components'. The URL must be a public Statuspage or Instatus JSON feed, normally https://status.<vendor>.com/api/v2/incidents.json. A plain URL string is also accepted, and then the hostname becomes the vendor name. The threshold defaults to 99.9 percent. 'excluded_components' names the components that your contract does not cover, for example a status page or a docs site. An entry this Actor cannot read gets its own row and does not stop the run.",
            "default": [
              {
                "name": "GitHub",
                "status_json_url": "https://www.githubstatus.com/api/v2/incidents.json",
                "sla_threshold_pct": 99.9,
                "excluded_components": []
              },
              {
                "name": "Cloudflare",
                "status_json_url": "https://www.cloudflarestatus.com/api/v2/incidents.json",
                "sla_threshold_pct": 99.99,
                "excluded_components": []
              },
              {
                "name": "OpenAI",
                "status_json_url": "https://status.openai.com/api/v2/incidents.json",
                "sla_threshold_pct": 99.9,
                "excluded_components": []
              }
            ]
          },
          "periodStart": {
            "title": "Period start (UTC)",
            "type": "string",
            "description": "The first instant of the billing period, as a date such as 2026-08-01 or a timestamp such as 2026-08-01T00:00:00Z. A date begins at 00:00 UTC. Leave both period fields empty to report the last complete calendar month, which keeps a monthly schedule correct for ever.",
            "default": ""
          },
          "periodEnd": {
            "title": "Period end (UTC)",
            "type": "string",
            "description": "The last instant of the billing period. A date such as 2026-08-31 covers the whole of that day, so the period ends at 2026-09-01T00:00:00Z. A timestamp is used exactly. The period must be at most 400 days. A period that has not finished is measured up to now, and the report says so.",
            "default": ""
          },
          "downtimeImpacts": {
            "title": "Severities that count as downtime",
            "type": "array",
            "description": "An incident of one of these severities removes its minutes from the uptime number. Most contracts treat only a major or a critical incident as downtime, and call a minor incident degradation. An incident of any other severity is still reported and still carries its minutes, but it does not change the uptime number. Planned maintenance never counts.",
            "items": {
              "type": "string",
              "enum": [
                "critical",
                "major",
                "minor",
                "none"
              ],
              "enumTitles": [
                "critical (full outage)",
                "major (partial outage)",
                "minor (degraded performance)",
                "none (informational)"
              ]
            },
            "default": [
              "critical",
              "major"
            ]
          },
          "maxHistoryPages": {
            "title": "History pages for each vendor",
            "minimum": 0,
            "maximum": 8,
            "type": "integer",
            "description": "The public Statuspage API answers with the 50 most recent incidents only, and it states no retention window, so a period that reaches behind its oldest incident is reported as partial coverage. The run then adds the history pages of the same status page, which hold three months each, until the period is covered. Raise this for a period longer than nine months. Set 0 to read the given URL alone. Not every status page serves a history page; when it does not, the report says so and still gives the number.",
            "default": 3
          },
          "maxIncidentsPerReport": {
            "title": "Incidents in each report",
            "minimum": 1,
            "maximum": 1000,
            "type": "integer",
            "description": "The largest number of incident records kept in the evidence list of one vendor row. The longest incidents are kept first, because they carry the claim. The counts and the uptime number always use every incident.",
            "default": 200
          },
          "requestTimeoutSeconds": {
            "title": "Request timeout (seconds)",
            "minimum": 5,
            "maximum": 120,
            "type": "integer",
            "description": "Timeout for each JSON read. One vendor needs one to four reads.",
            "default": 30
          },
          "concurrency": {
            "title": "Concurrency",
            "minimum": 1,
            "maximum": 10,
            "type": "integer",
            "description": "The largest number of vendors read at the same time. A public status page refuses a burst, so a small number is safer.",
            "default": 5
          },
          "maxRedirects": {
            "title": "Redirects",
            "minimum": 0,
            "maximum": 10,
            "type": "integer",
            "description": "The largest number of redirects followed for one read. Every hop is checked again against the private-address rule.",
            "default": 5
          },
          "maxResponseBytes": {
            "title": "Response size cap (bytes)",
            "minimum": 10000,
            "maximum": 10000000,
            "type": "integer",
            "description": "A JSON answer larger than this cap is refused, and the vendor is reported as unreadable.",
            "default": 5000000
          }
        }
      },
      "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
                  }
                }
              }
            }
          }
        }
      }
    }
  }
}