get your claude code tokens here

chore: add a bun needed warning

dunkirk.sh bb1ecf47 17e70ba0

verified
Changed files
+14 -2
src
+2 -2
package.json
···
{
"name": "anthropic-api-key",
-
"version": "0.1.3",
+
"version": "0.1.4",
"description": "CLI to fetch Anthropic API access tokens via OAuth with PKCE using Bun.",
"type": "module",
"private": false,
···
},
"homepage": "https://github.com/taciturnaxolotl/anthropic-api-key#readme",
"bin": {
-
"anthropic": "dist/index.js"
+
"anthropic-api-key": "dist/index.js"
},
"exports": {
".": "./dist/index.js",
+12
src/index.ts
···
#!/usr/bin/env bun
+
// Detect if running under Node.js instead of Bun
+
if (
+
typeof Bun === "undefined" ||
+
// @ts-ignore
+
(typeof process !== "undefined" && process.release?.name === "node")
+
) {
+
console.error(
+
"❌ This CLI requires Bun. Please install Bun from https://bun.sh/",
+
);
+
process.exit(1);
+
}
+
import { serve } from "bun";
import {
bootstrapFromDisk,