> ## Documentation Index
> Fetch the complete documentation index at: https://resq-dependabot-github-actions-github-actions-478e18be3d.mintlify.site/llms.txt
> Use this file to discover all available pages before exploring further.

# Config

<a id="resq_mcp.core.config" />

# resq\_mcp.core.config

Configuration management for the ResQ MCP server.

Settings are loaded from environment variables with sensible defaults.
Use a .env file or export environment variables to override.

Environment variables:
RESQ\_PROJECT\_NAME: Display name for the MCP server
RESQ\_VERSION: Version string for the server
RESQ\_DEBUG: Enable debug logging (true/false)
RESQ\_API\_KEY: API key for authenticated endpoints
RESQ\_PORT: Port for SSE server
RESQ\_HOST: Host to bind to
RESQ\_SAFE\_MODE: If True, side-effecting tools are disabled or mocked safely

<a id="resq_mcp.core.config.annotations" />

## annotations

<a id="resq_mcp.core.config.Literal" />

## Literal

<a id="resq_mcp.core.config.Field" />

## Field

<a id="resq_mcp.core.config.BaseSettings" />

## BaseSettings

<a id="resq_mcp.core.config.SettingsConfigDict" />

## SettingsConfigDict

<a id="resq_mcp.core.config.ConfigurationError" />

## ConfigurationError Objects

```python theme={null}
class ConfigurationError(Exception)
```

Raised when required configuration is missing or invalid.

<a id="resq_mcp.core.config.Settings" />

## Settings Objects

```python theme={null}
class Settings(BaseSettings)
```

Application configuration via environment variables.

<a id="resq_mcp.core.config.Settings.model_config" />

#### model\_config

<a id="resq_mcp.core.config.Settings.PROJECT_NAME" />

#### PROJECT\_NAME

<a id="resq_mcp.core.config.Settings.VERSION" />

#### VERSION

<a id="resq_mcp.core.config.Settings.DEBUG" />

#### DEBUG

<a id="resq_mcp.core.config.Settings.API_KEY" />

#### API\_KEY

<a id="resq_mcp.core.config.Settings.PORT" />

#### PORT

<a id="resq_mcp.core.config.Settings.HOST" />

#### HOST

<a id="resq_mcp.core.config.Settings.SAFE_MODE" />

#### SAFE\_MODE

<a id="resq_mcp.core.config.Settings.TELEMETRY_BACKEND" />

#### TELEMETRY\_BACKEND

<a id="resq_mcp.core.config.Settings.OTEL_EXPORTER_OTLP_ENDPOINT" />

#### OTEL\_EXPORTER\_OTLP\_ENDPOINT

<a id="resq_mcp.core.config.Settings.OTEL_SERVICE_NAME" />

#### OTEL\_SERVICE\_NAME

<a id="resq_mcp.core.config.settings" />

#### settings

<a id="resq_mcp.core.config.validate_environment" />

#### validate\_environment

```python theme={null}
def validate_environment(require_api_key: bool = False) -> None
```

Validate required environment variables at startup.

This function performs fail-fast validation by raising ConfigurationError
if any required environment variables are missing.

**Arguments**:

* `require_api_key` - If True, API\_KEY must be set and not be the default dev token.

**Raises**:

* `ConfigurationError` - If any required environment variable is missing or invalid.

**Example**:

> > > from resq\_mcp.core.config import validate\_environment
> > > validate\_environment(require\_api\_key=True)
