> ## Documentation Index
> Fetch the complete documentation index at: https://docs.plazen.org/llms.txt
> Use this file to discover all available pages before exploring further.

# Public endpoints

> Overview and conventions for the Plazen API

### Report connectivity to the database (introduced in [v1.11.0](https://www.plazen.org/release-notes/6e212460-10f6-4b02-8b78-4852c7df60d5))

```endpoint theme={null}
method: GET, OPTIONS (CORS)
path: /api/health
summary: Database connection failed
```

**Auth:** None, Cross Origin Allowed\
**Success:** `200 { status: "ok", message: "Database connection successful" }`\
**Errors:** `500 { error: "Failed to fetch documentation entries" }`

### Get a public profile (introduced in [v1.14.0](https://www.plazen.org/release-notes/bcbc8be0-77b5-4c8d-ad64-21ed9fac8fef))

```endpoint theme={null}
method: GET
path: /api/profile/[username]
summary: Fetch public profile data for a user by username
pathParams:
  - name: username
    required: true
    description: Public username
```

**Auth:** None\
**Success 200:** JSON profile: username, stats, avatar, bio, badges\
**Errors:** `400 { error: "Username is required" }` missing id, `404 { error: "Profile not found" }` not found, `500 { error: "Failed to fetch profile" }`.

### Get release note

```endpoint theme={null}
method: GET
path: /api/release-notes/:id
summary: Get one release note
pathParams:
  - name: id
    required: true
    description: Release note ID
```

**Auth:** None\
**Success 200:** JSON release note.\
**Errors:** `400` missing id, `404` not found, `500`.

### List documentation entries (will be removed in v2.0.0)

```endpoint theme={null}
method: GET
path: /api/documentation
summary: List all documentation entries
```

**Auth:** None\
**Success 200:** JSON array of `documentation_entries` ordered by `category`.\
**Errors:** `500 { error: "Failed to fetch documentation entries" }`.

### Get documentation entry (will be removed in v2.0.0)

```endpoint theme={null}
method: GET
path: /api/documentation/:id
summary: Get one documentation entry
pathParams:
  - name: id
    required: true
    description: Entry ID
```

**Auth:** None\
**Success 200:** JSON entry.\
**Errors:** `400` missing id, `404` not found, `500`.
