Welcome Guest! To enable all features please Login or Register.



Go to last post Go to first unread
#1 Posted : Wednesday, September 19, 2018 2:54:44 PM(UTC)

Rank: Guest

Joined: 9/19/2018(UTC)
Posts: 1
United Kingdom
Location: UK

I am hoping to use one call to get all session information as opposed to just an individual call per session. At the moment I am polling each session guid individually and it's taking a while.
#2 Posted : Wednesday, October 3, 2018 1:47:46 PM(UTC)

Rank: Administration

Medals: Level 4: Wise Old Owl! Received 100 Thanks!

Joined: 3/28/2014(UTC)
Posts: 2,806
United States

Thanks: 3 times
Was thanked: 345 time(s) in 299 post(s)
Offhand I can't think of a way to do this via the API (but I'm not saying its impossible via the API). With that said, it's likely easier to create an Extension that interacts with the SessionManager directly to return the information you want. This extension would contain a single WebService class which looks similar to:


public class Service : WebServiceBase
	public Guid[] GetSessionIDsWithGuestConnections()
		return SessionManagerPool.Demux.GetSessions()
			.Where(_ => _.ActiveConnections.Length > 0)
			.Select(s => s.SessionID)
	public Guid[] GetSessionIDsWithNoGuestConnections()
		return SessionManagerPool.Demux.GetSessions()
			.Where(_ => _.ActiveConnections.Length == 0)
			.Select(s => s.SessionID)

And invoking either of those methods via curl/wget/webrequest/whatever would return the desired information. The methods could easily be expanded to return the whole Session object instead of just the SessionID if that's more desirable.
ScreenConnect Team
Users browsing this topic
Forum Jump  
You cannot post new topics in this forum.
You cannot reply to topics in this forum.
You cannot delete your posts in this forum.
You cannot edit your posts in this forum.
You cannot create polls in this forum.
You cannot vote in polls in this forum.