[Integrations](https://spiral.ai/integrations) › [Muse Code](https://spiral.ai/integrations/muse-code) › [GLM Latest](https://spiral.ai/integrations/muse-code/glm-latest)

# How to Use GLM Latest in Muse Code

GLM Latest follows Z.ai's newest GLM release for coding and reasoning work, currently GLM 5.3. Unlike GLM 5.3, it can change which model answers as new releases arrive.

|  |  |
| --- | --- |
| Model | GLM Latest |
| Available through | OpenRouter |
| Category | LLM |
| Price | Up to $0.007459 per run at the default inputs. $0.09087 per 1M input tokens, $1.82 per 1M output tokens. |
| Returns | text, json |
| Runs | In the background |
| Setup | About 2 minutes, no API key |

## Prompts to try with GLM Latest in Muse Code

- Use GLM Latest to investigate the failing tests in this project. Reproduce one failure, trace its cause, make the smallest justified fix, and rerun the relevant checks. Report the changed files and any remaining failures.
- Use GLM Latest to inspect this project's authentication code and tests. Identify inconsistent session-expiration behavior, propose a focused correction, and add a regression check before changing the implementation.
- Use GLM Latest to implement pagination in this project's existing list endpoint. Follow the current conventions, preserve existing filters, and test empty results, the last page, and invalid page sizes.
- Use GLM Latest to plan a refactor of this project's duplicated validation logic. Map callers first, preserve public behavior, make the changes in small steps, and verify each step with relevant tests.
- Use GLM Latest to diagnose this project's slowest tested operation. Establish a baseline, identify the bottleneck, make one justified optimization, and compare performance while checking correctness.

## How to set up GLM Latest in Muse Code

Pick the way that suits you. Each takes about two minutes.

### Use Spiral's MCP server

1. **Install Muse Code**

```bash
curl -fsSL https://dev.meta.ai/install.sh | bash
```

2. **Ask Muse to add the server**: Start `muse` and ask:

```text
Add the Spiral MCP server at https://api.spiral.ai/mcp
```

3. **Sign in**: In your terminal, run:

```bash
muse mcp login spiral
```

### Use the Spiral skill

1. **Send Muse Code this message**: Your agent reads Spiral's skill and sets itself up.

```
set up https://spiral.ai/SKILL.md
```

2. **Sign in or paste a key**: Approve Spiral in the browser, or give the agent a key from the console.

### Use the Spiral CLI

1. **Install and sign in**: Installs the Spiral CLI, signs you in and adds its skill to your coding agents.

```bash
npx -y spiral-cli@latest init
```

### Call the Spiral API

1. **Create an API key**: In the console, under API keys.

2. **Run GLM Latest**: One request; the result comes back by polling or a webhook.

```bash
curl https://api.spiral.ai/v1/runs \
  -H "Authorization: Bearer $SPIRAL_API_KEY" \
  -H "Content-Type: application/json" \
  -H "Idempotency-Key: $(uuidgen)" \
  -d '{
    "provider": "openrouter",
    "model": "~z-ai/glm-latest",
    "input": {
      "messages": [
        {
          "role": "system"
        }
      ]
    }
  }'
```

Then paste one of the prompts above: Muse Code finds GLM Latest on Spiral, shows the price and runs it.

Setup guide in the docs: https://spiral.ai/docs/quickstarts/muse-code

## GLM Latest tools and prices

- [Z.ai: GLM Latest](https://spiral.ai/tools/openrouter/~z-ai/glm-latest) (OpenRouter): Up to $0.007459 per run at the default inputs. $0.09087 per 1M input tokens, $1.82 per 1M output tokens.

## Settings you can ask for

| Setting | Allowed values | Default | Description |
| --- | --- | --- | --- |
| seed |  | — |  |
| stop |  | — |  |
| min_p | 0 to 1 | — |  |
| tools |  | — |  |
| top_k | 0 to … | — |  |
| top_p | 0 to 1 | — |  |

## What can you do with GLM Latest in Muse Code?

GLM Latest can help carry a code change from diagnosis through implementation and verification. Give it the project context, expected behavior, and checks that define a finished result.

### Reproduce and fix a bug

Give GLM Latest the failing behavior, relevant code, and expected result. Ask for a focused fix and a regression check that reproduces the original failure.

### Implement a feature with acceptance criteria

Ask GLM Latest to turn a written specification into working code, checking each acceptance criterion before reporting what remains unfinished.

### Plan a refactor

Use GLM Latest to identify dependencies, propose a sequence of changes, and define checks that preserve existing behavior.

### Compare technical designs

Give GLM Latest competing approaches and concrete constraints. Request a decision table covering failure modes, implementation work, and assumptions that need testing.

### Compare long technical documents

Provide GLM Latest with labeled source text and ask it to find conflicting requirements, cite the relevant passages, and separate conclusions from unanswered questions.

### Extract structured feedback

Ask GLM Latest to organize supplied feedback into JSON with categories, evidence, and missing values, using an example of the required structure.

## Overview

- [OpenRouter](https://spiral.ai/providers/openrouter)
- [All Muse Code guides](https://spiral.ai/integrations/muse-code)

## GLM Latest in other agents

- [Amp](https://spiral.ai/integrations/amp/glm-latest)
- [ChatGPT](https://spiral.ai/integrations/chatgpt/glm-latest)
- [Claude](https://spiral.ai/integrations/claude-desktop/glm-latest)
- [Claude Code](https://spiral.ai/integrations/claude-code/glm-latest)
- [Cline](https://spiral.ai/integrations/cline/glm-latest)
- [Codex](https://spiral.ai/integrations/codex/glm-latest)
- [Cursor](https://spiral.ai/integrations/cursor/glm-latest)
- [Devin](https://spiral.ai/integrations/devin/glm-latest)
- [dots](https://spiral.ai/integrations/dots/glm-latest)
- [Factory Droid](https://spiral.ai/integrations/factory-droid/glm-latest)
- [Gemini](https://spiral.ai/integrations/gemini/glm-latest)
- [Gemini CLI](https://spiral.ai/integrations/gemini-cli/glm-latest)
- [Google Antigravity](https://spiral.ai/integrations/antigravity/glm-latest)
- [goose](https://spiral.ai/integrations/goose/glm-latest)
- [Grok](https://spiral.ai/integrations/grok/glm-latest)
- [Grok Build](https://spiral.ai/integrations/grok-build/glm-latest)
- [Hermes](https://spiral.ai/integrations/hermes/glm-latest)
- [Instinct](https://spiral.ai/integrations/instinct/glm-latest)
- [Manus](https://spiral.ai/integrations/manus/glm-latest)
- [Muse](https://spiral.ai/integrations/muse/glm-latest)
- [n8n](https://spiral.ai/integrations/n8n/glm-latest)
- [Notion](https://spiral.ai/integrations/notion/glm-latest)
- [OpenClaw](https://spiral.ai/integrations/openclaw/glm-latest)
- [opencode](https://spiral.ai/integrations/opencode/glm-latest)
- [Perplexity](https://spiral.ai/integrations/perplexity/glm-latest)
- [Raycast](https://spiral.ai/integrations/raycast/glm-latest)
- [VS Code](https://spiral.ai/integrations/vscode/glm-latest)
- [Windsurf](https://spiral.ai/integrations/windsurf/glm-latest)
- [Zapier](https://spiral.ai/integrations/zapier/glm-latest)

## More Muse Code guides

- [GLM Flash Latest](https://spiral.ai/integrations/muse-code/glm-flash-latest)
- [GLM-4.5](https://spiral.ai/integrations/muse-code/glm-4-5)
- [GLM 5.3 Prime](https://spiral.ai/integrations/muse-code/glm-5-3-prime)
- [GLM-4.5V](https://spiral.ai/integrations/muse-code/glm-4-5v)
- [GLM 5.3 FlashX Legal](https://spiral.ai/integrations/muse-code/glm-5-3-flashx-legal)
- [GLM-4.6](https://spiral.ai/integrations/muse-code/glm-4-6)

## Questions about GLM Latest in Muse Code

**Can Muse Code use GLM Latest?**

Yes. Add Spiral to Muse Code as an MCP server, and Muse Code can find and run GLM Latest like any built-in tool.

**How much does GLM Latest cost in Muse Code?**

Up to $0.007459 per run at the default inputs. $0.09087 per 1M input tokens, $1.82 per 1M output tokens. You pay from your Spiral balance as you go, with no subscription, and a failed run is not charged. Your Muse Code plan is separate.

**Do I need an OpenRouter account to use GLM Latest in Muse Code?**

No. Spiral runs GLM Latest on its own OpenRouter account. You sign in to Spiral once and never paste a key.

**How long does it take to set up GLM Latest in Muse Code?**

About two minutes: install Muse Code, then ask Muse to add the server, then sign in.

**Does Muse Code wait while GLM Latest runs?**

GLM Latest runs in the background. Muse Code starts the run, checks on it and gives you the text, json when it's ready.

**Is GLM Latest a fixed model?**

No. GLM Latest follows Z.ai's latest GLM model and currently points to GLM 5.3, so its behavior and limits can change after a new release.

**What is GLM Latest best suited to?**

Its current target, GLM 5.3, emphasizes complex coding and tasks that require sustained work across many steps. Useful starting points include debugging, implementing features, and comparing technical approaches against explicit requirements.

**Can GLM Latest read screenshots or images?**

The current target, GLM 5.3, accepts text only. Supply the relevant text, error messages, or a written description when asking about visual material.

**How much text can GLM Latest handle?**

GLM 5.3 has a documented 1M-token context window and a maximum output length of 128K tokens. Those are separate limits: a large context window does not mean an equally long answer.

**Can I turn off reasoning?**

GLM 5.3 always uses reasoning. For a narrow task, ask for a short final answer and clear completion criteria.

