SuperAPI AI Directory

getnote-auth

General & other

View repository

Updated 10-15 22:38

About this skill

Dedao Brain connection, diagnostics, and upgrades

Responsible for advancing "the user wants to use Dedao Brain" to a truly executable state. Don't just say "installed": connection is only successful when all three pass: CLI executable, account authorized, and API readable.

First-time installation loop

Execute in order, skipping steps that are already satisfied:

  1. Use command -v getnote to check the CLI; don't assume the CLI exists just because the Skill is installed. Standalone ClawHub/OpenClaw Skills have their CLI dependencies managed by the platform; don't look for or run scripts/install.sh。
  2. When the CLI is missing, check node --version and npm --version, then automatically execute npm install -g @getnote/cli@latest. This is the Agent's job; don't ask the user to manually copy commands; only ask the user to confirm when the system pops up an installation authorization.
  3. Execute getnote version; it must be able to start normally.
  4. Execute getnote auth status. When not logged in, run getnote auth login, having the user confirm only in the browser; don't ask for an API Key, Cookie, or Authorization.
  5. Execute getnote doctor -o json. Only when diagnostics_completed=true、ready=true and status=readycan you declare a complete connection;ready=true,status=degraded means core capabilities are available but warnings should still be handled.success and the old checks field are only for compatibility. If not ready, first handle issues[].blocking=true, then fix according to next_actions[] . Actions requiring confirmation must not be executed silently.
  6. In local Agents such as Codex, Claude Code, or Cursor, execute getnote setup to synchronize the 5 domain Skills; if the current platform already carries these domain Skills via a standalone Skill package, or the CLI explicitly indicates that no supported platform was detected, don't misreport this step's failure as an account connection failure.
  7. First use getnote notes --limit 1 -o json for write-free acceptance. Only save a test note when the user agrees to create test content.

Daily routing

Intent Command
Log in getnote auth login
View login status getnote auth status
Log out getnote auth logout
Diagnose connection getnote doctor -o json
View CLI capability contract getnote capabilities -o json
Synchronize domain Skills for the local AI getnote setup
View AI conversation quota getnote quota -o json
View version getnote version
Check for upgrades getnote update --check
Execute upgrade getnote update

When parameters are uncertain, read the corresponding command's --help; don't guess parameters from old documentation.

Each command's result and next step

Command Read/confirm after success What to do after success
getnote auth login Browser confirmed, credentials written locally Then run doctor -o json; don't display credentials in chat.
getnote auth status Authenticated / Not authenticated or environment variable login status Only start auth loginwhen not logged in; only masked values may appear in the status.
getnote auth logout Logged out successfully. Only state that the local machine has logged out; don't claim server-side authorization has been revoked.
getnote doctor -o json diagnostics_completed、local_ready、ready/status/summary、checks[]、issues[]、next_actions[]、update、integrations[] ready=true,status=ready only indicates complete availability;degraded requires continued handling of warnings.platforms[] only indicates that the application or command was detected; it cannot prove the Skill is installed; use integrations[].skill_status/ready to determine AI access status.
getnote capabilities -o json contract_version、commands、command_aliases、command_results、guarantees Read only during installation, upgrade, or compatibility troubleshooting; this is the sole source of truth for command and result fields.
getnote setup -o json success、targets[]、installed_cli、installed_skills、authenticated、platforms[]、next_actions[]、next platforms[].status=installed indicates local installation is complete;verify_in_platform indicates OpenClaw (Crayfish) or QClaw is managed by the platform, and only guide the user to complete the corresponding unique next_action. Failure to detect an AI platform does not affect the CLI and account connection.
getnote quota -o json data.read/write/write_note under daily/monthly.limit/used/remaining/reset_at describes the remaining quota by actual bucket; do not convert or merge buckets on your own.
getnote version Version text is only used to display the version; the machine contract is still based on capabilities -o json .
getnote update --check Current/available new version text Run again when there is a new version getnote update。
getnote update CLI update, Skills sync, and doctor verification results By default, the new CLI automatically completes the full update loop; only when all steps succeed can you say the upgrade is complete. When only upgrading the CLI, use --cli-only。

For all commands, the exit code is the primary judgment: a non-zero exit code means failure. Use -o json Both the API and local errors return success=false、data=null、error.code/message/reason/retryable and optional request_id; do not treat HTTP 200 or "the command ran" as success.

Doctor machine decision rules

  1. diagnostics_completed=false or the command exits non-zero: the diagnosis itself failed, and you must not act based on incomplete output.
  2. ready=true: CLI, account authorization, and OpenAPI connectivity are all available; if status=degraded, core capabilities are available but there are still non-blocking warnings.
  3. status=partial: usually --offline skips remote checks; read local_ready to judge the local environment,ready=null indicates the remote is unknown, and you must not claim it is connected.
  4. issues[].blocking=true: handle in order of priority; keep code、details.request_id and the error fields.
  5. next_actions[]:requires_confirmation=true first confirm with the user, then execute the exact command; after execution, rerun doctor to verify.
  6. integrations[].detected=true only indicates that a host was discovered; only skill_status=installed and ready=true can confirm that the CLI-verifiable Skills are complete.unverified indicates the installation status is managed by the platform, and the user should confirm within the platform; do not guess success.
  7. update.update_available=true is a non-blocking warning; only perform the upgrade action after the user explicitly requests an upgrade.

Update loop

When the user says "help me update to get the brain," that already constitutes full update authorization; do not ask the user to choose internal components such as CLI or domain Skills:

  1. Execute getnote update --check; when there is a new version or Skills need to be refreshed, execute getnote update. The command upgrades the CLI, and then the new CLI automatically runs setup and doctor, and syncs the five domain Skills bundled with the CLI.
  2. Independent aggregate Skills hosted by ClawHub/OpenClaw are updated by the platform;getnote update does not download or overwrite that Skill. If the host supports checking for Skill updates, continue using the host flow; otherwise, only tell the user the single necessary confirmation entry point.
  3. Check the CLI version, the sync results of the five domain Skills, and the doctor result in the update output.
  4. Use the most recent note read as acceptance, then tell the user the version, diagnosis result, and any remaining actions.

Security and recovery

  • Do not display or record full credentials;auth status only masked values may appear.
  • Do not log out unless the user explicitly requests it.
  • When authorization times out, is denied, or the verification code expires, restart the login flow once; do not reuse the old code.
  • On failure, keep the execution steps, error cause, and request_id; do not just reply "connection failed".