Kara's Earth has a Superman (obviously) and its own Batman/Bruce Wayne.
She actually made a hilarious but indirect reference to him in her show when meeting James as Guardian. Saying masks were for that other city and another time when saying her cousin often teamed up with a hero who used gadgets. So Bruce has indeed been referenced a handful of times as existing there.
It's also why she put two and two together. Chances are as per the norm almost all of Bruce's family are in the hero business on her Earth so meeting his cousin was easy for her to assume who Batwoman was.