@openclaw/imessage 2026.10.10 → 2026.11.5-beta.1
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/.setup/{accounts-BH0coL46.mjs → accounts-C1Ypv3Wn.mjs} +6 -7
- package/dist/.setup/{actions-CW7XYYF4.mjs → actions-qOuKy8To.mjs} +360 -108
- package/dist/.setup/{actions.runtime-B2ZHQ3TJ.mjs → actions.runtime-Ccg9CARL.mjs} +10 -56
- package/dist/.setup/{api-6xi-NBrt.mjs → api-BXXuQQCS.mjs} +7 -7
- package/dist/.setup/{api-B0ih8Iof.mjs → api-DTbxSOPc.mjs} +8 -8
- package/dist/.setup/{approval-handler.runtime-BKmqba3L.mjs → approval-handler.runtime-B6vrFfZx.mjs} +112 -131
- package/dist/.setup/{approval-reactions-B9CJS0NT.mjs → approval-reactions-DBBsqbRC.mjs} +152 -72
- package/dist/.setup/{channel-6kcKpSRw.mjs → channel-CLaN4mQn.mjs} +142 -119
- package/dist/.setup/{channel.runtime-BW4A0m4h.mjs → channel.runtime-XJGx1MIH.mjs} +205 -363
- package/dist/.setup/chat-context-fTfJVqAi.mjs +77 -0
- package/dist/.setup/chat-lookup-xtPsOBkl.mjs +50 -0
- package/dist/.setup/client-D_BaG8sC.mjs +367 -0
- package/dist/.setup/{config-schema-DRkdRC21.mjs → config-schema-BjkQV5P5.mjs} +1 -2
- package/dist/.setup/{conversation-bindings-vZFn6sN2.mjs → conversation-bindings-8DjxoIYU.mjs} +9 -6
- package/dist/.setup/{media-contract-CoixpXRX.mjs → media-contract-BErFBKV9.mjs} +1 -1
- package/dist/.setup/{message-tool-api-CxSY_rh7.mjs → message-tool-api-DtZ1wKbT.mjs} +3 -6
- package/dist/.setup/{remote-file-CCgMYZ-u.mjs → remote-file-DpK3GQFD.mjs} +8 -22
- package/dist/.setup/{sanitize-outbound-C02fJrn6.mjs → sanitize-outbound-Dhjhz0a-.mjs} +23 -27
- package/dist/.setup/{send-D98hQFdv.mjs → send-DhEW0gfe.mjs} +150 -226
- package/dist/.setup/{setup-core-BWnW0czE.mjs → setup-core-B1_P_t4T.mjs} +2 -2
- package/dist/.setup/{setup-surface-aRZhAzzQ.mjs → setup-surface-CD28mXWK.mjs} +11 -25
- package/dist/.setup/{targets-CIx4BKqL.mjs → targets-C7CIWJ0k.mjs} +12 -3
- package/dist/.source-module-urls/929c518fa2986b0f85f66bceefead22868db0ab452dee914dc6a2bb86b2e60ad.json +1 -1
- package/dist/api.js +8 -8
- package/dist/channel-config-api.js +1 -1
- package/dist/channel-plugin-api.js +1 -1
- package/dist/contract-api.js +1 -1
- package/dist/media-contract-api.js +1 -1
- package/dist/message-tool-api.js +1 -1
- package/dist/runtime-api.js +1 -3
- package/dist/session-binding-contract-api.js +1 -1
- package/dist/setup-entry.js +1 -1
- package/dist/src/chat-db.worker.js +1 -1
- package/node_modules/typebox/build/format/duration.d.mts +2 -2
- package/node_modules/typebox/build/format/duration.mjs +2 -2
- package/node_modules/typebox/build/format/idn_email.d.mts +1 -0
- package/node_modules/typebox/build/format/idn_email.mjs +1 -0
- package/node_modules/typebox/build/format/idn_hostname.d.mts +1 -1
- package/node_modules/typebox/build/format/idn_hostname.mjs +1 -1
- package/node_modules/typebox/build/format/ipv4.d.mts +2 -2
- package/node_modules/typebox/build/format/ipv4.mjs +2 -2
- package/node_modules/typebox/build/format/ipv6.d.mts +1 -1
- package/node_modules/typebox/build/format/ipv6.mjs +1 -1
- package/node_modules/typebox/build/format/relative_json_pointer.d.mts +2 -2
- package/node_modules/typebox/build/format/relative_json_pointer.mjs +2 -2
- package/node_modules/typebox/build/schema/build.mjs +1 -0
- package/node_modules/typebox/build/schema/engine/_unique.d.mts +4 -2
- package/node_modules/typebox/build/schema/engine/_unique.mjs +7 -3
- package/node_modules/typebox/build/schema/engine/additionalItems.mjs +3 -3
- package/node_modules/typebox/build/schema/engine/additionalProperties.d.mts +0 -3
- package/node_modules/typebox/build/schema/engine/additionalProperties.mjs +15 -17
- package/node_modules/typebox/build/schema/engine/contains.mjs +3 -3
- package/node_modules/typebox/build/schema/engine/index.d.mts +1 -0
- package/node_modules/typebox/build/schema/engine/index.mjs +1 -0
- package/node_modules/typebox/build/schema/engine/items.mjs +7 -4
- package/node_modules/typebox/build/schema/engine/maxContains.mjs +2 -2
- package/node_modules/typebox/build/schema/engine/minContains.mjs +3 -3
- package/node_modules/typebox/build/schema/engine/oneOf.mjs +2 -2
- package/node_modules/typebox/build/schema/engine/patternProperties.mjs +2 -2
- package/node_modules/typebox/build/schema/engine/propertyNames.mjs +2 -2
- package/node_modules/typebox/build/schema/engine/unevaluatedItems.mjs +2 -2
- package/node_modules/typebox/build/schema/engine/unevaluatedProperties.mjs +2 -2
- package/node_modules/typebox/build/system/hashing/hash.mjs +63 -34
- package/node_modules/typebox/build/system/locale/en_US.mjs +2 -1
- package/node_modules/typebox/build/system/memory/assign.d.mts +2 -8
- package/node_modules/typebox/build/system/memory/assign.mjs +13 -6
- package/node_modules/typebox/build/system/memory/clone.d.mts +4 -5
- package/node_modules/typebox/build/system/memory/clone.mjs +8 -96
- package/node_modules/typebox/build/system/memory/create.d.mts +1 -5
- package/node_modules/typebox/build/system/memory/create.mjs +18 -13
- package/node_modules/typebox/build/system/memory/deep.d.mts +2 -0
- package/node_modules/typebox/build/system/memory/deep.mjs +108 -0
- package/node_modules/typebox/build/system/memory/discard.d.mts +1 -1
- package/node_modules/typebox/build/system/memory/discard.mjs +9 -8
- package/node_modules/typebox/build/system/memory/finalize.d.mts +4 -0
- package/node_modules/typebox/build/system/memory/finalize.mjs +30 -0
- package/node_modules/typebox/build/system/memory/keys.d.mts +2 -0
- package/node_modules/typebox/build/system/memory/keys.mjs +8 -0
- package/node_modules/typebox/build/system/memory/update.d.mts +1 -4
- package/node_modules/typebox/build/system/memory/update.mjs +43 -16
- package/node_modules/typebox/build/type/engine/call/index.d.mts +1 -0
- package/node_modules/typebox/build/type/engine/call/index.mjs +1 -0
- package/node_modules/typebox/build/type/engine/evaluate/composite.d.mts +2 -24
- package/node_modules/typebox/build/type/engine/evaluate/composite.mjs +2 -29
- package/node_modules/typebox/build/type/engine/evaluate/index.d.mts +1 -0
- package/node_modules/typebox/build/type/engine/evaluate/index.mjs +1 -0
- package/node_modules/typebox/build/type/engine/evaluate/narrow.d.mts +5 -1
- package/node_modules/typebox/build/type/engine/evaluate/narrow.mjs +6 -1
- package/node_modules/typebox/build/type/engine/evaluate/property.d.mts +30 -0
- package/node_modules/typebox/build/type/engine/evaluate/property.mjs +29 -0
- package/node_modules/typebox/build/type/engine/immutable/instantiate_add.d.mts +1 -3
- package/node_modules/typebox/build/type/engine/immutable/instantiate_add.mjs +1 -4
- package/node_modules/typebox/build/type/engine/object/from_intersect.d.mts +2 -2
- package/node_modules/typebox/build/type/engine/object/from_intersect.mjs +2 -2
- package/node_modules/typebox/build/type/engine/object/from_union.d.mts +2 -2
- package/node_modules/typebox/build/type/engine/object/from_union.mjs +2 -2
- package/node_modules/typebox/build/type/engine/optional/instantiate_add.d.mts +1 -3
- package/node_modules/typebox/build/type/engine/optional/instantiate_add.mjs +1 -4
- package/node_modules/typebox/build/type/engine/readonly/instantiate_add.d.mts +1 -3
- package/node_modules/typebox/build/type/engine/readonly/instantiate_add.mjs +1 -4
- package/node_modules/typebox/build/type/engine/this/index.d.mts +1 -0
- package/node_modules/typebox/build/type/engine/this/index.mjs +1 -0
- package/node_modules/typebox/build/value/clone/clone.d.mts +4 -3
- package/node_modules/typebox/build/value/clone/clone.mjs +5 -7
- package/node_modules/typebox/build/value/repair/from_cyclic.d.mts +2 -0
- package/node_modules/typebox/build/value/repair/from_cyclic.mjs +6 -0
- package/node_modules/typebox/build/value/shared/union_priority_sort.mjs +25 -14
- package/node_modules/typebox/package.json +1 -1
- package/node_modules/typebox/readme.md +1 -1
- package/node_modules/zod/package.json +1 -1
- package/node_modules/zod/src/v4/classic/tests/array.test.ts +27 -0
- package/node_modules/zod/src/v4/classic/tests/map.test.ts +7 -0
- package/node_modules/zod/src/v4/classic/tests/set.test.ts +6 -0
- package/node_modules/zod/src/v4/core/compile.ts +9 -0
- package/node_modules/zod/src/v4/core/schemas.ts +35 -1
- package/node_modules/zod/src/v4/core/util.ts +13 -0
- package/node_modules/zod/src/v4/core/versions.ts +1 -1
- package/node_modules/zod/v4/core/compile.cjs +8 -0
- package/node_modules/zod/v4/core/compile.js +8 -0
- package/node_modules/zod/v4/core/schemas.cjs +30 -0
- package/node_modules/zod/v4/core/schemas.d.cts +3 -1
- package/node_modules/zod/v4/core/schemas.d.ts +3 -1
- package/node_modules/zod/v4/core/schemas.js +30 -0
- package/node_modules/zod/v4/core/util.cjs +15 -0
- package/node_modules/zod/v4/core/util.d.cts +2 -0
- package/node_modules/zod/v4/core/util.d.ts +2 -0
- package/node_modules/zod/v4/core/util.js +14 -0
- package/node_modules/zod/v4/core/versions.cjs +1 -1
- package/node_modules/zod/v4/core/versions.js +1 -1
- package/openclaw.plugin.json +0 -30
- package/package.json +6 -6
- package/dist/.setup/client-C3e7ZLqA.mjs +0 -739
- package/dist/.setup/question-reactions-DTj-VH3N.mjs +0 -67
- package/dist/.setup/reaction-context-Bw00FkmU.mjs +0 -105
- package/dist/.setup/runtime-BRQCPuAD.mjs +0 -7
- package/node_modules/typebox/build/system/memory/freeze.d.mts +0 -4
- package/node_modules/typebox/build/system/memory/freeze.mjs +0 -6
|
@@ -1,67 +0,0 @@
|
|
|
1
|
-
import { t as __exportAll } from "./rolldown-runtime-782esTHO.mjs";
|
|
2
|
-
import { i as normalizeIMessageGuid } from "./actions-CW7XYYF4.mjs";
|
|
3
|
-
import { t as resolveIMessageReactionContext } from "./reaction-context-Bw00FkmU.mjs";
|
|
4
|
-
import { createQuestionReactionTargetStore, questionGatewayRuntime } from "openclaw/plugin-sdk/question-gateway-runtime";
|
|
5
|
-
// extensions/imessage/src/question-reactions.ts
|
|
6
|
-
var question_reactions_exports = /* @__PURE__ */ __exportAll({
|
|
7
|
-
hasIMessageQuestionReactionTarget: () => hasIMessageQuestionReactionTarget,
|
|
8
|
-
maybeResolveIMessageQuestionReaction: () => maybeResolveIMessageQuestionReaction,
|
|
9
|
-
registerIMessageQuestionReactionTargetForDeliveredPayload: () => registerIMessageQuestionReactionTargetForDeliveredPayload
|
|
10
|
-
});
|
|
11
|
-
function buildKey(identity) {
|
|
12
|
-
const account = identity.accountId.trim();
|
|
13
|
-
const guid = normalizeIMessageGuid(identity.messageGuid);
|
|
14
|
-
return account && guid ? `${account}:${guid}` : null;
|
|
15
|
-
}
|
|
16
|
-
const questionReactionTargets = createQuestionReactionTargetStore({
|
|
17
|
-
channel: "imessage",
|
|
18
|
-
channelDisplayName: "iMessage",
|
|
19
|
-
buildKey,
|
|
20
|
-
registerChannelDelivery: questionGatewayRuntime.registerChannelDelivery,
|
|
21
|
-
resolveReaction: questionGatewayRuntime.resolveReaction
|
|
22
|
-
});
|
|
23
|
-
function resolveQuestionReaction(params) {
|
|
24
|
-
const reaction = resolveIMessageReactionContext(params.message, params.bodyText);
|
|
25
|
-
if (!reaction || reaction.action !== "added") return null;
|
|
26
|
-
const guids = [...new Set((reaction.targetGuids ?? []).map(normalizeIMessageGuid).filter(Boolean))];
|
|
27
|
-
if (guids.length === 0) return null;
|
|
28
|
-
const optionIndex = questionGatewayRuntime.resolveReactionIndex(reaction.emoji);
|
|
29
|
-
return optionIndex === void 0 ? null : {
|
|
30
|
-
optionIndex,
|
|
31
|
-
identities: guids.map((messageGuid) => ({
|
|
32
|
-
accountId: params.accountId,
|
|
33
|
-
messageGuid
|
|
34
|
-
}))
|
|
35
|
-
};
|
|
36
|
-
}
|
|
37
|
-
function registerIMessageQuestionReactionTargetForDeliveredPayload(params) {
|
|
38
|
-
const binding = questionGatewayRuntime.readReactionBinding(params.payload);
|
|
39
|
-
if (params.target.channel !== "imessage" || !binding) return false;
|
|
40
|
-
let registered = false;
|
|
41
|
-
for (const result of params.results) {
|
|
42
|
-
if (result.channel !== "imessage") continue;
|
|
43
|
-
const guid = typeof result.meta?.imessageMessageGuid === "string" ? result.meta.imessageMessageGuid : result.messageId;
|
|
44
|
-
if (/^\d+$/u.test(normalizeIMessageGuid(guid))) continue;
|
|
45
|
-
registered = questionReactionTargets.register(binding, {
|
|
46
|
-
accountId: params.accountId,
|
|
47
|
-
messageGuid: guid
|
|
48
|
-
}) || registered;
|
|
49
|
-
}
|
|
50
|
-
return registered;
|
|
51
|
-
}
|
|
52
|
-
function hasIMessageQuestionReactionTarget(params) {
|
|
53
|
-
const reaction = resolveQuestionReaction(params);
|
|
54
|
-
return reaction ? questionReactionTargets.has(reaction.identities) : false;
|
|
55
|
-
}
|
|
56
|
-
async function maybeResolveIMessageQuestionReaction(params) {
|
|
57
|
-
const reaction = resolveQuestionReaction(params);
|
|
58
|
-
if (!reaction) return false;
|
|
59
|
-
return await questionReactionTargets.resolve({
|
|
60
|
-
...reaction,
|
|
61
|
-
cfg: params.cfg,
|
|
62
|
-
senderId: params.senderId,
|
|
63
|
-
gatewayUrl: params.gatewayUrl,
|
|
64
|
-
logDebug: params.logDebug
|
|
65
|
-
});
|
|
66
|
-
}
|
|
67
|
-
export { maybeResolveIMessageQuestionReaction as n, question_reactions_exports as r, hasIMessageQuestionReactionTarget as t };
|
|
@@ -1,105 +0,0 @@
|
|
|
1
|
-
import { i as normalizeIMessageGuid } from "./actions-CW7XYYF4.mjs";
|
|
2
|
-
// extensions/imessage/src/monitor/reaction-context.ts
|
|
3
|
-
const TAPBACK_TEXT_PATTERNS = [
|
|
4
|
-
{
|
|
5
|
-
prefix: "loved",
|
|
6
|
-
action: "added",
|
|
7
|
-
emoji: "❤️"
|
|
8
|
-
},
|
|
9
|
-
{
|
|
10
|
-
prefix: "liked",
|
|
11
|
-
action: "added",
|
|
12
|
-
emoji: "👍"
|
|
13
|
-
},
|
|
14
|
-
{
|
|
15
|
-
prefix: "disliked",
|
|
16
|
-
action: "added",
|
|
17
|
-
emoji: "👎"
|
|
18
|
-
},
|
|
19
|
-
{
|
|
20
|
-
prefix: "laughed at",
|
|
21
|
-
action: "added",
|
|
22
|
-
emoji: "😂"
|
|
23
|
-
},
|
|
24
|
-
{
|
|
25
|
-
prefix: "emphasized",
|
|
26
|
-
action: "added",
|
|
27
|
-
emoji: "‼️"
|
|
28
|
-
},
|
|
29
|
-
{
|
|
30
|
-
prefix: "questioned",
|
|
31
|
-
action: "added",
|
|
32
|
-
emoji: "❓"
|
|
33
|
-
},
|
|
34
|
-
{
|
|
35
|
-
prefix: "removed a heart from",
|
|
36
|
-
action: "removed",
|
|
37
|
-
emoji: "❤️"
|
|
38
|
-
},
|
|
39
|
-
{
|
|
40
|
-
prefix: "removed a like from",
|
|
41
|
-
action: "removed",
|
|
42
|
-
emoji: "👍"
|
|
43
|
-
},
|
|
44
|
-
{
|
|
45
|
-
prefix: "removed a dislike from",
|
|
46
|
-
action: "removed",
|
|
47
|
-
emoji: "👎"
|
|
48
|
-
},
|
|
49
|
-
{
|
|
50
|
-
prefix: "removed a laugh from",
|
|
51
|
-
action: "removed",
|
|
52
|
-
emoji: "😂"
|
|
53
|
-
},
|
|
54
|
-
{
|
|
55
|
-
prefix: "removed an emphasis from",
|
|
56
|
-
action: "removed",
|
|
57
|
-
emoji: "‼️"
|
|
58
|
-
},
|
|
59
|
-
{
|
|
60
|
-
prefix: "removed a question from",
|
|
61
|
-
action: "removed",
|
|
62
|
-
emoji: "❓"
|
|
63
|
-
}
|
|
64
|
-
];
|
|
65
|
-
function normalizeReactionValue(value) {
|
|
66
|
-
return typeof value === "string" ? normalizeIMessageGuid(value) || void 0 : void 0;
|
|
67
|
-
}
|
|
68
|
-
function resolveReactionTargetGuidCandidates(...values) {
|
|
69
|
-
const candidates = [];
|
|
70
|
-
for (const value of values) {
|
|
71
|
-
if (typeof value !== "string") continue;
|
|
72
|
-
const raw = value.trim();
|
|
73
|
-
if (!raw) continue;
|
|
74
|
-
const normalized = normalizeIMessageGuid(raw);
|
|
75
|
-
for (const candidate of [normalized, raw]) if (candidate && !candidates.includes(candidate)) candidates.push(candidate);
|
|
76
|
-
}
|
|
77
|
-
return candidates;
|
|
78
|
-
}
|
|
79
|
-
function resolveTapbackTextContext(bodyText) {
|
|
80
|
-
const lower = bodyText.toLowerCase();
|
|
81
|
-
for (const pattern of TAPBACK_TEXT_PATTERNS) {
|
|
82
|
-
if (!lower.startsWith(pattern.prefix)) continue;
|
|
83
|
-
const afterPrefix = bodyText.slice(pattern.prefix.length).trim();
|
|
84
|
-
if (!/^(?:"[\s\S]*"|“[\s\S]*”)$/u.test(afterPrefix)) continue;
|
|
85
|
-
return {
|
|
86
|
-
action: pattern.action,
|
|
87
|
-
emoji: pattern.emoji,
|
|
88
|
-
targetText: afterPrefix.slice(1, -1).trim()
|
|
89
|
-
};
|
|
90
|
-
}
|
|
91
|
-
return null;
|
|
92
|
-
}
|
|
93
|
-
function resolveIMessageReactionContext(message, bodyText) {
|
|
94
|
-
if (message.is_reaction === true || message.is_tapback === true || typeof message.associated_message_type === "number" && Number.isFinite(message.associated_message_type) && message.associated_message_type >= 2e3 && message.associated_message_type < 4e3) {
|
|
95
|
-
const targetGuids = resolveReactionTargetGuidCandidates(message.reacted_to_guid, message.associated_message_guid);
|
|
96
|
-
return {
|
|
97
|
-
action: message.is_reaction_add === false ? "removed" : "added",
|
|
98
|
-
emoji: normalizeReactionValue(message.reaction_emoji) ?? normalizeReactionValue(message.reaction_type) ?? "reaction",
|
|
99
|
-
targetGuid: targetGuids[0],
|
|
100
|
-
targetGuids
|
|
101
|
-
};
|
|
102
|
-
}
|
|
103
|
-
return resolveTapbackTextContext(bodyText);
|
|
104
|
-
}
|
|
105
|
-
export { resolveIMessageReactionContext as t };
|
|
@@ -1,7 +0,0 @@
|
|
|
1
|
-
import { createPluginRuntimeStore } from "openclaw/plugin-sdk/runtime-store";
|
|
2
|
-
// extensions/imessage/src/runtime.ts
|
|
3
|
-
const { getRuntime: getIMessageRuntime, setRuntime: setIMessageRuntime, tryGetRuntime: getOptionalIMessageRuntime } = createPluginRuntimeStore({
|
|
4
|
-
pluginId: "imessage",
|
|
5
|
-
errorMessage: "iMessage runtime not initialized"
|
|
6
|
-
});
|
|
7
|
-
export { getOptionalIMessageRuntime as n, setIMessageRuntime as r, getIMessageRuntime as t };
|
|
@@ -1,6 +0,0 @@
|
|
|
1
|
-
// deno-lint-ignore-file no-explicit-any
|
|
2
|
-
import { Settings } from '../settings/index.mjs';
|
|
3
|
-
/** Conditionally freezes the value if `immutableTypes` is true, otherwise no action. */
|
|
4
|
-
export function Freeze(value) {
|
|
5
|
-
return Settings.Get().immutableTypes ? Object.freeze(value) : value;
|
|
6
|
-
}
|