feishu-mcp 0.1.9-test.3 → 0.1.9-test.4
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/server.js +1 -10
- package/package.json +1 -1
package/dist/server.js
CHANGED
|
@@ -8,7 +8,6 @@ import { SSEConnectionManager } from './manager/sseConnectionManager.js';
|
|
|
8
8
|
import { FeishuMcp } from './mcp/feishuMcp.js';
|
|
9
9
|
import { callback } from './services/callbackService.js';
|
|
10
10
|
import { UserAuthManager, UserContextManager, getBaseUrl, TokenCacheManager, TokenRefreshManager } from './utils/auth/index.js';
|
|
11
|
-
import { Config } from './utils/config.js';
|
|
12
11
|
export class FeishuMcpServer {
|
|
13
12
|
constructor() {
|
|
14
13
|
Object.defineProperty(this, "connectionManager", {
|
|
@@ -47,15 +46,7 @@ export class FeishuMcpServer {
|
|
|
47
46
|
}
|
|
48
47
|
async connect(transport) {
|
|
49
48
|
const server = new FeishuMcp();
|
|
50
|
-
|
|
51
|
-
const config = Config.getInstance();
|
|
52
|
-
const baseUrl = `http://localhost:${config.server.port}`;
|
|
53
|
-
await this.userContextManager.run({
|
|
54
|
-
userKey: 'stdio',
|
|
55
|
-
baseUrl: baseUrl
|
|
56
|
-
}, async () => {
|
|
57
|
-
await server.connect(transport);
|
|
58
|
-
});
|
|
49
|
+
await server.connect(transport);
|
|
59
50
|
// 监听 transport 关闭事件,清理 callback 服务器
|
|
60
51
|
// 对于 stdio 模式,监听 stdin 关闭事件
|
|
61
52
|
if (process.stdin && typeof process.stdin.on === 'function') {
|