# C Span — 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.

> Find C-SPAN TV schedules by channel and date, and look up detailed information about specific events and programs. Plan your viewing by browsing what's on air and discovering full details about any broadcast that interests you.

**Category:** Government & Public Data | **Website:** [www.c-span.org/schedule/](https://www.c-span.org/schedule/) | **Docs:** [parse.bot/marketplace/1e1027f3-bb49-470d-a7c1-d07a4b26b269/c-span-org-api](https://parse.bot/marketplace/1e1027f3-bb49-470d-a7c1-d07a4b26b269/c-span-org-api)

Pay-per-use API proxy. Each call is automatically billed to your wallet in USDC.

## Access

**Base URL:** `https://api.paywithlocus.com/api/wrapped/parse-c-span-org-api-1e1027f3/`
**Auth:** `Authorization: Bearer <LOCUS_API_KEY>`

## Endpoints

### get_details

Get detailed information about a C-SPAN event or program by its numeric ID. Accepts either an event_id or a program_id. Returns a unified structure including metadata, airings with UTC times, sponsors, and for programs the m3u8 video stream URL. When called with an event_id, the programs array lists constituent program segments.

**Estimated cost:** Metered

| Field | Type | Required | Description |
|-------|------|----------|-------------|
| `event_id` | string | No | Numeric event ID (e.g. '443464'). Either event_id or program_id must be provided. |
| `program_id` | string | No | Numeric program ID (e.g. '680198'). Either event_id or program_id must be provided. |

```bash
curl -X POST https://api.paywithlocus.com/api/wrapped/parse-c-span-org-api-1e1027f3/get_details \
  -H "Authorization: Bearer YOUR_LOCUS_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{"event_id":"<string>","program_id":"<string>"}'
```

### get_event

Get detailed information about a C-SPAN event by its numeric event ID. Returns event metadata including description, location, series, scheduled airings with UTC times and live status, sponsors, and constituent programs.

**Estimated cost:** Metered

| Field | Type | Required | Description |
|-------|------|----------|-------------|
| `event_id` | string | Yes | Numeric event ID (e.g. '443464'). Obtained from get_schedule results where type is 'event'. |

```bash
curl -X POST https://api.paywithlocus.com/api/wrapped/parse-c-span-org-api-1e1027f3/get_event \
  -H "Authorization: Bearer YOUR_LOCUS_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{"event_id":"<string>"}'
```

### get_live

Get currently live streams across C-SPAN channels. Returns all programs and events that are currently airing live, including m3u8 HLS stream URLs for events, website URLs, event/program IDs, and enriched metadata (location, category, series, networks) for identified events. Checks channels 1, 2, and 3 by default, or a single specified channel.

**Estimated cost:** Metered

| Field | Type | Required | Description |
|-------|------|----------|-------------|
| `channel` | string | No | Channel number to check for live content. Accepts exactly one of: 1 (C-SPAN), 2 (C-SPAN2), 3 (C-SPAN3), 5 (C-SPAN Radio), 6 (Today's Events). When omitted, checks channels 1, 2, and 3. |

```bash
curl -X POST https://api.paywithlocus.com/api/wrapped/parse-c-span-org-api-1e1027f3/get_live \
  -H "Authorization: Bearer YOUR_LOCUS_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{"channel":"<string>"}'
```

### get_program

Get detailed information about a C-SPAN program by its numeric program ID. Returns program metadata including description, category, format, location, airings with UTC times, sponsors, tags, and the m3u8 video stream URL.

**Estimated cost:** Metered

| Field | Type | Required | Description |
|-------|------|----------|-------------|
| `program_id` | string | Yes | Numeric program ID (e.g. '680198'). Obtained from get_schedule results where type is 'program', or from get_event programs array. |

```bash
curl -X POST https://api.paywithlocus.com/api/wrapped/parse-c-span-org-api-1e1027f3/get_program \
  -H "Authorization: Bearer YOUR_LOCUS_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{"program_id":"<string>"}'
```

### get_schedule

Get the TV schedule for a given C-SPAN channel and date. Returns a list of scheduled events and programs with their UTC start times, titles, descriptions, durations, live/scheduled/completed status, m3u8 video stream URLs for live and completed items, category, format, series title, location, thumbnail URLs, and links to detail pages. Each item's date and start_time_utc reflect the actual scheduled air date (extracted from the page's day section headers), not just the requested date. Enriches each item with metadata from the C-SPAN API when available. Items that start earlier than their scheduled slot are flagged with is_early=true; in that case start_time_utc is the actual (earlier) start from the API and original_start_date is the originally scheduled time from the schedule page.

**Estimated cost:** Metered

| Field | Type | Required | Description |
|-------|------|----------|-------------|
| `channel` | string | No | Channel number. Accepts exactly one of: 1 (C-SPAN), 2 (C-SPAN2), 3 (C-SPAN3), 5 (C-SPAN Radio), 6 (Today's Events). |
| `date` | string | No | Date in ISO format YYYY-MM-DD (e.g. 2026-06-01). When omitted, defaults to the current UTC date. |

```bash
curl -X POST https://api.paywithlocus.com/api/wrapped/parse-c-span-org-api-1e1027f3/get_schedule \
  -H "Authorization: Bearer YOUR_LOCUS_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{"channel":"<string>","date":"<string>"}'
```

### get_transcript

Get the transcript for a C-SPAN program by its numeric program ID or event ID. When an event_id is provided, the transcript for the first program in that event is returned. Returns closed captioning text segments with video time offsets and speaker names, along with the m3u8 video stream URL. Not all programs have transcripts; the response indicates availability via has_transcript.

**Estimated cost:** Metered

| Field | Type | Required | Description |
|-------|------|----------|-------------|
| `event_id` | string | No | Numeric event ID (e.g. '443464'). When provided without program_id, the transcript for the first program in the event is returned. |
| `program_id` | string | No | Numeric program ID (e.g. '680198'). Obtained from get_schedule results where type is 'program', or from get_event programs array. Either program_id or event_id must be provided. |

```bash
curl -X POST https://api.paywithlocus.com/api/wrapped/parse-c-span-org-api-1e1027f3/get_transcript \
  -H "Authorization: Bearer YOUR_LOCUS_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{"event_id":"<string>","program_id":"<string>"}'
```
