# `MingaClaudeBridge.Launch`
[🔗](https://github.com/jsmestad/minga-claude-bridge/blob/main/lib/minga_claude_bridge/launch.ex#L1)

Builds the `claude` command-line arguments for one session.

Every launch carries the fixed flags in `fixed_args/0`. They select the stream-json protocol on stdin and stdout with partial messages, and restrict what Claude Code loads: no built-in tools (`--tools ""`), only Minga's MCP tools allowed (`--allowedTools mcp__minga__*`), no MCP servers from `~/.claude.json` or `.mcp.json` (`--strict-mcp-config`), no settings files and so no hooks or plugins (`--setting-sources ""`), and no skills or slash commands (`--disable-slash-commands`). `--thinking-display summarized` makes Claude Code stream thinking text; without it, 2.1.330 streams thinking blocks with empty text (pi-claude-bridge does the same, see anthropics/claude-agent-sdk-python#830).

## Verified CLI version

Claude Code 2.1.330 accepts every flag here together and answers `initialize` with them. `-p` is not needed: with stdout not a TTY, Claude Code runs non-interactively. `--resume` with an id Claude Code does not know makes it exit with status 1 and the message "No conversation found with session ID". `@min_version` records 2.1.330 as the lowest supported version.

## Options

  * `:model` - a model alias or id, for example `"sonnet"`.
  * `:effort` - one of `"low"`, `"medium"`, `"high"`, `"xhigh"`, `"max"`. An effort also turns on adaptive thinking (`--thinking=adaptive`), as the Agent SDK does for `thinking: {type: "adaptive"}`.
  * `:resume` - a Claude Code session id to continue.
  * `:persist_session` - `false` adds `--no-session-persistence`, for isolated queries that must not leave a session behind. Defaults to `true`.

No shell runs these arguments, but a value that starts with `-` would still be read as a flag. `argv/1` rejects such values and every value that is not a non-empty string.

# `opts`

```elixir
@type opts() :: [
  model: String.t() | nil,
  effort: String.t() | nil,
  resume: String.t() | nil,
  persist_session: boolean()
]
```

# `argv`

```elixir
@spec argv(keyword()) :: {:ok, [String.t()]} | {:error, {:invalid_launch, atom()}}
```

Builds the argument list. Returns `{:error, {:invalid_launch, key}}` for an invalid option value.

# `fixed_args`

```elixir
@spec fixed_args() :: [String.t()]
```

The flags every launch carries.

# `min_version`

```elixir
@spec min_version() :: String.t()
```

The lowest Claude Code version the bridge supports.

---

*Consult [api-reference.md](api-reference.md) for complete listing*
