@agent-wechat/agent-wechat 2.4.2 → 2.6.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.
Files changed (3) hide show
  1. package/README.md +7 -7
  2. package/dist/index.js +40 -15
  3. package/package.json +2 -2
package/README.md CHANGED
@@ -46,7 +46,7 @@ The tool also accepts `disconnect` (retain saved trust), `logout` (durable nativ
46
46
  }
47
47
  ```
48
48
 
49
- Provision the native executable and account registration separately. Omitting `executable` resolves `wx` once from absolute trusted PATH entries. The plugin supports the package's tested npm launcher layout by selecting its already installed checksum-verified ELF payload directly. It never invokes an installer or shell. Unknown wrappers/old container CLIs are rejected. Managed startup refuses an occupied port and requires authenticated readiness matching the owned child PID, store path, server identity and process generation; it never adopts or terminates another process. Stop sends a graceful termination to its own child with bounded escalation. An unexpected child/stream failure is reported; automatic process crash restart is not implemented in this increment.
49
+ Provision the native executable and account registration separately. Omitting `executable` resolves `wx` once from absolute trusted PATH entries. The plugin supports the package's tested npm launcher layout by selecting its already installed checksum-verified ELF payload directly. It never invokes an installer or shell. Unknown wrappers/old container CLIs are rejected. Managed startup refuses an occupied port and requires authenticated readiness matching the owned child PID, store path, server identity and process generation; it never adopts or terminates another process. Stop sends a graceful termination to its own child with bounded escalation. When `wx --json version` lists `serve-exit-with-parent`, the child also runs with `--exit-with-parent`, so it stops gracefully by itself if the Gateway crashes or is killed; an older `wx` starts without the flag. An unexpected child/stream failure is reported; automatic process crash restart is not implemented in this increment.
50
50
 
51
51
  Managed startup sends the resolved token through a private stdin pipe; it creates no token file and does not put the token in arguments or the daemon environment. A managed `serverConfig` must omit `tokenFile`. Reload/restart the Gateway to change credentials or secret-provider configuration.
52
52
 
@@ -80,7 +80,7 @@ By default, `readPolicy: "on_inbound"` marks a whole thread read after its incom
80
80
 
81
81
  A whole-thread read also clears earlier unread messages in that thread, including messages the model did not receive. The daemon freezes the latest local message boundary, checks the expected version, updates local unread state and submits one native read-status notification. Server acceptance alone does not prove that a phone badge changed. A lost notification response remains `needs_review` and is never automatically resubmitted. Pending reads survive a Gateway restart and retry independently of model execution or new SSE traffic. `readPolicy: "never"` disables both local and remote marking, including previously queued reads. Crashes during an unfinished dispatch retain `needs_review`; the plugin does not automatically duplicate model turns or uncertain outgoing sends.
82
82
 
83
- The optional `readPolicy: "on_model_dispatch"` instead requires a confirmed model handoff. On OpenClaw **2026.11.2**, the host calls `onPreparedAgentRunStart` for the run that contains the dispatched message once its transcript is prepared, and that call confirms the handoff. It does not need `hooks.allowConversationAccess`. It happens before the provider request and before the host drops images for a text-only model, so it shows that the run started with the message, not that the model received every image. Built-in commands, rejected messages, and media without a ready supplied asset are never confirmed, and status reports `handoffUnconfirmed`.
83
+ The optional `readPolicy: "on_model_dispatch"` instead requires a confirmed model handoff. On OpenClaw **2026.11.4**, the host calls `onPreparedAgentRunStart` for the run that contains the dispatched message once its transcript is prepared, and that call confirms the handoff. It does not need `hooks.allowConversationAccess`. It happens before the provider request and before the host drops images for a text-only model, so it shows that the run started with the message, not that the model received every image. Built-in commands, rejected messages, and media without a ready supplied asset are never confirmed, and status reports `handoffUnconfirmed`.
84
84
 
85
85
  Hosts without `onPreparedAgentRunStart`, such as OpenClaw 2026.10.9, use a stricter compatibility path. Before dispatch, the adapter persists an immutable manifest binding the exact new message ID/version/content hash, policy hash, source and supplied asset hashes, and context roles. Text requires the exact current input and host-created message/account/session facts plus a matching `model_call_started`. Media additionally waits for the same run's `agent_end` snapshot and source-turn identity. Image bytes/MIME/length must match the frozen supplied representation; file/video/voice references must appear in the exact current body. Unknown, omitted, rewritten, merged or ambiguous inputs remain unconfirmed. This path requires the operator's explicit host permission, `plugins.entries.agent-wechat.hooks.allowConversationAccess: true`; it observes only run IDs issued by this adapter and never enables that permission itself. Without the grant, it leaves messages unread. The older `onAgentRunStart` also reports direct tools and early lifecycle phases and is never used as proof. Host/provider history formats can prevent confirmation even when a reply was delivered; use `on_inbound` for ordinary bot read behavior.
86
86
 
@@ -110,7 +110,7 @@ Stored-history tools return a recalled placeholder; media tools return terminal
110
110
 
111
111
  Old media handles whose stored source changed, or whose source identity cannot be verified, return terminal `unavailable` with `media_source_changed` or `media_identity_unavailable`. They expose no cached path and are not retried automatically. Fresh stored-message discovery can select the intended current message and its bound cached asset without resending a WeChat message.
112
112
 
113
- `node scripts/native-recall-model-smoke.mjs` builds the actual plugin and runs the pinned Gateway against synthetic native HTTP/SSE and a local provider. It checks registered tool discovery and exact-target execution, stable repeated keys, another thread's rejection, recall intake while provider/media requests are blocked, late-output suppression, out-of-order recall custody and one dispatch for a new exact occupant of a reused source ID. It makes no real account or native protocol exchange.
113
+ `node packages/openclaw-extension/test/smoke/recall-model.mjs` builds the actual plugin and runs the pinned Gateway against synthetic native HTTP/SSE and a local provider. It checks registered tool discovery and exact-target execution, stable repeated keys, another thread's rejection, recall intake while provider/media requests are blocked, late-output suppression, out-of-order recall custody and one dispatch for a new exact occupant of a reused source ID. It makes no real account or native protocol exchange.
114
114
 
115
115
  ## Stored-history tools
116
116
 
@@ -135,7 +135,7 @@ History/search return opaque string message IDs, a bounded text preview, coverag
135
135
 
136
136
  Missing media requests a durable daemon transfer by default, with a two-second bounded wait. A pending result includes its `jobId` when known and no claimed local path; call the same tool with the same message ID later to check. The daemon owns and deduplicates the transfer, so cancelling a tool invocation does not cancel submitted work. Use `download: false` for cached media only. `quality` defaults to `best` (best cached image, normal video or decoded voice); explicit `original`, `standard`, `thumbnail`, `normal` and `encoded` variants are strict and may be unavailable. Results report the actual variant and explicit pending, expired, unsupported, unavailable or too-large status. Never automatically retry `retryable: false` or confirmed expiry. The media tool requires account-scoped API `read` and `media` permission, including for download requests. Raw XML, signed transport URLs and keys are never returned.
137
137
 
138
- `node scripts/native-history-model-smoke.mjs` exercises the pinned Gateway with local account/media/model fixtures: durable group context, original file paths, one preview with a verified hash, a PNG sent as a file remaining a reference, direct image delivery, actual tool discovery, two paginated search calls, rejection of another thread's attachment before media access, one requested image download whose exact image bytes reach vision, and a cached file path reaching the provider. CI runs this check on both Linux architectures.
138
+ `node packages/openclaw-extension/test/smoke/history-model.mjs` exercises the pinned Gateway with local account/media/model fixtures: durable group context, original file paths, one preview with a verified hash, a PNG sent as a file remaining a reference, direct image delivery, actual tool discovery, two paginated search calls, rejection of another thread's attachment before media access, one requested image download whose exact image bytes reach vision, and a cached file path reaching the provider. CI runs this check on both Linux architectures.
139
139
 
140
140
  When asset metadata identifies an existing download job, retrieval polls that scoped job instead of submitting another transfer. A terminal job's reason and retryability are preserved, including in cache-only mode; this tool does not automatically retry failed jobs. A service rejection alone is not classified as expiry.
141
141
 
@@ -177,9 +177,9 @@ There is no plugin permission list, owner exception or archive sender/thread fil
177
177
 
178
178
  History/search/message/thread reads never send messages, mark threads read or change the inbound cursor. Archive media can submit the same bounded, deduplicated download jobs as `wechat_media`; it stays directly callable so actual image blocks reach vision.
179
179
 
180
- Run `node scripts/native-archive-tools-smoke.mjs` to check the pinned Gateway with three separately routed agents: no optional-tool grant, a full profile with an explicit deny, and an archive grant. It checks discovery and guessed-name invocation denial, cross-thread search pagination, other-sender history/media, unchanged default-tool scope, verified image bytes in provider input and a cached file path. All messages, account data and model responses in this test are synthetic. CI runs it on Linux x64 and ARM64.
180
+ Run `node packages/openclaw-extension/test/smoke/archive-tools.mjs` to check the pinned Gateway with three separately routed agents: no optional-tool grant, a full profile with an explicit deny, and an archive grant. It checks discovery and guessed-name invocation denial, cross-thread search pagination, other-sender history/media, unchanged default-tool scope, verified image bytes in provider input and a cached file path. All messages, account data and model responses in this test are synthetic. CI runs it on Linux x64 and ARM64.
181
181
 
182
- Run `node scripts/native-model-smoke.mjs` and `node scripts/native-media-model-smoke.mjs` after installing workspace dependencies. They use the actual pinned Gateway, a local model and synthetic daemon/files. Checks cover default inbound reads without conversation permission, commands without a model call, current provider input, image hashes and prepared previews, reference/transcription delivery, whole-thread read requests, lost-response/reopen recovery, duplicate prevention, omitted images on a text-only model, explicit model-handoff permission, never-read policy and group routing behavior. Transcription uses the real SDK with an explicitly configured local deterministic CLI; it does not test speech recognition accuracy. Concurrent text inputs were serialized into distinct model turns; merged-input refusal has unit coverage for the explicit model policy. These checks establish local runtime behavior, not external provider acceptance, semantic analysis or consumption.
182
+ Run `node packages/openclaw-extension/test/smoke/model.mjs` and `node packages/openclaw-extension/test/smoke/media-model.mjs` after installing workspace dependencies. They use the actual pinned Gateway, a local model and synthetic daemon/files. Checks cover default inbound reads without conversation permission, commands without a model call, current provider input, image hashes and prepared previews, reference/transcription delivery, whole-thread read requests, lost-response/reopen recovery, duplicate prevention, omitted images on a text-only model, explicit model-handoff permission, never-read policy and group routing behavior. Transcription uses the real SDK with an explicitly configured local deterministic CLI; it does not test speech recognition accuracy. Concurrent text inputs were serialized into distinct model turns; merged-input refusal has unit coverage for the explicit model policy. These checks establish local runtime behavior, not external provider acceptance, semantic analysis or consumption.
183
183
 
184
184
  Native text/media sends retain daemon intent/job identity and caller idempotency. Text waits for accepted submission; media jobs preserve partial and uncertain outcomes rather than resending. Ordinary audio remains a file; only explicit `audioAsVoice` requests independently encoded voice. Sender/group/mention gates run before retrieval/transcription. Verified voice may use the configured OpenClaw transcription runtime after admission. Native QR login uses a durable daemon operation and authenticated PNG retrieval. Logout commits local inhibition before at most one authenticated native logout, reporting the remote outcome separately; saved-device revocation remains unverified. Explicitly confirmed forgetting removes local auth while retaining history; disconnect retains reusable trust.
185
185
 
@@ -218,6 +218,6 @@ Set `native.gatewayFacade: {"enabled": true}` to register `/plugins/agent-wechat
218
218
 
219
219
  The actual Gateway authenticates requests before the proxy runs. Its bearer is never forwarded to the daemon; the plugin uses its private daemon token reference. Routes are restricted to the configured account, with no daemon-wide token/account administration. Binary bodies, byte ranges, status codes and SSE are preserved within explicit size limits. Client disconnect/plugin shutdown closes upstream streaming work without cancelling durable sends.
220
220
 
221
- `scripts/native-gateway-smoke.mjs` tests the built plugin on an isolated OpenClaw **2026.11.2** Gateway with synthetic loopback data: auth rejection, separate credentials, account boundaries, Range206, SSE and cancellation. This transport test is separate from the local model-boundary test above; neither uses an external model provider or a real WeChat account.
221
+ `packages/openclaw-extension/test/smoke/gateway.mjs` tests the built plugin on an isolated OpenClaw **2026.11.4** Gateway with synthetic loopback data: auth rejection, separate credentials, account boundaries, Range206, SSE and cancellation. This transport test is separate from the local model-boundary test above; neither uses an external model provider or a real WeChat account.
222
222
 
223
223
  See [native deployment examples](../../deploy/native/README.md) and [native CLI installation](../cli/README.md).
package/dist/index.js CHANGED
@@ -1583,6 +1583,10 @@ var NativeWeChatClient = class {
1583
1583
  const response = await this.response(`v1/accounts/${id(accountId)}/uploads`, { method: "POST", body: form, signal }, false, this.mediaTimeoutMs);
1584
1584
  return JSON.parse(new TextDecoder().decode(await this.readBounded(response)));
1585
1585
  }
1586
+ /** Delete an upload you have finished with, such as the source of an added sticker. Uploads a pending send or preparation needs are kept (`upload_in_use`). */
1587
+ releaseUpload(accountId, sourceId, signal) {
1588
+ return this.request(`v1/accounts/${id(accountId)}/uploads/${id(sourceId)}`, { method: "DELETE", signal });
1589
+ }
1586
1590
  /** Derive Saved and all added official pack tabs from the account profile. */
1587
1591
  stickerCollections(accountId, signal) {
1588
1592
  return this.request(`v1/accounts/${id(accountId)}/sticker-collections`, { signal });
@@ -1949,6 +1953,12 @@ function nativeExecutableFormat(bytes, platform = process.platform) {
1949
1953
  }
1950
1954
  return false;
1951
1955
  }
1956
+ function managedServeArgs(dataDir, listen, serverConfig, capabilities) {
1957
+ const args = ["serve", "--data-dir", dataDir, "--token-stdin", "--listen", listen];
1958
+ if (capabilities.includes("serve-exit-with-parent")) args.push("--exit-with-parent");
1959
+ if (serverConfig) args.push("--server-config", serverConfig);
1960
+ return args;
1961
+ }
1952
1962
  async function resolveNativeExecutable(explicit, path = process.env.PATH ?? "", environment = nativeChildEnvironment("")) {
1953
1963
  const target = nativeHostTarget();
1954
1964
  let candidate = explicit;
@@ -1993,7 +2003,7 @@ async function resolveNativeExecutable(explicit, path = process.env.PATH ?? "",
1993
2003
  const version = JSON.parse(stdout);
1994
2004
  requireNativeIdentity(version);
1995
2005
  if (version.target !== target.rustTarget) throw new Error("native_binary_incompatible: executable architecture differs from this host");
1996
- return candidate;
2006
+ return { path: candidate, capabilities: version.capabilities };
1997
2007
  }
1998
2008
  async function portOccupied(url2) {
1999
2009
  return new Promise((resolve, reject) => {
@@ -2046,9 +2056,8 @@ async function startNativeHost(config) {
2046
2056
  if (await portOccupied(url2)) throw new Error("native_owner_conflict: configured port is already owned; use external mode for an independently operated daemon");
2047
2057
  const executable = await resolveNativeExecutable(config.executable, void 0, nativeChildEnvironment(token));
2048
2058
  const client = new NativeWeChatClient({ baseUrl: url2.href, token, timeoutMs: 1e3 });
2049
- const args = ["serve", "--data-dir", config.dataDir, "--token-stdin", "--listen", url2.host];
2050
- if (config.serverConfig) args.push("--server-config", config.serverConfig);
2051
- const child = spawn(executable, args, { env: nativeChildEnvironment(token), stdio: ["pipe", "ignore", "pipe"], shell: false });
2059
+ const args = managedServeArgs(config.dataDir, url2.host, config.serverConfig, executable.capabilities);
2060
+ const child = spawn(executable.path, args, { env: nativeChildEnvironment(token), stdio: ["pipe", "ignore", "pipe"], shell: false });
2052
2061
  child.stderr?.on("data", () => {
2053
2062
  });
2054
2063
  let exited = false;
@@ -2991,7 +3000,7 @@ ${prepared.body}`.slice(0, 65536) };
2991
3000
  return { body: renderAttachmentBody("", attachment2), attachment: attachment2, pending: false };
2992
3001
  }
2993
3002
  await authorize();
2994
- if (attachmentKind === "file" && asset.byteLength != null && asset.byteLength > 128 * 1024 * 1024) {
3003
+ if ((attachmentKind === "file" || attachmentKind === "video") && asset.byteLength != null && asset.sha256) {
2995
3004
  const content2 = await client.mediaContentStream(accountId, asset.id, { maxBytes, signal: params.signal });
2996
3005
  const mime2 = content2.contentType.split(";", 1)[0].trim().toLowerCase();
2997
3006
  if (!/^[a-z0-9.+-]+\/[a-z0-9.+-]+$/.test(mime2)) {
@@ -3006,7 +3015,7 @@ ${prepared.body}`.slice(0, 65536) };
3006
3015
  filename,
3007
3016
  maxBytes,
3008
3017
  expectedBytes: asset.byteLength,
3009
- expectedSha256: asset.sha256 ?? "",
3018
+ expectedSha256: asset.sha256,
3010
3019
  assertCurrent: guard2,
3011
3020
  saveMediaStream: params.saveMediaStream ?? saveMediaStream
3012
3021
  });
@@ -3014,7 +3023,17 @@ ${prepared.body}`.slice(0, 65536) };
3014
3023
  await content2.cancel();
3015
3024
  }
3016
3025
  await authorize();
3017
- const attachment2 = { kind: "file", filename, status: "ready", path: saved2.path, mime: mime2 };
3026
+ guard2();
3027
+ const actual2 = asset.actualVariant ?? asset.variant;
3028
+ const attachment2 = {
3029
+ kind: attachmentKind,
3030
+ filename,
3031
+ status: "ready",
3032
+ path: saved2.path,
3033
+ mime: mime2,
3034
+ quality: actual2 === "original" ? "full" : actual2 === "standard" ? "standard" : actual2 === "thumbnail" ? "thumbnail" : void 0
3035
+ };
3036
+ const video = attachmentKind === "video";
3018
3037
  return {
3019
3038
  body: renderAttachmentBody("", attachment2),
3020
3039
  attachment: attachment2,
@@ -3022,22 +3041,23 @@ ${prepared.body}`.slice(0, 65536) };
3022
3041
  pending: false,
3023
3042
  jobId: job?.id,
3024
3043
  retryable: false,
3025
- variant: asset.actualVariant ?? asset.variant,
3044
+ variant: actual2,
3026
3045
  suppliedAssets: [{
3027
3046
  id: asset.id,
3028
3047
  contextRole: "trigger",
3029
3048
  role: "file_reference",
3030
- kind: "file",
3049
+ kind: attachmentKind,
3031
3050
  path: saved2.path,
3032
3051
  mime: mime2,
3033
3052
  sha256: saved2.sha256,
3034
3053
  byteLength: saved2.size,
3035
- runtimeMedia: false,
3054
+ runtimeMedia: video,
3036
3055
  sourceSha256: saved2.sha256,
3037
3056
  sourceByteLength: saved2.size,
3038
3057
  sourceMime: mime2,
3039
3058
  sourcePath: saved2.path
3040
- }]
3059
+ }],
3060
+ mediaPath: video ? saved2.path : void 0
3041
3061
  };
3042
3062
  }
3043
3063
  const content = await client.mediaContent(accountId, asset.id, { maxBytes, signal: params.signal });
@@ -3348,7 +3368,7 @@ function nativeDispatchManifest(params) {
3348
3368
  }))) } : {},
3349
3369
  assets,
3350
3370
  policySha256: digest(JSON.stringify(params.policy ?? null)),
3351
- // Exact source-turn identity of OpenClaw 2026.10.2 through 2026.11.2. Requiring it in the later
3371
+ // Exact source-turn identity of OpenClaw 2026.10.2 through 2026.11.4. Requiring it in the later
3352
3372
  // snapshot prevents an identical older image/body from proving this input.
3353
3373
  hostSourceTurnId: `channel-user:v1:${digest(JSON.stringify(["agent-wechat", params.channelAccountId, `wechat:${params.message.threadId}`, messageSid]))}`
3354
3374
  };
@@ -5416,6 +5436,7 @@ function createLookupTools(context, dependencies, archive) {
5416
5436
  message,
5417
5437
  core,
5418
5438
  cfg,
5439
+ saveMediaStream: dependencies.saveMediaStream,
5419
5440
  quality,
5420
5441
  download: args.download !== false,
5421
5442
  waitMs: 2e3,
@@ -5872,7 +5893,9 @@ function createNativeStickerTools(context, dependencies = { host: ensureNativeHo
5872
5893
  file: { type: "string", description: "Workspace-relative source file for prepare; resolved on the session execution host." },
5873
5894
  sourceId: { type: "string", description: "Existing daemon-owned upload instead of a workspace file." },
5874
5895
  output: { type: "string", description: "New workspace-relative output for download, using the original format extension; existing files are never replaced." },
5875
- fit: { type: "boolean", description: "Permit proportional resizing to the sticker output limit." },
5896
+ fit: { type: "boolean", description: "Shrink a source larger than 1024 pixels to fit. Smaller sources keep their size and encoding." },
5897
+ maxEdge: { type: "integer", minimum: 16, maximum: 1024, description: "Shrink so the longest edge is at most this many pixels; never enlarges. Video defaults to 240." },
5898
+ fps: { type: "integer", minimum: 1, maximum: 30, description: "Frame rate for a sticker made from video; default 10. Not accepted for images or GIFs." },
5876
5899
  startMs: { type: "integer", minimum: 0, maximum: 4294967295, description: "Explicit segment start in milliseconds; requires durationMs." },
5877
5900
  durationMs: { type: "integer", minimum: 1, maximum: 1e4, description: "Explicit retained duration in milliseconds; omitted means preserve duration." },
5878
5901
  idempotencyKey: { type: "string", minLength: 1, maxLength: 200, description: "Required stable key for prepare/add/move/remove and downloads that need acquisition. Reuse the key and identical intent after uncertain responses." }
@@ -5880,7 +5903,7 @@ function createNativeStickerTools(context, dependencies = { host: ensureNativeHo
5880
5903
  execute: async (_id, input, signal) => {
5881
5904
  if (!input || typeof input !== "object" || Array.isArray(input)) throw Error("Invalid sticker arguments");
5882
5905
  const args = input;
5883
- const fields = ["action", "stickerId", "preparationId", "file", "sourceId", "output", "fit", "startMs", "durationMs", "idempotencyKey", "revision", "afterId", "messageId", "assetId"];
5906
+ const fields = ["action", "stickerId", "preparationId", "file", "sourceId", "output", "fit", "maxEdge", "fps", "startMs", "durationMs", "idempotencyKey", "revision", "afterId", "messageId", "assetId"];
5884
5907
  if (Object.keys(args).some((key2) => !fields.includes(key2))) throw Error("Unknown sticker argument");
5885
5908
  const guard2 = () => {
5886
5909
  signal?.throwIfAborted();
@@ -5935,6 +5958,8 @@ function createNativeStickerTools(context, dependencies = { host: ensureNativeHo
5935
5958
  if (args.action === "prepare") {
5936
5959
  const key2 = text3(args.idempotencyKey, "idempotency key");
5937
5960
  if (key2.length > 200 || args.fit != null && typeof args.fit !== "boolean") throw Error("Invalid sticker preparation options");
5961
+ const whole = (value, min, max) => value == null || Number.isInteger(value) && value >= min && value <= max;
5962
+ if (!whole(args.maxEdge, 16, 1024) || !whole(args.fps, 1, 30)) throw Error("Invalid sticker preparation options");
5938
5963
  if (args.startMs != null && typeof args.startMs !== "number" || args.durationMs != null && typeof args.durationMs !== "number") throw Error("Invalid sticker segment");
5939
5964
  const trim = args.durationMs == null ? null : { startMs: Number(args.startMs ?? 0), durationMs: Number(args.durationMs) };
5940
5965
  if (args.startMs != null && !trim || trim && (!Number.isInteger(trim.startMs) || trim.startMs < 0 || trim.startMs > 4294967295 || !Number.isInteger(trim.durationMs) || trim.durationMs < 1 || trim.durationMs > 1e4)) throw Error("Invalid sticker segment");
@@ -5953,7 +5978,7 @@ function createNativeStickerTools(context, dependencies = { host: ensureNativeHo
5953
5978
  } else sourceId = text3(args.sourceId, "source identity");
5954
5979
  guard2();
5955
5980
  context.assertInputCommitAllowed?.();
5956
- const job2 = await client.prepareSticker(accountId, { sourceId, fit: args.fit === true, trim }, key2, signal);
5981
+ const job2 = await client.prepareSticker(accountId, { sourceId, fit: args.fit === true, maxEdge: args.maxEdge == null ? null : Number(args.maxEdge), fps: args.fps == null ? null : Number(args.fps), trim }, key2, signal);
5957
5982
  guard2();
5958
5983
  return result({ ...job2, idempotencyKey: key2 });
5959
5984
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@agent-wechat/agent-wechat",
3
- "version": "2.4.2",
3
+ "version": "2.6.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.11.2",
14
+ "openclaw": "2026.11.4",
15
15
  "typescript": "^5.4.5",
16
16
  "@agent-wechat/shared": "2.0.0"
17
17
  },