finds.dev← search

// the find

chenyme/grok2api

★ 5,290 · Python · MIT · updated Jun 2026

Grok2API 是一个基于 FastAPI 构建的 Grok 网关,支持将 Grok Web 能力以 OpenAI 兼容 API 的方式转换。

A FastAPI gateway that reverse-engineers the Grok web interface and exposes it as an OpenAI-compatible API, complete with multi-account pooling, image/video generation, and an admin UI. It targets developers who want programmatic access to Grok without paying for the official xAI API. The author has officially abandoned it.

The architecture is legitimately well-structured for what it is — clean separation into control, dataplane, and platform layers with proper account state machines and quota tracking. Multi-account pooling with tiered selection (basic/super/heavy) is more sophisticated than the typical 'just paste your cookie' approach. Supporting both OpenAI and Anthropic wire protocols from the same backend is convenient for callers already using either SDK. The config system — two-layer (env + runtime TOML) with live reload and `GROK_` prefix overrides — is more operator-friendly than most hobby projects.

The project is archived and dead — the maintainer posted a shutdown notice citing xAI's bot detection improvements; whatever tricks it uses to grab `x-statsig-id` will break on xAI's schedule, not yours. It's a Terms of Service violation by design, so production use carries account ban risk. The session/cookie scraping layer is entirely opaque — when it breaks you're reading undocumented protocol reverse engineering with no upstream to file bugs against. Deployment to Vercel is listed as an option but video generation and local media caching obviously don't work on a serverless platform, which the docs don't flag.

View on GitHub →

// want more like this?

We dig through GitHub every week and send a few repos picked for what you actually care about — each with an honest take like this one.

Get finds in your inbox → Search again →