To add a URL through ArchiveBox’s REST API, first inspect the interactive API documentation on your own running instance at /api/v1/docs. The official material confirms how to authenticate and list snapshot records, but does not establish a universal REST route or request body for adding a URL—or a universal field that proves a capture is complete. Use the schema for your installed version rather than guessing. For a documented local alternative, run archivebox add 'https://example.com'.
Find the API schema for your ArchiveBox instance
Open http://api.archivebox.localhost:5797/api/v1/docs as an example, replacing the host and port with the address configured for your deployment. The interactive API docs are served by the instance, so they are the relevant place to confirm available routes, methods, request bodies, response fields, and permissions.
The REST API has been available since ArchiveBox v0.8.0, and the project labels it alpha. Treat its schema and behavior as version-dependent; do not assume that a route or payload found elsewhere applies to your installation. See the ArchiveBox authentication guide and the project repository.
Authenticate and list snapshot records
Get an API token
Create a token in the Admin UI, or request one from the documented endpoint. Replace the example host and credentials with those for your installation:
The Tool Desk
Outbyte Driver Updater FREEFix the driver behind crashes, sound loss and screen glitchesFind Drivers →Outbyte PC Repair FREERepair Windows errors before they cause bigger problemsFix Now →#1 Best Overall
curl -X POST 'http://api.archivebox.localhost:5797/api/v1/auth/get_api_token'
-H 'Content-Type: application/json'
-d '{"username":"YOURUSERNAMEHERE","password":"YOURPASSWORDHERE"}'
Use the returned token in the Authorization: Bearer header for authenticated requests. The guide also documents X-ArchiveBox-API-Key for setups where a reverse proxy consumes the bearer header. Avoid placing a key in a URL query parameter unless you understand the exposure risk: anyone who obtains that URL may be able to use the API.
List snapshot records
This documented request retrieves up to 10 snapshot records:
Rank #2
curl -X GET 'http://api.archivebox.localhost:5797/api/v1/core/snapshots?limit=10'
-H 'accept: application/json'
-H 'Authorization: Bearer YOURAPITOKENHERE'
Use the response to inspect records, then consult your instance’s interactive schema for the fields it returns. A snapshot listing is not, by itself, proof that a capture finished successfully.
Add a URL: choose a verified route or a local workflow
REST API: confirm the add operation before sending a request
The REST materials establish authentication and snapshot listing, but do not establish an authoritative URL-submission endpoint, HTTP method, payload format, or response contract that applies across installations. In /api/v1/docs, locate the operation for creating or adding a snapshot, if present, and verify its method, required body, authentication requirements, and response before integrating it. Do not infer a REST endpoint from the CLI syntax or Python function signature.
Rank #3
CLI: add a URL locally
When you can run commands in the ArchiveBox environment, the documented CLI forms are:
archivebox add 'https://example.com'
To import URLs from standard input or a file:
echo 'https://example.com' | archivebox add
cat urls_to_archive.txt | archivebox add
archivebox add < urls_to_archive.txt
The CLI also documents --depth=1 to include one-hop outlinks, and imports from formats including RSS, XML, Netscape bookmarks, and text containing URLs. See the ArchiveBox usage documentation for the supported forms and options.
Rank #4
Python: call the local library
For a process running in the ArchiveBox data directory and Python environment, the usage documentation shows this local-library pattern:
import os
from pathlib import Path
DATA_DIR = Path("~/archivebox/data").expanduser()
os.chdir(DATA_DIR)
from archivebox.config.django import setup_django
setup_django(check_db=True)
from archivebox.cli.archivebox_add import add
crawl, snapshots = add(urls=["https://example.com"], index_only=True)
print(crawl.id, list(snapshots.values_list("id", flat=True)))
This is Python code for local use, not a REST request recipe. It requires access to the data directory and the installed ArchiveBox Python environment. Confirm compatibility with the installed version; the project describes its Python API as beta.
Best Value
Check whether a capture finished
The documented REST example shows how to list snapshots at /api/v1/core/snapshots. The reviewed API guidance does not establish a universal completion field, synchronous-versus-asynchronous behavior, or polling interval. Inspect the response schema and lifecycle behavior exposed by your own instance before writing status logic. Do not treat the presence of a snapshot record as a completion guarantee.
For local operational checks, the installation guidance documents archivebox list and archivebox status. These can help inspect snapshots and collection health, but they are not documented as equivalents of a particular REST status field. See the installation and usage documentation.
Choose the integration that fits your deployment
| Method | Where it runs | What it requires | What is established |
|---|---|---|---|
| REST API | Over HTTP to your ArchiveBox server | Instance URL and API authentication | Token authentication and snapshot listing are documented; add-route details and completion semantics must be checked in the running instance’s schema. REST API is labeled alpha. |
| CLI | On a host with ArchiveBox installed | Command-line access and local environment | Adding a URL and importing URL lists and several feed/bookmark formats are documented. |
| Python library | Inside the ArchiveBox Python environment | Access to the data directory, Django setup, and installed package | A local add example is documented; the Python API is described as beta and is not a REST recipe. |
Troubleshooting
- The docs URL does not open: use the hostname, port, and scheme configured for your instance, then append
/api/v1/docs. The documented localhost address is only an example. - Authentication fails: confirm that the token was obtained for this installation and is sent as
Authorization: Bearer TOKEN. If a reverse proxy consumes that header, check whether your setup requires the documentedX-ArchiveBox-API-Keyheader. - You cannot find a URL-add endpoint: do not guess the route from CLI or Python examples. Check the installed instance’s schema; if the operation is unavailable there, use the documented CLI or local Python workflow.
- A snapshot appears but you cannot confirm completion: inspect the instance’s response schema and documented lifecycle behavior. The listing example alone does not define a completion flag or polling schedule.
- The local Python example fails: ensure the process is using the correct ArchiveBox data directory and Python environment, and that Django setup runs before importing and calling
add.
Or skip the browser setup
If your goal is a screenshot or PDF rather than preserving a full ArchiveBox snapshot, ScreenshotNeo provides a one-request website capture API. For example, request a PNG by changing the output filename, or use this documented WebP example:
Quick Recap
curl -G "https://api.screenshotneo.com/v1/shot" -d access_key=YOUR_API_KEY --data-urlencode url=https://example.com -o shot.webp
See the ScreenshotNeo API documentation for request options and setup. Cookie banners are accepted and removed before capture, along with known consent platforms, newsletter popups, and chat widgets. Bot checks, blank pages, failed loads, timeouts, and cache hits are not billed. Its MCP server lets AI agents use screenshot tools. The free plan includes 1,000 screenshots a month with no card; paid plans start at $5 for 3,000.
Free tools Windows power users keep installed
One-click scans. No signup required.
Sign up for ScreenshotNeo’s free plan.
Product prices and availability are accurate as of the date/time indicated and are subject to change. Any price and availability information displayed on Amazon at the time of purchase will apply.

