Skip to content

Unable to access GLM 4.7 on Google Vertex AI #9909

@NimaAra

Description

@NimaAra

Description

I have the following provider set in my config which allows me to successfully access gemini models:

...
"provider": {
    "google-vertex": {
      "options": {
        "location": "global",
        "project": "my-project-id"
      },
      "models": {
        "zai-org/glm-4.7-maas": {
          "name": "GLM 4.7 (Vertex AI)"
        },
        "gemini-3-pro-preview": {
          "name": "Gemini 3 Pro (Vertex AI)",
          "options": {
            "temperature": 1.0,
            "generationConfig": {
              "thinkingConfig": {
                "thinkingLevel": "high"
              }
            }
          }
        }
...

However, I am not able to access GLM 4.7 and I get the "Not Found" toast in opencode.

I have validated the GLM 4.7 access in the GCP shell by executing:

curl \
  -X POST \
  -H "Authorization: Bearer $(gcloud auth print-access-token)" \
  -H "Content-Type: application/json" https://${ENDPOINT}/v1/projects/${PROJECT_ID}/locations/${REGION}/endpoints/openapi/chat/completions \
  -d '{"model":"zai-org/glm-4.7-maas", "stream":true, "messages":[{"role": "user", "content": "Summer travel plan to Paris"}]}'

What am I missing?

Plugins

none

OpenCode version

1.1.30

Steps to reproduce

  1. Add provider (as provided)
  2. Choose GLM 4.7 as the model
  3. Send prompt

Screenshot and/or share link

No response

Operating System

Windows 11

Terminal

Windows Terminal

Metadata

Metadata

Assignees

Labels

bugSomething isn't workingwindowszenRelates to Zen

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions