Skip to main content

We've Open-Sourced a CLI Bridge for Your Claude Code Subscription

After Anthropic banned our account, we built cli-bridge: a small, open-source, local tool that lets Hermes and other bots run on a terminal AI CLI you already pay for. Here is what it does, what it does not do, and the risks you carry.

We've Open-Sourced a CLI Bridge for Your Claude Code Subscription

TLDR. We have released cli-bridge, a small open-source tool that lets a bot framework such as Hermes, or any OpenAI-compatible client, run on a terminal AI CLI you have already paid for and signed into. It runs entirely on your own machine, stores nothing of its own, and is free under the MIT licence.

Please note that driving a personal or subscription CLI programmatically may breach the provider's terms and put your account at risk of suspension or a permanent ban. Read the warnings before you use it.

This article describes an independent, open-source project. It is not affiliated with, endorsed by, or supported by Anthropic or any other provider. Using the tool may breach a provider's terms of service and lead to throttling, suspension, or a permanent ban, with no warning and no refund. Nothing here is legal advice. Please read the repository's disclaimer and risk notice before you start.

Why we built this

A few weeks ago we wrote about Anthropic banning our account and what its terms of service actually say about automated access. We had been paying for a subscription and running our bots on it every day. That access was cut off with no warning, and the officially sanctioned path for programmatic use is a pay-per-token API account, which for heavy, always-on use can be prohibitively expensive.

A lot of people are in the same position. They pay for a subscription that already includes a capable terminal CLI, and they simply want to point their own bot at the tool they are already paying for. cli-bridge is for them.

We are not encouraging anyone to break a provider's rules but we are using this bridge consistently with acceptable use and the relevant terms of service.

What is cli-bridge?

cli-bridge is a small local server. To your bot, it looks like an ordinary OpenAI-compatible AI service. It takes each message from your bot, runs your CLI once to produce a reply, and passes that reply back. So your bot runs on the CLI you already pay for.

It is deliberately minimal:

  • It keeps nothing of its own: no saved chats, no API keys, no credentials.
  • It uses your CLI's own sign-in, and runs the CLI fresh for each message.
  • It listens only on your own machine (127.0.0.1), not the open internet.
  • If a request includes tools, it hands the tool call back to your bot to run, so your bot stays in charge.

Setup is three lines:

git clone https://github.com/Daimon-Law/cli-bridge.git cli-bridge
cd cli-bridge
./cli-bridge setup

You then add it to Hermes as a custom, OpenAI-compatible provider at http://127.0.0.1:18800/v1. The documentation walks through it step by step, including a Hermes-specific guide, even if you have never run a server before.

Does it spoof, fake, or steal anything?

No.

The bridge does not fake API credentials, scrape tokens, or impersonate anyone. It runs the official command-line program that you installed and signed into yourself, using that program's own authenticated session. It holds no credentials of its own and saves nothing. Every line of it is open source, so you can read exactly what it does before you run it.

That said, a clean mechanism is not the same thing as permission. Running an interactive CLI programmatically may still fall outside what a provider's terms allow, no matter how transparently it is done. We make no claim that using the bridge is permitted. Whether it is allowed in your case is governed solely by the provider's own terms and local law, which you must read and follow yourself.

What are the risks?

They are real, and you carry them in full. From the project's risk notice:

  • Your provider may throttle, degrade, suspend, or permanently terminate your account.
  • You may lose access to everything tied to that account, including paid time you will not get back.
  • This can happen without warning, at the provider's sole discretion, and at any time.
  • There is no warranty, and we accept no liability.

In short: do not connect anything to this software that you cannot afford to lose. By using it you accept the full disclaimer and our terms of use for Daimon Law repositories.

What is the officially sanctioned alternative?

To be fair to the providers, there is a supported path, and for some people it is the right one. The only officially sanctioned way to use these models programmatically and in production is an API-based, pay-per-token account. It is reliable and clearly permitted. The trade-off is cost: for heavy, always-on use it can become very expensive, which is exactly why so many people reach for their subscription instead. If you need production reliability, use the API.

Why publish it at all?

Two reasons, and they sit together.

First, we think people who pay in good faith for a tool should be able to use it in good faith, and that cutting off paying customers with no warning and no explanation is a poor way to treat them. We said as much in our earlier piece.

Second, we respect that providers are entitled to set the terms of their own services. The answer to an opaque rule is not a sneaky workaround. It is a transparent, open, readable tool, shipped with full and honest disclosure of the risks, so that each person can make their own informed decision. That is what we have tried to do here.

This is version 0.1.0. It works, but it is early days, and we expect the odd rough edge. Issues and fixes are welcome on GitHub.


Paul is the principal of Daimon Legal, a Melbourne-based law firm working with DeFi, AI, and crypto ventures across Australia, the UK, US and the EU. He also builds his own tools.

The information on this page is general in nature and does not constitute legal advice. Please review our Legal Disclaimer for important information about the limitations of this content and the terms governing your use of this website.