From 0a5d5bc524d038829e7dd39d4cb73bc3898206a7 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Tom=C3=A1=C5=A1=20Linhart?= Date: Tue, 3 Feb 2026 22:21:15 +0100 Subject: [PATCH] docs: fix logging example for plugin (#11989) --- packages/web/src/content/docs/plugins.mdx | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) diff --git a/packages/web/src/content/docs/plugins.mdx b/packages/web/src/content/docs/plugins.mdx index 394fecc40..411b827d2 100644 --- a/packages/web/src/content/docs/plugins.mdx +++ b/packages/web/src/content/docs/plugins.mdx @@ -317,10 +317,12 @@ Use `client.app.log()` instead of `console.log` for structured logging: ```ts title=".opencode/plugins/my-plugin.ts" export const MyPlugin = async ({ client }) => { await client.app.log({ - service: "my-plugin", - level: "info", - message: "Plugin initialized", - extra: { foo: "bar" }, + body: { + service: "my-plugin", + level: "info", + message: "Plugin initialized", + extra: { foo: "bar" }, + }, }) } ```