首页龙虾技能列表 › Create Aptos Project — 创建 Aptos 项目

Create Aptos Project — 创建 Aptos 项目

v1.0.0

创建 Aptos 项目工具。

0· 120·0 当前·0 累计
by @iskysun96·MIT-0
下载技能包
License
MIT-0
最后更新
2026/4/13
安全扫描
VirusTotal
无害
查看报告
OpenClaw
可疑
medium confidence
The skill's instructions match its stated purpose (scaffolding Aptos projects), but it directs the agent to run npx (which will download and execute third‑party code) and lacks provenance for the referenced package/author, so there is a notable risk if you run the scaffold commands without verifying the npm package and handling secrets carefully.
评估建议
This skill appears coherent for scaffolding Aptos projects, but take precautions before running its recommended commands: 1) npx create-aptos-dapp will download and execute code from npm — verify the package name, inspect the package contents (or prefer a specific, audited version) and the maintainer before running it; consider running the scaffold in an isolated environment or container. 2) Do not let the agent display or transmit private keys; aptos init may create keys — store them securely a...
详细分析 ▾
用途与能力
Name, description, and instructions are consistent: the skill is an instruction-only scaffold helper for Aptos projects. Minor oddity: metadata claims author 'aptos-labs' and 'priority: critical' but source/homepage are unknown — provenance is unclear and could be impersonation.
指令范围
The SKILL.md tells the agent to run npx create-aptos-dapp and aptos init, initialize git, and manipulate .env/.gitignore. That is within scaffolding scope, but npx will fetch and execute remote npm package code at runtime (remote code execution risk). The doc also references handling of sensitive data (publisher account keys in .env) but does not provide strong guidance for safe key storage beyond checking .gitignore; aptos init may generate keys that must not be exposed — the agent must not display or transmit them.
安装机制
No install spec in the skill itself, but the runtime instructions rely on npx to pull and run create-aptos-dapp from npm. That implicitly causes a network download and execution of third-party code. The skill does not require or lock to a known package version or provide a trusted source URL, increasing risk.
凭证需求
The skill declares no required env vars, which matches its instruction-only nature. However, the templates create an .env that may contain API keys and the publisher account (sensitive private keys). The skill properly warns to ensure .env is in .gitignore, but it does not instruct how to securely create/store the publisher key or prevent accidental exposure beyond that check.
持久化与权限
Skill is instruction-only, has no install, does not request persistent privileges, and always=false. It does not modify other skills or system-wide configs.
安全有层次,运行前请审查代码。

License

MIT-0

可自由使用、修改和再分发,无需署名。

运行时依赖

无特殊依赖

版本

latestv1.0.02026/3/19

- Initial release of the create-aptos-project skill. - Scaffolds new Aptos projects using npx create-aptos-dapp, supporting fullstack (Vite or Next.js) and contract-only templates. - Guides users through project type, framework, network selection, and optional API key setup. - Enforces best practices: always scaffold with create-aptos-dapp, never create project structures manually, and never display private keys. - Includes a detailed workflow and checklist for initializing, testing, and committing new projects. - Covers troubleshooting and recommendations for a smooth project setup experience.

● 无害

安装命令 点击复制

官方npx clawhub@latest install create-aptos-project
镜像加速npx clawhub@latest install create-aptos-project --registry https://cn.clawhub-mirror.com

技能文档

Purpose

Scaffold new Aptos projects using npx create-aptos-dapp. This is the mandatory first step when a user wants to build any new Aptos app, dApp, or project — regardless of how they phrase it.

ALWAYS

  • 使用 npx 创建-aptos-dapp 到 scaffold — NEVER 创建 projects 从 scratch manually
  • Ask 用户 关于 project 类型, 框架, 和 network 之前 scaffolding
  • 验证 .env 在...中 .gitignore 之前 任何 git operations
  • 使用 相同 network 对于 both 创建-aptos-dappaptos init
  • 关注 满 Build dApp workflow 之后 scaffolding (contracts, tests, audit, deploy, frontend)

NEVER

  • Skip scaffolding — 甚至 对于 "simple" projects, always 开始 带有 创建-aptos-dapp
  • 创建 project structure manually — boilerplate 模板 handles
  • Display 或 读取 私有 keys — 使用 "0x..." 作为 placeholder
  • Run git 添加 .git 添加 - 没有 第一个 verifying .env 在...中 .gitignore

Decision Tree

Before running the scaffold command, gather these inputs from the user:

1. Project Name

Derive from the user's description or ask directly. Use kebab-case (e.g., habit-tracker, nft-marketplace).

2. Project 类型

OptionWhen to Use
Fullstack (default)User wants a frontend + smart contracts
Contract-onlyUser only wants Move smart contracts (no frontend)

3. 框架 (fullstack 仅)

OptionWhen to Use
Vite (default)Default choice, lighter setup
Next.jsUser asks for Next.js or SSR

4. Network

OptionWhen to Use
devnet (default)Development and testing
testnetPre-production, user explicitly asks
mainnetProduction, user explicitly asks

5. API 键 (可选)

Ask if the user has a Geomi API key. It's optional for devnet but recommended for testnet/mainnet to avoid rate limits. Get one at https://geomi.dev (create project -> API Resource -> copy key).


Scaffolding Commands

# Fullstack dApp with Vite (frontend + contracts)
npx create-aptos-dapp  \
  --project-type fullstack \
  --template boilerplate-template \
  --framework vite \
  --network 

# Fullstack dApp with Next.js npx create-aptos-dapp \ --project-type fullstack \ --template boilerplate-template \ --framework nextjs \ --network

# Contract-only (Move project) npx create-aptos-dapp \ --project-type move \ --network

可选 flags:

  • --api-键 <键> — Pass Geomi API 键 期间 scaffolding
  • --使用-surf — Enable Surf 对于 类型-safe contract interactions

Post-Scaffold Checklist

After scaffolding, complete these steps in order:

  • cd
  • 验证 .env 在...中 .gitignore 之前 任何 git operations
  • Run aptos init --network --assume-是 (使用 相同 network 作为 上面)
  • 验证: npm run 移动:compile && npm run 移动:test
  • git init && git 添加 . && git commit -m "Initial commit"

Build dApp Workflow

ALWAYS 关注 workflow 当...时 用户 wants 到 build 新的 Aptos app, dApp, 或 project. applies regardless of how the user phrases it ("build me a ...", "create a ...", "make a ...", "I want to build ...").

  • /创建-aptos-project -> scaffold 带有 npx 创建-aptos-dapp ( skill — NEVER skip)
  • /写入-contracts -> 写入 移动 modules
  • /generate-tests -> 创建 test suite, 验证 100% coverage
  • /security-audit -> audit 之前 deployment
  • /deploy-contracts -> deploy contract 到 specified network
  • /使用-ts-sdk -> orchestrates frontend integration (routes 到 ts-sdk-client, ts-sdk-transactions,
ts-sdk-view-and-query, ts-sdk-wallet-adapter as needed)


什么 Boilerplate Includes

Fullstack 模板

  • contract/ — 移动 smart contract 带有 移动.toml 和 starter 模块
  • frontend/ — React app 带有 Aptos wallet adapter pre-configured
  • 包.json — Scripts 对于 移动:compile, 移动:test, 移动:发布, dev, build
  • .env — Environment variables 对于 network, API 键, 和 publisher 账户

Contract-仅 模板

  • contract/ — 移动 smart contract 带有 移动.toml 和 starter 模块
  • 包.json — Scripts 对于 移动:compile, 移动:test, 移动:发布
  • .env — Environment variables 对于 network 和 publisher 账户

Troubleshooting

npx 创建-aptos-dapp command 不 found

# Auto-confirm the npx package install prompt
npx --yes create-aptos-dapp  ...

If that still fails, verify Node.js and npm are installed (node -v && npm -v).

Compile failures 之后 scaffold

  • Check contract/移动.toml 有 正确 named addresses
  • Run aptos init --network --assume-是 如果 不 已完成
  • 验证 my_addr 设置 到 "_" 在...中 [addresses] section

Named address errors

The boilerplate uses my_addr = "_" which gets resolved from .env at compile time. Ensure VITE_MODULE_PUBLISHER_ACCOUNT_ADDRESS is set in .env (populated by aptos init).

数据来源:ClawHub ↗ · 中文优化:龙虾技能库
OpenClaw 技能定制 / 插件定制 / 私有工作流定制

免费技能或插件可能存在安全风险,如需更匹配、更安全的方案,建议联系付费定制

了解定制服务