Skip to content

Add CN host configuration - #7

Merged
zjn0505 merged 1 commit into
masterfrom
demo/add_cn_host
Aug 31, 2026
Merged

zjn0505 merged 1 commit into
masterfrom
demo/add_cn_host

Conversation

@zjn0505

@zjn0505 zjn0505 commented Aug 31, 2026

Copy link
Copy Markdown
Contributor

This pull request updates the documentation, configuration, and client code for the temi OpenAPI demos to support both the global production API (api.robotemi.com) and the China production API (api.robotemi.cn). It emphasizes using the production host that matches the organization's region and ensures that all relevant files, including code and documentation, reflect the availability of both production environments.

Documentation updates:

  • Updated all relevant README.md files and OpenAPI spec (temi-partner.openapi.yaml) to mention both api.robotemi.com (Production) and api.robotemi.cn (Production-CN), instructing users to select the host that matches their organization's region. [1] [2] [3] [4] [5] [6] [7] [8]

Frontend and demo code changes:

  • Added support for the production-cn environment in the environment selectors, API host configuration (ENVIRONMENTS), and CSP headers in both the mvp-frontend-only and temi-openapi-scenario-runner demos. [1] [2] [3] [4]

Scenario runner logic improvements:

  • Refactored environment handling to dynamically support all environments, including production-cn, and updated labels and state initialization logic to handle the new environment. [1] [2] [3] [4]

These changes ensure that users and developers can select the correct production environment for their region, improving clarity and correctness when integrating with the temi OpenAPI.

@zjn0505
zjn0505 requested a lite review from Copilot August 31, 2026 08:41
@vercel

vercel Bot commented Aug 31, 2026

Copy link
Copy Markdown

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Actions Updated (UTC)
temi-openapi-docs Ready Ready Preview Aug 31, 2026 8:41am

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🟢 Approval recommended

Changes are straightforward, consistent across spec/docs/demos, and the code updates correctly generalize environment handling for the new production-cn option.

Pull request overview

Updates the temi OpenAPI spec, docs, and demo clients to explicitly support both global Production (api.robotemi.com) and China Production (api.robotemi.cn) hosts, so users select the correct production environment for their organization’s region.

Changes:

  • Added Production-CN server/host references across the OpenAPI spec and repository/demos documentation.
  • Extended demo environment selection and base URL mappings to include production-cn.
  • Updated scenario runner environment handling to initialize environment transport state dynamically from the supported environment list, and expanded CSP connect-src to allow the CN API origin.
File summaries
File Description
temi-partner.openapi.yaml Adds Production-CN server entry and clarifies production host selection guidance in the API description.
README.md Documents both production OpenAPI base URLs and instructs choosing the host matching org region.
demos/temi-openapi-scenario-runner/src/main.ts Refactors environment transport initialization to support all environments and adds localized labels for production-cn.
demos/temi-openapi-scenario-runner/src/api.ts Adds production-cn to ENVIRONMENTS/base URLs and makes isEnvironment dynamic over the environment list.
demos/temi-openapi-scenario-runner/README.md Updates environment documentation to include Production-CN and reinforces region-matching guidance.
demos/temi-openapi-scenario-runner/index.html Expands CSP connect-src to allow https://api.robotemi.cn.
demos/README.md Updates demo token-handling guidance to mention both production hosts.
demos/mvp-frontend-only/README.md Updates host list and guidance for selecting the correct production region host.
demos/mvp-frontend-only/js/config.js Adds production-cn OpenAPI base URL to the environment config map.
demos/mvp-frontend-only/index.html Adds production-cn option to the environment selector UI.
.cursor/rules/demos-pages.mdc Updates internal rules to include the CN production host and region-matching guidance.
Review details
  • Files reviewed: 11/11 changed files
  • Comments generated: 0
  • Review effort level: Lite

💡 Add a code-review agent skill or configure MCP servers for context-aware, tailored reviews. Learn more in the docs.

@zjn0505
zjn0505 merged commit 1dcba4a into master Aug 31, 2026
5 checks passed
@zjn0505
zjn0505 deleted the demo/add_cn_host branch August 31, 2026 08:49

This branch was successfully deployed

1 active deployment
Preview — 9648ef84 Deployed Aug 31, 2026 by vercel[bot]
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants