Hi! I’ve been working hard trying to figure out how to change a projector’s lens memory with Home Assistant.
I have multiple steps completed, but the last one is problematic.
Here are the steps I’m trying to achieve:
Generate an
aspectRatios.json
file based on the crop data parsed from images in each media file.Write an automation triggered by Plex’s media state changing.
Make an API call to Plex to get the file system location using the content ID in state attributes.
I can make the call, but I don’t know how to do it in Home Assistant nor how to get the Plex token from the integration.
Change projector lens memory setting with virtual remote based on the selected aspect ratio.
As you can see, the one thing I need help with is the hardest.
I need to:
- Figure out how to make an API call to my Plex server in an automation. This returns XML.
- Read a JSON file shared over the network or stored locally and pass the file location as the first object
key
, then get the aspect ratio property off it.
If I can do those two things, I’ll have this entire system finally figured out!
Could someone help me figure out how to handle XML, JSON, and API calls?
1 post - 1 participant