Overview
Time Machine sets a cutoff for a search. Addsnapshot_as_of to a POST /search request, and each result comes from the copy of the page that Perplexity saved at or before that time. Use it when a task depends on what was knowable at an earlier moment, such as evaluating an agent on questions with known answers or backtesting a forecast.
Each time Perplexity reads a page for its web index, it saves a copy with the time it was saved. A search with snapshot_as_of uses those copies:
- Search looks only at pages published by the cutoff.
- The cutoff is compared with the time a copy was saved, not with a date shown on the page.
- Each result uses the page’s latest copy saved at or before the cutoff. Its
title,snippet, anddatecome from that copy.
Search as of a past time
This request searches python.org as the web was 30 days ago. First, install a library and setPERPLEXITY_API_KEY.
Read pages at the same time
A search result has a snippet, not the full page. To read the pages a search found, send their URLs to the Context API with the samesnapshot_as_of. Both steps then use the same cutoff.
Errors
A request that breaks one of the rules above returns HTTP 400 with"type": "invalid_request":
Next Steps
Context API: Pages at a Past Time
Read full pages as they were stored at or before a time.
Domain Filter
Include or exclude specific domains, paths, and top-level domains.
How Search Works
Result fields, several queries per request, and request limits.
API Reference
Every request parameter, the response schema, and error responses.