← 返回 Skills 市场
vincentism

EdgeOne Pages Deploy

作者 vincentism · GitHub ↗ · v1.0.0 · MIT-0
cross-platform ⚠ suspicious
284
总下载
0
收藏
1
当前安装
1
版本数
在 OpenClaw 中安装
/install edgeone-pages-deploy
功能描述
Deploy frontend and full-stack projects to EdgeOne Pages (Tencent EdgeOne). Use when the user wants to deploy, publish, ship, host, launch, or go live on Edg...
使用说明 (SKILL.md)

EdgeOne Pages Deployment Skill

Deploy any project to EdgeOne Pages.

⛔ Critical Rules (MUST follow — never skip)

  1. CLI version MUST be 1.2.30 or higher. If the installed version is lower, reinstall. Do NOT proceed with an outdated version.
  2. NEVER truncate the deploy URL. The EDGEONE_DEPLOY_URL includes eo_token= and eo_time= query parameters — they are required for access. Always output the complete URL.
  3. MUST ask the user to choose China or Global site before login. Never assume.
  4. MUST auto-detect the login method — browser login in desktop environments, token login in headless/remote/CI environments. Follow the decision table below.
  5. After token login, MUST ask if the user wants to save the token locally for future use.

Deployment Flow

Run these checks first, then follow the decision table:

# Check 1: CLI installed and correct version?
edgeone -v

# Check 2: Already logged in?
edgeone whoami

# Check 3: Project already linked?
cat edgeone.json 2>/dev/null

# Check 4: Saved token exists?
cat .edgeone/.token 2>/dev/null

Decision Table

CLI version Login status Action
Not installed or version \x3C 1.2.30 → Go to Install CLI
≥ 1.2.30 Logged in → Go to Deploy
≥ 1.2.30 Not logged in, has saved token → Go to Deploy with Token (use saved token)
≥ 1.2.30 Not logged in, no saved token → Go to Login

Install CLI

npm install -g edgeone@latest

Verify: edgeone -v must output 1.2.30 or higher. If not, retry installation.


Login

1. Ask the user to choose a site

You MUST ask before running any login command. Use the IDE's selection control (ask_followup_question):

Choose your EdgeOne Pages site:

  • China — For users in mainland China (console.cloud.tencent.com)
  • Global — For users outside China (console.intl.cloud.tencent.com)

2. Detect environment and choose login method

Condition Method
Local desktop IDE (e.g. VS Code, Cursor, etc.) Browser Login
Remote / SSH / container / CI / cloud IDE / headless Token Login
User explicitly requests token Token Login

Browser Login

# China site
edgeone login --site china

# Global site
edgeone login --site global

Wait for the user to complete browser auth. The CLI prints a success message when done.

Token Login

Token login does NOT use edgeone login. The token is passed directly in the deploy command via -t.

Guide the user to get a token:

  1. Go to the console:
  2. Find API TokenCreate Token → Copy it

⚠️ Remind the user: the token has account-level permissions. Never commit it to a repository.

3. Offer to save the token locally

After the user provides a token, MUST ask:

Would you like to save this token locally for future deployments?

  • Yes — Save to .edgeone/.token (auto-used next time)
  • No — Use for this deployment only

If Yes:

mkdir -p .edgeone
echo "\x3Ctoken>" > .edgeone/.token
grep -q '.edgeone/.token' .gitignore 2>/dev/null || echo '.edgeone/.token' >> .gitignore

Tell the user: "✅ Token saved to .edgeone/.token and added to .gitignore."


Deploy

Browser-authenticated deploy

# Project already linked (edgeone.json exists)
edgeone pages deploy

# New project (no edgeone.json)
edgeone pages deploy -n \x3Cproject-name>

\x3Cproject-name>: auto-generate from the project directory name. The first deploy creates edgeone.json automatically.

Token-based deploy

First check for a saved token:

cat .edgeone/.token 2>/dev/null
  • Saved token found → use it, tell the user: "Using saved token from .edgeone/.token"
  • No saved token → ask the user to provide one (see Token Login above)
# Project already linked
edgeone pages deploy -t \x3Ctoken>

# New project
edgeone pages deploy -n \x3Cproject-name> -t \x3Ctoken>

The token already contains site info — no --site flag needed.

After a successful deploy with a manually-entered token, ask if the user wants to save it (see "Offer to save the token locally" above).

Deploy to preview environment

edgeone pages deploy -e preview

Build behavior

The CLI auto-detects the framework, runs the build, and uploads the output directory. No manual config needed.


⚠️ Parse Deploy Output (Critical — read carefully)

After edgeone pages deploy succeeds, the CLI outputs:

[cli][✔] Deploy Success
EDGEONE_DEPLOY_URL=https://my-project-abc123.edgeone.cool?eo_token=xxxx&eo_time=yyyy
EDGEONE_DEPLOY_TYPE=preset
EDGEONE_PROJECT_ID=pages-xxxxxxxx
[cli][✔] You can view your deployment in the EdgeOne Pages Console at:
https://console.cloud.tencent.com/edgeone/pages/project/pages-xxxxxxxx/deployment/xxxxxxx

Extraction rules:

Field How to extract ⛔ Warning
Access URL Full value after EDGEONE_DEPLOY_URL= MUST include ?eo_token=...&eo_time=... — without these params the page won't load
Project ID Value after EDGEONE_PROJECT_ID=
Console URL Line after "You can view your deployment..."

Show the user:

✅ Deployment complete!

  • Access URL: https://my-project-abc123.edgeone.cool?eo_token=xxxx&eo_time=yyyy
  • Console URL: https://console.cloud.tencent.com/edgeone/pages/project/...

Error Handling

Error Solution
command not found: edgeone npm install -g edgeone@latest
Browser doesn't open during login Use token login instead
"not logged in" error edgeone whoami to check, then re-login or use token
Auth error with token Token may be expired — regenerate at the console
Project name conflict Use a different name with -n
Build failure Check logs — usually missing deps or bad build script

Appendix

Edge/Node Functions

For projects needing server-side functions, run before first deploy:

edgeone pages init

Pure static projects skip this.

Local Development

edgeone pages dev    # http://localhost:8088/

Environment Variables

edgeone pages env ls          # List all
edgeone pages env pull        # Pull to local .env
edgeone pages env add KEY val # Add
edgeone pages env rm KEY      # Remove

Project Linking

edgeone pages link

Token Management

Task How
Save token Stored in .edgeone/.token (auto-added to .gitignore)
Update token Delete .edgeone/.token, then deploy again — you'll be prompted to enter and save a new one
Use saved token Automatic — the agent reads .edgeone/.token before each token deploy

Command Reference

Action Command
Install CLI npm install -g edgeone@latest
Check version edgeone -v
Login (China) edgeone login --site china
Login (Global) edgeone login --site global
View login info edgeone whoami
Logout edgeone logout
Switch account edgeone switch
Init functions edgeone pages init
Local dev edgeone pages dev
Link project edgeone pages link
Deploy edgeone pages deploy
Deploy new project edgeone pages deploy -n \x3Cname>
Deploy preview edgeone pages deploy -e preview
Deploy with token edgeone pages deploy -t \x3Ctoken>
安全使用建议
This skill appears to do what it says: install the EdgeOne CLI, let you log in (browser or token), run deploy, and show the deploy URL. Before using it: (1) confirm you trust the source of the SKILL.md and the npm 'edgeone' package you will install; (2) prefer browser auth on a local machine when possible instead of account-level tokens; (3) if you must use a token, create one with the minimum required permissions and do not reuse an account-wide secret; (4) only save the token locally after explicit consent — understand .edgeone/.token is stored in your project directory; (5) treat the full EDGEONE_DEPLOY_URL (it includes eo_token) as sensitive — do not paste it into public chat or repos; (6) verify the CLI version requirement (>=1.2.30) and inspect the installed package before running global npm installs.
功能分析
Type: OpenClaw Skill Name: edgeone-pages-deploy Version: 1.0.0 The skill facilitates project deployment to Tencent EdgeOne Pages but involves several high-risk behaviors, including global installation of an NPM package (`edgeone`), writing sensitive API tokens to the local filesystem (`.edgeone/.token`), and executing shell commands for environment detection and deployment. While these actions are plausibly necessary for the stated purpose and the instructions include safety measures like user consent prompts and `.gitignore` updates, the handling of account-level secrets and broad shell access are inherently risky capabilities. The skill also explicitly instructs the agent to handle and display URLs containing authentication tokens (`eo_token`), which is a sensitive data handling practice (SKILL.md).
能力评估
Purpose & Capability
The skill's name and description match its instructions: it installs/uses the EdgeOne CLI, supports browser and token-based login, runs deploy commands, and extracts the deploy URL/IDs. Requiring the CLI and token usage is expected for a deploy helper.
Instruction Scope
Instructions explicitly read/write local files (edgeone.json, .edgeone/.token), run the 'edgeone' CLI, and require printing the full EDGEONE_DEPLOY_URL (which includes eo_token and eo_time). Those actions are within deployment scope but involve handling sensitive tokens and instruct the agent to never truncate or omit token-bearing URLs—this increases the sensitivity of outputs.
Install Mechanism
No registry install spec is provided (skill is instruction-only). SKILL.md instructs 'npm install -g edgeone@latest' which is a normal way to get a CLI from npm (public registry). This is a standard, expected mechanism but carries the usual npm-install risks (running third-party code) and requires the runtime to have npm and permission to install globally.
Credentials
The skill requests no declared environment variables, which is consistent. It does instruct saving an account-level API token to .edgeone/.token (and adding it to .gitignore). Saving account-level tokens is functional for convenience but is a high-privilege credential and should be handled with care (ask the user, use least-privilege tokens, avoid committing or exposing them).
Persistence & Privilege
The skill does not demand always:true or system-wide changes, but it does instruct local persistence of credentials (.edgeone/.token) and modifying .gitignore. That persistence is proportional to a deploy helper's convenience features, but the user should explicitly approve saving tokens and understand the local-file implications.
如何使用
  1. 确保已安装 OpenClaw(本地或 Docker 部署)
  2. 在对话框中输入安装命令:/install edgeone-pages-deploy
  3. 安装完成后,直接呼叫该 Skill 的名称或使用 /edgeone-pages-deploy 触发
  4. 根据 Skill 的参数说明提供必要输入,即可获得结构化输出
版本历史
v1.0.0
Initial release of edgeone-pages-deploy skill. - Enables deployment of frontend and full-stack projects to Tencent EdgeOne Pages. - Guides users through CLI installation and environment-adaptive login (browser or token). - Ensures safe handling and local storage of API tokens. - Parses and returns complete deployment URLs with required parameters for access. - Covers preview deploys, project linking, local dev, environment variables, and error handling. - Requires CLI version 1.2.30 or higher for all operations.
元数据
Slug edgeone-pages-deploy
版本 1.0.0
许可证 MIT-0
累计安装 1
当前安装数 1
历史版本数 1
常见问题

EdgeOne Pages Deploy 是什么?

Deploy frontend and full-stack projects to EdgeOne Pages (Tencent EdgeOne). Use when the user wants to deploy, publish, ship, host, launch, or go live on Edg... 它是一个面向 Claude Code / OpenClaw 的 AI Agent Skill 插件,目前累计下载 284 次。

如何安装 EdgeOne Pages Deploy?

在 OpenClaw 或 Claude Code 对话框中运行命令「/install edgeone-pages-deploy」即可一键安装,无需额外配置。

EdgeOne Pages Deploy 是免费的吗?

是的,EdgeOne Pages Deploy 完全免费,采用 MIT-0 许可证,可自由下载、安装和使用。

EdgeOne Pages Deploy 支持哪些平台?

EdgeOne Pages Deploy 跨平台运行,可在任意部署了 OpenClaw / Claude Code 的环境中使用(cross-platform)。

谁开发了 EdgeOne Pages Deploy?

由 vincentism(@vincentism)开发并维护,当前版本 v1.0.0。

💬 留言讨论