Skip to content

feat(hardware): add onekey-hardware skill for device lifecycle + auth login --hardware#4

Open
wabicai wants to merge 1 commit into
mainfrom
feat/onekey-hardware
Open

feat(hardware): add onekey-hardware skill for device lifecycle + auth login --hardware#4
wabicai wants to merge 1 commit into
mainfrom
feat/onekey-hardware

Conversation

@wabicai

@wabicai wabicai commented Apr 21, 2026

Copy link
Copy Markdown
Member

Summary

  • Adds a fifth skill onekey-hardware covering OneKey device lifecycle (onekey device search|lock|verify|firmware|change-pin|toggle-passphrase|settings) and the new onekey auth login --hardware path from app-monorepo.
  • Once the user is authenticated with --hardware, the CLI signer is wired off the session file, so normal onekey balance, onekey transfer, onekey swap … keep working without any extra flag — the skill is explicit about that so agents do not invent a --hardware flag on wallet commands.
  • references/common.md is a copy of the shared wallet ruleset; the skill's own SKILL.md adds hardware-specific safety rules (never ask for passphrase in chat, pinentry / on-device only, decline firmware/factory-reset via CLI).

Changes

  • skills/onekey-hardware/SKILL.md + references/common.md (new skill).
  • AGENTS.md, CLAUDE.md, README.md — skill tables updated from four to five skills.
  • .claude-plugin/marketplace.json, .claude-plugin/plugin.json, .cursor-plugin/plugin.json — versions bumped to 0.3.0, descriptions + keywords extended.
  • .opencode/opencode.json — adds the new SKILL.md path.
  • .codex/INSTALL.md, .opencode/INSTALL.md, .openclaw/INSTALL.md — skill tables updated.

Companion PR

Paired with the app-monorepo branch that restores onekey auth login --hardware on top of x's auth refactor (feat/cli-hardware-skill). The skill needs the CLI side merged before the onekey-hardware commands are reachable.

Follow-up (not in this PR)

.github/workflows/validate.yml should also list the new hardware skill files in its existence/frontmatter checks. That edit requires a token with workflow scope, so a maintainer with scope needs to land it in a separate tiny PR.

Test plan

  • python3 -m json.tool on every *.json manifest (local).
  • Existence + frontmatter check for the new SKILL.md, mirroring what validate.yml does for the existing four skills.
  • Install via /plugin install onekey-wallet-skills in Claude Code once merged and verify the hardware skill appears.

Open in Devin Review

… login --hardware

Adds a fifth skill covering hardware device management (search, verify,
firmware, pin, passphrase, settings) and the new `onekey auth login
--hardware` path. Once the user is logged in, the signer is wired off
the session file, so normal balance/transfer/swap commands keep working
without any hardware flag.

Updates:
- skills/onekey-hardware/{SKILL.md,references/common.md}
- AGENTS.md, CLAUDE.md, README.md skill tables
- .claude-plugin/{marketplace,plugin}.json bumped to 0.3.0
- .cursor-plugin/plugin.json bumped to 0.3.0
- .opencode/opencode.json adds the new SKILL.md
- .codex/, .opencode/, .openclaw/ INSTALL.md skill tables

Note: .github/workflows/validate.yml should also be updated to check
the new hardware skill files. That change needs a token with workflow
scope, so it is intentionally left out of this PR.
wabicai added a commit to OneKeyHQ/app-monorepo that referenced this pull request Apr 21, 2026
Deletes the last in-repo skill (apps/cli/skills/hardware/) now that
onekey-hardware is published in
https://github.com/OneKeyHQ/onekey-wallet-skills via
OneKeyHQ/onekey-wallet-skills#4.

Updates the root CLAUDE.md CLI section to reflect:
- Skills are installed via /plugin install onekey-wallet-skills
- After 'onekey auth login --hardware', normal wallet commands run
  against the device automatically; no --hardware flag on
  balance/transfer/swap.

@devin-ai-integration devin-ai-integration Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

Devin Review found 2 potential issues.

⚠️ 1 issue in files not directly in the diff

⚠️ CONTRIBUTING.md still says "four copies" for references/common.md sync rule (CONTRIBUTING.md:17-18)

The PR adds a fifth references/common.md (in skills/onekey-hardware/) but does not update CONTRIBUTING.md:17 which still reads "Keep all four copies in sync when editing shared policy." This is now inaccurate — there are five copies. Future contributors following CONTRIBUTING.md may not realize the hardware skill's common.md also needs to stay in sync, causing policy drift.

View 3 additional findings in Devin Review.

Open in Devin Review

Comment on lines +1 to +9
---
name: onekey-hardware
description: "Use when the user asks about their OneKey hardware device: connecting, verifying authenticity, checking firmware, locking, changing PIN, toggling passphrase protection, renaming the device, logging in with hardware, signing with hardware, or 硬件钱包, 连接设备, 固件, 修改PIN, 锁定设备, 隐藏钱包, 设备签名. Do NOT use for App Bot Wallet login — that is the default path in onekey-wallet."
license: Apache-2.0
metadata:
author: OneKey
version: 0.2.0
homepage: https://onekey.so
---

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

🔴 CI validation workflow not updated to include new onekey-hardware skill

The PR adds the onekey-hardware skill but does not update .github/workflows/validate.yml to validate the new skill's files. The workflow at .github/workflows/validate.yml:20-39 hardcodes the list of skill files to check for existence and frontmatter presence, but omits skills/onekey-hardware/SKILL.md and skills/onekey-hardware/references/common.md. This means CI will not catch if the new skill files are accidentally deleted, emptied, or have their frontmatter corrupted. Per CONTRIBUTING.md:21-23, the CI is supposed to perform "shell checks for skill/frontmatter presence", and this PR introduces a gap in that coverage.

Prompt for agents
The `.github/workflows/validate.yml` file needs to be updated to include the new onekey-hardware skill files. In the `validate-skills` job, there are two `for file in` loops:

1. The first loop (around lines 20-30) checks that skill files exist and are non-empty. Add `skills/onekey-hardware/SKILL.md` and `skills/onekey-hardware/references/common.md` to that list.

2. The second loop (around lines 32-39) checks YAML frontmatter presence (grep for `---` and `name:` in the first 5 lines). Add `skills/onekey-hardware/SKILL.md` to that list.

This ensures CI validates the new hardware skill the same way it validates the existing four skills.
Open in Devin Review

Was this helpful? React with 👍 or 👎 to provide feedback.

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.

1 participant