API Reference T3 v#0.3.0

Copy Markdown View Source

Modules

T3

Elixir SDK for T3 Code's MCP, HTTP JSON, WebSocket RPC and local CLI interfaces.

Attachments MCP operations. Pass T3's original string-keyed argument maps.

Pure board projection for ordinary orchestration shell/thread streams.

Small board row, independent of T3's wire projection.

Shell-free access to the installed T3 command line interface, using Exile.

A completed CLI invocation. stdout and stderr share the output field.

Versioned inventory of T3 MCP helpers, including context-only operations.

A connection to one T3 /mcp endpoint, backed by ConduitMCP.

Devices MCP operations. Pass T3's original string-keyed argument maps.

Environments MCP operations. Pass T3's original string-keyed argument maps.

A transport, HTTP, protocol, OAuth, or tool failure. Details may contain server data.

HTML MCP operations. Pass T3's original string-keyed argument maps.

Explicit HTTP access to T3's environment API, independent of the MCP session.

Named access to T3 HTTP auth routes. Options accept wire-map JSON/form bodies, query and headers.

HTTP routes declared by T3's EnvironmentHttpApi contract.

Named access to T3 HTTP connect routes. Options accept wire-map JSON/form bodies, query and headers.

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.

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).

Binary assets, attachment capability uploads and browser upload/download.

Named access to T3 HTTP metadata routes. Options accept wire-map JSON/form bodies, query and headers.

Multipart request bodies backed by the multipart package, including streamed files.

Named access to T3 HTTP oauth routes. Options accept wire-map JSON/form bodies, query and headers.

Named access to T3 HTTP orchestration routes. Options accept wire-map JSON/form bodies, query and headers.

Named access to T3 HTTP projects routes. Options accept wire-map JSON/form bodies, query and headers.

Named access to T3 HTTP pull_requests routes. Options accept wire-map JSON/form bodies, query and headers.

Routes implemented outside T3's typed EnvironmentHttpApi contract.

An HTTP success, including raw headers and a JSON-decoded or binary body.

Bounded HTTP response streaming with callback backpressure and cancellation.

Counters and response metadata after stream completion or callback halt.

Named access to T3 HTTP webhooks routes. Options accept wire-map JSON/form bodies, query and headers.

Cached, renewable native credentials for a service on the T3 host.

An owned native session. Token inspection is redacted; expiry is a DateTime.

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.

Private pending OAuth authorization.

Previews MCP operations. Pass T3's original string-keyed argument maps.

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.

PullRequests MCP operations. Pass T3's original string-keyed argument maps.

Queues MCP operations. Pass T3's original string-keyed argument maps.

Supervised WebSocket client for T3's Effect RPC protocol (/ws).

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.

Extract T3 orchestration resume sequences without interpreting event bodies.

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.

Supervised owner of reconnecting, read-only RPC subscriptions.

Optional bounded, ordered, in-memory processing for reader chunks.

Requests MCP operations. Pass T3's original string-keyed argument maps.

Read structured tool data from MCP structuredContent or a JSON text block.

Schedules MCP operations. Pass T3's original string-keyed argument maps.

Delegated-task and background-work operations.

Thread MCP operations with original string-keyed arguments.

One named function per known T3 MCP wire tool.

Raw WebSocket transport for T3's non-Effect media/device routes.

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"].

Worktrees MCP operations. Pass T3's original string-keyed argument maps.

Mix Tasks

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.