@antseed/provider-claude-code

中文文档
0.1.59发布于 2026/11/08TypeScriptES Module近 30 天下载 1823

Claude Code keychain provider plugin for Antseed

原始使用文档
文档目录5 节
  1. Installation
  2. Usage
  3. Configuration
  4. How It Works
  5. Requirements

@antseed/provider-claude-code

Testing and development only. This plugin reads credentials from your personal Claude Code subscription. Reselling subscription-based access violates Anthropic's Terms of Service and is not permitted. Use this plugin only for local development, testing, and demo purposes. For production use, see @antseed/provider-anthropic with a commercial API key.

Connect to the Anthropic API using Claude Code keychain credentials for local testing and development. No API key needed -- reads OAuth tokens directly from the macOS keychain.

Installation

antseed plugin add @antseed/provider-claude-code

Usage

antseed config seller add-provider claude-code --plugin claude-code
antseed config seller add-service claude-code claude-sonnet-4-5-20250929 \
  --input 10 --output 10 \
  --categories chat,coding
antseed seller start

No API key configuration is required. The plugin reads credentials from the system keychain where Claude Code stores them.

Configuration

KeyTypeRequiredDefaultDescription
ANTSEED_INPUT_USD_PER_MILLIONnumberNo10Input token price (USD per 1M)
ANTSEED_OUTPUT_USD_PER_MILLIONnumberNo10Output token price (USD per 1M)
ANTSEED_MAX_CONCURRENCYnumberNo10Max concurrent requests
ANTSEED_ALLOWED_SERVICESstring[]No--Comma-separated service allowlist

How It Works

Uses a custom ClaudeCodeTokenProvider that reads OAuth tokens from the macOS keychain via keytar. Tokens are automatically refreshed when they expire. The provider relays requests to https://api.anthropic.com using the retrieved credentials.

Requirements

  • macOS with Claude Code installed and authenticated
  • keytar native module (installed automatically)

版本与发布记录

@antseed/provider-claude-code 共发布 60 个版本,首次发布于 2026/02/24;过去 12 个月发布了 60 个版本。

版本发布日期距今
0.1.59latest2026/11/08今天
0.1.582026/11/07今天
0.1.572026/11/044 天前
0.1.562026/11/044 天前
0.1.552026/10/2613 天前
0.1.542026/10/1821 天前

关于 @antseed/provider-claude-code 的常见问题

@antseed/provider-claude-code 是什么?

Claude Code keychain provider plugin for Antseed

如何安装 @antseed/provider-claude-code?

在项目目录运行 npm install @antseed/provider-claude-code,或使用 pnpm add / yarn add / bun add。它还需要宿主项目提供 peer 依赖:@antseed/node(>=0.1.0)。npm 7 及以上与 pnpm 8 及以上默认会自动安装必需的 peer 依赖,Yarn 需要手动安装。

@antseed/provider-claude-code 支持 TypeScript 吗?

支持。包内自带 TypeScript 类型声明(package.json 声明了 types 入口),安装后即可获得类型提示,无需再安装 @types 包。

@antseed/provider-claude-code 支持 ESM 还是 CommonJS?

以 ES Module 形式发布,推荐使用 import 引入。在 CommonJS 项目中,Node.js 20.19+ / 22.12+ 可以直接 require() 不含顶层 await 的 ES Module,更早的版本需要改用动态 import()。

@antseed/provider-claude-code 可以商用吗?

@antseed/provider-claude-code 使用 未声明 许可。package.json 没有声明许可证。没有许可证的代码默认保留全部权利,商用前请联系作者或查看仓库中的 LICENSE 文件。以上为概括,不构成法律意见,请以许可原文为准。

@antseed/provider-claude-code 的下载量有多少?

根据 npm 官方下载统计,@antseed/provider-claude-code 在 2026/10/06 – 2026/11/04 这 30 天内被下载 1,823 次,日均约 61 次。下载量会把 CI 构建、镜像同步和作为其他包依赖的安装一并计入,适合横向比较热度,不能直接等同于使用人数。

@antseed/provider-claude-code 还在维护吗?

最新版本 0.1.59 发布于 2026/11/08(今天);至今共发布 60 个版本,其中过去 12 个月发布了 60 个;首次发布于 2026/02/24。发布频率只是参考信号:功能稳定的工具可能很少需要更新,建议结合源码仓库的 issue 和提交记录判断。