fix: show helpful message when free usage limit is exceeded (#13005)

This commit is contained in:
Dax
2026-02-10 13:58:29 -05:00
committed by opencode
parent 1d11a0adfd
commit 8bdf6fa359

View File

@@ -64,6 +64,8 @@ export namespace SessionRetry {
if (MessageV2.APIError.isInstance(error)) {
if (!error.data.isRetryable) return undefined
if (error.data.responseBody?.includes("FreeUsageLimitError"))
return `Free usage exceeded, add credits https://opencode.ai/zen`
return error.data.message.includes("Overloaded") ? "Provider is overloaded" : error.data.message
}