Multiple UniFi AP Controllers for Device Tracker?

Long story short, I have 2 UniFi Controller setup at 2 different locations. My primary instance (at home) is currently configured with hass, and works great. I recently setup site-to-site VPN between these 2 sites so I want to track devices at this other location as well. I’m not so interested in tracking the same device going between these 2 locations, but there are devices at both locations that I want to track (i.e., I want to know when a certain device is on site2, but couldn’t care less about knowing when it’s at site1).

Is this possible? I know hass supports multiple device trackers, but I’ve seen no mention about using the SAME type, but a different server.

This was easy enough, just had to add a second unifi platform and it worked.

Now I’m just curious how device_tracker will behave when client_1 from site_1 is at site_2 (will it list home or not_home?).

I never tried this because location seems based.of HASS lat/long

I expect entity with show home…but I want it to show location1, location 2, etc.
Let us know how it goes though

EDIT
You have 2 controller or 2 sites on one controller?

I am running 2 separate controller at 2 different physical locations, but I have access to both controllers from my hass installation.

I have not had the opportunity to take my phone (which is normally tracked at site1) to site2 to see how it behaves, but I’m guessing it’s not going to work. I use device alias’s in my unifi controllers, but I don’t have consistency between both controllers so I’m thinking my phone will show up as a separate entity in my known_devices list, unless it uses the MAC as the unique identifier. I should be able to test, and confirm, this weekend.

It uses MAC as identifier.

Indeed it does. When my phone is at site2, I am marked as home. Not ideal, but not the end of the world.

I had device_tracker working successfully but wanted to move the Unifi controller off my hass.io RPi3. So, I set up the Unifi controller on an always on pc in my network and adopted my two AP Pro’s. I have verified that I can ssh into both APs from hass.io, but when integrating into my config I get an error every time. My config looks like this:

device_tracker:
  - platform: unifi
    host: !secret unifi_ap1
    username: !secret unifi_username
    password: !secret unifi_password
    verify_ssl: false

I have only tried one AP so far, but what could be wrong with the config?

My bad. Missed that the platform should be unifi_direct.