Three mirrors had drifted:
- The rules-endpoint retirement (4f71eda6) deleted the routes but not
their mirrors: removed docs/developer/api/collections/
{add_auto_assign_rule,remove_auto_assign_rule,test_rule,update_rule}
.md + their bruno twins, and pruned /api/collections/test-rules,
/{id}/rules, /{id}/rules/{ruleId} from the generated openapi spec
(hand-edited — regenerating with -update would wipe hand-authored
bruno suites that predate the docs mirrors).
- New endpoint PUT /api/collections/:id/view-settings gets a doc page
+ schema-registry entry + bruno mirror (repo convention: the route
and its docs land together).
- 54 pre-existing TestDocsMatchRoutes failures: the media-item
endpoints emit the 16 episode/download fields (source_feed_id,
feed_position, download_state, enclosure_url, hosts/guests, …) and
libraries emit purpose/allow_member_feeds, but the doc examples
were never extended — the package only runs on the host, so the
container suite never caught it. Examples now carry every key the
handlers emit; internal/docs is fully green.
58 lines
1.3 KiB
Markdown
58 lines
1.3 KiB
Markdown
---
|
|
method: GET
|
|
path: /api/libraries/visibility
|
|
auth: jwt
|
|
area: libraries
|
|
---
|
|
<!-- source: internal/handlers/library.go:112 LibraryHandler.GetUserVisibleLibraries -->
|
|
|
|
# Get Visible Libraries
|
|
|
|
Retrieve all libraries visible to the current user.
|
|
|
|
**Endpoint**: `GET /api/libraries/visibility`
|
|
**Auth**: Required
|
|
|
|
## Request Headers
|
|
|
|
| Header | Type | Required | Description |
|
|
| ------------- | ------ | -------- | ------------ |
|
|
| Authorization | string | Yes | Bearer token |
|
|
|
|
### Example Request
|
|
|
|
```http
|
|
GET /api/libraries/visibility
|
|
Authorization: Bearer eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9...
|
|
```
|
|
|
|
## Response (200 OK)
|
|
|
|
A top-level JSON **array** of library rows:
|
|
|
|
```json example-response
|
|
[
|
|
{
|
|
"id": "uuid",
|
|
"name": "My Ebooks",
|
|
"description": "Ebook collection",
|
|
"library_type_id": "uuid",
|
|
"created_by_admin_id": "uuid",
|
|
"created_at": "2026-01-31T10:00:00Z",
|
|
"updated_at": "2026-01-31T10:00:00Z",
|
|
"type_name": "ebooks",
|
|
"type_description": "Ebook libraries",
|
|
"is_visible": true,
|
|
"allow_member_feeds": false
|
|
}
|
|
]
|
|
```
|
|
|
|
Nullable columns (`description`, `type_description`) serialize as `null` when unset. Timestamps are RFC 3339.
|
|
|
|
## Error Responses
|
|
|
|
| Code | Description |
|
|
| ---- | ------------------------ |
|
|
| 401 | Invalid or expired token |
|