You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Issue with sdk.chat function: Undefined Error #4977
I'm encountering an issue when trying to execute opencode. The error log indicates that sdk.chat is undefined. After a successful auth login into github-enterprise I start opencode and ask something. Here are the details:
Error Log:
ERROR 2025-12-02T10:07:17 +21ms service=default e=sdk.chat is not a function. (In 'sdk.chat(modelID)', 'sdk.chat' is undefined) rejection
OpenCode version
1.0.126
Steps to reproduce
remove all relevant directories
rm -rf .cache/opencode
rm -rf .config/opencode
rm -rf .local/share/opencode
rm -rf .opencode
opencode auth login
successful login in an gitHub-enterprise account xxx.ghe.com
start opencode and ask something
tested also different models, always the same issue
Activity
rekram1-node commentedon Dec 2, 2025
hmm I must have broken something, I will take a look
rekram1-node commentedon Dec 2, 2025
in meantime you can downgrade to something pre 1.0.115ish ill fix this today
rekram1-node commentedon Dec 3, 2025
fixed in next release: b457923
fix: cloudflare-ai-gateway sdk.chat undefined error