Skip to content

bad gateway error #35148

Closed as not planned
Closed as not planned

Description

@dnm-stack

Description

Image

get bad gateway error and looping

Plugins

Go

OpenCode version

OpenCode Desktop v1.16.2

Steps to reproduce

no specifc steps
give specific command, run it, in the middle get it

Screenshot and/or share link

No response

Operating System

macOs 26.5.1

Terminal

Ghostty

Activity

  1. liyang960414 commented on Jul 3, 2026

    @liyang960414

    DeepSeek service is unavailable, GLM is available.

  2. jabin-hao commented on Jul 3, 2026

    @jabin-hao
    Image Yes, I meet same problem
  3. erelst commented on Jul 3, 2026

    @erelst

    same here

  4. hkgodhani commented on Jul 3, 2026

    @hkgodhani

    same here and i try to use another model now i have to told it every think till now old model is doing

  5. hkgodhani commented on Jul 3, 2026

    @hkgodhani

    DeepSeek service is unavailable, GLM is available.

    deepseek service is available in free but in go it is not available

  6. ricolandia commented on Jul 3, 2026

    @ricolandia

    The same here.

    OpenCode Go API returning 502 Bad Gateway — all opencode-go/ models broken

    Version: opencode CLI 1.17.9, Desktop 1.16.2
    OS: Debian 13 (Trixie)

    Steps to reproduce:

    1. In OpenCode Desktop, select any opencode-go/ model (e.g. opencode-go/deepseek-v4-flash)
    2. Send a message
    3. Receive "Bad Gateway" error

    Diagnostic findings:

    • DNS resolves correctly (Cloudflare IPs)

    • TLS handshake succeeds

    • Every API endpoint returns the website's SPA 404 HTML page:

      • GET https://opencode.ai/api/ → 404 HTML
      • POST https://opencode.ai/api/chat/completions → 404 HTML
      • POST https://opencode.ai/v1/chat/completions → 404 HTML
      • GET https://opencode.ai/health → 404 HTML
    • OpenRouter and Google providers work fine on the same machine

    • API key (sk-...) is valid and has credits remaining

    • Issue is not network-related (Tailscale, proxies, etc.) — confirmed via direct curl requests

    Expected behavior: API endpoints should return JSON responses and process model requests.

    Actual behavior: All API routes return the OpenCode website HTML (SPA), indicating the Go backend service is not running or the reverse proxy is misconfigured.

  7. liyang960414 commented on Jul 3, 2026

    @liyang960414

    DeepSeek service is unavailable, GLM is available.

    deepseek service is available in free but in go it is not available

    You can try the official DeepSeek API; the time-based pricing hasn't doubled yet.

  8. victor-ovalle commented on Jul 3, 2026

    @victor-ovalle

    Yes, it seems that GLM is working fine

  9. github-actions commented on Sep 5, 2026

    @github-actions
    Contributor

    To stay organized issues are automatically closed after 60 days of no activity. If the issue is still relevant please open a new one.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

Labels

No labels
No labels

Type

No type

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions