Rename a thread, write its description, or set its default model and reasoning effort
Changes what a person writes about the thread, in any state of the thread, finished ones included (a title and a description label the conversation, not a job). At least one of four members is given:
title: the thread's new title. Trimmed, then one line of 1 to 200 characters with no control character. A rename is logged as athread_titledevent (source: user) and is final: nothing else replaces a title a person wrote. Renaming to the title the thread has from the person already writes nothing.description: the thread's description (ADR 0035): what the conversation is about now, in a sentence or two. Trimmed, then one line of 0 to 500 characters with no control character; an empty one clears it. It is logged as athread_describedevent (source: user) and is final, an empty one included: the model is never asked for this thread's description again, and one it had in flight is dropped. Writing the description the thread has from the person already writes nothing.modelandreasoningEffort(ADR 0086,model-pick-v1.md): the thread's default pick, what a message that names none is sent with (a message's own pick wins, then the thread's, then the agent's own default). A model alias, or one ofnone,minimal,low,medium,high,xhigh,max;nullclears it, and a member that is absent is left as it is. It is checked when it is set against the thread's agent's live card, so a choice the agent does not offer is a 422 (model_not_offered,reasoning_not_offered, withoffered) and nothing is written; it is checked again whenever a message resolves to it. It is a setting of the thread row: no event records it, and a fork or an export does not copy it. The answer then carries the default as it is now inmodelandreasoningEffort.
All are checked before any is written, so a 400 changes nothing. A member other than these four is a 400, so that a client that thinks it can change more learns it cannot. The caller's own threads only (thread.write): someone else's is a 404 indistinguishable from one that does not exist, whatever the caller's roles. Everything else about the thread is as getThread says.
Authorizations
A JWT signed by the configured issuer (RS256, RS384, ES256 or EdDSA), with the configured audience. Read when auth.mode is jwt or jwt_or_proxy_header. A missing or refused token gets 401 with WWW-Authenticate: Bearer; an issuer whose keys cannot be fetched gets 503.
A JWT as bearerToken, bound to the key of the client (cnf.jkt, RFC 7638), sent as Authorization: DPoP <token> with one DPoP header holding a proof signed by that key (RFC 9449, ADR 0054). Read only when auth.dpop is configured. A bad proof gets 401 with WWW-Authenticate: DPoP error="invalid_dpop_proof", algs="ES256 EdDSA", a bad or unbound token error="invalid_token".
Set by oauth2-proxy after OIDC login; requests without it get 401. Read when auth.mode is proxy_header (the default) or jwt_or_proxy_header without a bearer token.
Request Body
Responses
The thread, with what was changed