pub struct Codex { /* private fields */ }Implementations§
Source§impl Codex
impl Codex
pub fn with_initialize_params( client: CodexClient, initialize_params: InitializeParams, ) -> Self
pub fn from_client(client: CodexClient) -> Self
pub async fn spawn_stdio(config: StdioConfig) -> Result<Self, ClientError>
pub async fn connect_ws(config: WsConfig) -> Result<Self, ClientError>
pub async fn start_and_connect_ws(config: WsConfig) -> Result<Self, ClientError>
pub fn start_thread(&self, options: ThreadOptions) -> Thread
pub fn resume_thread( &self, target: impl Into<ResumeThread>, options: ThreadOptions, ) -> Thread
pub fn resume_thread_by_id( &self, id: impl Into<String>, options: ThreadOptions, ) -> Thread
pub fn resume_latest_thread(&self, options: ThreadOptions) -> Thread
Sourcepub async fn ask(
&self,
input: impl Into<Input>,
) -> Result<String, ThreadRunError>
pub async fn ask( &self, input: impl Into<Input>, ) -> Result<String, ThreadRunError>
Runs a one-shot turn on a new thread and returns only the final agent response text.
Sourcepub async fn ask_with_options(
&self,
input: impl Into<Input>,
thread_options: ThreadOptions,
turn_options: TurnOptions,
) -> Result<String, ThreadRunError>
pub async fn ask_with_options( &self, input: impl Into<Input>, thread_options: ThreadOptions, turn_options: TurnOptions, ) -> Result<String, ThreadRunError>
Runs a one-shot turn on a new thread and returns only the final agent response text.
Sourcepub async fn thread_list(
&self,
params: ThreadListParams,
) -> Result<ThreadListResult, ClientError>
pub async fn thread_list( &self, params: ThreadListParams, ) -> Result<ThreadListResult, ClientError>
Lists recorded threads after ensuring the app-server handshake is complete.
pub async fn thread_start( &self, params: ThreadStartParams, ) -> Result<ThreadResult, ClientError>
pub async fn thread_resume( &self, params: ThreadResumeParams, ) -> Result<ThreadResult, ClientError>
pub async fn thread_fork( &self, params: ThreadForkParams, ) -> Result<ThreadResult, ClientError>
pub async fn thread_archive( &self, params: ThreadArchiveParams, ) -> Result<ThreadArchiveResult, ClientError>
pub async fn thread_name_set( &self, params: ThreadSetNameParams, ) -> Result<ThreadSetNameResult, ClientError>
pub async fn thread_unarchive( &self, params: ThreadUnarchiveParams, ) -> Result<ThreadUnarchiveResult, ClientError>
pub async fn thread_compact_start( &self, params: ThreadCompactStartParams, ) -> Result<ThreadCompactStartResult, ClientError>
pub async fn thread_background_terminals_clean( &self, params: ThreadBackgroundTerminalsCleanParams, ) -> Result<ThreadBackgroundTerminalsCleanResult, ClientError>
pub async fn thread_rollback( &self, params: ThreadRollbackParams, ) -> Result<ThreadRollbackResult, ClientError>
pub async fn thread_loaded_list( &self, params: ThreadLoadedListParams, ) -> Result<ThreadLoadedListResult, ClientError>
pub async fn thread_read( &self, params: ThreadReadParams, ) -> Result<ThreadReadResult, ClientError>
pub async fn skills_list( &self, params: SkillsListParams, ) -> Result<SkillsListResult, ClientError>
pub async fn skills_remote_list( &self, params: SkillsRemoteReadParams, ) -> Result<SkillsRemoteReadResult, ClientError>
pub async fn skills_remote_export( &self, params: SkillsRemoteWriteParams, ) -> Result<SkillsRemoteWriteResult, ClientError>
pub async fn app_list( &self, params: AppsListParams, ) -> Result<AppsListResult, ClientError>
pub async fn skills_config_write( &self, params: SkillsConfigWriteParams, ) -> Result<SkillsConfigWriteResult, ClientError>
pub async fn turn_start( &self, params: TurnStartParams, ) -> Result<TurnResult, ClientError>
pub async fn turn_steer( &self, params: TurnSteerParams, ) -> Result<TurnSteerResult, ClientError>
pub async fn turn_interrupt( &self, params: TurnInterruptParams, ) -> Result<EmptyObject, ClientError>
pub async fn review_start( &self, params: ReviewStartParams, ) -> Result<ReviewStartResult, ClientError>
pub async fn model_list( &self, params: ModelListParams, ) -> Result<ModelListResult, ClientError>
pub async fn experimental_feature_list( &self, params: ExperimentalFeatureListParams, ) -> Result<ExperimentalFeatureListResult, ClientError>
pub async fn collaboration_mode_list( &self, params: CollaborationModeListParams, ) -> Result<CollaborationModeListResult, ClientError>
pub async fn mock_experimental_method( &self, params: MockExperimentalMethodParams, ) -> Result<MockExperimentalMethodResult, ClientError>
pub async fn mcp_server_oauth_login( &self, params: McpServerOauthLoginParams, ) -> Result<McpServerOauthLoginResult, ClientError>
pub async fn mcp_server_status_list( &self, params: ListMcpServerStatusParams, ) -> Result<McpServerStatusListResult, ClientError>
pub async fn windows_sandbox_setup_start( &self, params: WindowsSandboxSetupStartParams, ) -> Result<WindowsSandboxSetupStartResult, ClientError>
pub async fn account_login_start( &self, params: LoginAccountParams, ) -> Result<LoginAccountResult, ClientError>
pub async fn account_login_cancel( &self, params: CancelLoginAccountParams, ) -> Result<EmptyObject, ClientError>
pub async fn feedback_upload( &self, params: FeedbackUploadParams, ) -> Result<FeedbackUploadResult, ClientError>
pub async fn command_exec( &self, params: CommandExecParams, ) -> Result<CommandExecResult, ClientError>
pub async fn config_read( &self, params: ConfigReadParams, ) -> Result<ConfigReadResult, ClientError>
pub async fn config_value_write( &self, params: ConfigValueWriteParams, ) -> Result<ConfigValueWriteResult, ClientError>
pub async fn config_batch_write( &self, params: ConfigBatchWriteParams, ) -> Result<ConfigBatchWriteResult, ClientError>
pub async fn account_read( &self, params: GetAccountParams, ) -> Result<GetAccountResult, ClientError>
pub async fn fuzzy_file_search_session_start( &self, params: FuzzyFileSearchSessionStartParams, ) -> Result<FuzzyFileSearchSessionStartResult, ClientError>
pub async fn fuzzy_file_search_session_update( &self, params: FuzzyFileSearchSessionUpdateParams, ) -> Result<FuzzyFileSearchSessionUpdateResult, ClientError>
pub async fn fuzzy_file_search_session_stop( &self, params: FuzzyFileSearchSessionStopParams, ) -> Result<FuzzyFileSearchSessionStopResult, ClientError>
pub async fn skills_remote_read( &self, params: SkillsRemoteReadParams, ) -> Result<SkillsRemoteReadResult, ClientError>
pub async fn skills_remote_write( &self, params: SkillsRemoteWriteParams, ) -> Result<SkillsRemoteWriteResult, ClientError>
pub async fn config_mcp_server_reload(&self) -> Result<EmptyObject, ClientError>
pub async fn account_logout(&self) -> Result<EmptyObject, ClientError>
pub async fn account_rate_limits_read( &self, ) -> Result<AccountRateLimitsReadResult, ClientError>
pub async fn config_requirements_read( &self, ) -> Result<ConfigRequirementsReadResult, ClientError>
pub async fn send_raw_request( &self, method: impl Into<String>, params: Value, timeout: Option<Duration>, ) -> Result<Value, ClientError>
pub async fn send_raw_notification( &self, method: impl Into<String>, params: Value, ) -> Result<(), ClientError>
pub fn client(&self) -> CodexClient
Trait Implementations§
Auto Trait Implementations§
impl Freeze for Codex
impl !RefUnwindSafe for Codex
impl Send for Codex
impl Sync for Codex
impl Unpin for Codex
impl UnsafeUnpin for Codex
impl !UnwindSafe for Codex
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