Codex (Codex SDK v0.3.0)

View Source

Public entry point for the Codex SDK.

Provides helpers to start new threads or resume existing ones.

Summary

Functions

Resumes an existing thread with the given thread_id.

Starts a new Codex thread returning a %Codex.Thread{} struct.

Types

start_opts()

@type start_opts() :: map() | keyword() | Codex.Options.t()

thread_opts()

@type thread_opts() :: map() | keyword() | Codex.Thread.Options.t()

Functions

resume_thread(thread_id, opts \\ %{}, thread_opts \\ %{})

@spec resume_thread(String.t(), start_opts(), thread_opts()) ::
  {:ok, Codex.Thread.t()} | {:error, term()}

Resumes an existing thread with the given thread_id.

start_thread(opts \\ %{}, thread_opts \\ %{})

@spec start_thread(start_opts(), thread_opts()) ::
  {:ok, Codex.Thread.t()} | {:error, term()}

Starts a new Codex thread returning a %Codex.Thread{} struct.