Skip to content

Edit an answer

PUT
/api/answers/{question_id}
curl --request PUT \
--url http://127.0.0.1:8765/api/answers/example \
--header 'Content-Type: application/json' \
--data '{ "actor": "agent", "answer": "Yes, 5 years, GKE, BigQuery and Dataflow", "revision": 1 }'

Edit an answer: its text, the question words and/or the tag. At least one of answer, question, tag, source (an empty source removes it). Every write bumps revision and updated_at and records written_by. 409 revision_conflict carries the current answer in the error: someone (the user, or another agent) wrote it after you read it; read it, merge, and send again with its revision. A changed answer or question (not a tag alone): 0.1.10.7: the write also queues the background pipeline (tailored resume, assessment against it, Scout ATS score, Scout label) for every job of an active profile whose stored assessment left open a question this answers; at most pipeline.auto_jobs_per_trigger (10) jobs run, the rest wait for an approval (GET /api/pipeline/approvals). The pipeline’s tailoring replaces only a tailored resume the pipeline itself made: one tailored on demand (POST /api/tailored-resumes) or with a line chosen or edited (PUT /api/tailored-resumes/lines) is kept as it is, its updated_at unchanged, and the assessment, the Scout ATS score and the Scout label are made against it. Read what was queued with GET /api/pipeline.

question_id
required
string

An answer’s id (e.g. cloud:gcp). Percent-encode it in the path.

Media typeapplication/json
object
actor

Who writes: recorded as written_by. Also the X-GigAI-Actor header. Without either, a write from the Scout UI (a browser page of this server) is the operator’s and any other loopback write is the agent’s.

string
Allowed values: operator agent
answer

The new answer.

string
question

The question’s own words.

string
revision
required

The revision of the answer you read; when it changed since, the reply is 409.

integer
source

Free text, at most 300 characters: where the answer came from (e.g. “from the user’s repo, at the user’s request”). Returned with the answer; never sent to a model. A new answer text without it drops the stored one.

string
tag

Your own tag; an empty string puts the automatic tag back.

string
Example
{
"actor": "agent",
"answer": "Yes, 5 years, GKE, BigQuery and Dataflow",
"revision": 1
}

Success.

Media typeapplication/json
object
schema_version
required
Allowed value: scout-answers-response:1
key
additional properties
any
Example
{
"answer": {
"answer": "Yes, 4 years, GKE + BigQuery",
"created_at": "2026-10-02T15:00:00.000000Z",
"history": [
{
"action": "answered",
"at": "2026-10-02T15:00:00.000000Z",
"by": "agent"
}
],
"jobs": [
{
"at": "2026-10-02T15:00:00.000000Z",
"company": "Acme",
"job_identity": "https://boards.greenhouse.io/acme/jobs/101",
"kind": "answered",
"title": "Software Engineer",
"url": "https://boards.greenhouse.io/acme/jobs/101"
}
],
"question": "Do you have GCP experience?",
"question_id": "cloud:gcp",
"revision": 1,
"source": "from the user's repo infra-charts, at the user's request",
"tag": "technical",
"updated_at": "2026-10-02T15:00:00.000000Z",
"written_by": "agent"
},
"schema_version": "scout-answers-response:1"
}

Forbidden / forbidden_origin: loopback peer and Host 127.0.0.1:<port> or localhost:<port> only (Origin too on writes).

Media typeapplication/json
object
error
required
object
allowed_keys
Array<string>
code
required
string
message
required
string
key
additional properties
any
Examplegenerated
{
"error": {
"allowed_keys": [
"example"
],
"code": "example",
"message": "example"
}
}

Not_found, target_unavailable

Media typeapplication/json
object
error
required
object
allowed_keys
Array<string>
code
required
string
message
required
string
key
additional properties
any
Example
{
"error": {
"code": "not_found",
"message": "..."
}
}

Revision_conflict

Media typeapplication/json
object
error
required
object
allowed_keys
Array<string>
code
required
string
message
required
string
key
additional properties
any
Example
{
"error": {
"code": "revision_conflict",
"message": "..."
}
}

Unsupported_media_type: writes need Content-Type: application/json.

Media typeapplication/json
object
error
required
object
allowed_keys
Array<string>
code
required
string
message
required
string
key
additional properties
any
Examplegenerated
{
"error": {
"allowed_keys": [
"example"
],
"code": "example",
"message": "example"
}
}

Unknown_key, wrong_type, invalid_value, answer_invalid, personal_info_refused

Media typeapplication/json
object
error
required
object
allowed_keys
Array<string>
code
required
string
message
required
string
key
additional properties
any
Example
{
"error": {
"code": "unknown_key",
"message": "..."
}
}