作者:濯光
近期火山引擎的智能体开发平台 Coze(扣子)宣布部分套餐停止新售及分批下线 [ 1] ,受此影响,使用受影响套餐的团队需要在下线前完成迁移和业务验证。
阿里云 AgentCore 是用于构建、部署和运行智能体的平台,其托管 Agent、知识库、自定义代码 Agent、Skill 与 MCP 工具服务分别对应 Coze 的 Bot、文档知识库、工作流、业务 Skill 和 MCP 服务,大部分资产可由迁移助手 coze-to-agentcore 完成迁移,少量(凭据与工具调用权限)需在目标环境手动接入,数据库、用户记忆、历史会话、页面和渠道配置需另行迁移。
把 Coze 应用资产迁移至 AgentCore,最头疼的环节是搞清楚“哪些能自动搬、哪些得手动接”。这份指南把两类操作分开讲,覆盖 Bot 重建、知识库迁移、工作流转换、Skill 导入,以及 MCP 服务的接入。指南适用于扣子中国站,可以单独迁移一项资源,也可以将 Bot 和选定的依赖一并迁入。
下载迁移助手(点击阅读原文即可下载):
直接下载 coze-to-agentcore.zip(免登录):
agentteams-release-cn-hangzhou.oss-cn-hangzhou.aliyuncs.com/coze-to-age…
或在 AgentCore 控制台的 Skill 广场搜索 coze-to-agentcore 并下载。
资源对应关系与迁移范围
本指南适用于扣子中国站。可以单独迁移一项资源,也可以将 Bot 和选定的依赖一并迁入。
数据库、用户记忆、历史会话、页面和渠道配置需另行迁移。只备份文档或在本地转换工作流时,无需准备阿里云账号。
迁移前准备
▍源资源与读取权限
迁移助手会先询问本次要迁移的资源。迁移 Bot 时,确认要迁的修改已发布,复制 Bot 链接。需要从扣子读取 Bot 或知识文档时,进入「扣子编程 → API & SDK → 授权 → 个人访问令牌」,选择本次涉及的空间,并按需授予 getMetadata(读取 Bot)或 listDocument(读取文档)权限。助手可以从 Bot 找到关联库,并尝试下载所选文档。只迁工作流、业务 Skill 或 MCP 服务时,按「其他资源的迁移操作」准备对应链接或材料。创建扣子个人访问令牌 [ 2] 。
▍目标工作空间
需要迁入 AgentCore 时,准备有权操作所选资源的阿里云账号。配置阿里云 CLI,记下配置名(profile)、地域和目标工作空间名称或 ID。运行 aliyun agentcore --help 检查 AgentCore 插件,若未安装,执行 aliyun plugin install --names aliyun-cli-agentcore。迁移 Bot 时,从该工作空间的可用模型中选择。只备份文档或在本地转换工作流时,跳过这一步。安装阿里云 CLI [ 3] · 配置账号 [ 4] 。
▍安装并启动迁移助手
点击下载 coze-to-agentcore.zip,即可免登录获取迁移助手。也可以打开 coze-to-agentcore Skill 下载页面 [ 5] 下载已发布版本。下载完成后,按下方命令安装到本机 Codex。
下载迁移助手:AgentCore 控制台——点击 Skill 广场——搜索“coze-to-agentcore”并下载。
以下以已安装并登录 Codex CLI 的 macOS 终端(zsh)为例。在下载文件所在目录打开终端,执行下方安装命令。如果下载的 ZIP 名称不同,将命令中的文件名替换为实际名称。读取扣子原件或转换工作流时,确保终端可以运行 python3。Codex CLI 安装说明 [ 6] 。
mkdir -p ~/.codex/skills/coze-to-agentcore
unzip -o coze-to-agentcore.zip -d ~/.codex/skills/coze-to-agentcore
仅在需要读取扣子 Bot 或知识文档、且当前终端尚未配置 COZE_PAT 时,执行下一行,粘贴前面准备的令牌并按回车。终端会隐藏输入并启动 Codex。已配置令牌,或仅使用本地文件和现成服务地址时,直接运行 codex。请只在终端输入令牌。
read -rs COZE_PAT && export COZE_PAT && codex
操作示例:迁移售后 Bot 与退换货知识库
扣子上的“售后助手”引用了“退换货政策”和“产品说明书”两个知识库。
本例迁移 Bot 和“退换货政策”,在 AgentCore 验证退换货问答。操作时请使用自己的 Bot、知识库和政策条款。
▍步骤一:选定验收依据
选取一份包含已知规则的源文档。本例假设《换货须知》写明「申请换货需提供订单号和破损照片」,且退换货政策没有规定寄回运费。迁移后分别核对这两类问题的回答。
▍步骤二:迁移 Bot 并绑定知识库
在 Codex 中输入**「帮我从扣子迁到 AgentCore」**。助手询问迁移范围时,发送下面的指令,并填入准备好的 Bot 链接。
我要迁这个已发布的售后 Bot:[Bot 链接]。先列出它关联的知识库,我来选要迁的库。
从助手列出的知识库中选择“退换货政策”,并提供目标工作空间。
只迁“售后助手”和“退换货政策”。请在目标空间新建知识库并绑定到新 Agent。使用阿里云配置 [配置名]、地域 [地域]、工作空间 [名称或 ID]。请列出可用模型让我选。
选定模型后,助手会下载所选原文件,在目标工作空间新建知识库并上传文档。文档可检索后,助手创建托管 Agent 并绑定知识库。完成后,核对返回的 Agent ID、知识库名称和文档清单,确认其中包含《换货须知》。
如果只有个别文档下载失败,补充缺失原件即可。如果目标端调用报错,按助手提示处理。确需通过控制台建库或上传时,使用已下载的文档,在同一目标工作空间完成受阻步骤,等文档可检索后把库 ID 交给助手继续绑定。
▍步骤三:验证新 Agent 的问答
让迁移助手调用刚创建的 Agent,分别在两个新会话中提问,并返回实际回答。用步骤一选定的源文档核对结果。
如果第一问漏了材料,可让助手用“破损照片”检索目标知识库。检索不到时,检查《换货须知》是否已导入并可检索。能找到原文时,再核对新 Agent 绑定的知识库,重新提问。如需切换整个客服入口,还要在新 Agent 中验证查阅“产品说明书”等其他功能。
其他资源的迁移操作
缺少工作流 ZIP 时,使用支持导出的扣子付费套餐。资源库的「更多 → 导出」下载当前草稿,指定发布版本从发布历史导出。应用专属工作流无法直接导出。如果应用菜单有「复制到资源库」,可先复制,再从副本导出。主流程包缺少子工作流时,另行导出引用版本。含 HTTP 鉴权的流程需检查导出包是否包含凭据,分享前移除凭据,并在目标环境重新配置。扣子工作流导出说明 [ 7] 。
工作流调用外部接口时,迁移助手会先核对原接口能否从 AgentCore 访问。若缺少目标侧的调用权限或网络连接,请接口或网络管理员协助配置。若原接口将随扣子停用,请提供迁移后可用的接口地址。
若技能项目无法读取,可提供对应版本的可读下载地址、完整源码目录,或从扣子编程编辑器的文件树下载 .skill 文件。MCP 项目若只能读到域名,再补充服务提供方给出的正式接入地址。扣子技能包下载说明 [ 8] 。
如迁移遇到问题,可加入 AgentCore 用户支持群(钉钉群号 185130001370)。
相关链接:
[1] 智能体开发平台 Coze(扣子)宣布部分套餐停止新售及分批下线
[2] 创建扣子个人访问令牌
[3] 安装阿里云 CLI
[4] 配置账号
[5] coze-to-agentcore Skill 下载页面
agentcore.console.aliyun.com/workspaces/…
[6] Codex CLI 安装说明
developers.openai.com/codex/cli/
[7] 扣子工作流导出说明
[8] 扣子技能包下载说明
本文由 AI图鉴自动抓取并翻译,版权归原作者所有;如需查看原文请点下方链接。
Author: Zhuo Guang
Recently, Volcengine’s AI Agent development platform Coze (Coze) announced that select subscription plans have ceased new sales and will be gradually decommissioned [1]. Consequently, teams using the affected plans must complete migration and business validation prior to decommissioning.
Alibaba Cloud AgentCore is a platform for building, deploying, and running AI agents. Its managed Agents, knowledge bases, custom code Agents, Skills, and MCP tool services correspond respectively to Coze’s Bots, document knowledge bases, workflows, business Skills, and MCP services. Most assets can be migrated via the coze-to-agentcore migration assistant; a small portion (credentials and tool call permissions) must be manually integrated in the target environment. Databases, user memory, historical conversations, pages, and channel configurations require separate migration.
Migrating Coze application assets to AgentCore, the most headache‑inducing part is figuring out “what can be automatically moved and what needs manual integration.” This guide separates the two types of operations, covering Bot recreation, knowledge base migration, workflow conversion, Skill import, and MCP service integration. The guide applies to the Coze China site. You can migrate a single resource alone, or migrate a Bot along with selected dependencies.
Download migration assistant (click the original link to download):
Direct download coze‑to‑agentcore.zip (no login required):
agentteams-release-cn-hangzhou.oss-cn-hangzhou.aliyuncs.com/coze-to-age…
or search for coze‑to‑agentcore in the Skill Square of the AgentCore console and download.
Resource Correspondence and Migration Scope
This guide applies to the Coze China site. You can migrate a single resource alone, or migrate a Bot along with selected dependencies.
Databases, user memory, historical conversations, pages, and channel configurations require separate migration. When only backing up documents or converting workflows locally, no Alibaba Cloud account is needed.
Pre‑migration Preparation
▍ Source Resources and Read Permissions
The migration assistant will first ask about the resources to be migrated this time. When migrating a Bot, ensure the modifications to be migrated are published, and copy the Bot link. To read Bots or knowledge documents from Coze, navigate to “Coze Programming → API & SDK → Authorization → Personal Access Tokens”, select the workspace involved this time, and grant getMetadata (for reading Bots) or listDocument (for reading documents) permissions as needed. The assistant can find linked libraries from the Bot and attempt to download selected documents. When migrating only workflows, business Skills, or MCP services, prepare the corresponding links or materials according to “Migration Operations for Other Resources”. Create a Coze personal access token [2].
▍ Target Workspace
When migrating into AgentCore, prepare an Alibaba Cloud account with permissions to operate on the selected resources. Configure Alibaba Cloud CLI, note the configuration name (profile), region, and target workspace name or ID. Run aliyun agentcore --help to check the AgentCore plugin. If not installed, execute aliyun plugin install --names aliyun-cli-agentcore. When migrating a Bot, choose from the available models in that workspace. When only backing up documents or converting workflows locally, skip this step. Install Alibaba Cloud CLI [3] · Configure account [4].
▍ Install and Launch Migration Assistant
Click to download coze‑to‑agentcore.zip to obtain the migration assistant without login. Alternatively, open the coze‑to‑agentcore Skill download page [5] to download the published version. After download, install to local Codex using the commands below.
Download migration assistant: AgentCore console — click Skill Square — search for “coze‑to‑agentcore” and download.
The following uses a macOS terminal (zsh) with Codex CLI installed and logged in as an example. Open a terminal in the directory where the downloaded file resides, and execute the installation command below. If the downloaded ZIP file has a different name, replace the filename in the command with the actual name. When reading Coze source files or converting workflows, ensure the terminal can run python3. Codex CLI installation instructions [6].
mkdir -p ~/.codex/skills/coze-to-agentcore
unzip -o coze-to-agentcore.zip -d ~/.codex/skills/coze-to-agentcore
Only when you need to read Coze Bots or knowledge documents, and the current terminal has not configured COZE_PAT, execute the next line, paste the token prepared earlier, and press Enter. The terminal will hide input and launch Codex. If the token is already configured, or you are only using local files and ready‑made service addresses, directly run codex. Please enter the token only in the terminal.
read -rs COZE_PAT && export COZE_PAT && codex
Example: Migrating an After-sales Bot and Return & Exchange Knowledge Base
The "After-sales Assistant" on Coze references two knowledge bases: "Return & Exchange Policy" and "Product Manual."
This example migrates the Bot and "Return & Exchange Policy," then verifies return-and-exchange Q&A in AgentCore. Use your own Bot, knowledge base, and policy clauses when operating.
▍Step 1: Select Acceptance Criteria
Select a source document containing known rules. In this example, assume the "Exchange Instructions" states "An exchange request requires the order number and photos of damage," and the return & exchange policy does not regulate return shipping fees. After migration, verify answers to both types of questions separately.
▍Step 2: Migrate the Bot and Bind the Knowledge Base
In Codex, enter **「Help me migrate from Coze to AgentCore」**. When the assistant asks about the migration scope, send the following instruction and fill in the prepared Bot link.
I want to migrate this published After-sales Bot: [Bot Link]. First list its associated knowledge bases so I can choose which ones to migrate.
From the knowledge bases listed by the assistant, select "Return & Exchange Policy" and provide the target workspace.
Only migrate "After-sales Assistant" and "Return & Exchange Policy." Please create a new knowledge base in the target workspace and bind it to the new Agent. Use Alibaba Cloud configuration [Config Name], region [Region], workspace [Name or ID]. Please list available models for me to choose from.
After selecting a model, the assistant will download the selected original files, create a new knowledge base in the target workspace, and upload the documents. Once the documents are searchable, the assistant creates a hosted Agent and binds the knowledge base. Upon completion, verify the returned Agent ID, knowledge base name, and document list to confirm it includes the "Exchange Instructions."
If only individual documents fail to download, supplement the missing originals. If the target side returns errors when calling, follow the assistant's prompts. If creating the knowledge base or uploading is required through the console, use the downloaded documents, complete the blocked steps in the same target workspace, and once the documents are searchable, hand the knowledge base ID to the assistant to continue binding.
▍Step 3: Verify the New Agent's Q&A
Ask the migration assistant to call the newly created Agent, ask questions in two separate new sessions, and return the actual answers. Cross-check results against the source document selected in Step 1.
If the first question misses material, have the assistant search the target knowledge base using "photos of damage." If nothing is found, verify whether the "Exchange Instructions" has been imported and is searchable. When the original text can be found, re-check the knowledge base bound to the new Agent and re-ask the question. If you also need to switch the entire customer service entry point, validate other functions such as viewing the "Product Manual" in the new Agent as well.
Migration Operations for Other Resources
When a workflow ZIP is unavailable, use a Coze paid plan that supports exports. In the resource library, go to 「More → Export」 to download the current draft; to export a specified published version, use the publish history. App-specific workflows cannot be exported directly. If the app menu has "Copy to Resource Library," copy first, then export from the copy. If the main flow package is missing sub-workflows, export the referenced versions separately. Workflows that include HTTP authentication must be checked to ensure credentials are included in the export package; remove credentials before sharing and reconfigure them in the target environment. Coze workflow export guide [7].
When workflows call external interfaces, the migration assistant will first verify whether the original interface is accessible from AgentCore. If target-side call permissions or network connectivity are missing, contact the interface or network administrator for assistance. If the original interface will be retired along with Coze, provide the post-migration interface address.
If a skill project cannot be read, provide a readable download URL for the corresponding version, a complete source code directory, or download the .skill file from the file tree in Coze coding editor. For MCP projects, if only domain names can be read, supplement the official access address provided by the service provider. Coze skill pack download guide [8].
If you encounter problems during migration, join the AgentCore User Support Group (DingTalk group number 185130001370).
Related Links:
[1] AI Agent Development Platform Coze Announces Discontinuation of Selected Plans and Phased Decommissioning
[2] Create a Coze Personal Access Token
[3] Install the Alibaba Cloud CLI
[4] Configure Account
[5] coze-to-agentcore Skill Download Page
agentcore.console.aliyun.com/workspaces/…
[6] Codex CLI Installation Guide
developers.openai.com/codex/cli/
[7] Coze Workflow Export Guide
[8] Coze Skill Pack Download Guide
Auto-fetched and translated by AI Atlas. All rights belong to the original author.