TopicTrace

TopicTrace API

Topics over time, as data.

Follow any topic (people, policies, markets) through time, from your own code: AI-written summaries from daily snapshots up to yearly overviews, each with links back to its sources.

TopicTrace turns the ongoing coverage of a topic into a timeline you can query: what happened, when, and where it was reported.

What you get

Ask for a topic and a time frame and you get back the summary for that day, week, month, quarter or year, with the source links behind it. So you can check a claim, or trace a keyword back to where it appeared.

  • Summaries at every scale: daily through yearly, for each topic
  • Context that builds: each summary draws on the coverage collected over its period, not a handful of links
  • Evidence you can check: source URLs, and keywords mapped to the sources they came from
  • Ready to work with: topics, dates, summaries and metadata in one consistent shape
Read the docs and try the playground →

TopicTrace is in beta and changing often. More topics, and more ways to explore them, are on the way.

TopicTrace API Documentation

The API gives you TopicTrace's timelines as data. Look up the topics, pull their summaries by day, week, month, quarter or year, then fetch the keywords and source URLs behind each one to trace it back to the original reporting.

  • Topics catalog with coverage date ranges
  • Time-indexed summaries (daily → yearly) per topic
  • Sentiment + source counts for trend scanning
  • Keyword-to-source URLs to validate and explore evidence

Need a key? Request one and start pulling data.

Request Access ↓

Already have a key? Try a call right here, in the playground.

Try API Playground ↓

API Host

https://tohblpcjhzaxivhxkecm.supabase.co/functions/v1

Gateway Path

All requests go through the gateway function below. Specify the target operation using the endpoint query parameter.

/topics?endpoint=...

Authentication

All API requests include two headers:

  • Authorization: Supabase anon token (public) used to call the edge function
  • X-Api-Key: your TopicTrace API key (used for access + rate limits)

Your TopicTrace API key controls what you can access and how much you can call the API.

curl \ -H "Authorization: Bearer YOUR_BEARER_TOKEN" \ -H "X-Api-Key: YOUR_API_KEY" \ "https://tohblpcjhzaxivhxkecm.supabase.co/functions/v1/topics?endpoint=topics"

Quick Start

  1. Call topics to get a topic_hash and coverage dates.
  2. Use content_daily, content_weekly, or content_monthly to pull summaries.
  3. Use the matching *_keyword_source endpoint to retrieve keywords and traceable source URLs.

Request Format

Specify the endpoint using the endpoint query parameter. Additional parameters are passed as query parameters.

Rate Limits

Rate limits are enforced per API key based on your plan. Response headers include X-RateLimit-Limit and X-RateLimit-Remaining to track your usage.

Coverage & Backfills

Current coverage begins in August 2026 and expands over time. Historical backfills (e.g., to 2010 for a topic) are available on request for paid plans.

Core Endpoints

GET topics Core ▼

Returns a list of all available topics with their full hierarchy of subtopics. Use this to discover what topics are available for tracking.

Parameters

None required

Response Fields
hash — TEXT: Unique identifier for the topic
topic — TEXT: Main topic name
subtopic — TEXT: Primary subtopic
subtopic1-9 — TEXT: Additional subtopic levels
min_date — INTEGER: Earliest available date (YYYYMMDD)
max_date — INTEGER: Latest available date (YYYYMMDD)
Example Request
curl -H "Authorization: Bearer TOKEN" -H "X-Api-Key: KEY" \ "https://tohblpcjhzaxivhxkecm.supabase.co/functions/v1/topics?endpoint=topics"
GET dates Core ▼

Returns date dimension information for a specific month, including week numbers, day names, and ISO week data. Useful for building calendar views.

Parameters
Parameter Type Description
p_year required INTEGER The year (e.g., 2026)
p_month required INTEGER The month (1-12)
Response Fields
date — INTEGER: Date ID (YYYYMMDD format)
year — INTEGER: Calendar year
quarter — INTEGER: Quarter (1-4)
month — INTEGER: Month (1-12)
month_name — TEXT: Full month name
week — INTEGER: Week of month
day — INTEGER: Day of month
day_of_week — INTEGER: Day of week (1-7)
day_name — TEXT: Full day name
is_weekend — INTEGER: 1 if weekend, 0 otherwise
iso_year — INTEGER: ISO year
iso_week — INTEGER: ISO week number
week_start_date — INTEGER: Start date of the week
week_end_date — INTEGER: End date of the week
Example Request
curl -H "Authorization: Bearer TOKEN" -H "X-Api-Key: KEY" \ "https://tohblpcjhzaxivhxkecm.supabase.co/functions/v1/topics?endpoint=dates&p_year=2026&p_month=10"
GET topic_overview Core ▼

Returns overview content for all topics. Perfect for building topic landing pages.

Parameters

None required

Response Fields
topic_hash — TEXT: Unique topic identifier
content — TEXT: Full overview content
Example Request
curl -H "Authorization: Bearer TOKEN" -H "X-Api-Key: KEY" \ "https://tohblpcjhzaxivhxkecm.supabase.co/functions/v1/topics?endpoint=topic_overview"

Content Endpoints

GET content_daily Content ▼

Returns daily content summaries for a specific topic and month. Includes sentiment analysis and source count.

Parameters
Parameter Type Description
p_topic_hash required TEXT Topic hash identifier
p_year required INTEGER The year
p_month required INTEGER The month (1-12)
Response Fields
topic_hash — TEXT: Topic identifier
year — INTEGER: Year
iso_year — INTEGER: ISO year
quarter — INTEGER: Quarter
month — INTEGER: Month
week — INTEGER: Week of month
iso_week — INTEGER: ISO week
date_id — INTEGER: Date ID (YYYYMMDD)
sentiment — TEXT: Sentiment (positive/neutral/negative)
content — TEXT: Full content
source_count — INTEGER: Number of sources
Example Request
curl -H "Authorization: Bearer TOKEN" -H "X-Api-Key: KEY" \ "https://tohblpcjhzaxivhxkecm.supabase.co/functions/v1/topics?endpoint=content_daily&p_topic_hash=YOUR_TOPIC_HASH&p_year=2026&p_month=10"
GET content_weekly Content ▼

Returns weekly aggregated content summaries for a topic throughout a year. Summaries consolidate daily updates into weekly overviews.

Parameters
Parameter Type Description
p_topic_hash required TEXT Topic hash identifier
p_year required INTEGER The year
Response Fields
topic_hash — TEXT: Topic identifier
year — INTEGER: Year
iso_year — INTEGER: ISO year
quarter — INTEGER: Quarter
month — INTEGER: Month
iso_week — INTEGER: ISO week number
start_date — INTEGER: Week start date
end_date — INTEGER: Week end date
sentiment — TEXT: Overall sentiment
content — TEXT: Full weekly summary
source_count — INTEGER: Total sources
Example Request
curl -H "Authorization: Bearer TOKEN" -H "X-Api-Key: KEY" \ "https://tohblpcjhzaxivhxkecm.supabase.co/functions/v1/topics?endpoint=content_weekly&p_topic_hash=YOUR_TOPIC_HASH&p_year=2026"
GET content_monthly Content ▼

Returns monthly aggregated content for a topic in a given year. Provides high-level monthly summaries with sentiment and sources.

Parameters
Parameter Type Description
p_topic_hash required TEXT Topic hash identifier
p_year required INTEGER The year
Response Fields
topic_hash — TEXT: Topic identifier
year — INTEGER: Year
quarter — INTEGER: Quarter
month — INTEGER: Month
start_date — INTEGER: Month start date
end_date — INTEGER: Month end date
sentiment — TEXT: Monthly sentiment
content — TEXT: Full monthly summary
source_count — INTEGER: Total sources
Example Request
curl -H "Authorization: Bearer TOKEN" -H "X-Api-Key: KEY" \ "https://tohblpcjhzaxivhxkecm.supabase.co/functions/v1/topics?endpoint=content_monthly&p_topic_hash=YOUR_TOPIC_HASH&p_year=2026"
GET content_quarterly Content ▼

Returns quarterly content summaries for a topic in a specific year. Ideal for Q1-Q4 reporting and trend analysis.

Parameters
Parameter Type Description
p_topic_hash required TEXT Topic hash identifier
p_year required INTEGER The year
Response Fields
topic_hash — TEXT: Topic identifier
year — INTEGER: Year
quarter — INTEGER: Quarter (1-4)
start_date — INTEGER: Quarter start
end_date — INTEGER: Quarter end
sentiment — TEXT: Quarterly sentiment
content — TEXT: Full quarterly summary
source_count — INTEGER: Total sources
Example Request
curl -H "Authorization: Bearer TOKEN" -H "X-Api-Key: KEY" \ "https://tohblpcjhzaxivhxkecm.supabase.co/functions/v1/topics?endpoint=content_quarterly&p_topic_hash=YOUR_TOPIC_HASH&p_year=2026"
GET content_yearly Content ▼

Returns yearly content summaries for a topic across all available years. Best for long-term trend analysis and year-over-year comparisons.

Parameters
Parameter Type Description
p_topic_hash required TEXT Topic hash identifier
Response Fields
topic_hash — TEXT: Topic identifier
year — INTEGER: Year
start_date — INTEGER: Year start date
end_date — INTEGER: Year end date
sentiment — TEXT: Yearly sentiment
content — TEXT: Full yearly summary
source_count — INTEGER: Total sources
Example Request
curl -H "Authorization: Bearer TOKEN" -H "X-Api-Key: KEY" \ "https://tohblpcjhzaxivhxkecm.supabase.co/functions/v1/topics?endpoint=content_yearly&p_topic_hash=YOUR_TOPIC_HASH"

Source & Keyword Endpoints

GET content_daily_keyword_source Sources ▼

Returns detailed keyword and source information for a specific daily content entry. Includes relevance scores and primary source indicators.

Parameters
Parameter Type Description
p_topic_hash required TEXT Topic hash identifier
p_date_id required INTEGER Date ID (YYYYMMDD format)
Response Fields
topic_hash — TEXT: Topic identifier
date_id — INTEGER: Date ID
keyword — TEXT: Associated keyword
source_url — TEXT: Source URL
source_name — TEXT: Source display name
relevance_score — REAL: Relevance score (0-1)
confidence_score — REAL: Confidence score (0-1)
is_primary — BOOLEAN: Primary source flag
Example Request
curl -H "Authorization: Bearer TOKEN" -H "X-Api-Key: KEY" \ "https://tohblpcjhzaxivhxkecm.supabase.co/functions/v1/topics?endpoint=content_daily_keyword_source&p_topic_hash=YOUR_TOPIC_HASH&p_date_id=20261015"
GET content_weekly_keyword_source Sources ▼

Returns keyword and source data for a specific ISO week's content.

Parameters
Parameter Type Description
p_topic_hash required TEXT Topic hash identifier
p_iso_year required INTEGER ISO year
p_iso_week required INTEGER ISO week number (1-53)
Response Fields
topic_hash — TEXT: Topic identifier
iso_year — INTEGER: ISO year
iso_week — INTEGER: ISO week
keyword — TEXT: Associated keyword
source_url — TEXT: Source URL
source_name — TEXT: Source name
relevance_score — REAL: Relevance (0-1)
confidence_score — REAL: Confidence (0-1)
is_primary — BOOLEAN: Primary source
Example Request
curl -H "Authorization: Bearer TOKEN" -H "X-Api-Key: KEY" \ "https://tohblpcjhzaxivhxkecm.supabase.co/functions/v1/topics?endpoint=content_weekly_keyword_source&p_topic_hash=YOUR_TOPIC_HASH&p_iso_year=2026&p_iso_week=42"
GET content_monthly_keyword_source Sources ▼

Returns keyword and source data for a specific month's content.

Parameters
Parameter Type Description
p_topic_hash required TEXT Topic hash identifier
p_year required INTEGER The year
p_month required INTEGER The month (1-12)
Response Fields
topic_hash — TEXT: Topic identifier
year — INTEGER: Year
month — INTEGER: Month
keyword — TEXT: Associated keyword
source_url — TEXT: Source URL
source_name — TEXT: Source name
relevance_score — REAL: Relevance (0-1)
confidence_score — REAL: Confidence (0-1)
is_primary — BOOLEAN: Primary source
Example Request
curl -H "Authorization: Bearer TOKEN" -H "X-Api-Key: KEY" \ "https://tohblpcjhzaxivhxkecm.supabase.co/functions/v1/topics?endpoint=content_monthly_keyword_source&p_topic_hash=YOUR_TOPIC_HASH&p_year=2026&p_month=10"
GET content_quarterly_keyword_source Sources ▼

Returns keyword and source data for a specific quarter's content.

Parameters
Parameter Type Description
p_topic_hash required TEXT Topic hash identifier
p_year required INTEGER The year
p_quarter required INTEGER The quarter (1-4)
Response Fields
topic_hash — TEXT: Topic identifier
year — INTEGER: Year
quarter — INTEGER: Quarter
keyword — TEXT: Associated keyword
source_url — TEXT: Source URL
source_name — TEXT: Source name
relevance_score — REAL: Relevance (0-1)
confidence_score — REAL: Confidence (0-1)
is_primary — BOOLEAN: Primary source
Example Request
curl -H "Authorization: Bearer TOKEN" -H "X-Api-Key: KEY" \ "https://tohblpcjhzaxivhxkecm.supabase.co/functions/v1/topics?endpoint=content_quarterly_keyword_source&p_topic_hash=YOUR_TOPIC_HASH&p_year=2026&p_quarter=4"
GET content_yearly_keyword_source Sources ▼

Returns keyword and source data for a specific year's content.

Parameters
Parameter Type Description
p_topic_hash required TEXT Topic hash identifier
p_year required INTEGER The year
Response Fields
topic_hash — TEXT: Topic identifier
year — INTEGER: Year
keyword — TEXT: Associated keyword
source_url — TEXT: Source URL
source_name — TEXT: Source name
relevance_score — REAL: Relevance (0-1)
confidence_score — REAL: Confidence (0-1)
is_primary — BOOLEAN: Primary source
Example Request
curl -H "Authorization: Bearer TOKEN" -H "X-Api-Key: KEY" \ "https://tohblpcjhzaxivhxkecm.supabase.co/functions/v1/topics?endpoint=content_yearly_keyword_source&p_topic_hash=YOUR_TOPIC_HASH&p_year=2026"

Error Codes

Code Description
400 Bad Request — Missing or invalid endpoint parameter
401 Unauthorized — Missing or invalid API key
403 Forbidden — API key revoked or endpoint not allowed for your plan
413 Payload Too Large — Response exceeds max_rows_per_call limit
429 Too Many Requests — Monthly request limit exceeded
500 Internal Server Error — RPC or system failure

FAQ

Is this a news API?

Not quite. TopicTrace doesn't hand you articles. It follows the coverage of a topic and gives you summaries over time, with the source URLs so you can go to the original.

How is this different from asking an LLM?

Ask an LLM about a topic and you get one answer, drawn from the few pages it found just then. TopicTrace follows the topic over time, so its summaries are built from coverage collected along the way and arranged from daily to yearly, with links to the evidence.

Do you provide raw articles?

No. You get summaries, keywords and source URLs, so you can read the original coverage where it was published.

Request API Access

Free Plan: 200 rows per request · 200 calls/month · rate limits enforced per API key

Get Your API Key

Building something with TopicTrace data? Tell me a little about it below and I'll get you set up.

Your email client will open with a pre-filled message. Please send the email to complete your request.

I read every request myself and usually reply within 1-2 business days.

Having trouble with the form? You can also send your request directly to topictrace@gmail.com with the following information:
  • Your Name
  • Your Email address
  • A Message describing your use case and requirements

API Playground

Test the API

Already have a key? Run any endpoint from this page and see what comes back.

Response