docs(pr-agent): document the OpenCode Go session header
PR Check / Security scan (Snyk) (pull_request) Skipped
PR Check / Lint + typecheck (pull_request) Failing after 23s
PR Check / Secret scan (gitleaks) (pull_request) Successful in 6s
PR Check / Dependency audit (pull_request) Failing after 10s
PR Check / Dockerfile lint (droast) (pull_request) Successful in 4s

This commit is contained in:
Noel Sabia committed 2026-10-30 21:11:19 +01:00
1 parent f5810960a8
commit b84d353dcb
3 files changed
+10

No files matched your search

+4
View File
@@ -52,6 +52,10 @@ api base https://opencode.ai/inference/go/openai/v1
model table does not know; PR-Agent's default `config.max_model_tokens`
still caps the review budget at 32000.
OpenCode Go requires an `x-opencode-session` header. PR-Agent sends the
stable id `pr-agent` through `LITELLM__EXTRA_HEADERS`; without it the
provider rejects the request before it reaches the model.
# Why
* One container replaces a per-PR CLI install, binary cache and prompt
+3
View File
@@ -23,3 +23,6 @@ CONFIG__FALLBACK_MODELS=["openai/glm-5.3"]
CONFIG__CUSTOM_MODEL_MAX_TOKENS=128000
OPENAI__API_BASE=https://opencode.ai/inference/go/openai/v1
OPENAI__KEY=
# OpenCode Go requires a session id header; a stable id is enough here.
LITELLM__EXTRA_HEADERS={"x-opencode-session":"pr-agent"}
+3
View File
@@ -70,6 +70,9 @@ api base https://opencode.ai/inference/go/openai/v1
the model is not in its token table. The effective review budget is still
capped by PR-Agent's default `config.max_model_tokens` of 32000.
OpenCode Go requires an `x-opencode-session` header; PR-Agent sends the
stable id `pr-agent` through `LITELLM__EXTRA_HEADERS`.
The transfer file used during installation was empty, so set the key as
root and redeploy: