whatisgithub

What is pinwheel?

kartik-2239/pinwheel — explained in plain English

Analysis updated 2026-05-18

1GoAudience · developerComplexity · 3/5Setup · moderate

In one sentence

A Go based proxy server that hands out limited, expiring API keys for AI providers like OpenAI, Anthropic, and Gemini.

Mindmap

mindmap
  root((Pinwheel))
    What it does
      Proxies LLM API calls
      Issues limited API keys
      Enforces cost and expiry limits
    Tech stack
      Go
      SQLite
      CLI TUI
    Use cases
      Share AI access safely
      Limit team spending
      Time limited API access
    Audience
      Developers
      Ops teams
    Requirements
      Provider API key
      Go 1.25 or newer

Code map

Detail Auto

An interactive map of this repo's files and how they connect — its source is parsed live in your browser. Click Visualize to build it.

filefunction / class

What do people build with it?

USE CASE 1

Create a limited, expiring API key to safely share AI access with a teammate or app.

USE CASE 2

Set a maximum spending cap on an API key so no one accidentally runs up a large AI bill.

USE CASE 3

Restrict which AI models a given key is allowed to call.

What is it built with?

GoSQLite

How does it compare?

kartik-2239/pinwheeladvayc/wrappedaegrail/aegrail-engine
Stars111
LanguageGoGoGo
Setup difficultymoderateeasyhard
Complexity3/52/55/5
Audiencedevelopergeneralops devops

Figures from each repo's GitHub metadata at analysis time.

How do you get it running?

Difficulty · moderate Time to first run · 30min

Requires at least one supported AI provider API key and Go 1.25 or newer.

No license information was found in the README.

So what is it?

Pinwheel is a small server, written in the Go programming language, that sits between an app and the AI companies it talks to, such as OpenAI, Anthropic, OpenRouter, Groq, and Gemini. Instead of giving every user or app your real provider API keys directly, you run Pinwheel with your real keys stored safely on your own server, and it hands out its own local keys to whoever needs access. Each local key Pinwheel creates can be limited in specific ways: you can restrict which AI models it is allowed to use, set a maximum amount of money it is allowed to spend, and give it an expiration date after which it stops working. This is useful if you want to let other people, teammates, or separate parts of an app use AI features without giving them your actual, unrestricted provider keys. Setting it up involves creating a text file with your real provider keys, then using a built in command line tool with a simple interactive menu to generate a new limited key, choosing its name, which models it can use, and any spending or time limits. Once created, that key works with a running proxy server that listens for requests, checks the key against a small local database to confirm it is valid and within its limits, forwards the request to the correct AI provider, and streams the response back to whoever made the request, the same way a normal API call to that provider would work. The project requires at least one AI provider API key and a recent version of Go installed to run.

Copy-paste prompts

Prompt 1
Walk me through setting up Pinwheel with my OpenAI and Anthropic API keys.
Prompt 2
Explain how Pinwheel enforces spending limits and expiration dates on proxy keys.
Prompt 3
Show me how to create a new limited API key using Pinwheel's CLI.
Prompt 4
How would I send a request through the Pinwheel proxy instead of directly to OpenAI?

Frequently asked questions

What is pinwheel?

A Go based proxy server that hands out limited, expiring API keys for AI providers like OpenAI, Anthropic, and Gemini.

What language is pinwheel written in?

Mainly Go. The stack also includes Go, SQLite.

What license does pinwheel use?

No license information was found in the README.

How hard is pinwheel to set up?

Setup difficulty is rated moderate, with roughly 30min to a first successful run.

Who is pinwheel for?

Mainly developer.

Open on GitHub → Ask about another repo

This repo across BitVibe Labs

Verify against the repo before relying on details.