# Livelaw — Wrapped API

> **You are on:** `https://api.beta.paywithlocus.com/api` | [llms.txt](https://beta.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.

> Access Supreme Court and High Court judgments, legal news, articles, and digests from LiveLaw.in, with the ability to filter by year, category, and author. Stay updated on the latest legal developments, court decisions, and expert legal analysis across Indian courts.

**Category:** News & Media | **Website:** [livelaw.in/](https://livelaw.in/) | **Docs:** [parse.bot/marketplace/eb9b5793-b6dd-4cb2-8faf-c7d3462e1acf/livelaw-in-api](https://parse.bot/marketplace/eb9b5793-b6dd-4cb2-8faf-c7d3462e1acf/livelaw-in-api)

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

## Access

**Base URL:** `https://api.beta.paywithlocus.com/api/wrapped/credits/livelaw/`
**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 article detail

Fetch full content and metadata of a specific article by its slug or full URL. Returns title, body text, premium status, and URL. Body may be empty for premium/paywalled articles.

**Estimated cost:** Metered

| Field | Type | Required | Description |
|-------|------|----------|-------------|
| `slug` | string | Yes | The article slug (e.g., 'top-stories/courts-must-order-psychological-assessment-of-child-only-if-necessary-minimum-intrusion-should-be-norm-supreme-court-537514') or full URL starting with https://. |

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

### Get category articles

Fetch articles from a specific category. Returns paginated results. Valid categories include 'consumer-cases', 'ibc', 'news-updates', 'law-firms', 'job-updates'. A 404 upstream error indicates the category slug is invalid.

**Estimated cost:** Metered

| Field | Type | Required | Description |
|-------|------|----------|-------------|
| `category` | string | Yes | The category slug (e.g., 'consumer-cases', 'ibc', 'news-updates', 'law-firms', 'job-updates'). |
| `page` | integer | No | Page number to fetch. |

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

### Get digests

Fetch legal digests including weekly, monthly, and quarterly roundups from various courts. Returns a list of digest summaries with pagination support.

**Estimated cost:** Metered

| Field | Type | Required | Description |
|-------|------|----------|-------------|
| `page` | integer | No | Page number to fetch. |

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

### Get high court by name

Fetch news and judgments for a specific High Court by its slug. Returns a list of article summaries for that court.

**Estimated cost:** Metered

| Field | Type | Required | Description |
|-------|------|----------|-------------|
| `court_slug` | string | Yes | The slug of the High Court (e.g., 'bombay-high-court', 'delhi-high-court', 'allahabad-high-court', 'kerala-high-court', 'madras-high-court', 'karnataka-high-court'). |

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

### Get high court news

Fetch news from all Indian High Courts with pagination support. Returns a list of article summaries. Each page contains ~12 items.

**Estimated cost:** Metered

| Field | Type | Required | Description |
|-------|------|----------|-------------|
| `page` | integer | No | Page number to fetch. |

```bash
curl -X POST https://api.beta.paywithlocus.com/api/wrapped/credits/livelaw/get-high-court-news \
  -H "Authorization: Bearer $LOCUS_CREDITS_SECRET_KEY" \
  -H "Idempotency-Key: $(uuidgen)" \
  -H "Content-Type: application/json" \
  -d '{"page":"<integer>"}'
```

### Get sc judgments

Fetch paginated list of Supreme Court judgments for a specific year. Iterates through listing pages on livelaw.in/sc-judgments and filters by year extracted from titles. Returns all matching judgments up to the max_pages limit. Each page contains ~12 items. If the target year is older, more pages may be needed to reach it.

**Estimated cost:** Metered

| Field | Type | Required | Description |
|-------|------|----------|-------------|
| `max_pages` | integer | No | Maximum number of listing pages to scan. |
| `year` | integer | No | The year of judgments to extract. |

```bash
curl -X POST https://api.beta.paywithlocus.com/api/wrapped/credits/livelaw/get-sc-judgments \
  -H "Authorization: Bearer $LOCUS_CREDITS_SECRET_KEY" \
  -H "Idempotency-Key: $(uuidgen)" \
  -H "Content-Type: application/json" \
  -d '{"max_pages":"<integer>","year":"<integer>"}'
```

### Get top stories

Fetch the latest top stories from LiveLaw with pagination support. Returns a list of article summaries including title, URL, summary text, and extracted year when available. Each page contains ~12 items.

**Estimated cost:** Metered

| Field | Type | Required | Description |
|-------|------|----------|-------------|
| `page` | integer | No | Page number to fetch. |

```bash
curl -X POST https://api.beta.paywithlocus.com/api/wrapped/credits/livelaw/get-top-stories \
  -H "Authorization: Bearer $LOCUS_CREDITS_SECRET_KEY" \
  -H "Idempotency-Key: $(uuidgen)" \
  -H "Content-Type: application/json" \
  -d '{"page":"<integer>"}'
```

## Next steps

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