-
Notifications
You must be signed in to change notification settings - Fork 1
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Clarify or fix default IP usage #24
Comments
Yes, there is a difference between the central plex.tv API and the Plex Media Server (the app you install on a server to self-host). In the case of plex.tv, the url is hard-coded and with anything else it requires a server url of where the API is hosted.
This is purely an example ip and means nothing
That's the tricky thing, it is not always needed. With plex.tv, no but anything else yes. But this single library handles both use-cases so it's "sometimes" needed. I do agree more clarification is always welcome. If you can give some specific pointers or clarifications then I will see if I can add it to the documentation |
It looks like all of the endpoints that require an actual PMS instance displays a prefix and those that are hardcoded for use with plex.tv do not have this If it's possible to modify the generated SDK docs to the right hand side so that It would also be helpful to include this clarification at, before, or in the SDK Example Usage section in the readme. The example usage code will fail with connection/timeout error since no serverURL is defined. (Also, I think the example is outdated since it does not show If possible it would also be good to get rid of the default IP address in the config so that if a user tries to use a PMS-instance required endpoint without a serverURL they will get an error about host missing or something else other than "connection/timeout error" since that error implies it could work but that's misleading. The default address makes on-boarding confusing if the user hasn't fully read the docs -- and even then its only mentioned once in the entire readme and zero times in the generated docs site. They will make an assumption that config is valid because they do not know about the default ip which might lead them to try diagnosing the connection issue without realizing a "valid" IP was provided without their knowledge. |
Almost all of the examples in the readme as well as the API Reference documentation show code examples like
which implies that it is possible to use this library without specifying a server url. This is somewhat reinforced by the server index being optional.
However, it looks like the actual client library defaults to using a private IP address,
10.10.10.47
, when no server url is provided. This leads to the same error shown in #20 if using the client code as shown in all examples because that IP address obviously isn't used by everyone.Please let me know if this address is supposed to be special to Plex somehow and I just don't understand.
Otherwise, it seems like the documentation should specify that
serverURL
always needs to be specified and, ideally, that it is NOT optional when initializing a new client.The text was updated successfully, but these errors were encountered: