nc://alibaba-token-plan

v0.1.0Pinned
Backnodecode-ai
pomterrekilo: a sign-in still waiting answers again with its page and code -- found by the sweep of every offered provider (2026-10-26). The /models wizard's Esc, then Enter on Kilo Gateway, sent /kilo login again; START-LOGIN cancelled the waiting code and asked Kilo for a new one, and after a few Kilo answered 429 `Too many pending authorization requests'. A login still waiting (not cancelled, before its deadline, the same auth.json) is now answered again (LOGIN-ANSWER, kept on the login), and Kilo is asked for nothing. Gate kilo-cell-answers-a-waiting-sign-in-again: red on the old START-LOGIN, green after; the cell's 20 tests green on the build host.211fc1c· 26 Oct2 commits
test1 filecell.lisp4.4 KBprovider.lisp6.2 KB

nodecode-alibaba-token-plan

A Nodecode cell for the QwenCloud Token Plan, Alibaba's token subscription (Qwen3.8, Qwen3.7, GLM-5.2 and DeepSeek V4 Pro). With it, /connect offers QwenCloud Token Plan, /models lists the plan's models, and a turn on alibaba-token-plan/<model> goes to the plan's endpoint in your region over the OpenAI chat wire, asking a reasoning model to think in its own dialect.

Ported from oh-my-pi's alibaba-token-plan provider. See NOTICE.

What omp's login does, and how this cell carries it

omp's login for this provider is a custom one, but it signs nothing in. The Token Plan is sold as two regional products whose keys do not cross, so the login asks:

  1. Which region: 1 International, Singapore (the default, https://token-plan.ap-southeast-1.maas.aliyuncs.com/compatible-mode/v1), 2 China, Beijing (https://token-plan.cn-beijing.maas.aliyuncs.com/compatible-mode/v1), or 3 a custom base URL.
  2. The key (sk-sp-...), from that region's console. It checks the key with GET <base>/models.
  3. Optionally, the Cookie header of the console's usage request, copied from the browser's DevTools, for quota reporting.

It keeps a region other than the default inside the credential, so both inference and model discovery go there. Here:

  • Region. The section's "region": "international" (the default) or "china".
  • Custom base. "base_url", when set, wins over the region, as omp's option 3 does.
  • Key. Save it with /connect, or set ALIBABA_TOKEN_PLAN_API_KEY (or BAILIAN_TOKEN_PLAN_API_KEY). A saved key wins over the variables. /connect checks a key against the region's /models listing before it saves it, as omp's login does. OPENAI_API_KEY is never sent: omp refuses that fallback for this provider by name.

Where to subscribe and copy the key: https://home.qwencloud.com/billing/subscription/token-plan-individual for the international plan, https://www.aliyun.com/benefit/scene/tokenplan for the China one.

Models

The bundled rows are the provider rule's seed: the plan's documented Individual text models. They outrank a same-id row from models.dev, as omp's seed precedence has it. The core also lists the region's /models once a key is saved, which is omp's credentialed discovery.

Thinking

omp's rule for this provider is the Qwen dialect: for a reasoning model, an effort sends enable_thinking: true and no reasoning_effort, and off sends enable_thinking: false. Qwen3.8 Max and Qwen3.8 Flash take both while they think: enable_thinking: true and reasoning_effort for the depth (Max's rungs are low, medium, xhigh). Not thinking, they send enable_thinking: false like the rest. Qwen3.8 Max Preview stays on the switch alone. With no effort set, nothing is sent, so the plan's default applies, as the chat lane does for every provider.

Install

Copy this folder into ~/.nodecode/cells/nodecode-alibaba-token-plan/ and restart Nodecode, or run (restart-cells).

Configure

Optional. The section is on unless it says "enabled": false:

{
  "alibaba-token-plan": {
    // where the plan was bought: international (Singapore) or china (Beijing)
    "region": "international"
    // another regional endpoint, or a proxy; set, it wins over region
    // "base_url": "https://token-plan.<region>.maas.aliyuncs.com/compatible-mode/v1"
  }
}

Not ported

  • Quota reporting. omp reads the plan's usage from the console's private usage API, with a browser session cookie the operator copies out of DevTools at login. The cell neither asks for nor keeps that cookie.
  • omp's structured credential ({"token", "cookie", "baseUrl"} as one JSON string). The region lives in the section instead, so a plain key is all /connect needs.
  • The token grammar check (sk-...) omp applies before a request.
  • omp's discovery filter and per-model limits for listed models the seed does not carry.

Test

From this repository's root:

tools/test-cell.sh nodecode-alibaba-token-plan

MIT licensed.

Add nc://alibaba-token-plan

  1. 1

    Install Nodecode

    Once per machine.

    $ curl -fsSL https://nodecode.ai/install.sh | sh
  2. 2

    Add the cell

    Pinned at 211fc1c.

    $ nodecode add nc://alibaba-token-plan

    Or tell the agent add the alibaba token plan cell.

  3. 3

    Add your key

    Run /models, pick QwenCloud Token Plan and paste your key.