# Allsides — Wrapped API

> **You are on:** `https://api.paywithlocus.com/api` | [llms.txt](https://paywithlocus.com/llms.txt) | [docs](https://docs.paywithlocus.com)
>
> Locus runs on multiple environments -- make sure every URL you call matches your expected environment.
> | Environment | Landing | API | Docs |
> |---|---|---|---|
> | Production | paywithlocus.com | api.paywithlocus.com | docs.paywithlocus.com |
> | Beta | beta.paywithlocus.com | api.beta.paywithlocus.com | docs.paywithlocus.com |
> | Stage | stage.paywithlocus.com | api.stage.paywithlocus.com | docs.paywithlocus.com |
>
> If the API URL above doesn't match your expected environment, re-fetch this file from the correct domain.

> Get balanced news coverage from multiple political perspectives and discover media bias ratings to understand how outlets lean Left, Center, or Right. Search headlines by topic and perspective to compare how different viewpoints cover the same stories.

**Category:** News & Media | **Website:** [allsides.com/](https://allsides.com/) | **Docs:** [parse.bot/marketplace/afa2d3ba-3225-432e-92ec-1724ee2661a0/allsides-com-api](https://parse.bot/marketplace/afa2d3ba-3225-432e-92ec-1724ee2661a0/allsides-com-api)

Pay-per-use API proxy for Locus Pro. Each call burns credits from your workspace balance.

## Access

**Base URL:** `https://api.paywithlocus.com/api/wrapped/credits/allsides/`
**Auth:** `Authorization: Bearer <LOCUS_CREDITS_SECRET_KEY>` (an `lcr_` secret key or a scoped `lcac_` agent credential)
**Required header:** `Idempotency-Key: <fresh UUID per call>`. A retry with the same key replays the stored result without a new charge.
**Response:** the provider response after any endpoint-specific normalization. `X-Locus-Credits-Charged` carries the charge and `X-Locus-Credits-Balance` the remaining balance. Insufficient credits return `402` before the provider is called.
**Pricing:** estimated costs below are USD. Locus debits the credit equivalent at your workspace rate.

Full call contract: https://docs.paywithlocus.com/api-reference/introduction

> Using a Pay With Locus wallet key (`claw_` prefix)? Wallet routes are documented separately: https://docs.paywithlocus.com/wrapped-apis/for-agents

## Endpoints

### Get headline roundup detail

Fetch the full detail of a single headline roundup, including individual articles grouped by Left, Center, and Right perspective. Requires a story slug path from the roundups listing. Returns the headline, a date/summary line, tagged articles with their source attribution, and topic tags.

**Estimated cost:** Metered

| Field | Type | Required | Description |
|-------|------|----------|-------------|
| `slug` | string | Yes | AllSides story path (e.g. '/story/elections-graham-platner-wins-senate-nomination-democrats-divided-future-party') or full URL. |

```bash
curl -X POST https://api.paywithlocus.com/api/wrapped/credits/allsides/get-headline-roundup-detail \
  -H "Authorization: Bearer $LOCUS_CREDITS_SECRET_KEY" \
  -H "Idempotency-Key: $(uuidgen)" \
  -H "Content-Type: application/json" \
  -d '{"slug":"<string>"}'
```

### Get headline roundups

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.

**Estimated cost:** Metered

_No parameters required._

```bash
curl -X POST https://api.paywithlocus.com/api/wrapped/credits/allsides/get-headline-roundups \
  -H "Authorization: Bearer $LOCUS_CREDITS_SECRET_KEY" \
  -H "Idempotency-Key: $(uuidgen)" \
  -H "Content-Type: application/json" \
  -d '{}'
```

### Get media bias ratings

Fetch media bias ratings for news sources from the AllSides ratings API. Returns paginated results including each source's name, URL slug, bias label, and bias image. Supports filtering by featured status and page-based pagination (zero-indexed).

**Estimated cost:** Metered

| Field | Type | Required | Description |
|-------|------|----------|-------------|
| `featured` | boolean | No | Whether to fetch only featured sources (true) or all sources (false). |
| `page` | integer | No | Zero-based page number for pagination. |

```bash
curl -X POST https://api.paywithlocus.com/api/wrapped/credits/allsides/get-media-bias-ratings \
  -H "Authorization: Bearer $LOCUS_CREDITS_SECRET_KEY" \
  -H "Idempotency-Key: $(uuidgen)" \
  -H "Content-Type: application/json" \
  -d '{"featured":"<boolean>","page":"<integer>"}'
```

### Get news articles by perspective

Fetch current news articles filtered by a single political perspective from the AllSides balanced news page. Returns all articles currently displayed for that perspective — no pagination. Each article includes a headline, link, source name (when available), and the perspective label.

**Estimated cost:** Metered

| Field | Type | Required | Description |
|-------|------|----------|-------------|
| `perspective` | string | Yes | Political perspective filter. Accepted values: Left, Center, Right. |

```bash
curl -X POST https://api.paywithlocus.com/api/wrapped/credits/allsides/get-news-articles-by-perspective \
  -H "Authorization: Bearer $LOCUS_CREDITS_SECRET_KEY" \
  -H "Idempotency-Key: $(uuidgen)" \
  -H "Content-Type: application/json" \
  -d '{"perspective":"<string>"}'
```

### Search allsides

Search AllSides content by keyword. Returns paginated results including article title, link, source name, text snippet, and content type (News, Opinion, Analysis, Fact Check). Supports zero-indexed pagination.

**Estimated cost:** Metered

| Field | Type | Required | Description |
|-------|------|----------|-------------|
| `page` | integer | No | Zero-based page number for pagination. |
| `query` | string | Yes | Search keyword or phrase. |

```bash
curl -X POST https://api.paywithlocus.com/api/wrapped/credits/allsides/search-allsides \
  -H "Authorization: Bearer $LOCUS_CREDITS_SECRET_KEY" \
  -H "Idempotency-Key: $(uuidgen)" \
  -H "Content-Type: application/json" \
  -d '{"page":"<integer>","query":"<string>"}'
```

## Next steps

- [All wrapped API providers](https://paywithlocus.com/wapi/index.md): pick another provider.
- [Find and call tools](https://paywithlocus.com/agent/tools.md): price ceilings, async results, and errors.
- [Credits and billing](https://paywithlocus.com/agent/billing.md): what a call costs and how to add credits.
- [Agent docs index](https://paywithlocus.com/agent/index.md): every Locus agent page.