pub struct ClientConfig {
pub cli_bin: PathBuf,
pub compatibility_guard: CompatibilityGuard,
pub initialize_capabilities: InitializeCapabilities,
pub hooks: RuntimeHookConfig,
}Fields§
§cli_bin: PathBuf§compatibility_guard: CompatibilityGuard§initialize_capabilities: InitializeCapabilities§hooks: RuntimeHookConfigImplementations§
Source§impl ClientConfig
impl ClientConfig
Sourcepub fn with_cli_bin(self, cli_bin: impl Into<PathBuf>) -> Self
pub fn with_cli_bin(self, cli_bin: impl Into<PathBuf>) -> Self
Override CLI executable path.
Sourcepub fn with_compatibility_guard(self, guard: CompatibilityGuard) -> Self
pub fn with_compatibility_guard(self, guard: CompatibilityGuard) -> Self
Override runtime compatibility guard policy.
Sourcepub fn without_compatibility_guard(self) -> Self
pub fn without_compatibility_guard(self) -> Self
Disable compatibility guard checks at connect time.
Sourcepub fn with_initialize_capabilities(
self,
initialize_capabilities: InitializeCapabilities,
) -> Self
pub fn with_initialize_capabilities( self, initialize_capabilities: InitializeCapabilities, ) -> Self
Override initialize capability switches.
Sourcepub fn enable_experimental_api(self) -> Self
pub fn enable_experimental_api(self) -> Self
Opt into Codex experimental app-server methods and fields.
Sourcepub fn with_hooks(self, hooks: RuntimeHookConfig) -> Self
pub fn with_hooks(self, hooks: RuntimeHookConfig) -> Self
Replace runtime hook configuration.
Sourcepub fn with_pre_hook(self, hook: Arc<dyn PreHook>) -> Self
pub fn with_pre_hook(self, hook: Arc<dyn PreHook>) -> Self
Register one pre hook on client runtime config.
Sourcepub fn with_post_hook(self, hook: Arc<dyn PostHook>) -> Self
pub fn with_post_hook(self, hook: Arc<dyn PostHook>) -> Self
Register one post hook on client runtime config.
Sourcepub fn with_pre_tool_use_hook(self, hook: Arc<dyn PreHook>) -> Self
pub fn with_pre_tool_use_hook(self, hook: Arc<dyn PreHook>) -> Self
Register one pre-tool-use hook on client runtime config. When at least one pre-tool-use hook is registered, the runtime manages the approval channel internally and auto-escalates ApprovalPolicy → Untrusted. Allocation: amortized O(1) push. Complexity: O(1).
Trait Implementations§
Source§impl Clone for ClientConfig
impl Clone for ClientConfig
Source§fn clone(&self) -> ClientConfig
fn clone(&self) -> ClientConfig
Returns a duplicate of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for ClientConfig
impl Debug for ClientConfig
Source§impl Default for ClientConfig
impl Default for ClientConfig
Source§impl PartialEq for ClientConfig
impl PartialEq for ClientConfig
impl Eq for ClientConfig
impl StructuralPartialEq for ClientConfig
Auto Trait Implementations§
impl Freeze for ClientConfig
impl !RefUnwindSafe for ClientConfig
impl Send for ClientConfig
impl Sync for ClientConfig
impl Unpin for ClientConfig
impl UnsafeUnpin for ClientConfig
impl !UnwindSafe for ClientConfig
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more