Starts an MCP session in the current process, optionally binding to a specific session ID and working directory. Designed for non-interactive contexts where the agent needs to provision an R session on demand.
Arguments
- session_id
Optional integer session/socket identifier to bind.
- timeout_seconds
Session timeout before auto-cleanup (default: 900 seconds).
- working_dir
Optional path to set as the working directory before launch.
- daemon
Logical. If TRUE, return immediately after starting session (for processx spawning). If FALSE, block in event loop until session stops (for interactive use). Default FALSE.
