# Golem Tools Middleware Effect

> Defines and calls Golem tools and attaches Effect-native typed or universal middleware. Use for tool providers, clients, and middleware composition.

- Skill: `golemcloud/golem-tools-middleware-effect` (Agent Skill)
- Install (CLI): `npx skillmds@latest add golemcloud/golem-tools-middleware-effect`
- Raw SKILL.md: https://api.skillmd.com/api/skills/golemcloud/golem-tools-middleware-effect/raw
- Safety review: pending
- Works with: Claude Code, Claude.ai, OpenAI Codex
- Category: Coding & Dev Tools
- Author: golemcloud (https://skillmd.com/u/golemcloud)
- Updated: 2026-09-17
- Page: https://skillmd.com/skills/golemcloud/golem-tools-middleware-effect

---


# Effect tools and middleware

Build a definition with `Tool.toolDefinition(name).body(...)`. A provider finishes it with `.implement({ camelCaseName: handler })`; a caller uses `Tool.client(definition)`. Handlers and clients return Effects and stream stdin/stdout with Effect `Stream`.

Use `Middleware.typed({ name, presented, handler })` when the presented tool shape is known. Use the universal middleware API only when every tool must be intercepted. Forward input, output, permission cards, and streams exactly once to `underlying`; capability handles are affine.

Combined agent/tool worlds are supported by current SDK artifacts. Standalone middleware attachment and deployment is host-blocked by GOL-39; do not invent a manifest field or claim it can be deployed independently.

