SuperAPI AI Directory

wbso-auth

General & other

View repository

Updated 10-16 03:36

About this skill

Log in to WBSO.ai

Help the user create a new API key and save it in ~/.config/wbso/config. Use the supplied wbso CLI.

Claude Code sets plugin-root bin/ in $PATH, so there wbso works directly. Otherwise you resolve the self-contained scripts/wbso next to this skill as $WBSO_CLI:

WBSO_CLI="$(
  command -v wbso 2>/dev/null ||
  { [ -n "${CLAUDE_PLUGIN_ROOT:-}" ] && [ -x "${CLAUDE_PLUGIN_ROOT}/bin/wbso" ] && printf '%s\n' "${CLAUDE_PLUGIN_ROOT}/bin/wbso"; } ||
  find \
    "$PWD" \
    "$HOME/.claude/skills" \
    "$PWD/.claude/skills" \
    "$HOME/.cursor/skills" \
    "$PWD/.cursor/skills" \
    "$HOME/.agents/skills" \
    "$PWD/.agents/skills" \
    "$HOME/.codex/skills" \
    "$HOME/.codex/plugins/cache/wbso-ai/wbso" \
    "$HOME/.codex/plugins/cache" \
    -path '*/scripts/wbso' -type f 2>/dev/null |
  sort -V | tail -1
)"
test -n "$WBSO_CLI" || { echo "WBSO CLI niet gevonden"; exit 127; }

Step 1: Ask permission to open the browser

Explain why you're doing it, then ask permission:

"To log you in I need an API key that links your account to this device. You create it in the browser on your WBSO.ai company page — I'll open it for you, you create a key and paste it here."

"May I open that page now?"

Wait for an answer. On "yes" / "ok" / empty line:

[ -f "$HOME/.config/wbso/.env.local" ] && . "$HOME/.config/wbso/.env.local"
URL="${WBSO_API_BASE_URL:-https://portal.wbso.ai}/companies/current/compliance/api_keys"
xdg-open "$URL" 2>/dev/null || open "$URL" 2>/dev/null || echo "Open zelf: $URL"

On "no" / "later": show the URL as plain text, the user opens it themselves.

~/.config/wbso/.env.local is automatically loaded by the CLI on every call, but to open the browser URL you need to source it yourself — see the bash block above.

Step 2: Ask for the API key

Send as plain text:

"Paste your new API key here."

Step 3: Log in via the CLI

WBSO_CLI="$(
  command -v wbso 2>/dev/null ||
  { [ -n "${CLAUDE_PLUGIN_ROOT:-}" ] && [ -x "${CLAUDE_PLUGIN_ROOT}/bin/wbso" ] && printf '%s\n' "${CLAUDE_PLUGIN_ROOT}/bin/wbso"; } ||
  find \
    "$PWD" \
    "$HOME/.claude/skills" \
    "$PWD/.claude/skills" \
    "$HOME/.cursor/skills" \
    "$PWD/.cursor/skills" \
    "$HOME/.agents/skills" \
    "$PWD/.agents/skills" \
    "$HOME/.codex/skills" \
    "$HOME/.codex/plugins/cache/wbso-ai/wbso" \
    "$HOME/.codex/plugins/cache" \
    -path '*/scripts/wbso' -type f 2>/dev/null |
  sort -V | tail -1
)"
test -n "$WBSO_CLI" || { echo "WBSO CLI niet gevonden"; exit 127; }
"$WBSO_CLI" login --api-key "<KEY>"

Output ok (<email> · <bedrijf>) = done — confirm briefly:

"Logged in as at ."

Output starts with error: = key invalid, ask again.