How to get logged-in user's IP address

I want to store logged-in user’s IP address to the table
what is the step?

Actually, we want to know how do we get the IP info of deplay device of a running Tulip Player

Hey @Xin -

This is a great idea. We do expose the station name, which can act as a unique identifier for that display device, but supporting IP address probably makes sense.

What is your usecase where you would use IP over station name?


Hi, Pete,
Thanks for reply!

We are developing an app to detect whethe PAD, PDA are online everyday. We need to gather these device location. In our company, different physical areas had been assigned different WiFi IP subnet. So, once we have device IP, we are able to identify it’s physical area. This would be useful for us for asset audit purpose.

Bootter Qian

Hey @jinbootter.qian -

Thanks for the additonal context. This is a first time ask (as far as I can find) so I wrote up a feature request for this. In the meantime I made a custom widget that pulls the external facing IP address of the Tulip Player based on this guide.

The above linked document goes through the process to import this custom widget into your instance. The setup on this widget is stupid simple. Add the widget to your app, and set the userIP setting to the variable you want to store the user IP to.

NOTE: The custom widget can be off screen in your app, and it will still work.

Second Note: This widget hasn’t gone through the standard Tulip code review process, use it at your own risk
customWidget-Get IP (1).json (1.9 KB)

Hi, Pete,

Nice to have this widget to get external IP. it really works. Thanks your time developing this widget.

It was my bad that I didn’t explain to you we need widget or action of tulip that shows us an internal IP (LAN) of Tulip client device. Regarding internal IP, is any way we can get?

Thanks again!
Bootter Qian

Hey @jinbootter.qian -

This isn’t possible on a technical side anymore. Check out this thread:

In short, websites were using local IP addresses to track users for targeted ads so the service that used to return local IP address no longer does. I will dig into this a little deeper, but it doesn’t look like this is possible.

If Tulip apps were only able to be run on a windows executable (like Tulip player) we could potentially talk directly to the machine to get this information, but Tulip apps can also be run in browser, so we need to go through web portals to get information by default, and local IP isn’t accessible over any web connection.