(id: string, context: McpAuthContext)
| 23 | } |
| 24 | |
| 25 | async setContext(id: string, context: McpAuthContext): Promise<void> { |
| 26 | await getRedisCache().setJson(redisKey(id), SESSION_TTL_SECONDS, context); |
| 27 | logger.info( |
| 28 | { |
| 29 | sessionId: id, |
| 30 | clientType: context.clientType, |
| 31 | organizationId: context.organizationId, |
| 32 | projectId: context.projectId, |
| 33 | }, |
| 34 | 'MCP session context stored', |
| 35 | ); |
| 36 | } |
| 37 | |
| 38 | getContext(id: string): Promise<McpAuthContext | null> { |
| 39 | return getRedisCache().getJson<McpAuthContext>(redisKey(id)); |
no test coverage detected