Tautulli Integration Not Wroking

Hi,

I have been using the Tuatulli integration in HA for a while now, but its stopped working over the last couple of months, and I have not been able to figure out why, beyond the fact that its not receiving the data in the correct mime format.

I have tried numerous items, such as starting afresh with Tautulli, restarting HA / Supervisor in between, but have not had any luck.

The log from HA is below.

Error fetching tautulli data: Request exception for 'https://tautulli.example.in:443/api/v2?apikey=[REDACTED_API_TOKEN]&cmd=get_activity' with - 0, message='Attempt to decode JSON with unexpected mimetype: text/html', url=URL('https://tautulli.example.in:443/api/v2?apikey=[REDACTED_API_TOKEN]&cmd=get_activity')

Any and all help would be greatly appreciated
Thanks
Moksh

That log isn’t helpful if we don’t know where it is really connecting to.
Tautulli by default is on port 8181 (though I am not using the addon, so that might be different) - I would expect the log to show it is connecting to http://some-internal-name:8181 not port 443.

I understand, sorry i forgot to mention that earlier.

My tautulli instance is over WAN and uses HTTPS / SSL. My entire config from my “sensors.yaml” file is below

- platform: tautulli
  name: Tautulli Sensor
  api_key: !secret tautulli_api_key
  host: "tautulli.example.in"
  port: "443"
  ssl: "true"
  #   #  host: "192.168.0.11"
  #   #  port: "8181"
  monitored_conditions:
    - title
    - lan_bandwidth
    - wan_bandwidth
    - number_of_direct_plays
    - number_of_direct_streams
    - stream_count
    - top_user
    - total_bandwidth
    - transcode_count
    - platform
    - player
    - ip_address

I have also tried connecting over my LAN, but i get exactly the same issue in my logs

OK, so the next thing to do is to visit the full URL mentioned in the log, in your browser - and see what comes up, if you see JSON then there is something else going on, but I suspect you are going to see an actual webpage rather than JSON. Let us know (a screenshot would help) what is showing up when you visit that exact URL from your log.

I actually can see the json output when I hit up that URL. I’m attaching a screenshot below. (Ps sorry for the image, took a screenshot on my phone)

any clue as to what’s going wrong?
i tried viewing the page in chrome too, but the mime type is the same as whats being put up in HA

Is Tautulli behind a reverse proxy like Nginx or something on the remote server? The mime-type being set incorrectly is more likely to be an issue with a proxy server getting in between than it is an actual issue with Tautulli.

it is behind a reverse proxy, but like i mentioned, i get exactly the same issue even when i expose it through the lan ip (i.e. 192.168.0.11:8181, and disable SSL). I’ll post a screenshot of that shortly.

Okay, for some reason it seems to be working perfectly now. This thread can be closed.