Privacy settings

Privacy and GDPR notice

Nfero uses essential storage for language preferences and demo access controls. With your consent, Google Analytics and lightweight usage events help improve model demos and outbound subscription routing. Live demo prompts may be sent to configured Alibaba-hosted model endpoints.

Tool + model pairing

OpenClaw with Alibaba Coding Plan and Token Plan

Open-source, self-hosted personal AI assistant for coding and local agent workflows.

OpenClaw is a strong fit when you want a self-hosted assistant that can work across a repository, terminal, browser, and connected channels. Alibaba documents direct support for pay-as-you-go, Coding Plan, and Token Plan access.

Choose the right access route

Choose the right access route

Choose Coding Plan for one person's interactive development sessions. Choose Token Plan when a solo founder or team needs Credits-based usage, multiple seats, or steadier day-to-day agent use. Stop the gateway when you are not using it if you do not want heartbeat calls consuming plan usage.

RecommendedToken Plan for sustained agent use; Coding Plan for one interactive developer

Token Plan (Team Edition)

Best when one or more assigned users need Credits-based access across regular coding and agent sessions without Coding Plan's rolling call windows.

Coding Plan

Best for one developer using OpenClaw interactively and preferring a fixed monthly request allowance.

Pay-as-you-go Model Studio API

Use for backends, scheduled automation, shared services, or any workload that is not an assigned user's interactive tool session.

Safe configuration pattern

Register an Alibaba provider and select it as the primary model

The example is deliberately redacted. Replace placeholders only on your device and never paste a real API key into Nfero.

Before you start

  1. Install a current OpenClaw release and confirm `openclaw --version` works.
  2. Obtain a dedicated Coding Plan or Token Plan API key from the matching Alibaba subscription page.
  3. Choose an exact supported model ID before changing `~/.openclaw/openclaw.json`.
  4. Back up the existing OpenClaw configuration and never paste the real key into a public issue, chat, or website.

Safe configuration pattern

Protocol
OpenAI-compatible
Configuration path
~/.openclaw/openclaw.json
  1. Create a `bailian` provider so the model prefix and provider record agree.
  2. Use the Token Plan endpoint shown below, or replace it with the Coding Plan endpoint `https://coding-intl.dashscope.aliyuncs.com/v1`.
  3. Replace the placeholder locally with the dedicated key for that same plan.
  4. Restart the gateway, then use `/model` or `/status` to confirm the active provider and model.
json
{
  "models": {
    "providers": {
      "bailian": {
        "baseUrl": "https://token-plan.ap-southeast-1.maas.aliyuncs.com/compatible-mode/v1",
        "apiKey": "YOUR_TOKEN_PLAN_API_KEY",
        "api": "openai-completions",
        "models": [{ "id": "qwen3.7-plus", "name": "Qwen3.7 Plus" }]
      }
    }
  },
  "agents": {
    "defaults": { "model": { "primary": "bailian/qwen3.7-plus" } }
  }
}

Verify the connection

  • Run `openclaw gateway restart`, then open `openclaw tui`.
  • Run `/status` and confirm the selected model begins with `bailian/`.
  • Send a small repository question before enabling channels, Skills, or scheduled jobs.
  • Review session logs for `[OpenClaw heartbeat poll]` if usage increases while you are idle.

Model pairings

Recommended starting models

Use this tool to run interactive coding, reasoning, review, and documentation tasks with each model. Confirm final model availability and exact plan support in Alibaba Cloud before production use.

Text generationReasoningVisual understanding
Best pairing angle

Balanced default with reasoning, vision understanding, and tool-oriented workflows.

Text generationReasoning
Best pairing angle

Alibaba recommends it for large codebases and long-context agent work.

Text generationReasoningVisual understanding
Best pairing angle

Lower-consumption option for lightweight routing, summaries, and quick repository questions.

Common problems

Common problems

What you see

HTTP 401, invalid access token, or invalid_iam_token

Likely cause

The key is incomplete, revoked, from another plan, or paired with the wrong plan/region endpoint.

What to do

Copy the dedicated key again and pair it only with its documented base URL. Remove leading/trailing spaces and restart the gateway.

What you see

Unknown model

Likely cause

The provider key, `bailian/` model prefix, and model list do not agree, or the model is not on the current allowlist.

What to do

Ensure `models.providers.bailian` exists, the primary model uses `bailian/<model-id>`, and the exact model ID is listed under that provider.

What you see

OAuth token refresh failed

Likely cause

OpenClaw is still routing through an older OAuth provider or cached model configuration.

What to do

Back up the files, remove obsolete OAuth/provider records, clear the stale model cache, and restart OpenClaw as described in Alibaba's FAQ.

What you see

Usage continues while no one is chatting

Likely cause

OpenClaw's gateway heartbeat can call the configured model periodically.

What to do

Stop the gateway while idle or increase `agents.defaults.heartbeat.every`; verify the change in the session logs.

Important restrictions

  • Use the dedicated API key and base URL from the same Alibaba billing plan. Coding Plan, Token Plan, and general Model Studio credentials are not interchangeable.
  • Plan keys are for the assigned user in an interactive coding or agent tool. Do not share them, commit them to a repository, or expose them in screenshots.
  • Do not use a Coding Plan or Token Plan key for automated scripts, batch jobs, application backends, public services, or other non-interactive API workloads. Use pay-as-you-go Model Studio API access for those workloads.
  • Model availability is an exact-string allowlist and can change. Confirm the model ID in the current Alibaba plan documentation before editing a working configuration.