Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
85 changes: 53 additions & 32 deletions API.md
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,6 @@ WatchState HTTP API reference. Examples use the default `/v1/api` prefix.
- [GET|POST /v1/api/backends/users/{type}](#getpost-v1apibackendsuserstype)
- [GET|POST /v1/api/backends/discover/{type}](#getpost-v1apibackendsdiscovertype)
- [POST /v1/api/backends/accesstoken/{type}](#post-v1apibackendsaccesstokentype)
- [POST /v1/api/backends/validate/token/{type}](#post-v1apibackendsvalidatetokentype)
- [POST /v1/api/backends/plex/generate](#post-v1apibackendsplexgenerate)
- [POST /v1/api/backends/plex/check](#post-v1apibackendsplexcheck)
- [Configured Backend Endpoints](#configured-backend-endpoints)
Expand Down Expand Up @@ -455,35 +454,6 @@ Generates a Jellyfin or Emby access token using username/password credentials.

---

#### POST /v1/api/backends/validate/token/{type}
Validates a Plex token.

**Path**:
- `type`: Must resolve to the Plex client.

**Body**:
```json
{
"token": "plex-token"
}
```

**Response**:
```json
{
"info": {
"code": 200,
"message": "Token is valid."
}
}
```

**Errors**:
- `400 Bad Request` if the endpoint is used with a non-Plex backend or if `token` is missing.
- `401 Unauthorized` if the token is rejected.

---

#### POST /v1/api/backends/plex/generate
Starts the Plex PIN flow used for browser/device login.

Expand Down Expand Up @@ -2729,12 +2699,63 @@ Restarts the task scheduler.
---

#### GET /v1/api/system/report
Returns the output of the `system:report` command.
Returns a structured diagnostic report.

**Response**:
```json
{
"...": "report payload"
"generated_at": "2024-01-01T12:00:00+00:00",
"system": {
"version": "v1.0.0",
"php_version": "8.4.0",
"sapi": "cli",
"timezone": "UTC",
"data_path": "/config",
"temp_path": "/tmp",
"database_migrated": true,
"env_file_exists": true,
"scheduler_running": true,
"scheduler_message": "OK",
"in_container": true
},
"users": ["main"],
"backends": [
{
"name": "plex_server",
"user": "main",
"type": "plex",
"version": "1.40.1",
"https": true,
"has_uuid": true,
"has_user": true,
"export": { "enabled": true, "last_sync": 1704110400, "playlist_last_sync": null },
"import": { "enabled": true, "metadata_refresh": true, "last_sync": 1704110400, "playlist_last_sync": null },
"options": {}
}
],
"suppression": {
"file_exists": false,
"rules": null,
"error": null
},
"tasks": [
{
"name": "import",
"enabled": true,
"args": "-v",
"timer": "5 * * * *",
"next_run": "2024-01-01T13:00:00+00:00",
"error": null
}
],
"logs": [
{
"type": "app",
"entries": [
{ "datetime": "2024-01-01T12:00:00+00:00", "level": "INFO", "logger": "main", "message": "Application started" }
]
}
]
}
```

Expand Down
2 changes: 1 addition & 1 deletion FAQ.md
Original file line number Diff line number Diff line change
Expand Up @@ -454,7 +454,7 @@ the issue. Please enable webhooks for your jellyfin backend to avoid this issue.

We have added an experimental workaround for this issue in the `state:import` command. To enable it, add the env `WS_CLIENTS_JELLYFIN_FIX_PLAYED` via the `Configuration > Environment` page. It's turned off by default as it may cause some issues as it's untested in production, so please use it with caution and report any issues you find.

## CODE: DM001 - Item queued for re-processing.
## DM001 (`error: dm001_stale_date`) - Item queued for re-processing.

This warning appears when the backend reports an older item state than the last recorded sync point. This usually
shows up in edge cases and can often be resolved by forcing a state export to the backend.
Expand Down
65 changes: 38 additions & 27 deletions composer.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Loading
Loading