@wu529778790/open-im 1.10.9-beta.2 → 1.10.9-beta.21
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/README.md +43 -62
- package/README.zh-CN.md +43 -62
- package/dist/adapters/claude-sdk-adapter.d.ts +13 -0
- package/dist/adapters/claude-sdk-adapter.js +221 -23
- package/dist/adapters/registry.js +3 -0
- package/dist/channels/capabilities.js +5 -0
- package/dist/clawbot/client.d.ts +14 -0
- package/dist/clawbot/client.js +299 -0
- package/dist/clawbot/event-handler.d.ts +12 -0
- package/dist/clawbot/event-handler.js +85 -0
- package/dist/clawbot/message-sender.d.ts +18 -0
- package/dist/clawbot/message-sender.js +109 -0
- package/dist/clawbot/qr-login.d.ts +33 -0
- package/dist/clawbot/qr-login.js +120 -0
- package/dist/clawbot/types.d.ts +111 -0
- package/dist/clawbot/types.js +7 -0
- package/dist/codebuddy/cli-runner.js +31 -2
- package/dist/codex/cli-runner.js +28 -2
- package/dist/config/file-io.d.ts +6 -3
- package/dist/config/file-io.js +12 -7
- package/dist/config/types.d.ts +17 -1
- package/dist/config-web-page-i18n.d.ts +24 -2
- package/dist/config-web-page-i18n.js +24 -2
- package/dist/config-web.js +79 -0
- package/dist/config.d.ts +1 -1
- package/dist/config.js +38 -2
- package/dist/constants.d.ts +6 -0
- package/dist/constants.js +6 -0
- package/dist/dingtalk/client.js +2 -1
- package/dist/dingtalk/event-handler.js +1 -1
- package/dist/index.js +50 -0
- package/dist/qq/client.js +7 -1
- package/dist/queue/request-queue.js +11 -10
- package/dist/setup.js +131 -3
- package/dist/shared/active-chats.d.ts +2 -2
- package/dist/shared/ai-task.d.ts +14 -0
- package/dist/shared/ai-task.js +57 -9
- package/dist/shared/process-kill.d.ts +24 -0
- package/dist/shared/process-kill.js +79 -0
- package/dist/shared/reconnect.d.ts +28 -0
- package/dist/shared/reconnect.js +56 -0
- package/dist/shared/task-cleanup.d.ts +16 -0
- package/dist/shared/task-cleanup.js +34 -1
- package/dist/telegram/client.js +7 -1
- package/dist/telemetry/telemetry-upload.js +1 -1
- package/dist/wework/client.js +17 -5
- package/dist/wework/event-handler.js +3 -0
- package/dist/workbuddy/centrifuge-client.d.ts +4 -0
- package/dist/workbuddy/centrifuge-client.js +76 -28
- package/dist/workbuddy/client.js +39 -2
- package/package.json +1 -1
- package/web/dist/assets/index-BaLTMeeF.js +57 -0
- package/web/dist/index.html +1 -1
- package/dist/config/credentials.d.ts +0 -19
- package/dist/config/credentials.js +0 -36
- package/web/dist/assets/index-B-oVSMUp.js +0 -57
package/web/dist/index.html
CHANGED
|
@@ -7,7 +7,7 @@
|
|
|
7
7
|
<link rel="preconnect" href="https://fonts.googleapis.com" />
|
|
8
8
|
<link rel="preconnect" href="https://fonts.gstatic.com" crossorigin />
|
|
9
9
|
<link href="https://fonts.googleapis.com/css2?family=Inter:wght@400;500;600;700&display=swap" rel="stylesheet" />
|
|
10
|
-
<script type="module" crossorigin src="./assets/index-
|
|
10
|
+
<script type="module" crossorigin src="./assets/index-BaLTMeeF.js"></script>
|
|
11
11
|
<link rel="stylesheet" crossorigin href="./assets/index-7fl61tV1.css">
|
|
12
12
|
</head>
|
|
13
13
|
<body>
|
|
@@ -1,19 +0,0 @@
|
|
|
1
|
-
import type { FileConfig } from './types.js';
|
|
2
|
-
/**
|
|
3
|
-
* Resolves a single credential value using the standard priority chain:
|
|
4
|
-
* environment variable → platform file config → legacy file config.
|
|
5
|
-
*/
|
|
6
|
-
export declare function resolveCredential(envKey: string, fileValue?: string, legacyFileValue?: string): string | undefined;
|
|
7
|
-
/**
|
|
8
|
-
* Generic per-platform credential resolution.
|
|
9
|
-
* Returns all resolved credentials and whether the platform should be enabled.
|
|
10
|
-
*/
|
|
11
|
-
export interface ResolvedPlatform {
|
|
12
|
-
enabled: boolean;
|
|
13
|
-
credentials: Record<string, string | undefined>;
|
|
14
|
-
}
|
|
15
|
-
export declare function resolvePlatformCredentials(envKeys: Record<string, string>, fileValues: Record<string, string | undefined>, legacyValues: Record<string, string | undefined>, requiredKeys: string[], enabledFlag?: boolean): ResolvedPlatform;
|
|
16
|
-
/**
|
|
17
|
-
* Extract WorkBuddy credentials, with legacy platforms.wechat migration support.
|
|
18
|
-
*/
|
|
19
|
-
export declare function resolveWorkBuddyFileConfig(fileConfig: FileConfig): NonNullable<FileConfig['platforms']>['workbuddy'] | undefined;
|
|
@@ -1,36 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* Resolves a single credential value using the standard priority chain:
|
|
3
|
-
* environment variable → platform file config → legacy file config.
|
|
4
|
-
*/
|
|
5
|
-
export function resolveCredential(envKey, fileValue, legacyFileValue) {
|
|
6
|
-
return process.env[envKey] ?? fileValue ?? legacyFileValue;
|
|
7
|
-
}
|
|
8
|
-
export function resolvePlatformCredentials(envKeys, fileValues, legacyValues, requiredKeys, enabledFlag) {
|
|
9
|
-
const credentials = {};
|
|
10
|
-
for (const [name, envKey] of Object.entries(envKeys)) {
|
|
11
|
-
credentials[name] = resolveCredential(envKey, fileValues[name], legacyValues[name]);
|
|
12
|
-
}
|
|
13
|
-
const hasRequired = requiredKeys.every((key) => credentials[key] !== undefined && credentials[key] !== '');
|
|
14
|
-
return {
|
|
15
|
-
enabled: hasRequired && enabledFlag !== false,
|
|
16
|
-
credentials,
|
|
17
|
-
};
|
|
18
|
-
}
|
|
19
|
-
/**
|
|
20
|
-
* Extract WorkBuddy credentials, with legacy platforms.wechat migration support.
|
|
21
|
-
*/
|
|
22
|
-
export function resolveWorkBuddyFileConfig(fileConfig) {
|
|
23
|
-
const direct = fileConfig.platforms?.workbuddy;
|
|
24
|
-
if (direct)
|
|
25
|
-
return direct;
|
|
26
|
-
const legacyWechat = fileConfig.platforms?.wechat;
|
|
27
|
-
if (legacyWechat?.workbuddyAccessToken && legacyWechat?.workbuddyRefreshToken) {
|
|
28
|
-
return {
|
|
29
|
-
accessToken: legacyWechat.workbuddyAccessToken,
|
|
30
|
-
refreshToken: legacyWechat.workbuddyRefreshToken,
|
|
31
|
-
userId: legacyWechat.userId,
|
|
32
|
-
baseUrl: legacyWechat.workbuddyBaseUrl,
|
|
33
|
-
};
|
|
34
|
-
}
|
|
35
|
-
return undefined;
|
|
36
|
-
}
|