@voiceclaw/voiceclaw-plugin 1.0.3 → 1.0.4

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.
Files changed (2) hide show
  1. package/dist/index.js +9 -3
  2. package/package.json +1 -1
package/dist/index.js CHANGED
@@ -80,22 +80,27 @@ export default function register(api) {
80
80
  listAccountIds: (cfg) => {
81
81
  const accounts = cfg.channels?.voiceclaw?.accounts ?? {};
82
82
  const ids = Object.keys(accounts);
83
+ const topLevelConfig = cfg.plugins?.entries?.['voiceclaw-plugin']?.config;
84
+ console.log(`[VoiceClaw Plugin] listAccountIds called. topLevelConfig exists: ${!!topLevelConfig}, explicit channels: ${ids.join(',')}`);
83
85
  // If top-level config exists, ensure 'default' is in the list
84
- if (cfg.plugins?.entries?.['voiceclaw-plugin']?.config && !ids.includes('default')) {
86
+ if (topLevelConfig && !ids.includes('default')) {
85
87
  ids.push('default');
86
88
  }
89
+ console.log(`[VoiceClaw Plugin] listAccountIds returning: ${ids.join(',')}`);
87
90
  return ids;
88
91
  },
89
92
  resolveAccount: (cfg, accountId) => {
90
93
  const accounts = cfg.channels?.voiceclaw?.accounts ?? {};
91
94
  const id = accountId ?? 'default';
92
95
  const account = accounts[id] ?? {};
96
+ let finalAccount = account;
93
97
  // Merge with top-level plugin config if this is the default account
94
98
  if (id === 'default') {
95
99
  const topLevelConfig = cfg.plugins?.entries?.['voiceclaw-plugin']?.config ?? {};
96
- return { ...topLevelConfig, ...account };
100
+ finalAccount = { ...topLevelConfig, ...account };
97
101
  }
98
- return account;
102
+ console.log(`[VoiceClaw Plugin] resolveAccount for ${id} returning:`, finalAccount);
103
+ return finalAccount;
99
104
  },
100
105
  },
101
106
  outbound: {
@@ -119,6 +124,7 @@ export default function register(api) {
119
124
  },
120
125
  gateway: {
121
126
  start: async (ctx) => {
127
+ api.logger.info('VoiceClaw: gateway.start() called');
122
128
  handleInbound = ctx.processInbound;
123
129
  let accounts = ctx.config.channels?.voiceclaw?.accounts ?? {};
124
130
  // Auto-inject default account if top-level config exists and default isn't explicitly defined
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@voiceclaw/voiceclaw-plugin",
3
- "version": "1.0.3",
3
+ "version": "1.0.4",
4
4
  "description": "OpenClaw channel plugin for VoiceClaw — relay messages between your AI agent and the VoiceClaw iOS/macOS app via Siri",
5
5
  "main": "dist/index.js",
6
6
  "type": "module",