Propose a decision record (own session token only)
const url = 'http://127.0.0.1:8080/v1/sessions/2489E9AD-2EE2-8E00-8EC9-32D5F69181C0/decisions';const options = { method: 'POST', headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'}, body: '{"title":"example","context":"example","decision":"example","consequences":"example","alternatives":"example","risk":"low","supersedes":"2489E9AD-2EE2-8E00-8EC9-32D5F69181C0"}'};
try { const response = await fetch(url, options); const data = await response.json(); console.log(data);} catch (error) { console.error(error);}curl --request POST \ --url http://127.0.0.1:8080/v1/sessions/2489E9AD-2EE2-8E00-8EC9-32D5F69181C0/decisions \ --header 'Authorization: Bearer <token>' \ --header 'Content-Type: application/json' \ --data '{ "title": "example", "context": "example", "decision": "example", "consequences": "example", "alternatives": "example", "risk": "low", "supersedes": "2489E9AD-2EE2-8E00-8EC9-32D5F69181C0" }'The server never lowers the stated risk. It raises low to high
when the title or the decision names a risky area (ADR-0009,
section 4), and a decision that supersedes a high one is high
too. risk_reason says why. A low decision is accepted at once.
A high one stays proposed until a lead or admin other than the
proposer reviews it, and they get a decision_pending notice. Every
field passes the secret scan, and the proposal is audited.
Authorizations
Section titled “Authorizations”Parameters
Section titled “Parameters”Path Parameters
Section titled “Path Parameters”Request Bodyrequired
Section titled “Request Bodyrequired”object
A decision of the same project this one replaces, which is not already superseded. A rejected decision stays rejected, and an accepted successor from the same session clears its merge gate.
Responses
Section titled “Responses”Stored.
object
object
object
Why the server raised the risk. Absent when it kept the stated one.
object
object
Search only: the cosine or trigram similarity to q.
Up to three of the session’s most urgent undelivered notices, one line each, after a “Zentri notices:” header. A last line says how many more wait. Showing a notice here marks it delivered but not acked. Absent when nothing is undelivered or the caller is not the session’s own token.
Example
{ "decision": { "risk": "low", "risk_stated": "low", "status": "proposed", "review": { "verdict": "approved" } }}The request is malformed.
object
object
Example generated
{ "error": { "code": "example", "message": "example" }}No valid bearer token.
object
object
Example generated
{ "error": { "code": "example", "message": "example" }}The token may not do this.
object
object
Example generated
{ "error": { "code": "example", "message": "example" }}No such resource in the caller’s org.
object
object
Example generated
{ "error": { "code": "example", "message": "example" }}The request clashes with current state.
object
object
Example generated
{ "error": { "code": "example", "message": "example" }}The request is well formed but breaks a rule or a limit.
object
object
Example generated
{ "error": { "code": "example", "message": "example" }}A rate limit or quota stopped the request. Retry-After gives seconds to wait.
object
object
Example generated
{ "error": { "code": "example", "message": "example" }}