@openclaw/msteams 2026.9.6 → 2026.9.7
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/assets/icon.png +0 -0
- package/dist/.setup/{adapter.runtime-CQWZeqB5.cjs → adapter.runtime-BiWeMKXE.cjs} +21 -29
- package/dist/.setup/{approval-card-CPNH_q3P.cjs → approval-card-DWPDItvq.cjs} +6 -3
- package/dist/.setup/{approval-handler.runtime-CUnanUdR.cjs → approval-handler.runtime-D1s7UR3U.cjs} +4 -4
- package/dist/.setup/bot-framework-service-url-BUhTe8F3.cjs +55 -0
- package/dist/.setup/{channel-BDp16XRR.cjs → channel-ByzS7QJ0.cjs} +286 -180
- package/dist/.setup/{channel.runtime-Cv5F8JCa.cjs → channel.runtime-Baz8XDFs.cjs} +43 -142
- package/dist/.setup/{channel.setup-BVDfgdCc.cjs → channel.setup-DL8lcWT_.cjs} +6 -6
- package/dist/.setup/{config-schema-D22Lr1Qk.cjs → config-schema-0KoBzb0t.cjs} +24 -38
- package/dist/.setup/{messenger-8RA1FUJa.cjs → conversation-store-state-B7JuyZTm.cjs} +693 -287
- package/dist/.setup/{src-BfOCwlHp.cjs → monitor-BJ7IyH4y.cjs} +422 -592
- package/dist/.setup/{oauth-C6m7dvHj.cjs → oauth-DQjOnJ4l.cjs} +1 -1
- package/dist/.setup/{reaction-types-C7RA7Wxt.cjs → reaction-types-CQ4oSUe7.cjs} +2 -6
- package/dist/.setup/{resolve-allowlist-CHzaaWiC.cjs → resolve-allowlist-Pl_NQFYH.cjs} +55 -312
- package/dist/.setup/{rolldown-runtime-VH7oDXx4.cjs → rolldown-runtime-BloeesfJ.cjs} +22 -0
- package/dist/.setup/{send-CYN_N7O1.cjs → send-VUM7Sryb.cjs} +43 -96
- package/dist/.setup/{setup-plugin-api-DpiaA8z1.cjs → setup-plugin-api-Dyf8kF-l.cjs} +1 -1
- package/dist/.setup/{thread-session-CXgHK-yi.cjs → thread-session--rw3BTal.cjs} +2 -5
- package/dist/api.cjs +2 -2
- package/dist/channel-config-api.cjs +1 -1
- package/dist/channel-plugin-api.cjs +1 -1
- package/dist/configured-state.cjs +0 -1
- package/dist/directory-contract-api.cjs +1 -1
- package/dist/doctor-contract-api.cjs +201 -371
- package/dist/qa-runner-api.cjs +1 -1
- package/dist/runtime-api.cjs +0 -6
- package/dist/setup-entry.cjs +1 -1
- package/dist/setup-plugin-api.cjs +1 -1
- package/openclaw.plugin.json +46 -5
- package/package.json +9 -9
- package/dist/.setup/polls-BJ4-4uZm.cjs +0 -668
- package/dist/.setup/secret-input-C65t6kjM.cjs +0 -1
- package/dist/.setup/sso-token-store-YYLHXgFH.cjs +0 -111
|
@@ -1,111 +0,0 @@
|
|
|
1
|
-
const require_runtime = require("./runtime-gZTAuFux.cjs");
|
|
2
|
-
const require_polls = require("./polls-BJ4-4uZm.cjs");
|
|
3
|
-
let node_crypto = require("node:crypto");
|
|
4
|
-
//#region extensions/msteams/src/sso-token-store.ts
|
|
5
|
-
/**
|
|
6
|
-
* SQLite-backed store for Bot Framework OAuth SSO tokens.
|
|
7
|
-
*
|
|
8
|
-
* Tokens are keyed by (connectionName, userId). `userId` should be the
|
|
9
|
-
* stable AAD object ID (`activity.from.aadObjectId`) when available,
|
|
10
|
-
* falling back to the Bot Framework `activity.from.id`.
|
|
11
|
-
*
|
|
12
|
-
* The store is intentionally minimal: it persists the exchanged user
|
|
13
|
-
* token plus its expiration so consumers (for example tool handlers
|
|
14
|
-
* that call Microsoft Graph with delegated permissions) can fetch a
|
|
15
|
-
* valid token without reaching back into Bot Framework every turn.
|
|
16
|
-
*/
|
|
17
|
-
const MSTEAMS_SSO_TOKENS_LEGACY_FILENAME = "msteams-sso-tokens.json";
|
|
18
|
-
const MSTEAMS_SSO_TOKENS_NAMESPACE = "sso-tokens";
|
|
19
|
-
const SSO_TOKEN_MUTATION_KEY = "sso-tokens";
|
|
20
|
-
const MSTEAMS_MAX_SSO_TOKENS = 5e3;
|
|
21
|
-
const STORE_KEY_VERSION_PREFIX = "v2:";
|
|
22
|
-
function makeMSTeamsSsoTokenStoreKey(connectionName, userId) {
|
|
23
|
-
return `${STORE_KEY_VERSION_PREFIX}${(0, node_crypto.createHash)("sha256").update(JSON.stringify([connectionName, userId])).digest("hex")}`;
|
|
24
|
-
}
|
|
25
|
-
function createTokenStore(params) {
|
|
26
|
-
return require_runtime.getMSTeamsRuntime().state.openKeyedStore({
|
|
27
|
-
namespace: MSTEAMS_SSO_TOKENS_NAMESPACE,
|
|
28
|
-
maxEntries: MSTEAMS_MAX_SSO_TOKENS,
|
|
29
|
-
env: require_polls.resolveMSTeamsSqliteStateEnv(params)
|
|
30
|
-
});
|
|
31
|
-
}
|
|
32
|
-
function normalizeMSTeamsSsoStoredToken(value) {
|
|
33
|
-
if (!value || typeof value !== "object") return null;
|
|
34
|
-
const token = value;
|
|
35
|
-
if (typeof token.connectionName !== "string" || !token.connectionName || typeof token.userId !== "string" || !token.userId || typeof token.token !== "string" || !token.token || typeof token.updatedAt !== "string" || !token.updatedAt) return null;
|
|
36
|
-
return {
|
|
37
|
-
connectionName: token.connectionName,
|
|
38
|
-
userId: token.userId,
|
|
39
|
-
token: token.token,
|
|
40
|
-
...typeof token.expiresAt === "string" ? { expiresAt: token.expiresAt } : {},
|
|
41
|
-
updatedAt: token.updatedAt
|
|
42
|
-
};
|
|
43
|
-
}
|
|
44
|
-
function isMSTeamsSsoStoreData(value) {
|
|
45
|
-
if (!value || typeof value !== "object") return false;
|
|
46
|
-
const obj = value;
|
|
47
|
-
return obj.version === 1 && typeof obj.tokens === "object" && obj.tokens !== null;
|
|
48
|
-
}
|
|
49
|
-
function createMSTeamsSsoTokenStoreFs(params) {
|
|
50
|
-
const tokenStore = createTokenStore(params);
|
|
51
|
-
return {
|
|
52
|
-
async get({ connectionName, userId }) {
|
|
53
|
-
return await tokenStore.lookup(makeMSTeamsSsoTokenStoreKey(connectionName, userId)) ?? null;
|
|
54
|
-
},
|
|
55
|
-
async save(token) {
|
|
56
|
-
await require_polls.withMSTeamsSqliteMutationLock(params, SSO_TOKEN_MUTATION_KEY, async () => {
|
|
57
|
-
await tokenStore.register(makeMSTeamsSsoTokenStoreKey(token.connectionName, token.userId), require_polls.toPluginJsonValue({ ...token }));
|
|
58
|
-
});
|
|
59
|
-
},
|
|
60
|
-
async remove({ connectionName, userId }) {
|
|
61
|
-
let removed = false;
|
|
62
|
-
await require_polls.withMSTeamsSqliteMutationLock(params, SSO_TOKEN_MUTATION_KEY, async () => {
|
|
63
|
-
removed = await tokenStore.delete(makeMSTeamsSsoTokenStoreKey(connectionName, userId));
|
|
64
|
-
});
|
|
65
|
-
return removed;
|
|
66
|
-
}
|
|
67
|
-
};
|
|
68
|
-
}
|
|
69
|
-
//#endregion
|
|
70
|
-
Object.defineProperty(exports, "MSTEAMS_MAX_SSO_TOKENS", {
|
|
71
|
-
enumerable: true,
|
|
72
|
-
get: function() {
|
|
73
|
-
return MSTEAMS_MAX_SSO_TOKENS;
|
|
74
|
-
}
|
|
75
|
-
});
|
|
76
|
-
Object.defineProperty(exports, "MSTEAMS_SSO_TOKENS_LEGACY_FILENAME", {
|
|
77
|
-
enumerable: true,
|
|
78
|
-
get: function() {
|
|
79
|
-
return MSTEAMS_SSO_TOKENS_LEGACY_FILENAME;
|
|
80
|
-
}
|
|
81
|
-
});
|
|
82
|
-
Object.defineProperty(exports, "MSTEAMS_SSO_TOKENS_NAMESPACE", {
|
|
83
|
-
enumerable: true,
|
|
84
|
-
get: function() {
|
|
85
|
-
return MSTEAMS_SSO_TOKENS_NAMESPACE;
|
|
86
|
-
}
|
|
87
|
-
});
|
|
88
|
-
Object.defineProperty(exports, "createMSTeamsSsoTokenStoreFs", {
|
|
89
|
-
enumerable: true,
|
|
90
|
-
get: function() {
|
|
91
|
-
return createMSTeamsSsoTokenStoreFs;
|
|
92
|
-
}
|
|
93
|
-
});
|
|
94
|
-
Object.defineProperty(exports, "isMSTeamsSsoStoreData", {
|
|
95
|
-
enumerable: true,
|
|
96
|
-
get: function() {
|
|
97
|
-
return isMSTeamsSsoStoreData;
|
|
98
|
-
}
|
|
99
|
-
});
|
|
100
|
-
Object.defineProperty(exports, "makeMSTeamsSsoTokenStoreKey", {
|
|
101
|
-
enumerable: true,
|
|
102
|
-
get: function() {
|
|
103
|
-
return makeMSTeamsSsoTokenStoreKey;
|
|
104
|
-
}
|
|
105
|
-
});
|
|
106
|
-
Object.defineProperty(exports, "normalizeMSTeamsSsoStoredToken", {
|
|
107
|
-
enumerable: true,
|
|
108
|
-
get: function() {
|
|
109
|
-
return normalizeMSTeamsSsoStoredToken;
|
|
110
|
-
}
|
|
111
|
-
});
|