MCPcopy
hub / github.com/Skyvern-AI/skyvern / list_sessions

Function list_sessions

scripts/test_persistent_browsers.py:46–63  ·  view source on GitHub ↗

List all active browser sessions

()

Source from the content-addressed store, hash-verified

44
45
46def list_sessions() -> None:
47 """List all active browser sessions"""
48 try:
49 response = make_request("GET", "/browser_sessions")
50 sessions = response.json()
51 print("\nActive browser sessions:")
52 if not sessions:
53 print(" No active sessions found")
54 return
55 for session in sessions:
56 try:
57 print(json.dumps(session, indent=2))
58 print(" ---")
59 except Exception as e:
60 print(f" Error parsing session data: {session}")
61 print(f" Error: {str(e)}")
62 except Exception as e:
63 print(f"Error listing sessions: {str(e)}")
64
65
66def create_browser_session() -> Optional[str]:

Callers 1

mainFunction · 0.85

Calls 3

make_requestFunction · 0.85
dumpsMethod · 0.80
jsonMethod · 0.45

Tested by

no test coverage detected