# ServerConfig

> **Class** in `deepagents_code`

📖 [View in docs](https://reference.langchain.com/python/deepagents-code/_server_config/ServerConfig)

Full configuration payload passed from the app to the server subprocess.

Serialized to/from `DEEPAGENTS_CODE_SERVER_*` environment variables so
that the server graph (which runs in a separate Python interpreter)
can reconstruct the app's intent without sharing memory.

## Signature

```python
ServerConfig(
    self,
    model: str | None = None,
    summarization_model: str | None = None,
    model_params: dict[str, Any] | None = None,
    cli_max_retries: int | None = None,
    profile_overrides: dict[str, Any] | None = None,
    assistant_id: str = DEFAULT_ASSISTANT_ID,
    system_prompt: str | None = None,
    auto_approve: bool = False,
    interrupt_shell_only: bool = False,
    shell_allow_list: list[str] | None = None,
    interactive: bool = True,
    enable_shell: bool = True,
    enable_ask_user: bool = False,
    enable_memory: bool = True,
    enable_skills: bool = True,
    enable_interpreter: bool = False,
    interpreter_ptc: str | list[str] | None = None,
    interpreter_ptc_acknowledge_unsafe: bool = False,
    allow_fs_tools: list[FsToolName] | None = None,
    rubric_model: str | None = None,
    rubric_max_iterations: int | None = None,
    auto_classifier_model: str | None = None,
    recursion_limit: int | None = None,
    sandbox_type: str | None = None,
    sandbox_id: str | None = None,
    sandbox_snapshot_name: str | None = None,
    sandbox_setup: str | None = None,
    cwd: str | None = None,
    project_root: str | None = None,
    mcp_config_path: str | None = None,
    no_mcp: bool = False,
    trust_project_mcp: bool | None = None,
    trust_project_extensions: bool = False,
    extension_paths: tuple[str, ...] = (),
)
```

## Constructors

```python
__init__(
    self,
    model: str | None = None,
    summarization_model: str | None = None,
    model_params: dict[str, Any] | None = None,
    cli_max_retries: int | None = None,
    profile_overrides: dict[str, Any] | None = None,
    assistant_id: str = DEFAULT_ASSISTANT_ID,
    system_prompt: str | None = None,
    auto_approve: bool = False,
    interrupt_shell_only: bool = False,
    shell_allow_list: list[str] | None = None,
    interactive: bool = True,
    enable_shell: bool = True,
    enable_ask_user: bool = False,
    enable_memory: bool = True,
    enable_skills: bool = True,
    enable_interpreter: bool = False,
    interpreter_ptc: str | list[str] | None = None,
    interpreter_ptc_acknowledge_unsafe: bool = False,
    allow_fs_tools: list[FsToolName] | None = None,
    rubric_model: str | None = None,
    rubric_max_iterations: int | None = None,
    auto_classifier_model: str | None = None,
    recursion_limit: int | None = None,
    sandbox_type: str | None = None,
    sandbox_id: str | None = None,
    sandbox_snapshot_name: str | None = None,
    sandbox_setup: str | None = None,
    cwd: str | None = None,
    project_root: str | None = None,
    mcp_config_path: str | None = None,
    no_mcp: bool = False,
    trust_project_mcp: bool | None = None,
    trust_project_extensions: bool = False,
    extension_paths: tuple[str, ...] = (),
) -> None
```

| Name | Type |
|------|------|
| `model` | `str \| None` |
| `summarization_model` | `str \| None` |
| `model_params` | `dict[str, Any] \| None` |
| `cli_max_retries` | `int \| None` |
| `profile_overrides` | `dict[str, Any] \| None` |
| `assistant_id` | `str` |
| `system_prompt` | `str \| None` |
| `auto_approve` | `bool` |
| `interrupt_shell_only` | `bool` |
| `shell_allow_list` | `list[str] \| None` |
| `interactive` | `bool` |
| `enable_shell` | `bool` |
| `enable_ask_user` | `bool` |
| `enable_memory` | `bool` |
| `enable_skills` | `bool` |
| `enable_interpreter` | `bool` |
| `interpreter_ptc` | `str \| list[str] \| None` |
| `interpreter_ptc_acknowledge_unsafe` | `bool` |
| `allow_fs_tools` | `list[FsToolName] \| None` |
| `rubric_model` | `str \| None` |
| `rubric_max_iterations` | `int \| None` |
| `auto_classifier_model` | `str \| None` |
| `recursion_limit` | `int \| None` |
| `sandbox_type` | `str \| None` |
| `sandbox_id` | `str \| None` |
| `sandbox_snapshot_name` | `str \| None` |
| `sandbox_setup` | `str \| None` |
| `cwd` | `str \| None` |
| `project_root` | `str \| None` |
| `mcp_config_path` | `str \| None` |
| `no_mcp` | `bool` |
| `trust_project_mcp` | `bool \| None` |
| `trust_project_extensions` | `bool` |
| `extension_paths` | `tuple[str, ...]` |


## Properties

- `model`
- `summarization_model`
- `model_params`
- `cli_max_retries`
- `profile_overrides`
- `assistant_id`
- `system_prompt`
- `auto_approve`
- `interrupt_shell_only`
- `shell_allow_list`
- `interactive`
- `enable_shell`
- `enable_ask_user`
- `enable_memory`
- `enable_skills`
- `enable_interpreter`
- `interpreter_ptc`
- `interpreter_ptc_acknowledge_unsafe`
- `allow_fs_tools`
- `rubric_model`
- `rubric_max_iterations`
- `auto_classifier_model`
- `recursion_limit`
- `sandbox_type`
- `sandbox_id`
- `sandbox_snapshot_name`
- `sandbox_setup`
- `cwd`
- `project_root`
- `mcp_config_path`
- `no_mcp`
- `trust_project_mcp`
- `trust_project_extensions`
- `extension_paths`

## Methods

- [`to_workspace_payload()`](https://reference.langchain.com/python/deepagents-code/_server_config/ServerConfig/to_workspace_payload)
- [`workspace_fingerprint()`](https://reference.langchain.com/python/deepagents-code/_server_config/ServerConfig/workspace_fingerprint)
- [`to_env()`](https://reference.langchain.com/python/deepagents-code/_server_config/ServerConfig/to_env)
- [`from_env()`](https://reference.langchain.com/python/deepagents-code/_server_config/ServerConfig/from_env)
- [`from_cli_args()`](https://reference.langchain.com/python/deepagents-code/_server_config/ServerConfig/from_cli_args)

---

[View source on GitHub](https://github.com/langchain-ai/deepagents/blob/3812967c84d90619848f3185f22470204fc88bd8/libs/code/deepagents_code/_server_config.py#L260)