Time Portal · Search
Search
Time Portal search gives ranked results from the time-gated web.
Request
Send a POST request to https://api.epochal.com/v1/time-portal/search with three headers and a JSON body.
| Header | Required | Value |
|---|---|---|
x-api-key | Yes | Your API key. See Authentication. |
Accept-Datetime | Yes | The instant the request is set to: a past HTTP-date or RFC 3339 instant at or after 1970-01-01T00:00:00Z. For every form it accepts, see How the Instant Works. |
Content-Type | Yes | application/json |
curl https://api.epochal.com/v1/time-portal/search \
-H "x-api-key: $EPOCHAL_API_KEY" \
-H "Accept-Datetime: 2026-03-01T00:00:00Z" \
-H "Content-Type: application/json" \
-d '{
"query": "european battery gigafactory delays",
"num_results": 2,
"published_after": "2026-01-01T00:00:00Z"
}'Body fields
| Field | Type | Default | Description |
|---|---|---|---|
query | string, 1 to 1,000 characters | required | Search query string. |
num_results | integer, 1 to 10 | 10 | Maximum number of results to return. |
domains | array of strings (up to 2,048 chars each; max 200 combined with exclude_domains) | none | Restrict results to these hosts, paths, or public suffixes (subdomains included), e.g. example.com, example.com/blog, gov.uk. |
exclude_domains | array of strings (same syntax and shared 200 limit) | none | Exclude pages from these sites (subdomains included). Cannot overlap with domains. |
languages | array of up to 8 BCP 47 tags | none | Preferred result languages in priority order, e.g. en, pt-BR. |
published_after | RFC 3339 timestamp | none | Return only pages published on or after this timestamp. Must be earlier than Accept-Datetime. |
categories | array of category names | none | Filter to specific verticals: news, finance (SEC filings), legal (court opinions, statutes, regulations, sanctions), publications (academic articles), companies, people, or maps. Omit to search all verticals. |
include_text | boolean | false | Include each page's extracted full text in results[].text. |
Unknown fields return 400. Pass the cutoff timestamp in the Accept-Datetime header (as_of in
the request body returns 400).
Response
A 200 returns ranked results, best first, with the instant and a request id.
JSON
json
{
"as_of": "2026-03-01T00:00:00Z",
"request_id": "7c2e5f0a-93b4-4d1e-a6f8-2b0c9e4d7a15",
"results": [
{
"title": "Battery plant start pushed back to late 2027",
"url": "https://news.example.com/energy/battery-plant-delay",
"snippet": "The cell maker said commissioning would slip by three quarters…",
"published_at": "2026-02-11T06:12:00Z",
"domain": "example.com",
"language": "en",
"entity": null
},
{
"title": "Gigafactory timelines slip across Europe",
"url": "https://analysis.example.org/energy/gigafactory-timelines",
"snippet": "Three of the five plants announced for 2026 now target 2027 or later…",
"published_at": "2026-01-28T09:00:00Z",
"domain": "example.org",
"language": "en",
"entity": null
}
]
}| Field | Meaning |
|---|---|
as_of | The instant the search was set to, from Accept-Datetime. |
request_id | Identifies this request in Epochal's logs; quote it when reporting a problem. |
results | Ranked results, best first. An empty list is still a 200. |
results[].title | The page's title. |
results[].url | The page's canonical URL. |
results[].snippet | A short passage from the page that matches the query. |
results[].text | The page's extracted text. Only present when include_text is true and text is available. |
results[].published_at | When the page was published. null when unknown. |
results[].domain | The page's registrable domain, such as example.com. null when unknown. |
results[].language | The page's language as a BCP 47 tag. null when not detected. |
results[].entity | The entity when the result is from an Epochal World page. It's the entity Fetch returns for url, built from the copy of the page the result came from. null for every other result. See World Entities. |
To read a result in full, send its url to Fetch with the same Accept-Datetime.
Best practices
- Keep the query to the one question.
queryis plain text, up to 1,000 characters. - Narrow by site first.
domainsandexclude_domainstake up to 200 entries between them: a host, a host and path, or a public suffix, subdomains included. An entry can't be in both. - Name the languages the task needs.
languagestakes up to 8 BCP 47 tags, most preferred first. - Use one instant for the whole task. Every search and fetch in a run shares the same
Accept-Datetime; advancing it mid-task leaks. See How the Instant Works.
Errors
Errors use the same JSON shape as every other endpoint. Check type, not message. No error counts against your free requests.
| Status | type | What to do |
|---|---|---|
400 | invalid_request | A body field is invalid, or Accept-Datetime is missing, invalid, not in the past, or before 1970. See error.message for details. |
401 | invalid_api_key | The x-api-key header is missing, or the key is unknown, revoked, or expired. Fix the key. |
402 | free_quota_exhausted | Your organization has exhausted its free trial requests. Contact us for more. |
422 | query_refused | The query falls under the usage policy and was not billed. Do not retry the same query. |
429 | rate_limit_exceeded | Rate limit exceeded. Wait for Retry-After before retrying. |
500, 503, 504 | internal_error, service_unavailable, timeout | Something failed on Epochal's side. Retry with backoff. |
For the cause and fix of each, see Errors.
Next steps
Time Portal fetch gives an archived copy of a page from the time-gated web.
Every Time Portal request evaluates against a point-in-time cutoff specified in Accept-Datetime.
Organization and per-IP rate limits, retry behavior, and pacing guidance.
Standard JSON error envelope, HTTP status codes, sandbox failure types, and retry rules.