API reference
Stats
Watch history and server-wide statistics (P3-20).
Paths are relative to /api/v1 on your server.
/history#My watch history
- Authorisation
- Bearer token or API key · Session cookie
| Parameter | In | Type | Description |
|---|---|---|---|
types | query | string | |
libraryId | query | string (uuid) | |
itemId | query | string (uuid) | |
method | query | "direct_play" | "direct_stream" | "transcode" | |
from | query | string (date-time) | |
to | query | string (date-time) | |
cursor | query | string | |
limit | query | integer | |
cards | query | |
- 200Success.
application/json·HistoryPage - 400
VALIDATION_FAILED: the request did not match the schema;details.issueslists what.application/json·ErrorEnvelope - 401
UNAUTHENTICATED: no session, or the access token expired.application/json·ErrorEnvelope - 403
FORBIDDEN: the account lackslibrary:view, or the library, label, age or schedule scope refuses it.application/json·ErrorEnvelope
/profile#My profile
When the caller joined, and how much they have played: every play of theirs, whatever library it was in.
- Authorisation
- Bearer token or API key · Session cookie
- 200Success.
application/json·Profile - 401
UNAUTHENTICATED: no session, or the access token expired.application/json·ErrorEnvelope - 403
FORBIDDEN: the account lackslibrary:view, or the library, label, age or schedule scope refuses it.application/json·ErrorEnvelope
/stats#Server-wide statistics
- Authorisation
- Bearer token or API key · Session cookie
| Parameter | In | Type | Description |
|---|---|---|---|
period | query | "7d" | "30d" | "90d" | "365d" | "all" | |
libraryId | query | string (uuid) | |
tz | query | string |
- 200Success.
application/json·ServerStats - 400
VALIDATION_FAILED: the request did not match the schema;details.issueslists what.application/json·ErrorEnvelope - 401
UNAUTHENTICATED: no session, or the access token expired.application/json·ErrorEnvelope - 403
FORBIDDEN: the account lackssession:manage, or the library, label, age or schedule scope refuses it.application/json·ErrorEnvelope
No endpoint here matches. Try another word, or look in another area.