Skip to content

ccproxy.cli.options

ccproxy.cli.options

CLI option modules for organized command-line argument handling.

ClaudeOptions

ClaudeOptions(
    max_thinking_tokens=None,
    allowed_tools=None,
    disallowed_tools=None,
    claude_cli_path=None,
    append_system_prompt=None,
    permission_mode=None,
    max_turns=None,
    cwd=None,
    permission_prompt_tool_name=None,
)

Container for all Claude-related CLI options.

This class provides a convenient way to include all Claude-related options in a command using typed attributes.

Parameters:

Name Type Description Default
max_thinking_tokens int | None

Maximum thinking tokens for Claude Code

None
allowed_tools str | None

List of allowed tools (comma-separated)

None
disallowed_tools str | None

List of disallowed tools (comma-separated)

None
claude_cli_path str | None

Path to Claude CLI executable

None
append_system_prompt str | None

Additional system prompt to append

None
permission_mode str | None

Permission mode

None
max_turns int | None

Maximum conversation turns

None
cwd str | None

Working directory path

None
permission_prompt_tool_name str | None

Permission prompt tool name

None
Source code in ccproxy/cli/options/claude_options.py
def __init__(
    self,
    max_thinking_tokens: int | None = None,
    allowed_tools: str | None = None,
    disallowed_tools: str | None = None,
    claude_cli_path: str | None = None,
    append_system_prompt: str | None = None,
    permission_mode: str | None = None,
    max_turns: int | None = None,
    cwd: str | None = None,
    permission_prompt_tool_name: str | None = None,
):
    """Initialize Claude options.

    Args:
        max_thinking_tokens: Maximum thinking tokens for Claude Code
        allowed_tools: List of allowed tools (comma-separated)
        disallowed_tools: List of disallowed tools (comma-separated)
        claude_cli_path: Path to Claude CLI executable
        append_system_prompt: Additional system prompt to append
        permission_mode: Permission mode
        max_turns: Maximum conversation turns
        cwd: Working directory path
        permission_prompt_tool_name: Permission prompt tool name
    """
    self.max_thinking_tokens = max_thinking_tokens
    self.allowed_tools = allowed_tools
    self.disallowed_tools = disallowed_tools
    self.claude_cli_path = claude_cli_path
    self.append_system_prompt = append_system_prompt
    self.permission_mode = permission_mode
    self.max_turns = max_turns
    self.cwd = cwd
    self.permission_prompt_tool_name = permission_prompt_tool_name

CoreOptions

CoreOptions(config=None)

Container for core CLI options.

This class provides a convenient way to include core options in a command using typed attributes.

Parameters:

Name Type Description Default
config Path | None

Path to configuration file

None
Source code in ccproxy/cli/options/core_options.py
def __init__(
    self,
    config: Path | None = None,
):
    """Initialize core options.

    Args:
        config: Path to configuration file
    """
    self.config = config

SecurityOptions

SecurityOptions(auth_token=None)

Container for all security-related CLI options.

This class provides a convenient way to include all security-related options in a command using typed attributes.

Parameters:

Name Type Description Default
auth_token str | None

Bearer token for API authentication

None
Source code in ccproxy/cli/options/security_options.py
def __init__(
    self,
    auth_token: str | None = None,
):
    """Initialize security options.

    Args:
        auth_token: Bearer token for API authentication
    """
    self.auth_token = auth_token

ServerOptions

ServerOptions(
    port=None,
    host=None,
    reload=None,
    log_level=None,
    log_file=None,
)

Container for all server-related CLI options.

This class provides a convenient way to include all server-related options in a command using typed attributes.

Parameters:

Name Type Description Default
port int | None

Port to run the server on

None
host str | None

Host to bind the server to

None
reload bool | None

Enable auto-reload for development

None
log_level str | None

Logging level

None
log_file str | None

Path to JSON log file

None
Source code in ccproxy/cli/options/server_options.py
def __init__(
    self,
    port: int | None = None,
    host: str | None = None,
    reload: bool | None = None,
    log_level: str | None = None,
    log_file: str | None = None,
):
    """Initialize server options.

    Args:
        port: Port to run the server on
        host: Host to bind the server to
        reload: Enable auto-reload for development
        log_level: Logging level
        log_file: Path to JSON log file
    """
    self.port = port
    self.host = host
    self.reload = reload
    self.log_level = log_level
    self.log_file = log_file