Skip to content

NewSession

Base classes

Name Children Inherits
BaseSessionConfig
clawd_code_sdk.models.options
Common fields for all session configurations.

⋔ Inheritance diagram

graph TD
  1055368575["options.NewSession"]
  2922679169["options.BaseSessionConfig"]
  2751680898["builtins.object"]
  2922679169 --> 1055368575
  2751680898 --> 2922679169

🛈 DocStrings

Bases: BaseSessionConfig

Start a fresh session.

Source code in src/clawd_code_sdk/models/options.py
@dataclass(kw_only=True)
class NewSession(BaseSessionConfig):
    """Start a fresh session."""

    mode: Literal["new"] = "new"
    session_id: str | None = None
    """Deterministic session ID, or None to auto-generate a UUID."""
    title: str | None = None
    """Title for the session, or None to auto-generate a title."""

session_id class-attribute instance-attribute

session_id: str | None = None

Deterministic session ID, or None to auto-generate a UUID.

title class-attribute instance-attribute

title: str | None = None

Title for the session, or None to auto-generate a title.

:fa-brands-github: Show source on GitHub