MCPcopy
hub / github.com/simstudioai/sim / getTabSessionId

Function getTabSessionId

apps/sim/app/workspace/providers/socket-provider.tsx:59–68  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

57const AUTH_RETRY_MAX_MS = 30000
58
59function getTabSessionId(): string {
60 if (typeof window === 'undefined') return ''
61
62 let tabSessionId = sessionStorage.getItem(TAB_SESSION_ID_KEY)
63 if (!tabSessionId) {
64 tabSessionId = generateId()
65 sessionStorage.setItem(TAB_SESSION_ID_KEY, tabSessionId)
66 }
67 return tabSessionId
68}
69
70interface User {
71 id: string

Callers 1

SocketProviderFunction · 0.85

Calls 3

generateIdFunction · 0.90
getItemMethod · 0.80
setItemMethod · 0.80

Tested by

no test coverage detected