@openclaw/tlon 2026.10.10 → 2026.10.34

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.
@@ -1,5 +1,5 @@
1
1
  import { SsrFBlockedError, createDedupeCache, createLoggerBackedRuntime, fetchWithSsrFGuard, isBlockedHostnameOrIp, ssrfPolicyFromDangerouslyAllowPrivateNetwork } from "../runtime-api.js";
2
- import { t as tlonPlugin } from "./channel-DwKKUzwx.mjs";
3
- import { n as setTlonRuntime } from "./runtime-ReERXJF_.mjs";
2
+ import { t as tlonPlugin } from "./channel-DUrG5iQ1.mjs";
3
+ import { n as setTlonRuntime } from "./runtime-Ck3lNvST.mjs";
4
4
  import "../api.js";
5
5
  export { SsrFBlockedError, createDedupeCache, createLoggerBackedRuntime, fetchWithSsrFGuard, isBlockedHostnameOrIp, setTlonRuntime, ssrfPolicyFromDangerouslyAllowPrivateNetwork, tlonPlugin };
@@ -1,5 +1,5 @@
1
- import { n as normalizeCompatibilityConfig, t as legacyConfigRules } from "./doctor-contract-CfYeTj9o.mjs";
2
- import { c as resolveTlonAccount, f as parseTlonTarget, i as tlonSetupContract, l as formatTargetHint, n as createTlonSetupWizardBase, p as resolveTlonOutboundTarget, s as listTlonAccountIds, u as normalizeShip } from "./setup-core-DnIfSMDp.mjs";
1
+ import { n as normalizeCompatibilityConfig, t as legacyConfigRules } from "./doctor-contract-bInPRAQZ.mjs";
2
+ import { c as resolveTlonAccount, d as normalizeShip, i as tlonSetupContract, l as TLON_CLUB_ID_RE, m as resolveTlonOutboundTarget, n as createTlonSetupWizardBase, p as parseTlonTarget, s as listTlonAccountIds, u as formatTargetHint } from "./setup-core-DQLcZhhT.mjs";
3
3
  import { buildChannelOutboundSessionRoute } from "openclaw/plugin-sdk/core";
4
4
  import { describeAccountSnapshot } from "openclaw/plugin-sdk/account-helpers";
5
5
  import { DEFAULT_ACCOUNT_ID } from "openclaw/plugin-sdk/account-id";
@@ -11,7 +11,13 @@ import { createComputedAccountStatusAdapter, createDefaultChannelRuntimeState }
11
11
  import { chunkTextForOutbound, sanitizeAssistantVisibleText } from "openclaw/plugin-sdk/text-chunking";
12
12
  import { ChannelImplicitMentionsSchema, buildChannelConfigSchema } from "openclaw/plugin-sdk/channel-config-schema";
13
13
  import { z } from "zod";
14
- // extensions/tlon/src/config-schema.ts
14
+ //#region extensions/tlon/src/config-schema.ts
15
+ const TlonClubPolicySchema = z.enum([
16
+ "approve-once",
17
+ "approve-each",
18
+ "disabled"
19
+ ]);
20
+ const TlonClubRulesSchema = z.record(z.string().regex(TLON_CLUB_ID_RE), z.enum(["allow", "deny"]));
15
21
  const ShipSchema = z.string().min(1);
16
22
  const ChannelNestSchema = z.string().min(1);
17
23
  const TlonChannelRuleSchema = z.object({
@@ -32,6 +38,8 @@ const tlonCommonConfigFields = {
32
38
  network: TlonNetworkSchema,
33
39
  groupChannels: z.array(ChannelNestSchema).optional(),
34
40
  dmAllowlist: z.array(ShipSchema).optional(),
41
+ clubPolicy: TlonClubPolicySchema.optional(),
42
+ clubRules: TlonClubRulesSchema.optional(),
35
43
  groupInviteAllowlist: z.array(ShipSchema).optional(),
36
44
  autoDiscoverChannels: z.boolean().optional(),
37
45
  showModelSignature: z.boolean().optional(),
@@ -54,6 +62,14 @@ const botThreadMentionHint = {
54
62
  label: "Require Mention in Bot Threads",
55
63
  help: "Override mention gating when this account's ship authored the thread root. False allows unmentioned replies; true requires a mention even after the bot participates. Omit to preserve existing behavior. Sender authorization still applies."
56
64
  };
65
+ const clubPolicyHint = {
66
+ label: "Tlon Group DM Policy",
67
+ help: "Default: approve-once. Enable each club once for automatic replies, require approval for every message with approve-each, or disable group DMs. Club authors and participants are unverified."
68
+ };
69
+ const clubRulesHint = {
70
+ label: "Tlon Group DM Rules",
71
+ help: "Club IDs mapped to allow or deny. Allow accepts unverified input delivered under that club ID with the agent's normal permitted tools; it does not authenticate participants or grant owner authority. Deny blocks the club, not a claimed ship. Approve-each still requires each message; disabled overrides all rules."
72
+ };
57
73
  const tlonChannelConfigSchema = buildChannelConfigSchema(TlonConfigSchema, { uiHints: {
58
74
  ...createChannelConfigUiHints({
59
75
  channelLabel: "Tlon",
@@ -61,19 +77,25 @@ const tlonChannelConfigSchema = buildChannelConfigSchema(TlonConfigSchema, { uiH
61
77
  }),
62
78
  requireMentionInBotThreads: botThreadMentionHint,
63
79
  "accounts.*.requireMentionInBotThreads": botThreadMentionHint,
64
- "authorization.channelRules.*.requireMentionInBotThreads": botThreadMentionHint
80
+ "authorization.channelRules.*.requireMentionInBotThreads": botThreadMentionHint,
81
+ clubPolicy: clubPolicyHint,
82
+ "accounts.*.clubPolicy": clubPolicyHint,
83
+ clubRules: clubRulesHint,
84
+ "accounts.*.clubRules": clubRulesHint
65
85
  } });
66
- // extensions/tlon/src/doctor.ts
86
+ //#endregion
87
+ //#region extensions/tlon/src/doctor.ts
67
88
  const tlonDoctor = {
68
89
  legacyConfigRules,
69
90
  normalizeCompatibilityConfig
70
91
  };
71
- // extensions/tlon/src/session-route.ts
92
+ //#endregion
93
+ //#region extensions/tlon/src/session-route.ts
72
94
  function resolveTlonOutboundSessionRoute(params) {
73
95
  const parsed = parseTlonTarget(params.target);
74
96
  if (!parsed) return null;
75
- const isGroup = parsed.kind === "group";
76
- const peerId = isGroup ? parsed.nest : parsed.ship;
97
+ const isGroup = parsed.kind !== "dm";
98
+ const peerId = parsed.kind === "dm" ? parsed.ship : parsed.kind === "club" ? `club:${parsed.clubId}` : parsed.nest;
77
99
  return buildChannelOutboundSessionRoute({
78
100
  cfg: params.cfg,
79
101
  agentId: params.agentId,
@@ -85,13 +107,14 @@ function resolveTlonOutboundSessionRoute(params) {
85
107
  id: peerId
86
108
  },
87
109
  chatType: isGroup ? "group" : "direct",
88
- from: isGroup ? `tlon:group:${peerId}` : `tlon:${peerId}`,
110
+ from: parsed.kind === "group" ? `tlon:group:${peerId}` : `tlon:${peerId}`,
89
111
  to: `tlon:${peerId}`
90
112
  });
91
113
  }
92
- // extensions/tlon/src/channel.ts
114
+ //#endregion
115
+ //#region extensions/tlon/src/channel.ts
93
116
  const TLON_CHANNEL_ID = "tlon";
94
- const loadTlonChannelRuntime = createLazyRuntimeModule(() => import("./channel.runtime-CdWyxE8W.mjs"));
117
+ const loadTlonChannelRuntime = createLazyRuntimeModule(() => import("./channel.runtime-DjdFSVIL.mjs"));
95
118
  const tlonSetupWizardProxy = createTlonSetupWizardBase(async (params) => await (await loadTlonChannelRuntime()).tlonSetupWizard.finalize(params));
96
119
  const tlonConfigAdapter = createHybridChannelConfigAdapter({
97
120
  sectionKey: TLON_CHANNEL_ID,
@@ -178,6 +201,7 @@ const tlonPlugin = createChatChannelPlugin({
178
201
  const parsed = parseTlonTarget(target);
179
202
  if (!parsed) return target.trim();
180
203
  if (parsed.kind === "dm") return parsed.ship;
204
+ if (parsed.kind === "club") return `club:${parsed.clubId}`;
181
205
  return parsed.nest;
182
206
  },
183
207
  inferTargetChatType: ({ to }) => {
@@ -237,4 +261,5 @@ const tlonPlugin = createChatChannelPlugin({
237
261
  },
238
262
  outbound: tlonChannelOutbound
239
263
  });
240
- export { tlonPlugin as t };
264
+ //#endregion
265
+ export { TlonClubPolicySchema as n, TlonClubRulesSchema as r, tlonPlugin as t };