{
  "openapi": "3.0.1",
  "info": {
    "title": "Snapshot History for the Wayback Machine: URLs & Domains",
    "description": "List archived snapshots of URLs and domains from the Internet Archive Wayback Machine: date, archive link, status code, MIME type, digest and size. Filter by date, status and type, keep one per day, month or year, or get the one closest to a date. Pay per snapshot.",
    "version": "0.1",
    "x-build-id": "t2N4XIqWgfXkH51bX"
  },
  "servers": [
    {
      "url": "https://api.apify.com/v2"
    }
  ],
  "paths": {
    "/acts/forgeloop~wayback-snapshots/run-sync-get-dataset-items": {
      "post": {
        "operationId": "run-sync-get-dataset-items-forgeloop-wayback-snapshots",
        "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/forgeloop~wayback-snapshots/runs": {
      "post": {
        "operationId": "runs-sync-forgeloop-wayback-snapshots",
        "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/forgeloop~wayback-snapshots/run-sync": {
      "post": {
        "operationId": "run-sync-forgeloop-wayback-snapshots",
        "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": [
          "targets"
        ],
        "properties": {
          "targets": {
            "title": "URLs or domains",
            "type": "array",
            "description": "URLs or domains to look up, like \"example.com\" or \"https://www.python.org/about/\". A value like \"*.example.com\" uses domain matching and \"example.com/blog/*\" uses prefix matching, whatever the match type below says. Duplicates are removed. Format: a list of strings.",
            "items": {
              "type": "string"
            }
          },
          "mode": {
            "title": "Mode",
            "enum": [
              "snapshots",
              "closest"
            ],
            "type": "string",
            "description": "snapshots: list the archived snapshots of each target. closest: return the one snapshot of each URL closest to the date below, or the newest one when the date is empty.",
            "default": "snapshots"
          },
          "matchType": {
            "title": "Match type",
            "enum": [
              "exact",
              "prefix",
              "host",
              "domain"
            ],
            "type": "string",
            "description": "Snapshots mode only. exact: only this URL. prefix: all URLs that start with this URL, for example a folder. host: all URLs on this host name. domain: all URLs on the domain and its subdomains.",
            "default": "exact"
          },
          "from": {
            "title": "From date",
            "type": "string",
            "description": "Snapshots mode only. First capture date to include, like 2015, 2015-06 or 2015-06-01. Empty means from the start."
          },
          "to": {
            "title": "To date",
            "type": "string",
            "description": "Snapshots mode only. Last capture date to include, like 2020, 2020-12 or 2020-12-31. Empty means up to today."
          },
          "collapse": {
            "title": "Collapse",
            "enum": [
              "none",
              "digest",
              "urlkey",
              "hour",
              "day",
              "month",
              "year"
            ],
            "type": "string",
            "description": "Snapshots mode only. Keep one snapshot per hour, day, month or year, one per unique URL, or only snapshots whose content changed (digest). Collapsing compares each capture with the one before it in the list. The README explains how this works with prefix, host and domain matching.",
            "default": "none"
          },
          "limit": {
            "title": "Max snapshots per target",
            "minimum": 1,
            "maximum": 100000,
            "type": "integer",
            "description": "Snapshots mode only. Stop after this many snapshots per target, oldest first. Every snapshot is one charged result, so this also caps the cost.",
            "default": 100
          },
          "statusCodes": {
            "title": "Status codes",
            "type": "array",
            "description": "Snapshots mode only. Keep only snapshots with these HTTP status codes, like 200, 301 or 3xx. Empty keeps all.",
            "items": {
              "type": "string"
            }
          },
          "mimeTypes": {
            "title": "MIME types",
            "type": "array",
            "description": "Snapshots mode only. Keep only snapshots of these types, like text/html, application/pdf or image/*. Empty keeps all.",
            "items": {
              "type": "string"
            }
          },
          "closestTo": {
            "title": "Closest to date",
            "type": "string",
            "description": "Closest mode only. Date to search around, like 2010, 2010-06-15 or 20100615. Empty returns the newest snapshot."
          },
          "includeSummary": {
            "title": "Summary per target",
            "type": "boolean",
            "description": "Store first seen, last seen, count and snapshots per year for each target in the key-value store under OUTPUT. Free.",
            "default": true
          },
          "resumeKey": {
            "title": "Resume key",
            "type": "string",
            "description": "Continue an earlier query that hit the limit. Copy nextResumeKey from the summary of that run and keep the single target and all other settings the same."
          },
          "timeoutSecs": {
            "title": "Timeout (seconds)",
            "minimum": 10,
            "maximum": 300,
            "type": "integer",
            "description": "Give up on one request after this many seconds without an answer. Large domain queries can take a minute. Failed requests are retried with a growing pause.",
            "default": 90
          }
        }
      },
      "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
                  }
                }
              }
            }
          }
        }
      }
    }
  }
}