Added URL path support. (#13436)

Changes:
Fix: Now using KTOR instead of building the url by simple string concad. This fixes the https and port 443 bug that existed prier to this change. (https://example.com would look like: https://example.com:443)
Added: Support for jellyfins Base URL option. This allows the addon to be used on installations were jellyfin uses a base path.

Signed-off-by: tliese <mail@tobiasliese.me>
This commit is contained in:
Tobias Liese
2022-10-01 15:32:11 +02:00
committed by GitHub
parent cc50497f31
commit 8b4607a4f1
6 changed files with 60 additions and 34 deletions

View File

@@ -33,41 +33,42 @@ In order to assist you with this process the binding expose a simple login form
## Server Thing Configuration
| Config | Type | description |
|----------|----------|------------------------------|
| hostname | text | Hostname or IP address of the server (required) |
| port | integer | Port of the server (required) |
| ssl | boolean | Connect through https (required) |
| refreshSeconds | integer | Interval to pull devices state from the server |
| Config | Type | description |
|---------------------------|---------|----------------------------------------------------------------------------------------------|
| hostname | text | Hostname or IP address of the server (required) |
| port | integer | Port of the server (required) |
| ssl | boolean | Connect through https (required) |
| path | text | Base path of the server |
| refreshSeconds | integer | Interval to pull devices state from the server |
| clientActiveWithInSeconds | integer | Amount off seconds allowed since the last client activity to assert it's online (0 disabled) |
| userId | text | The user id |
| token | text | The user access token |
| userId | text | The user id |
| token | text | The user access token |
## Channels
| channel | type | description |
|----------|--------|------------------------------|
| send-notification | String | Display message in client |
| media-control | Player | Control media playback |
| playing-item-id | String | Id of the item currently playing (readonly) |
| playing-item-name | String | Name of the item currently playing (readonly) |
| playing-item-series-name | String | Name of the item's series currently playing, only have value when item is an episode (readonly) |
| playing-item-season-name | String | Name of the item's season currently playing, only have value when item is an episode (readonly) |
| playing-item-season | Number | Number of the item's season currently playing, only have value when item is an episode (readonly) |
| playing-item-episode | Number | Number of the episode item currently playing, only have value when item is an episode (readonly) |
| playing-item-genders | String | Coma separate list genders of the item currently playing (readonly) |
| playing-item-type | String | Type of the item currently playing (readonly) |
| playing-item-percentage | Dimmer | Played percentage for the item currently playing, allow seek |
| playing-item-second | Number | Current second for the item currently playing, allow seek |
| playing-item-total-seconds | Number | Total seconds for the item currently playing (readonly) |
| play-by-terms | String | Play media by terms, works for series, episodes and movies; terms search is explained bellow |
| play-next-by-terms | String | Add to playback queue as next by terms, works for series, episodes and movies; terms search is explained bellow |
| play-last-by-terms | String | Add to playback queue as last by terms, works for series, episodes and movies; terms search is explained bellow |
| browse-by-terms | String | Browse media by terms, works for series, episodes and movies; terms search is explained bellow |
| play-by-id | String | Play media by id, works for series, episodes and movies; id search is explained bellow |
| play-next-by-id | String | Add to playback queue as next by id, works for series, episodes and movies |
| play-last-by-id | String | Add to playback queue as last by id, works for series, episodes and movies |
| browse-by-id | String | Browse media by id, works for series, episodes and movies |
| channel | type | description |
|----------------------------|--------|-----------------------------------------------------------------------------------------------------------------|
| send-notification | String | Display message in client |
| media-control | Player | Control media playback |
| playing-item-id | String | Id of the item currently playing (readonly) |
| playing-item-name | String | Name of the item currently playing (readonly) |
| playing-item-series-name | String | Name of the item's series currently playing, only have value when item is an episode (readonly) |
| playing-item-season-name | String | Name of the item's season currently playing, only have value when item is an episode (readonly) |
| playing-item-season | Number | Number of the item's season currently playing, only have value when item is an episode (readonly) |
| playing-item-episode | Number | Number of the episode item currently playing, only have value when item is an episode (readonly) |
| playing-item-genders | String | Coma separate list genders of the item currently playing (readonly) |
| playing-item-type | String | Type of the item currently playing (readonly) |
| playing-item-percentage | Dimmer | Played percentage for the item currently playing, allow seek |
| playing-item-second | Number | Current second for the item currently playing, allow seek |
| playing-item-total-seconds | Number | Total seconds for the item currently playing (readonly) |
| play-by-terms | String | Play media by terms, works for series, episodes and movies; terms search is explained bellow |
| play-next-by-terms | String | Add to playback queue as next by terms, works for series, episodes and movies; terms search is explained bellow |
| play-last-by-terms | String | Add to playback queue as last by terms, works for series, episodes and movies; terms search is explained bellow |
| browse-by-terms | String | Browse media by terms, works for series, episodes and movies; terms search is explained bellow |
| play-by-id | String | Play media by id, works for series, episodes and movies; id search is explained bellow |
| play-next-by-id | String | Add to playback queue as next by id, works for series, episodes and movies |
| play-last-by-id | String | Add to playback queue as last by id, works for series, episodes and movies |
| browse-by-id | String | Browse media by id, works for series, episodes and movies |
### Terms search:
The terms search has a default behavior that can be modified sending some predefined prefixes.