Wayback Machine MCP server (Python)
Project description
Wayback Machine MCP Server (Python)
A Model Context Protocol (MCP) server that provides access to the Internet Archive Wayback Machine: list snapshots and fetch archived pages. Inspired by the TypeScript server described in the LobeHub listing.
- Reference: Wayback MCP (listing) — link
- Reference: Internet Archive APIs — Wayback APIs index
- Reference: MCP server quickstart — Build an MCP Server
Features
- Tools
get_snapshots(url, from, to, limit, match_type)via Wayback CDX APIget_archived_page(url, timestamp, original)fetches archived contentsearch_items(query, mediatype, collection, fields, sort, rows, page)searches archive.org items
- Resource
wayback://{url}/{timestamp}returns the archived page content
Install
python -m venv .venv
source .venv/bin/activate
pip install -r requirements.txt
Run (stdio)
python -m wayback_mcp.server
Install as CLI
pip install wayback-mcp
wayback-mcp
Configure in MCP client
Claude Desktop settings (example):
{
"mcpServers": {
"wayback-machine": {
"command": "/usr/bin/python3",
"args": ["-m", "wayback_mcp.server"],
"env": {},
"disabled": false,
"autoApprove": []
}
}
}
Usage examples
- Tool call (snapshots):
get_snapshots(url="example.com", from="20200101", to="20201231", limit=10)
- Tool call (page):
get_archived_page(url="example.com", timestamp="20200101120000", original=true)
- Tool call (items search):
search_items(
query="title:(Wayback) AND creator:(Internet Archive)",
mediatype="texts",
fields=["identifier","title","creator","mediatype","publicdate"],
sort=["publicdate desc"],
rows=20,
page=1
)
- Resource fetch:
wayback://example.com/20200101120000
Notes
- Snapshot data via CDX API:
https://web.archive.org/cdx/search/cdx?url={url}&output=json - Page retrieval via Wayback:
https://web.archive.org/web/{timestamp}/{url}(orid_mode for original content) - Advanced item search endpoint:
https://archive.org/advancedsearch.php(JSON output)
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
wayback_mcp-0.1.1.tar.gz
(5.9 kB
view details)
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file wayback_mcp-0.1.1.tar.gz.
File metadata
- Download URL: wayback_mcp-0.1.1.tar.gz
- Upload date:
- Size: 5.9 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.12.11
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
f5cbfb43ce7707236d4681fec1bdf057c9c40d9d82fa163f55c03a8a30b342f7
|
|
| MD5 |
a8fb7f8f0df90cf310666b86d5ba0855
|
|
| BLAKE2b-256 |
3c43eb119c51ed19bacfc2d2aafb19f5e7625902e76c9dc7b57efb4b80758525
|
File details
Details for the file wayback_mcp-0.1.1-py3-none-any.whl.
File metadata
- Download URL: wayback_mcp-0.1.1-py3-none-any.whl
- Upload date:
- Size: 7.0 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.12.11
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
4dd7dd83c2a20aa73a550ee6d194fab9a37cb579e92c4d9a48cb116733fce2a7
|
|
| MD5 |
c3d9ccf3d5614057973551a5114a8ad5
|
|
| BLAKE2b-256 |
6e46f98ff1a9def78e07b784129dee2e609a8fbf5024fe1c56a5cdf8ea863a26
|