- 登入後開啟「API 金鑰」。
- 建立金鑰並填寫容易辨識的名稱,例如 local-dev。
- 如帳戶支援有效期、用量或模型限制,請按專案需要設定最小權限。
- 將完整金鑰儲存至密碼管理員或本機密鑰庫。如有外洩,請停用並更換。
驗證金鑰
export TOKENPILOT_API_KEY='replace-with-your-key' # bash / zsh
# PowerShell: $env:TOKENPILOT_API_KEY = 'replace-with-your-key'curl "https://api.tokentpilot.com/v1/models" \
-H "Authorization: Bearer $TOKENPILOT_API_KEY"