# Lmarena — 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.

> Lmarena provides 13 callable API endpoints through the Parse marketplace.

**Category:** Developer Tools | **Website:** [lmarena.ai/](https://lmarena.ai/) | **Docs:** [parse.bot/marketplace/f4504720-6673-4f4c-bca2-323669b31876/lmarena-ai-api](https://parse.bot/marketplace/f4504720-6673-4f4c-bca2-323669b31876/lmarena-ai-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-lmarena-ai-api-f4504720/`
**Auth:** `Authorization: Bearer <LOCUS_API_KEY>`

## Endpoints

### get_best_coding_models

Get a combined summary of the best AI coding models from the Code Arena leaderboard alongside a snapshot of the top 10 models from the Text Arena leaderboard. Useful for comparing code-focused models to general text leaders.

**Estimated cost:** Metered

_No parameters required._

```bash
curl -X POST https://api.paywithlocus.com/api/wrapped/parse-lmarena-ai-api-f4504720/get_best_coding_models \
  -H "Authorization: Bearer YOUR_LOCUS_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{}'
```

### get_code_leaderboard

Fetch the Code Arena leaderboard showing model rankings for code generation tasks. Returns entries and available model list.

**Estimated cost:** Metered

_No parameters required._

```bash
curl -X POST https://api.paywithlocus.com/api/wrapped/parse-lmarena-ai-api-f4504720/get_code_leaderboard \
  -H "Authorization: Bearer YOUR_LOCUS_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{}'
```

### get_image_edit_leaderboard

Fetch the Image Edit Arena leaderboard showing model rankings for image editing tasks.

**Estimated cost:** Metered

_No parameters required._

```bash
curl -X POST https://api.paywithlocus.com/api/wrapped/parse-lmarena-ai-api-f4504720/get_image_edit_leaderboard \
  -H "Authorization: Bearer YOUR_LOCUS_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{}'
```

### get_image_to_video_leaderboard

Fetch the Image-to-Video Arena leaderboard showing model rankings for video generation from images.

**Estimated cost:** Metered

_No parameters required._

```bash
curl -X POST https://api.paywithlocus.com/api/wrapped/parse-lmarena-ai-api-f4504720/get_image_to_video_leaderboard \
  -H "Authorization: Bearer YOUR_LOCUS_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{}'
```

### get_leaderboard_overview

Fetch the default leaderboard overview showing ranked models on the main leaderboard page. Returns the full entries array and metadata. Useful as a quick summary of top-performing models across the default category.

**Estimated cost:** Metered

_No parameters required._

```bash
curl -X POST https://api.paywithlocus.com/api/wrapped/parse-lmarena-ai-api-f4504720/get_leaderboard_overview \
  -H "Authorization: Bearer YOUR_LOCUS_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{}'
```

### get_search_leaderboard

Fetch the Search Arena leaderboard showing model rankings for search/retrieval tasks.

**Estimated cost:** Metered

_No parameters required._

```bash
curl -X POST https://api.paywithlocus.com/api/wrapped/parse-lmarena-ai-api-f4504720/get_search_leaderboard \
  -H "Authorization: Bearer YOUR_LOCUS_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{}'
```

### get_text_leaderboard

Fetch the Text Arena leaderboard showing model rankings for text generation tasks. Returns entries and the full initialModels list of available models.

**Estimated cost:** Metered

_No parameters required._

```bash
curl -X POST https://api.paywithlocus.com/api/wrapped/parse-lmarena-ai-api-f4504720/get_text_leaderboard \
  -H "Authorization: Bearer YOUR_LOCUS_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{}'
```

### get_text_to_image_leaderboard

Fetch the Text-to-Image Arena leaderboard showing model rankings for image generation tasks.

**Estimated cost:** Metered

_No parameters required._

```bash
curl -X POST https://api.paywithlocus.com/api/wrapped/parse-lmarena-ai-api-f4504720/get_text_to_image_leaderboard \
  -H "Authorization: Bearer YOUR_LOCUS_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{}'
```

### get_text_to_video_leaderboard

Fetch the Text-to-Video Arena leaderboard showing model rankings for video generation from text prompts.

**Estimated cost:** Metered

_No parameters required._

```bash
curl -X POST https://api.paywithlocus.com/api/wrapped/parse-lmarena-ai-api-f4504720/get_text_to_video_leaderboard \
  -H "Authorization: Bearer YOUR_LOCUS_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{}'
```

### get_top_models_by_category

Get the top N models from a specific category leaderboard, sorted by rank. Accepts any leaderboard category and a limit. The most flexible ranked-model endpoint — equivalent to fetching a category-specific leaderboard and slicing to the requested count.

**Estimated cost:** Metered

| Field | Type | Required | Description |
|-------|------|----------|-------------|
| `category` | string | Yes | Leaderboard category to query. |
| `limit` | integer | No | Maximum number of top models to return. |

```bash
curl -X POST https://api.paywithlocus.com/api/wrapped/parse-lmarena-ai-api-f4504720/get_top_models_by_category \
  -H "Authorization: Bearer YOUR_LOCUS_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{"category":"<string>","limit":"<integer>"}'
```

### get_vision_leaderboard

Fetch the Vision Arena leaderboard showing model rankings for vision/multimodal tasks.

**Estimated cost:** Metered

_No parameters required._

```bash
curl -X POST https://api.paywithlocus.com/api/wrapped/parse-lmarena-ai-api-f4504720/get_vision_leaderboard \
  -H "Authorization: Bearer YOUR_LOCUS_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{}'
```

### list_available_models

List all models available for direct interaction on LMArena, including their capabilities (input/output modalities), organization, selectability status, and per-modality rank. This is the full model catalog independent of leaderboard rankings.

**Estimated cost:** Metered

_No parameters required._

```bash
curl -X POST https://api.paywithlocus.com/api/wrapped/parse-lmarena-ai-api-f4504720/list_available_models \
  -H "Authorization: Bearer YOUR_LOCUS_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{}'
```

### search_leaderboard_models

Search for models in a leaderboard category by matching a query string against model display names and organization names (case-insensitive substring match). Returns all matching entries from the specified category.

**Estimated cost:** Metered

| Field | Type | Required | Description |
|-------|------|----------|-------------|
| `category` | string | No | Leaderboard category to search in. |
| `query` | string | Yes | Search keyword to match against model display names or organization names (case-insensitive substring match). |

```bash
curl -X POST https://api.paywithlocus.com/api/wrapped/parse-lmarena-ai-api-f4504720/search_leaderboard_models \
  -H "Authorization: Bearer YOUR_LOCUS_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{"category":"<string>","query":"<string>"}'
```
