Skip to content

[bug] token-plan preset sends Singapore Personal Edition keys to Beijing #206

Description

@ansellchiu

Environment

  • CLI: bl 1.25.0
  • Bailian skills: 1.25.0
  • Node: v26.3.0
  • OS: macOS 26.6.2 (Build 25G83)
  • Console: international, ap-southeast-1
  • Plan: Token Plan Personal Edition

Problem

The installed bailian-protocol setup guidance and the built-in token-plan profile use this Base URL:

https://token-plan.cn-beijing.maas.aliyuncs.com

Token Plan Personal Edition is Singapore-only. A valid Personal Edition key is therefore rejected by the Beijing host with HTTP 401 InvalidApiKey, which looks like a bad credential rather than a region mismatch.

The same key is accepted by the Singapore host:

https://token-plan.ap-southeast-1.maas.aliyuncs.com

Reproduce

  1. Install or update bl and its skills to 1.25.0.
  2. Configure a valid Token Plan Personal Edition key in the token-plan profile.
  3. Leave the profile's supplied Beijing Base URL unchanged.
  4. Run a text request or query the OpenAI-compatible model endpoint.

No credential values are included in this report.

Expected

For Token Plan Personal Edition, the profile or setup guidance should select the Singapore Token Plan host, or require an explicit region choice that prevents a Singapore-only key from being sent to Beijing.

Actual

  • Beijing host: HTTP 401, InvalidApiKey / Invalid API-key provided
  • Singapore host with the same key: authentication succeeds and the request reaches the plan quota check (HTTP 429 insufficient_quota when the weekly allowance is exhausted)

The 401 → authenticated quota response comparison isolates the region preset as the cause.

Suggested resolution

Please make the Token Plan profile region-aware. At minimum:

  • document that Personal Edition uses ap-southeast-1;
  • avoid materializing the Beijing Base URL for an international Personal Edition login; and
  • report a region/profile mismatch more clearly than a generic invalid-key diagnosis when possible.

Activity

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

Metadata

Metadata

Assignees

No one assigned

    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