prepare_h5_upload
Verify H5 game project directory and confirm app selection to generate upload readiness info.
Instructions
[H5 Game Upload Workflow - Step 1]
Use this tool when user wants to publish/upload/deploy H5 game ('发布', '上传', '部署').
**PREREQUISITE: An app MUST be selected first.**
Before calling this tool, ALWAYS call get_current_app_info to verify an app is selected.
If not selected, guide user through:
1) Call list_developers_and_apps to show available apps
2) Show list to user and ASK them to choose
3) Call select_app with user's choice
4) Then call this tool
This tool will:
1. Verify the game project directory (must contain index.html)
2. Read app info from cache (selected via select_app)
3. Return confirmation info for user to review
After gathering info, use upload_h5_game to upload the game.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| genre | No | If user provides a specific game genre, use it directly. If user is unsure or doesn't specify, analyze the code files, game mechanics, UI elements, and gameplay features in the project directory to determine the most appropriate game genre. Available genres keys: rpg, casual, action, strategy, simulation, trivia, arcade, adventure, card, sports, racing, puzzle, educational, music, word, board, and the chinese name of the genre is 角色扮演, 休闲, 动作, 策略, 模拟, 益智, 街机, 冒险, 卡牌, 体育, 竞速, 知识问答, 教育, 音乐, 文字, 桌面和棋类. When analyzing, consider game rules, player interactions, visual elements, and core gameplay loops. If still uncertain after analysis, default to 'casual' as fallback. | |
| gamePath | No | **MUST be a relative path** to the H5 game build output directory. ✅ Correct: "dist", "build", "output", "." ❌ Wrong: "/workspace/dist", "/tmp/build" (absolute paths not allowed) **BEHAVIOR:** - If user specifies directory, pass that relative path - If user doesn't specify, ASK: "请问游戏构建产物在哪个目录?(如 dist、build)" - If index.html is in project root, pass "." or leave empty - DO NOT guess - confirm with user if unsure |