-
Notifications
You must be signed in to change notification settings - Fork 2
API
loken edited this page Feb 18, 2016
·
21 revisions
All API endpoints are based off of /api/v1
, so if you access Plex Requests via http://localhost:8000 the API root would be http://localhost:8000/api/v1.
All requests to secured end points requires a valid JSON Web Token (JWT) to authenticate against. A token can be obtained by authenticating against the login end point. They are valid for 14 days from issue. A new token can be obtained from the refresh-token end point if you have a valid token.
Tokens should be included in the Authorization field of the requests Header.
Authorization: "ggfehghxjjdh81dogwrzkvh7bdtef6h919e0g4dq"
All requests return JSON encoded responses, following the below format:
// Valid response structure:
{
"statusCode": ...,
"data": ...,
"meta": ...
}
// Error response structure:
{
"statusCode": ...,
"error": ...,
"message": ...
}
An *
indicates the endpoint hasn't been implemented or isn't complete yet.