@openclaw/twitch 2026.8.1 → 2026.8.33

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,6 +1,6 @@
1
- import { n as stripMarkdownForTwitch, r as getOrCreateClientManager } from "./plugin-DitCSgI5.js";
2
- import { m as normalizeTwitchChannel } from "./setup-surface-BkbaBYll.js";
3
- import { t as getTwitchRuntime } from "./runtime-B5If4b0g.js";
1
+ import { n as stripMarkdownForTwitch, r as getOrCreateClientManager } from "./plugin-CEf12Jnx.mjs";
2
+ import { m as normalizeTwitchChannel } from "./setup-surface-CPpsDfR8.mjs";
3
+ import { t as getTwitchRuntime } from "./runtime-B5If4b0g.mjs";
4
4
  import { createChannelIngressError, createChannelIngressMonitor } from "openclaw/plugin-sdk/channel-outbound";
5
5
  import { formatErrorMessage } from "openclaw/plugin-sdk/error-runtime";
6
6
  import { normalizeLowercaseStringOrEmpty, normalizeNullableString } from "openclaw/plugin-sdk/string-coerce-runtime";
@@ -1,4 +1,4 @@
1
- import { a as getAccountConfig, c as resolveTwitchSnapshotAccountId, d as isAccountConfigured, f as missingTargetError, h as resolveTwitchToken, i as DEFAULT_ACCOUNT_ID, l as twitchConfigAdapter, m as normalizeTwitchChannel, o as resolveDefaultTwitchAccountId, p as normalizeToken, r as twitchSetupWizard, s as resolveTwitchAccountContext, t as twitchSetupContract, u as generateMessageId } from "./setup-surface-BkbaBYll.js";
1
+ import { a as getAccountConfig, c as resolveTwitchSnapshotAccountId, d as isAccountConfigured, f as missingTargetError, h as resolveTwitchToken, i as DEFAULT_ACCOUNT_ID, l as twitchConfigAdapter, m as normalizeTwitchChannel, o as resolveDefaultTwitchAccountId, p as normalizeToken, r as twitchSetupWizard, s as resolveTwitchAccountContext, t as twitchSetupContract, u as generateMessageId } from "./setup-surface-CPpsDfR8.mjs";
2
2
  import { describeAccountSnapshot } from "openclaw/plugin-sdk/account-helpers";
3
3
  import { MarkdownConfigSchema, buildChannelConfigSchema } from "openclaw/plugin-sdk/channel-config-schema";
4
4
  import { buildChannelOutboundSessionRoute, createChatChannelPlugin, stripChannelTargetPrefix } from "openclaw/plugin-sdk/channel-core";
@@ -197,9 +197,7 @@ var TwitchClientManager = class {
197
197
  case LogLevel.DEBUG:
198
198
  this.logger.debug?.(message);
199
199
  break;
200
- case LogLevel.TRACE:
201
- this.logger.debug?.(message);
202
- break;
200
+ case LogLevel.TRACE: this.logger.debug?.(message);
203
201
  }
204
202
  } }
205
203
  }
@@ -808,7 +806,8 @@ async function probeTwitch(account, timeoutMs) {
808
806
  username: account.username
809
807
  };
810
808
  const rawToken = normalizeToken(account.accessToken.trim());
811
- client = new ChatClient({ authProvider: new StaticAuthProvider(account.clientId ?? "", rawToken) });
809
+ const authProvider = new StaticAuthProvider(account.clientId ?? "", rawToken);
810
+ client = new ChatClient({ authProvider });
812
811
  const connectionPromise = new Promise((resolve, reject) => {
813
812
  let settled = false;
814
813
  const cleanup = () => {
@@ -1112,7 +1111,7 @@ function collectTwitchStatusIssues(accounts, getCfg) {
1112
1111
  fix: "Start the Twitch gateway to begin receiving messages. Check logs for connection errors."
1113
1112
  });
1114
1113
  if (entry.running && entry.lastStartAt) {
1115
- const daysSinceStart = (Date.now() - entry.lastStartAt) / (1e3 * 60 * 60 * 24);
1114
+ const daysSinceStart = (Date.now() - entry.lastStartAt) / 864e5;
1116
1115
  if (daysSinceStart > 7) issues.push({
1117
1116
  channel: "twitch",
1118
1117
  accountId,
@@ -1137,7 +1136,8 @@ function normalizeTwitchMessagingTarget(target) {
1137
1136
  const kindMatch = /^(user|dm|channel|group|conversation|room):/i.exec(providerTarget);
1138
1137
  const kind = kindMatch?.[1]?.toLowerCase();
1139
1138
  if (kind === "user" || kind === "dm") return "";
1140
- return normalizeTwitchChannel(kindMatch ? providerTarget.slice(kindMatch[0].length) : providerTarget);
1139
+ const channelTarget = kindMatch ? providerTarget.slice(kindMatch[0].length) : providerTarget;
1140
+ return normalizeTwitchChannel(channelTarget);
1141
1141
  }
1142
1142
  /**
1143
1143
  * Twitch channel plugin.
@@ -1260,7 +1260,7 @@ const twitchPlugin = createChatChannelPlugin({
1260
1260
  await runPassiveAccountLifecycle({
1261
1261
  abortSignal: ctx.abortSignal,
1262
1262
  start: async () => {
1263
- const { monitorTwitchProvider } = await import("./monitor-CgM3FcBi.js");
1263
+ const { monitorTwitchProvider } = await import("./monitor-Cn8NjByN.mjs");
1264
1264
  return monitorTwitchProvider({
1265
1265
  account,
1266
1266
  accountId,
@@ -0,0 +1,3 @@
1
+ import { n as twitchSetupPlugin } from "./setup-surface-CPpsDfR8.mjs";
2
+ import "../setup-plugin-api.js";
3
+ export { twitchSetupPlugin };
@@ -425,11 +425,12 @@ const twitchDmPolicy = createChannelDmPolicy({
425
425
  const resolvedAccountId = resolveSetupAccountId(cfg, accountId);
426
426
  const account = getAccountConfig(cfg, resolvedAccountId);
427
427
  const existingAllowFrom = account?.allowFrom ?? [];
428
- const allowFrom = normalizeStringEntries((await prompter.text({
428
+ const entry = await prompter.text({
429
429
  message: t("wizard.twitch.allowFromPrompt"),
430
430
  placeholder: "123456789",
431
431
  initialValue: existingAllowFrom[0] || void 0
432
- }) ?? "").split(/[\n,;]+/g));
432
+ });
433
+ const allowFrom = normalizeStringEntries((entry ?? "").split(/[\n,;]+/g));
433
434
  return setTwitchAccount(cfg, {
434
435
  ...account ?? void 0,
435
436
  allowFrom
package/dist/api.js CHANGED
@@ -1,3 +1,3 @@
1
- import { t as twitchPlugin } from "./plugin-DitCSgI5.js";
2
- import { n as setTwitchRuntime } from "./runtime-B5If4b0g.js";
1
+ import { t as twitchPlugin } from "./.setup/plugin-CEf12Jnx.mjs";
2
+ import { n as setTwitchRuntime } from "./.setup/runtime-B5If4b0g.mjs";
3
3
  export { setTwitchRuntime, twitchPlugin };
@@ -1,2 +1,2 @@
1
- import { t as twitchPlugin } from "./plugin-DitCSgI5.js";
1
+ import { t as twitchPlugin } from "./.setup/plugin-CEf12Jnx.mjs";
2
2
  export { twitchPlugin };
@@ -1,9 +1,10 @@
1
1
  import { defineBundledChannelSetupEntry } from "openclaw/plugin-sdk/channel-entry-contract";
2
+ import { fileURLToPath } from "node:url";
2
3
  //#region extensions/twitch/setup-entry.ts
3
4
  var setup_entry_default = defineBundledChannelSetupEntry({
4
5
  importMetaUrl: import.meta.url,
5
6
  plugin: {
6
- specifier: "./setup-plugin-api.js",
7
+ specifier: fileURLToPath(new URL(".setup/setup-plugin-api-Bdu2iZjV.mjs", import.meta.url).href),
7
8
  exportName: "twitchSetupPlugin"
8
9
  }
9
10
  });
@@ -1,2 +1,2 @@
1
- import { n as twitchSetupPlugin } from "./setup-surface-BkbaBYll.js";
1
+ import { n as twitchSetupPlugin } from "./.setup/setup-surface-CPpsDfR8.mjs";
2
2
  export { twitchSetupPlugin };
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@openclaw/twitch",
3
- "version": "2026.8.1",
3
+ "version": "2026.8.33",
4
4
  "description": "OpenClaw Twitch channel plugin for chat and moderation workflows.",
5
5
  "repository": {
6
6
  "type": "git",
@@ -30,10 +30,10 @@
30
30
  "minHostVersion": ">=2026.4.10"
31
31
  },
32
32
  "compat": {
33
- "pluginApi": ">=2026.8.1"
33
+ "pluginApi": ">=2026.8.33"
34
34
  },
35
35
  "build": {
36
- "openclawVersion": "2026.8.1"
36
+ "openclawVersion": "2026.8.33"
37
37
  },
38
38
  "channel": {
39
39
  "id": "twitch",
@@ -71,7 +71,7 @@
71
71
  "README.md"
72
72
  ],
73
73
  "peerDependencies": {
74
- "openclaw": ">=2026.8.1"
74
+ "openclaw": ">=2026.8.33"
75
75
  },
76
76
  "peerDependenciesMeta": {
77
77
  "openclaw": {