AllSides APIallsides.com ↗
Access AllSides media bias ratings, balanced news roundups, and perspective-filtered headlines via 5 endpoints. Compare Left, Center, and Right coverage of the same stories.
What is the AllSides API?
The AllSides API exposes 5 endpoints covering media bias ratings, multi-perspective headline roundups, and keyword search across AllSides content. Use get_headline_roundup_detail to pull a single story's articles grouped by Left, Center, and Right perspective alongside source names and headlines, or call get_media_bias_ratings to retrieve paginated bias scores and rating images for hundreds of news outlets.
No input parameters required.
curl -X GET 'https://api.parse.bot/scraper/aeaabc35-896b-4ab6-a8f7-1f9f4240d41a/get_headline_roundups' \ -H 'X-API-Key: $PARSE_API_KEY'
Typed, relational, agent-ready
A generated client with real types, enums, and the links between objects — the structure a flat JSON response can't carry. Autocompletes in your editor and reads cleanly to coding agents.
- Fully typed · autocompletes
- Objects link to objects
- Typed errors & pagination
Typed Python client. Set up the SDK in your uv project, then pull this API’s typed client:
uv add parse-sdk uv run parse init uv run parse add --marketplace allsides-com-api
uv run parse add --marketplace pulls a pinned snapshot of this canonical API — it won’t change underneath you. To customize it, subscribe and swap to your own copy.
"""Walkthrough: AllSides SDK — balanced news, media bias ratings, and multi-perspective roundups."""
from parse_apis.allsides_api import AllSides, Perspective, RoundupNotFound
client = AllSides()
# List recent headline roundups — each groups Left/Center/Right coverage of one story.
for roundup in client.roundups.list(limit=3):
print(roundup.title, roundup.perspectives)
# Drill into the first roundup's sub-resource articles for per-perspective detail.
roundup = client.roundups.list(limit=1).first()
if roundup:
for article in roundup.articles.list(limit=5):
print(article.perspective, article.headline, article.source)
# Filter current news by political perspective using the Perspective enum.
for article in client.newsarticles.list_by_perspective(perspective=Perspective.RIGHT, limit=5):
print(article.headline, article.link)
# Browse media bias ratings — paginated, returns source name + bias label.
for source in client.mediasources.list(limit=5):
print(source.name, source.bias, source.slug)
# Search across all AllSides content by keyword.
for result in client.searchresults.search(query="immigration", limit=5):
print(result.title, result.source, result.type)
# Typed error handling: catch RoundupNotFound when a slug is invalid.
try:
bad_roundup = client.roundups.list(limit=1).first()
if bad_roundup:
for art in bad_roundup.articles.list(limit=1):
print(art.headline)
except RoundupNotFound as exc:
print(f"Roundup gone: {exc}")
print("exercised: roundups.list / roundup.articles.list / newsarticles.list_by_perspective / mediasources.list / searchresults.search")
Fetch recent headline roundups from AllSides. Each roundup groups articles from Left, Center, and Right perspectives on a single news story. Returns all roundups currently displayed on the recent roundups page — no pagination, no filtering.
No input parameters required.
{
"type": "object",
"fields": {
"roundups": "array of headline roundup summaries with title, link, date, and perspective labels"
},
"sample": {
"data": {
"roundups": [
{
"date": null,
"link": "https://www.allsides.com/story/elections-graham-platner-wins-senate-nomination-democrats-divided-future-party",
"title": "Graham Platner Wins Senate Nomination, Democrats Divided on Future of Party",
"perspectives": [
"From the Center",
"From the Left",
"From the Right"
]
}
]
},
"status": "success"
}
}About the AllSides API
Headline Roundups and Perspectives
The get_headline_roundups endpoint returns a list of story roundups, each with a title, link, date, and perspective labels. To drill into a specific story, pass its slug (e.g. /story/china-us-china-negotiations-who-has-upper-hand) to get_headline_roundup_detail, which returns an articles array where each item carries a perspective field (Left, Center, or Right), a headline, the originating source, and a link. A tags array and a summary field are also included at the roundup level.
Perspective-Filtered News Feed
get_news_articles_by_perspective accepts a single required perspective parameter — Left, Center, or Right — and returns the current balanced news feed filtered to that political category. Each article object includes headline, link, source, and perspective. This is useful for monitoring how outlets of a specific lean are covering breaking topics at any given moment.
Media Bias Ratings
get_media_bias_ratings provides paginated access to AllSides bias assessments for news sources. Pagination is zero-based via the page parameter, and an optional featured boolean narrows results to highlighted sources. Each record in the sources array includes name, slug, bias (the rating label), and bias_image (a URL to the visual rating indicator). The total field in the response tells you how many sources match your filter.
Search
search_allsides takes a required query string and an optional zero-based page integer. Results include title, link, source, snippet, and type — the content type field lets you distinguish between news articles, media bias pages, and other AllSides content types in a single query.
The AllSides API is a managed, monitored endpoint for allsides.com — not a raw scraper you maintain. Every endpoint is automatically health-checked on a schedule, and when allsides.com changes and a check fails, the API is automatically queued for repair and re-verified. It is built to keep working as the site underneath it changes.
This isn't an official allsides.com API — it's an independent, maintained REST wrapper over public data. Where the source has no official API (or only a limited one), Parse gives you a stable contract over a source that never promised one, and keeps it current. Need a new endpoint or field? You can revise it yourself in plain English and the agent rebuilds it against the live site in minutes — contributing the change back to the shared API is free.
Will this API break when the source site changes?+
Is this an official API from the source site?+
Can I fix or extend this API myself if I need a new endpoint or field?+
What happens if I call an endpoint that has an issue?+
- Build a media bias lookup tool that shows a news outlet's
biasrating andbias_imagefromget_media_bias_ratings. - Aggregate Left, Center, and Right coverage of the same event by fetching
get_headline_roundup_detailfor a given story slug. - Monitor breaking news from a specific political lean by polling
get_news_articles_by_perspectivewith theLeft,Center, orRightparameter. - Populate a research dashboard with paginated bias ratings for hundreds of sources using the
pageandfeaturedfilters. - Search AllSides content by keyword with
search_allsidesto surface relevant story roundups, bias pages, or articles bytype. - Compare how headline framing differs across perspectives for the same story using the
headlineandsourcefields in roundup detail responses. - Tag news articles in a dataset with bias context by matching source names against
get_media_bias_ratingsresults.
| Tier | Price | Credits/month | Rate limit |
|---|---|---|---|
| Free | $0/mo | 100 | 5 req/min |
| Hobby | $30/mo | 1,000 | 20 req/min |
| Developer | $100/mo | 5,000 | 100 req/min |
One credit = one API call regardless of which marketplace API you call. Exceeding the rate limit returns a 429 response. Authenticate with the X-API-Key header.
Does AllSides offer an official developer API?+
What does `get_headline_roundup_detail` return beyond the article list?+
articles array (each with perspective, headline, source, and link), the response includes a top-level headline string for the roundup, a summary field, and a tags array. The slug parameter accepts either a path like /story/topic-slug-name or a full URL.Does `get_media_bias_ratings` return individual journalist or author ratings?+
sources array returns name, slug, bias, and bias_image per outlet. You can fork this API on Parse and revise it to add an endpoint targeting individual author or journalist bias data if AllSides exposes that separately.Is there an endpoint for historical bias rating changes over time for a source?+
get_media_bias_ratings, with no historical change data. You can fork the API on Parse and revise it to add an endpoint that captures rating history if that data becomes accessible.How does pagination work in `search_allsides` and `get_media_bias_ratings`?+
page integer parameter. The response always includes a total field indicating the full count of matching records, and a page field confirming which page was returned. Start at page=0 and increment until you have retrieved all results.