Webhooks demo not working !!

other-dev

#1

Hi

I'm trying to get Webhooks demo avalaible on Github to work on my Linux laptop but I have an issue to setup it correctly for that step:

Figure out the identifier of the player you want to control by hitting https://plex.tv/api/resources.xml?auth_token=api-token and grab the clientIdentifier value for the player.

I'm already logged on Plex website and my plex server in my browser but when I run the command indicated in documentation I get:

This XML file does not appear to have any style information associated with it. The document tree is shown below.
<errors>
<error>Jeton d'authentification incorrect.</error>
</errors>

Message in french means "Authentification token incorrect". How should I proceed then to find the id of the player I want to control ??

Thanks


#2

I didn’t have much luck with github setup at first I was able to get more data out of zapier and see the clientId that way which is actually the Payload_Player_UUID last I was testing this.

If you set it up in Zapier (30 day free trial) you will have a much greater understanding and should be able to configure the python/github stuff once you use this as a crutch.


#3

@vincen said:
Hi

I'm trying to get Webhooks demo avalaible on Github to work on my Linux laptop but I have an issue to setup it correctly for that step:

Figure out the identifier of the player you want to control by hitting https://plex.tv/api/resources.xml?auth_token=api-token and grab the clientIdentifier value for the player.

I'm already logged on Plex website and my plex server in my browser but when I run the command indicated in documentation I get:

This XML file does not appear to have any style information associated with it. The document tree is shown below.
<errors>
<error>Jeton d'authentification incorrect.</error>
</errors>

Message in french means "Authentification token incorrect". How should I proceed then to find the id of the player I want to control ??

Thanks

You'll want to use Chrome's inspector.

Go to the Networks tab and refresh the page.

You'll see a post to index.html in the network sources log.

Click on that line item, and then in the contents panel, click the "headers" tab at the top. Scroll through the various request headers until you see one with all the X-Plex-Headers="xxxxx".

You'll want the authToken, and clientIdentifier headers.

Then paste those into the node command.

  • just a note for when you're ready: The notifications demo on GitHub is specifically made for Apple computers. So you'll need to read up on node-notifier docs to get the correct properties for a Linux notification. (https://www.npmjs.com/package/node-notifier)

Also, I couldn't get mediakeys to install on Windows or Ubuntu, so I just removed the whole medias keys section from the starter code. It always fails with a syntax error on node-gyp build.
(https://www.npmjs.com/package/mediakeys)