# Wikia (wikia.org) — 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.

> Search and retrieve detailed information about characters, episodes, lore, and other content from Fandom wikis across thousands of fan communities. Browse wiki categories, look up specific pages, and access structured data about your favorite franchises all in one place.

**Category:** Entertainment | **Website:** [wikia.org/](https://wikia.org/) | **Docs:** [parse.bot/marketplace/9cb4e345-1b9f-45e0-a0b5-ec0469d3b071/wikia-org-api](https://parse.bot/marketplace/9cb4e345-1b9f-45e0-a0b5-ec0469d3b071/wikia-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-wikia-org-api-9cb4e345/`
**Auth:** `Authorization: Bearer <LOCUS_API_KEY>`

## Endpoints

### get_page_data

Retrieve detailed information for a specific wiki page, including its description (first paragraph), infobox data (structured key-value pairs from the sidebar), sections outline, and categories. Returns stale_input with kind 'input_not_found' if the page title does not exist on the wiki.

**Estimated cost:** Metered

| Field | Type | Required | Description |
|-------|------|----------|-------------|
| `page` | string | Yes | The exact title of the page (e.g., 'Luke Skywalker'). |
| `wiki` | string | Yes | The wiki subdomain (e.g., 'starwars' for starwars.fandom.com). |

```bash
curl -X POST https://api.paywithlocus.com/api/wrapped/parse-wikia-org-api-9cb4e345/get_page_data \
  -H "Authorization: Bearer YOUR_LOCUS_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{"page":"<string>","wiki":"<string>"}'
```

### get_wiki_info

Get general information and statistics for a specific Fandom wiki, including site name, server URL, language, MediaWiki version, and usage statistics (article counts, edit counts, user counts). Returns a single result with metadata and statistics objects.

**Estimated cost:** Metered

| Field | Type | Required | Description |
|-------|------|----------|-------------|
| `wiki` | string | Yes | The wiki subdomain (e.g., 'starwars' for starwars.fandom.com). |

```bash
curl -X POST https://api.paywithlocus.com/api/wrapped/parse-wikia-org-api-9cb4e345/get_wiki_info \
  -H "Authorization: Bearer YOUR_LOCUS_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{"wiki":"<string>"}'
```

### list_category_members

List all pages belonging to a specific category on a wiki. Supports pagination via a continue token returned in the response. Each page of results includes member titles, page IDs, and namespace IDs. The continue token in the response can be passed back to retrieve the next page.

**Estimated cost:** Metered

| Field | Type | Required | Description |
|-------|------|----------|-------------|
| `category` | string | Yes | The category name. May be provided with or without the 'Category:' prefix (e.g., 'Humans' or 'Category:Humans'). |
| `continue` | string | No | Pagination token from a previous response's 'continue' field. |
| `limit` | integer | No | Maximum number of members to return per page (max 500). |
| `wiki` | string | Yes | The wiki subdomain (e.g., 'starwars' for starwars.fandom.com). |

```bash
curl -X POST https://api.paywithlocus.com/api/wrapped/parse-wikia-org-api-9cb4e345/list_category_members \
  -H "Authorization: Bearer YOUR_LOCUS_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{"category":"<string>","continue":"<string>","limit":"<integer>","wiki":"<string>"}'
```

### search_pages

Search for pages within a specific Fandom wiki. Returns matching page titles, IDs, snippets, and word counts ordered by relevance. Snippet text may be empty depending on wiki configuration. Results are returned in a single page; use the limit parameter to control result count.

**Estimated cost:** Metered

| Field | Type | Required | Description |
|-------|------|----------|-------------|
| `limit` | integer | No | Maximum number of results to return. |
| `query` | string | Yes | Search keyword or phrase. |
| `wiki` | string | Yes | The wiki subdomain (e.g., 'starwars' for starwars.fandom.com, 'marvel' for marvel.fandom.com). |

```bash
curl -X POST https://api.paywithlocus.com/api/wrapped/parse-wikia-org-api-9cb4e345/search_pages \
  -H "Authorization: Bearer YOUR_LOCUS_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{"limit":"<integer>","query":"<string>","wiki":"<string>"}'
```
