chore(claude-code)!: strip boundary, agentapi, tasks, tools#861
Merged
chore(claude-code)!: strip boundary, agentapi, tasks, tools#861
Conversation
92718d5 to
42ff02a
Compare
This was referenced Apr 22, 2026
…tasks, tools - Remove boundary variables and install logic. - Drop agentapi module; orchestrate scripts through coder-utils instead. - Remove start-script-only variables not shared with install (resume_session_id, continue, ai_prompt, dangerously_skip_permissions). - Remove allowed_tools and disallowed_tools. - Remove report_tasks, system_prompt, claude_md_path, and coder exp mcp / coder_report_task wiring. - Rename claude_api_key to anthropic_api_key (ANTHROPIC_API_KEY). - Rename enable_aibridge to enable_ai_gateway. - Drop install_via_npm; always use the official claude.ai/install.sh installer. - Tighten workdir description and drop dead module_dir_name/task_app_id. - Move module logs to $HOME/.coder-modules/coder/claude-code/logs (matches coder-utils 1.3.0 nested layout).
3c9937a to
3885188
Compare
matifali
added a commit
that referenced
this pull request
Apr 24, 2026
…le_directory (#874) ## Summary Derives `coder-utils` script names from `module_directory` instead of a separate `agent_name` input. The `module_directory` already encodes both the namespace and the module name, so carrying both is redundant and error-prone. Callers like `claude-code` no longer need to pass `agent_name`. Scripts this module materializes lose the `${agent_name}-utils-` prefix because `module_directory` already namespaces them per-caller. We will address multiple instances of coder-utils per caller in a future iteration if needed. ## Versioning Note Previous tags (`v1.0.0` through `v1.3.0`) have been deleted because no published module ever consumed them — the module was effectively unreleased. This PR ships the first real public version as **`v0.0.1`**, treating it as a fresh start rather than a breaking bump from a version that was never in production use. ## Changes - Remove `agent_name` variable. - Derive `caller_name = "${namespace}-${module_name}"` from `module_directory`. - Validate `module_directory` matches `$HOME/.coder-modules/<namespace>/<module-name>`. - Rename script files on disk from `${agent_name}-utils-<phase>.sh` to plain `<phase>.sh`. - Add a TS test for the `module_directory` validation. - Ship as `v0.0.1` (first published version; all prior tags removed). ## Breaking Changes | Before | After | |---|---| | `agent_name = "myagent"` | removed (derived from `module_directory`) | | `module_directory = ".my-module"` | `module_directory = "$HOME/.coder-modules/<ns>/<name>"` (validated) | | Script files `${agent_name}-utils-install.sh` | `install.sh` | | Script sync names `${agent_name}-install_script` | `${namespace}-${module_name}-install_script` | No callers were depending on the old format (prior tags were unpublished). ## Validation - `terraform fmt -recursive` clean - `terraform validate` clean - `terraform test` → 17/17 pass - `bun test registry/coder/modules/coder-utils` → 5/5 pass - `prettier --check` clean ## Consumer #861 (`claude-code`) consumes this and is currently pinned to the commit SHA until this merges and ships as `v0.0.1`. > 🤖 This PR was created with the help of Coder Agents, and needs a human review. 🧑💻
…ia templatefile Render scripts/install.sh.tftpl once at plan time and pass the result directly to coder-utils, replacing the runtime base64 encode/decode wrapper and the redundant scripts/install.sh. Sources coder-utils from a pinned commit on its refactor branch until the `module_directory`-derived caller name lands in a tagged release.
…nd scope MCP to user workdir is now optional. When set, the module still pre-creates the directory and pre-accepts the Claude Code trust dialog for it. When unset, the module installs the CLI and configures authentication only; users accept trust dialogs interactively per project. MCP servers are added at Claude Code's user scope via `claude mcp add-json --scope user` so they are available across every project the workspace owner opens, instead of being tied to a single project directory. For project-local MCP servers, callers should commit a `.mcp.json` to the project repository rather than passing it through this module. Drop primaryApiKey from the standalone-mode config writer. Claude Code reads credentials from the ANTHROPIC_API_KEY and CLAUDE_CODE_OAUTH_TOKEN env vars (which the module already exports via coder_env); writing the key into ~/.claude.json had no effect on authentication. Split the standalone-mode .claude.json writer into two steps: the always-on auth/onboarding keys, and the optional `.projects[workdir]` trust block that only runs when workdir is set.
3885188 to
46ce616
Compare
DevelopmentCats
approved these changes
Apr 24, 2026
Collaborator
DevelopmentCats
left a comment
There was a problem hiding this comment.
Everything looks good to me. I think it honestly makes more sense for this module to stick with just the claude-code install and configuration since everyone seems to have their own methods of utilizing the module, and with /agents we would be moving away from tasks anyways to some extent.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Reduces
claude-codeto a minimal install-and-configure module for the Claude CLI. Boundary, agentapi, task reporting, session tracking, tool allow/deny, and start orchestration are removed. Script execution is delegated tocoder-utilsv1.2.0. Starting Claude is now the caller's responsibility (template command, IDE launcher, or a customcoder_script).Warning
This is a breaking change. See the migration guide below.
Changes
scripts/start.sh. The module no longer launches Claude.agentapisub-module withcoder-utilsv1.2.0 for install/pre/post script orchestration.claude.ai/install.shinstaller.scripts/install.sh.tftplonce at plan time viatemplatefile()and pass the result directly tocoder-utils, replacing the runtime base64 encode/decode wrapper and the redundantscripts/install.sh.workdiroptional. When set, the module pre-creates the directory and pre-accepts the Claude Code trust dialog for it. When unset, the module installs the CLI and configures authentication only; users accept trust dialogs interactively per project.claude mcp add-json --scope userso they are available across every project the workspace owner opens, instead of being tied to a single project directory.primaryApiKeyfrom the standalone-mode config writer — credentials are already exported viacoder_env, writing the key into~/.claude.jsonhad no effect.claude_api_key→anthropic_api_key(envANTHROPIC_API_KEY).enable_aibridge→enable_ai_gateway.ANTHROPIC_AUTH_TOKEN(notANTHROPIC_API_KEY) to the workspace owner's Coder session token, matching the AI Gateway centralized API key flow.configure_standalone_modeto also recognizeCLAUDE_CODE_OAUTH_TOKENso OAuth-only users get the onboarding bypass.scriptsoutput (pass-through fromcoder-utils) so upstream modules can serialize theircoder_scriptresources behind this module's install pipeline viacoder exp sync want.task_app_idoutput.$HOME/.coder-modules/coder/claude-code/logs/(was$HOME/.claude-module/).report_tasks,system_prompt,claude_md_path,allowed_tools,disallowed_tools,enable_boundary,boundary_version,compile_boundary_from_source,use_boundary_directly,order,group,web_app,cli_app,web_app_display_name,cli_app_display_name,install_agentapi,agentapi_version,ai_prompt,subdomain,resume_session_id,continue,dangerously_skip_permissions,enable_state_persistence,permission_mode,install_via_npm.5.0.0.Breaking Changes
claude_api_keyanthropic_api_keyenable_aibridgeenable_ai_gatewayANTHROPIC_API_KEYto session tokenANTHROPIC_AUTH_TOKENto session tokenworkdirrequiredworkdiroptionalmodule.claude-code.task_app_idcoder_appcreated)permission_modeinstall_via_npmai_prompt,system_prompt,allowed_tools,disallowed_tools,report_tasks, session/continue vars, Boundary vars, agentapi vars,web_app/cli_appvars,order/group,enable_state_persistence$HOME/.claude-module/*.log$HOME/.coder-modules/coder/claude-code/logs/*.logCallers depending on any of the above must migrate. The module no longer starts Claude — provide your own
coder_scriptor template command if you want it to launch automatically.Validation
terraform fmt -recursivecleanterraform validatecleanterraform test→ 13/13 passbun test registry/coder/modules/claude-code→ 12/12 passshellcheck --severity=warningcleanprettier --checkclean