Follow Discord
Sweep 22 Oct 2026 · 04:32Z Build v2.1.308 527 read Stable v2.1.308 Latest v2.1.308 Next v2.1.308 Feeds RSS JSON llms.txt llms-full.txt Unofficial
One change · claude-code

Mods reference changedplugins/mods/reference

Nearest release: v2.1.296, published 23 hours before upstream edited the page. Shown because the two are within 24 hours of each other. Nothing here says the release caused the edit.

Upstream edited this page at 10 Oct 2026 16:33 UTC, give or take a minute or two: the time comes from Anthropic’s own sitemap rather than from a commit. This site recorded the change at 10 Oct 2026 16:37 UTC.

Upstream edited
Recorded here
Lines+6added
Lines−0removed
From line 149 where the diff opens
First seen 1 Oct 2026 this site's first read of the page
Recorded edits32to this page, all time

The whole hunk

from line 149, old and new numbered
/
lines
from line 149
149149| [`plugin.register`](/docs/en/plugins/mods/admin#enforce-a-policy-with-a-mod-of-your-own) | A hooks module is about to load. `e.uses` lists its events, mods API calls, environment variables, and state, as `claude plugin validate` prints them. Each call is written without the `$.` prefix, such as `fs.read`. | `{ refuse: reason }` |
150150| `engine.create` | The mods API is being built for this mod | A changed mods API, to add a namespace. A mod outside the `user` [tier](#the-hook-function) can also withhold one. |
151151 
152A namespace you add in an `engine.create` hook can make `$` calls of its own when another mod calls its methods. While the hook that called your method is still running, those calls act for that hook. A relative path resolves against that hook's working directory, and a call that would wait for the turn, such as `$.prompt.submit` or `$.command.run`, rejects while the turn is waiting on that hook. Once that hook and every other hook on the same event have returned, a call your method makes acts as your mod's own: a relative path resolves against the session's working directory, and a prompt is queued.
153 
152154### Telemetry
153155 
154156Telemetry events fire for the usage records Claude Code logs:
from line 279
277279| `$.process.run` timeout | 30 seconds by default, 10 minutes at most |
278280| `$.model.complete` `maxTokens` | 1024 by default, up to 64,000 or the model's output limit |
279281| `$.fs.read` and `$.fs.write` | 4 MiB for one file |
282| A `$.http.fetch` request body | 4 MiB, counted in characters. A call with a larger body rejects. |
283| A `$.http.fetch` response body | 4 MiB. `text` holds the first 4 MiB and the rest isn't read. When the `Content-Length` header declares more, the call rejects instead, with a reason that ends `is over the 4194304-byte limit`, except when the last request after any redirects uses the `HEAD` method. The `HEAD` exemption requires Claude Code v2.1.296 or later. |
284| One `$.http.fetch` call, redirects and body included | 30 seconds |
285| Redirects one `$.http.fetch` call follows | 5 |
280286| A hook's `drop` reason or `config.set` `deny` reason | 4,096 characters. The end of a longer reason is cut, and the drop or deny still applies. The cut requires Claude Code v2.1.292 or later, and on earlier versions the hook [fails](/docs/en/plugins/mods/events#handle-a-hook-that-fails) instead. |
281287| Text in one tree | The first 100,000 characters are drawn |
282288| A `Code`'s `language` or `path`, a `Select` option's `value`, or a `Client`'s `module` | 10,000 characters. If one is longer, Claude Code [draws its own version of the site](/docs/en/plugins/mods/interface#build-a-tree-from-elements). |
Feedback