# T3 v0.3.0 - API Reference

## Modules

- [T3](T3.md): Elixir SDK for T3 Code's MCP, HTTP JSON, WebSocket RPC and local CLI interfaces.
- [T3.Attachments](T3.Attachments.md): Attachments MCP operations. Pass T3's original string-keyed argument maps.
- [T3.Board](T3.Board.md): Pure board projection for ordinary orchestration shell/thread streams.
- [T3.Board.Thread](T3.Board.Thread.md): Small board row, independent of T3's wire projection.
- [T3.CLI](T3.CLI.md): Shell-free access to the installed T3 command line interface, using Exile.
- [T3.CLI.Result](T3.CLI.Result.md): A completed CLI invocation. stdout and stderr share the output field.
- [T3.Catalog](T3.Catalog.md): Versioned inventory of T3 MCP helpers, including context-only operations.
- [T3.Client](T3.Client.md): A connection to one T3 `/mcp` endpoint, backed by ConduitMCP.
- [T3.Devices](T3.Devices.md): Devices MCP operations. Pass T3's original string-keyed argument maps.
- [T3.Environments](T3.Environments.md): Environments MCP operations. Pass T3's original string-keyed argument maps.
- [T3.HTML](T3.HTML.md): HTML MCP operations. Pass T3's original string-keyed argument maps.
- [T3.HTTP](T3.HTTP.md): Explicit HTTP access to T3's environment API, independent of the MCP session.
- [T3.HTTP.Auth](T3.HTTP.Auth.md): Named access to T3 HTTP auth routes. Options accept wire-map JSON/form bodies, query and headers.
- [T3.HTTP.Catalog](T3.HTTP.Catalog.md): HTTP routes declared by T3's `EnvironmentHttpApi` contract.
- [T3.HTTP.Connect](T3.HTTP.Connect.md): Named access to T3 HTTP connect routes. Options accept wire-map JSON/form bodies, query and headers.
- [T3.HTTP.DeviceHub](T3.HTTP.DeviceHub.md): Low-level HTTP access to T3's allowlisted device-hub proxy routes.
Pass `query: %{"hostId" => host_id}` to select a host. Codec streams remain
binary, and screenshots/accessibility/control payloads are forwarded unchanged.
These APIs expose the server interface; they do not boot or select devices.

- [T3.HTTP.Guest](T3.HTTP.Guest.md): Guest-share routes. Supply `query: %{"share" => share_id}` and the appropriate
guest Cookie header explicitly; a normal MCP bearer is not a guest session.
`redeem/2` returns Set-Cookie headers for the caller to retain securely.
`messages/2` accepts JSON or `multipart: T3.HTTP.multipart(fields, files)`.

- [T3.HTTP.Media](T3.HTTP.Media.md): Binary assets, attachment capability uploads and browser upload/download.
- [T3.HTTP.Metadata](T3.HTTP.Metadata.md): Named access to T3 HTTP metadata routes. Options accept wire-map JSON/form bodies, query and headers.
- [T3.HTTP.Multipart](T3.HTTP.Multipart.md): Multipart request bodies backed by the `multipart` package, including streamed files.
- [T3.HTTP.OAuth](T3.HTTP.OAuth.md): Named access to T3 HTTP oauth routes. Options accept wire-map JSON/form bodies, query and headers.
- [T3.HTTP.Orchestration](T3.HTTP.Orchestration.md): Named access to T3 HTTP orchestration routes. Options accept wire-map JSON/form bodies, query and headers.
- [T3.HTTP.Projects](T3.HTTP.Projects.md): Named access to T3 HTTP projects routes. Options accept wire-map JSON/form bodies, query and headers.
- [T3.HTTP.PullRequests](T3.HTTP.PullRequests.md): Named access to T3 HTTP pull_requests routes. Options accept wire-map JSON/form bodies, query and headers.
- [T3.HTTP.Raw](T3.HTTP.Raw.md): Routes implemented outside T3's typed EnvironmentHttpApi contract.
- [T3.HTTP.Response](T3.HTTP.Response.md): An HTTP success, including raw headers and a JSON-decoded or binary body.
- [T3.HTTP.Stream](T3.HTTP.Stream.md): Bounded HTTP response streaming with callback backpressure and cancellation.
- [T3.HTTP.Stream.Summary](T3.HTTP.Stream.Summary.md): Counters and response metadata after stream completion or callback halt.
- [T3.HTTP.Webhooks](T3.HTTP.Webhooks.md): Named access to T3 HTTP webhooks routes. Options accept wire-map JSON/form bodies, query and headers.
- [T3.LocalAuth](T3.LocalAuth.md): Cached, renewable native credentials for a service on the T3 host.
- [T3.LocalAuth.Credential](T3.LocalAuth.Credential.md): An owned native session. Token inspection is redacted; expiry is a DateTime.
- [T3.OAuth](T3.OAuth.md): T3 sign-in using ConduitMCP's OAuth discovery, registration, PKCE and callback handling.
Defaults to read-only scope. Tokens stay in Conduit's in-memory store unless the
caller supplies a custom `:store` in `:oauth_options`. The caller owns single-use
consumption of flows created through `begin/2`; `login/2` uses a one-shot listener.

- [T3.OAuth.Flow](T3.OAuth.Flow.md): Private pending OAuth authorization.
- [T3.Previews](T3.Previews.md): Previews MCP operations. Pass T3's original string-keyed argument maps.
- [T3.Projects](T3.Projects.md): Project discovery and mutation through MCP. Outside clients have no implicit T3
project. `read/2`, `create/2`, `update/2`, `delete/2` and `clone/2` take T3's
original string-keyed maps. Permission and availability are enforced by T3.

- [T3.PullRequests](T3.PullRequests.md): PullRequests MCP operations. Pass T3's original string-keyed argument maps.
- [T3.Queues](T3.Queues.md): Queues MCP operations. Pass T3's original string-keyed argument maps.
- [T3.RPC](T3.RPC.md): Supervised WebSocket client for T3's Effect RPC protocol (`/ws`).
- [T3.RPC.Catalog](T3.RPC.Catalog.md): Pinned upstream WebSocket method inventory. Methods accept their original JSON
wire payloads; this catalog does not pretend to validate TypeScript schemas.
The transport supports arbitrary method strings for forward compatibility.

- [T3.RPC.Cursor](T3.RPC.Cursor.md): Extract T3 orchestration resume sequences without interpreting event bodies.
- [T3.RPC.Methods](T3.RPC.Methods.md): Named helpers for every method in the pinned T3 WebSocket contract.
All take `(rpc, payload \ %{}, options \ [])`. Stream methods return a
subscription ID, unary methods return their result. See `T3.RPC` for explicit
acknowledgements and lifecycle. Argument maps keep T3's original string keys.

- [T3.RPC.Reader](T3.RPC.Reader.md): Supervised owner of reconnecting, read-only RPC subscriptions.
- [T3.RPC.WorkQueue](T3.RPC.WorkQueue.md): Optional bounded, ordered, in-memory processing for reader chunks.
- [T3.Requests](T3.Requests.md): Requests MCP operations. Pass T3's original string-keyed argument maps.
- [T3.Result](T3.Result.md): Read structured tool data from MCP structuredContent or a JSON text block.
- [T3.Schedules](T3.Schedules.md): Schedules MCP operations. Pass T3's original string-keyed argument maps.
- [T3.Tasks](T3.Tasks.md): Delegated-task and background-work operations.
- [T3.Threads](T3.Threads.md): Thread MCP operations with original string-keyed arguments.
- [T3.Tools](T3.Tools.md): One named function per known T3 MCP wire tool.
- [T3.WebSocket](T3.WebSocket.md): Raw WebSocket transport for T3's non-Effect media/device routes.
- [T3.WebSocket.Routes](T3.WebSocket.Routes.md): The four non-Effect WebSocket routes in the pinned T3 server. All use the
environment/media authentication audience, not MCP OAuth credentials. Obtain a
media ticket with `T3.HTTP.Auth.web_socket_ticket_for(http, "media")` and pass
`ticket: response.body["ticket"]`.
- [T3.Worktrees](T3.Worktrees.md): Worktrees MCP operations. Pass T3's original string-keyed argument maps.

- Exceptions
  - [T3.Error](T3.Error.md): A transport, HTTP, protocol, OAuth, or tool failure. Details may contain server data.

## Mix Tasks

- [mix t3.interfaces](Mix.Tasks.T3.Interfaces.md): `mix t3.interfaces` prints the known interface families and operation counts.
`mix t3.interfaces --json` prints their complete catalogs as JSON.
This command does not contact T3 or execute its CLI.

