User ID (usr_...) whose threads should be listed.
Request body.
Optionalskip_welcome_message?: booleanWhen true, suppresses the automatic welcome message that is otherwise sent into the thread on creation. Defaults to false.
Attributes for the new thread. See ThreadCreateParams for the full set of accepted fields.
The newly created thread object.
Create a private thread from a template
Creates a private thread, installs the template's agent once per user,
and atomically adds its members and a dedicated E2B computer. Requires
devbox_access. The computer starts pending and provisions asynchronously.
key is prefixed by the template namespace and is unique for the user. Replays return
200 and never provision another computer or resend the first message; creation
returns 201. Initial-message delivery occurs after commit; a delivery failure
is returned as first_message_error so the caller can resend it.
computer is optional and applies on creation only: a replay with the same
key returns the original thread and computer, ignoring any different
computer, exactly like title and first_message. Invalid computer
input returns 422 invalid_parameters before anything is created; a provider
this deployment has no credentials for returns 422 provider_unavailable.
tags is optional and is written in the same transaction that creates the
thread, so a thread never exists without them; a replay returns the stored
tags and ignores tags in its body. Invalid tags return 422
invalid_parameters before anything is created.
Unknown templates return 422 unknown_thread_template; installation failures
return 502 agent_install_failed. Computer config and credentials are never returned.
Personal templates retain their existing behavior. Standard, private templates
require shared-thread creation to be enabled and may supply discovery/join ACL
grants. Without grants, the thread stays closed to discovery and self-join.
Their new computers use the organization's GitHub App for any repository its
installation can reach, including permission to push branches and create pull
requests. computer.repositories chooses the checkouts made at setup, not
which repositories the computer can reach.
They receive model-only ArchDev workspace authentication and do not inherit
personal GitHub credentials, Intern access or repository environment bundles.
Shared computers do not currently support the devbox provider.
User ID (usr_...) whose threads should be listed.
Request body.
Optionalcomputer?: Record<string, unknown>Optional computer choice, applied on creation only: provider (sprites, vercel, e2b or devbox; defaults to the template's) and repositories (0 to 16 {repository: owner/name, ref: optional}; the first is the primary working directory and may instead carry create: {private: boolean} to create an initialized GitHub repository asynchronously as the owner; private defaults to true; create cannot accompany ref).
Optionalfirst_message?: stringOptional first user message, posted only on creation.
Optionalkey?: stringRequired nonempty client idempotency key.
Optionaltags?: string[]Optional tags stored with the thread on creation, in the same transaction (0 to 20; the format of POST /threads/:thread/tags, so a project id such as prj_… is a valid tag). Ignored on replay: the stored tags are returned.
Thread template lookup key.
Optionaltitle?: stringTitle for the new thread.
Thread fields plus agent and computers summaries, and optional first_message_error.
List threads for a user
Returns all threads visible to the specified user. The authenticated caller must
have access to the target user's account; a 403 is returned otherwise.
Pass one or more agent IDs to narrow results to threads where at least one of
the listed agents is also a member — useful for displaying every thread a user
shares with a particular agent. Pass a structured metadata expression to
narrow results by thread metadata; it supports nested paths, contains,
exists, and and / or / not composition. The older filter objects
match one top-level metadata key/value pair each and are still accepted. Pass
one or more tags to keep only threads carrying at least one of them. All
narrowings may be combined in a single request.
Results are returned as a flat array; no cursor-based pagination is applied.
Threads are ordered with default threads first, then by most recent activity
(newest first), each carrying a last_activity timestamp.
User ID (usr_...) whose threads should be listed.
Optionalparams: {Query parameters.
Optionalagent?: string[]Array of agent user IDs (usr_...). When provided, only threads where at least one of the listed agents is also a member are returned. Omit or pass an empty array to return all threads regardless of agent membership.
Optionalfilter?: { key: string; type: string; value: string }[]Array of metadata filter objects. Each filter matches threads whose metadata map contains the specified key/value pair. All filters must match (logical AND). Omit to return threads regardless of metadata.
Optionalinclude?: "work_summary"[]Optional enrichments. work_summary returns viewer-visible hand-off counts for owned threads.
Optionalmetadata?: {Structured metadata filter expression, JSON-encoded. Only threads whose metadata satisfies the expression are returned.
Optionaltags?: string[]Optional: only return threads tagged with at least one of these tags (OR-match). Repeated query params, e.g. ?tags[]=blocked&tags[]=needs-review.
Successful response
Create a thread for a user Creates a new thread owned by the specified user. The authenticated caller must have access to the target user's account; a 403 is returned otherwise. An automatic welcome message is sent into the thread upon creation unless
skip_welcome_messageis set totrue. The thread is immediately visible to the owning user and any members added at creation time.