@agent-wechat/agent-wechat 1.3.3 → 1.4.0-beta.0

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,14 +1,42 @@
1
1
  {
2
2
  "id": "agent-wechat",
3
3
  "contracts": {
4
- "tools": ["wechat_history", "wechat_search", "wechat_message", "wechat_media", "wechat_archive_threads", "wechat_archive_search", "wechat_archive_history", "wechat_archive_message", "wechat_archive_media", "wechat_recall", "wechat_send_share", "wechat_group_info", "wechat_login"]
4
+ "tools": [
5
+ "wechat_history",
6
+ "wechat_search",
7
+ "wechat_message",
8
+ "wechat_media",
9
+ "wechat_archive_threads",
10
+ "wechat_archive_search",
11
+ "wechat_archive_history",
12
+ "wechat_archive_message",
13
+ "wechat_archive_media",
14
+ "wechat_recall",
15
+ "wechat_send_share",
16
+ "wechat_group_info",
17
+ "wechat_login",
18
+ "wechat_call"
19
+ ]
5
20
  },
6
21
  "toolMetadata": {
7
- "wechat_archive_threads": { "optional": true },
8
- "wechat_archive_search": { "optional": true },
9
- "wechat_archive_history": { "optional": true },
10
- "wechat_archive_message": { "optional": true },
11
- "wechat_archive_media": { "optional": true }
22
+ "wechat_archive_threads": {
23
+ "optional": true
24
+ },
25
+ "wechat_archive_search": {
26
+ "optional": true
27
+ },
28
+ "wechat_archive_history": {
29
+ "optional": true
30
+ },
31
+ "wechat_archive_message": {
32
+ "optional": true
33
+ },
34
+ "wechat_archive_media": {
35
+ "optional": true
36
+ },
37
+ "wechat_call": {
38
+ "optional": true
39
+ }
12
40
  },
13
41
  "legacyPluginIds": [
14
42
  "wechat"
@@ -125,6 +153,163 @@
125
153
  }
126
154
  }
127
155
  }
156
+ },
157
+ "calls": {
158
+ "type": "object",
159
+ "additionalProperties": false,
160
+ "description": "Independent voice and video permissions. Both default off; the current backend supports direct voice only.",
161
+ "properties": {
162
+ "voice": {
163
+ "type": "object",
164
+ "additionalProperties": false,
165
+ "properties": {
166
+ "enabled": {
167
+ "type": "boolean",
168
+ "default": false,
169
+ "description": "Enable direct voice calling. Disabled voice calls are ignored without answering or declining."
170
+ },
171
+ "inboundPolicy": {
172
+ "type": "string",
173
+ "enum": [
174
+ "disabled",
175
+ "allowlist"
176
+ ]
177
+ },
178
+ "inboundAllowFrom": {
179
+ "type": "array",
180
+ "maxItems": 128,
181
+ "items": {
182
+ "type": "string",
183
+ "minLength": 1,
184
+ "maxLength": 200
185
+ }
186
+ },
187
+ "outboundPolicy": {
188
+ "type": "string",
189
+ "enum": [
190
+ "disabled",
191
+ "allowlist"
192
+ ]
193
+ },
194
+ "outboundAllowTo": {
195
+ "type": "array",
196
+ "maxItems": 128,
197
+ "items": {
198
+ "type": "string",
199
+ "minLength": 1,
200
+ "maxLength": 200
201
+ }
202
+ },
203
+ "outboundToolAllowFrom": {
204
+ "type": "array",
205
+ "maxItems": 128,
206
+ "items": {
207
+ "type": "string",
208
+ "minLength": 1,
209
+ "maxLength": 200
210
+ }
211
+ },
212
+ "agentId": {
213
+ "type": "string",
214
+ "minLength": 1,
215
+ "maxLength": 200
216
+ },
217
+ "realtime": {
218
+ "type": "object",
219
+ "additionalProperties": false,
220
+ "properties": {
221
+ "provider": {
222
+ "type": "string",
223
+ "minLength": 1,
224
+ "maxLength": 200,
225
+ "description": "Use openai. Other providers and continuous-output models fail preflight without fallback."
226
+ },
227
+ "model": {
228
+ "type": "string",
229
+ "minLength": 1,
230
+ "maxLength": 200,
231
+ "description": "Realtime speech model; omitted uses the selected provider's default."
232
+ },
233
+ "voice": {
234
+ "type": "string",
235
+ "minLength": 1,
236
+ "maxLength": 200,
237
+ "description": "Spoken voice; omitted uses the selected provider's default."
238
+ },
239
+ "instructions": {
240
+ "type": "string",
241
+ "maxLength": 4000,
242
+ "description": "Additional conversation guidance; does not grant tool or account-owner authority."
243
+ },
244
+ "providers": {
245
+ "type": "object",
246
+ "additionalProperties": false,
247
+ "properties": {
248
+ "openai": {
249
+ "type": "object",
250
+ "additionalProperties": false,
251
+ "properties": {
252
+ "apiKey": {
253
+ "description": "Optional OpenClaw SecretRef or API-key string. Omitted uses the selected agent's OpenAI auth profile or Gateway environment."
254
+ }
255
+ }
256
+ }
257
+ }
258
+ }
259
+ }
260
+ },
261
+ "toolPolicy": {
262
+ "type": "string",
263
+ "enum": [
264
+ "none",
265
+ "safe-read-only"
266
+ ],
267
+ "default": "none"
268
+ },
269
+ "allowConsultSessionPersistence": {
270
+ "type": "boolean",
271
+ "default": false,
272
+ "description": "Required for safe-read-only consultation: OpenClaw creates a separate per-call agent session which can persist. This adapter does not store transcripts or recordings."
273
+ },
274
+ "consultation": {
275
+ "type": "object",
276
+ "additionalProperties": false,
277
+ "properties": {
278
+ "model": {
279
+ "type": "string",
280
+ "minLength": 1,
281
+ "maxLength": 200,
282
+ "pattern": "^[^/]+/.+$",
283
+ "description": "Agent-consult provider/model override; omitted uses the selected agent's model."
284
+ },
285
+ "timeoutMs": {
286
+ "type": "integer",
287
+ "minimum": 1000,
288
+ "maximum": 120000,
289
+ "default": 30000
290
+ }
291
+ }
292
+ },
293
+ "maxDurationSeconds": {
294
+ "type": "integer",
295
+ "minimum": 30,
296
+ "maximum": 3600,
297
+ "default": 300
298
+ }
299
+ }
300
+ },
301
+ "video": {
302
+ "type": "object",
303
+ "additionalProperties": false,
304
+ "properties": {
305
+ "enabled": {
306
+ "type": "boolean",
307
+ "default": false,
308
+ "description": "Allow video independently of voice. Current video capability is unavailable; permission alone never answers a video call or routes it as voice."
309
+ }
310
+ }
311
+ }
312
+ }
128
313
  }
129
314
  }
130
315
  },
@@ -305,6 +490,163 @@
305
490
  }
306
491
  }
307
492
  }
493
+ },
494
+ "calls": {
495
+ "type": "object",
496
+ "additionalProperties": false,
497
+ "description": "Independent voice and video permissions. Both default off; the current backend supports direct voice only.",
498
+ "properties": {
499
+ "voice": {
500
+ "type": "object",
501
+ "additionalProperties": false,
502
+ "properties": {
503
+ "enabled": {
504
+ "type": "boolean",
505
+ "default": false,
506
+ "description": "Enable direct voice calling. Disabled voice calls are ignored without answering or declining."
507
+ },
508
+ "inboundPolicy": {
509
+ "type": "string",
510
+ "enum": [
511
+ "disabled",
512
+ "allowlist"
513
+ ]
514
+ },
515
+ "inboundAllowFrom": {
516
+ "type": "array",
517
+ "maxItems": 128,
518
+ "items": {
519
+ "type": "string",
520
+ "minLength": 1,
521
+ "maxLength": 200
522
+ }
523
+ },
524
+ "outboundPolicy": {
525
+ "type": "string",
526
+ "enum": [
527
+ "disabled",
528
+ "allowlist"
529
+ ]
530
+ },
531
+ "outboundAllowTo": {
532
+ "type": "array",
533
+ "maxItems": 128,
534
+ "items": {
535
+ "type": "string",
536
+ "minLength": 1,
537
+ "maxLength": 200
538
+ }
539
+ },
540
+ "outboundToolAllowFrom": {
541
+ "type": "array",
542
+ "maxItems": 128,
543
+ "items": {
544
+ "type": "string",
545
+ "minLength": 1,
546
+ "maxLength": 200
547
+ }
548
+ },
549
+ "agentId": {
550
+ "type": "string",
551
+ "minLength": 1,
552
+ "maxLength": 200
553
+ },
554
+ "realtime": {
555
+ "type": "object",
556
+ "additionalProperties": false,
557
+ "properties": {
558
+ "provider": {
559
+ "type": "string",
560
+ "minLength": 1,
561
+ "maxLength": 200,
562
+ "description": "Use openai. Other providers and continuous-output models fail preflight without fallback."
563
+ },
564
+ "model": {
565
+ "type": "string",
566
+ "minLength": 1,
567
+ "maxLength": 200,
568
+ "description": "Realtime speech model; omitted uses the selected provider's default."
569
+ },
570
+ "voice": {
571
+ "type": "string",
572
+ "minLength": 1,
573
+ "maxLength": 200,
574
+ "description": "Spoken voice; omitted uses the selected provider's default."
575
+ },
576
+ "instructions": {
577
+ "type": "string",
578
+ "maxLength": 4000,
579
+ "description": "Additional conversation guidance; does not grant tool or account-owner authority."
580
+ },
581
+ "providers": {
582
+ "type": "object",
583
+ "additionalProperties": false,
584
+ "properties": {
585
+ "openai": {
586
+ "type": "object",
587
+ "additionalProperties": false,
588
+ "properties": {
589
+ "apiKey": {
590
+ "description": "Optional OpenClaw SecretRef or API-key string. Omitted uses the selected agent's OpenAI auth profile or Gateway environment."
591
+ }
592
+ }
593
+ }
594
+ }
595
+ }
596
+ }
597
+ },
598
+ "toolPolicy": {
599
+ "type": "string",
600
+ "enum": [
601
+ "none",
602
+ "safe-read-only"
603
+ ],
604
+ "default": "none"
605
+ },
606
+ "allowConsultSessionPersistence": {
607
+ "type": "boolean",
608
+ "default": false,
609
+ "description": "Required for safe-read-only consultation: OpenClaw creates a separate per-call agent session which can persist. This adapter does not store transcripts or recordings."
610
+ },
611
+ "consultation": {
612
+ "type": "object",
613
+ "additionalProperties": false,
614
+ "properties": {
615
+ "model": {
616
+ "type": "string",
617
+ "minLength": 1,
618
+ "maxLength": 200,
619
+ "pattern": "^[^/]+/.+$",
620
+ "description": "Agent-consult provider/model override; omitted uses the selected agent's model."
621
+ },
622
+ "timeoutMs": {
623
+ "type": "integer",
624
+ "minimum": 1000,
625
+ "maximum": 120000,
626
+ "default": 30000
627
+ }
628
+ }
629
+ },
630
+ "maxDurationSeconds": {
631
+ "type": "integer",
632
+ "minimum": 30,
633
+ "maximum": 3600,
634
+ "default": 300
635
+ }
636
+ }
637
+ },
638
+ "video": {
639
+ "type": "object",
640
+ "additionalProperties": false,
641
+ "properties": {
642
+ "enabled": {
643
+ "type": "boolean",
644
+ "default": false,
645
+ "description": "Allow video independently of voice. Current video capability is unavailable; permission alone never answers a video call or routes it as voice."
646
+ }
647
+ }
648
+ }
649
+ }
308
650
  }
309
651
  }
310
652
  }
@@ -317,6 +659,11 @@
317
659
  "path": "native.token",
318
660
  "expected": "string",
319
661
  "ownerKind": "capability"
662
+ },
663
+ {
664
+ "path": "calls.voice.realtime.providers.openai.apiKey",
665
+ "expected": "string",
666
+ "ownerKind": "capability"
320
667
  }
321
668
  ]
322
669
  }
@@ -324,6 +671,9 @@
324
671
  "uiHints": {
325
672
  "native.token": {
326
673
  "sensitive": true
674
+ },
675
+ "calls.voice.realtime.providers.openai.apiKey": {
676
+ "sensitive": true
327
677
  }
328
678
  }
329
679
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@agent-wechat/agent-wechat",
3
- "version": "1.3.3",
3
+ "version": "1.4.0-beta.0",
4
4
  "license": "MIT",
5
5
  "type": "module",
6
6
  "files": [
@@ -11,7 +11,7 @@
11
11
  "devDependencies": {
12
12
  "@types/node": "^22",
13
13
  "esbuild": "^0.25.0",
14
- "openclaw": "2026.10.7",
14
+ "openclaw": "2026.10.9",
15
15
  "typescript": "^5.4.5",
16
16
  "@agent-wechat/shared": "1.1.1"
17
17
  },
@@ -205,6 +205,163 @@
205
205
  }
206
206
  }
207
207
  }
208
+ },
209
+ "calls": {
210
+ "type": "object",
211
+ "additionalProperties": false,
212
+ "description": "Independent voice and video permissions. Both default off; the current backend supports direct voice only.",
213
+ "properties": {
214
+ "voice": {
215
+ "type": "object",
216
+ "additionalProperties": false,
217
+ "properties": {
218
+ "enabled": {
219
+ "type": "boolean",
220
+ "default": false,
221
+ "description": "Enable direct voice calling. Disabled voice calls are ignored without answering or declining."
222
+ },
223
+ "inboundPolicy": {
224
+ "type": "string",
225
+ "enum": [
226
+ "disabled",
227
+ "allowlist"
228
+ ]
229
+ },
230
+ "inboundAllowFrom": {
231
+ "type": "array",
232
+ "maxItems": 128,
233
+ "items": {
234
+ "type": "string",
235
+ "minLength": 1,
236
+ "maxLength": 200
237
+ }
238
+ },
239
+ "outboundPolicy": {
240
+ "type": "string",
241
+ "enum": [
242
+ "disabled",
243
+ "allowlist"
244
+ ]
245
+ },
246
+ "outboundAllowTo": {
247
+ "type": "array",
248
+ "maxItems": 128,
249
+ "items": {
250
+ "type": "string",
251
+ "minLength": 1,
252
+ "maxLength": 200
253
+ }
254
+ },
255
+ "outboundToolAllowFrom": {
256
+ "type": "array",
257
+ "maxItems": 128,
258
+ "items": {
259
+ "type": "string",
260
+ "minLength": 1,
261
+ "maxLength": 200
262
+ }
263
+ },
264
+ "agentId": {
265
+ "type": "string",
266
+ "minLength": 1,
267
+ "maxLength": 200
268
+ },
269
+ "realtime": {
270
+ "type": "object",
271
+ "additionalProperties": false,
272
+ "properties": {
273
+ "provider": {
274
+ "type": "string",
275
+ "minLength": 1,
276
+ "maxLength": 200,
277
+ "description": "Use openai. Other providers and continuous-output models fail preflight without fallback."
278
+ },
279
+ "model": {
280
+ "type": "string",
281
+ "minLength": 1,
282
+ "maxLength": 200,
283
+ "description": "Realtime speech model; omitted uses the selected provider's default."
284
+ },
285
+ "voice": {
286
+ "type": "string",
287
+ "minLength": 1,
288
+ "maxLength": 200,
289
+ "description": "Spoken voice; omitted uses the selected provider's default."
290
+ },
291
+ "instructions": {
292
+ "type": "string",
293
+ "maxLength": 4000,
294
+ "description": "Additional conversation guidance; does not grant tool or account-owner authority."
295
+ },
296
+ "providers": {
297
+ "type": "object",
298
+ "additionalProperties": false,
299
+ "properties": {
300
+ "openai": {
301
+ "type": "object",
302
+ "additionalProperties": false,
303
+ "properties": {
304
+ "apiKey": {
305
+ "description": "Optional OpenClaw SecretRef or API-key string. Omitted uses the selected agent's OpenAI auth profile or Gateway environment."
306
+ }
307
+ }
308
+ }
309
+ }
310
+ }
311
+ }
312
+ },
313
+ "toolPolicy": {
314
+ "type": "string",
315
+ "enum": [
316
+ "none",
317
+ "safe-read-only"
318
+ ],
319
+ "default": "none"
320
+ },
321
+ "allowConsultSessionPersistence": {
322
+ "type": "boolean",
323
+ "default": false,
324
+ "description": "Required for safe-read-only consultation: OpenClaw creates a separate per-call agent session which can persist. This adapter does not store transcripts or recordings."
325
+ },
326
+ "consultation": {
327
+ "type": "object",
328
+ "additionalProperties": false,
329
+ "properties": {
330
+ "model": {
331
+ "type": "string",
332
+ "minLength": 1,
333
+ "maxLength": 200,
334
+ "pattern": "^[^/]+/.+$",
335
+ "description": "Agent-consult provider/model override; omitted uses the selected agent's model."
336
+ },
337
+ "timeoutMs": {
338
+ "type": "integer",
339
+ "minimum": 1000,
340
+ "maximum": 120000,
341
+ "default": 30000
342
+ }
343
+ }
344
+ },
345
+ "maxDurationSeconds": {
346
+ "type": "integer",
347
+ "minimum": 30,
348
+ "maximum": 3600,
349
+ "default": 300
350
+ }
351
+ }
352
+ },
353
+ "video": {
354
+ "type": "object",
355
+ "additionalProperties": false,
356
+ "properties": {
357
+ "enabled": {
358
+ "type": "boolean",
359
+ "default": false,
360
+ "description": "Allow video independently of voice. Current video capability is unavailable; permission alone never answers a video call or routes it as voice."
361
+ }
362
+ }
363
+ }
364
+ }
208
365
  }
209
366
  }
210
367
  }
@@ -220,8 +377,11 @@
220
377
  "url": "git+https://github.com/thisnick/agent-wechat.git",
221
378
  "directory": "packages/openclaw-extension"
222
379
  },
380
+ "dependencies": {
381
+ "ws": "8.22.0"
382
+ },
223
383
  "scripts": {
224
- "build": "esbuild index.ts --bundle --format=esm --platform=node --outfile=dist/index.js --external:openclaw",
384
+ "build": "esbuild index.ts --bundle --format=esm --platform=node --outfile=dist/index.js --external:openclaw --external:ws",
225
385
  "typecheck": "tsc --noEmit",
226
386
  "test": "node --test --experimental-strip-types src/*.test.ts"
227
387
  }