Skip to main content

A command-line interface for Claude AI

Project description

Claude CLI

A command-line interface for interacting with Claude AI.

Claude CLI Demo

Features

  • Interactive chat with Claude AI in your terminal
  • Send one-off queries without entering an interactive session
  • Manage your conversations (list, delete, rename)
  • Support for file attachments
  • Rich text formatting (markdown)
  • Configuration management

Installation

From PyPI

pip install claudeshell

From Source

git clone https://github.com/yourusername/claude-cli.git
cd claude-cli
pip install -e .

Setup

Before using Claude CLI, you need to configure your Claude cookie:

claude config

This will prompt you to enter your Claude cookie. Alternatively, you can set the CLAUDE_COOKIE environment variable.

Getting Your Claude Cookie

  1. Go to claude.ai and log in
  2. Open your browser's developer tools (F12 or right-click > Inspect)
  3. Go to the Network tab
  4. Refresh the page
  5. Click on any request to claude.ai
  6. In the Headers tab, find the Cookie header
  7. Copy the entire cookie value

Usage

Interactive Chat

Start a new chat conversation:

claude chat --new

Continue an existing conversation:

claude chat --id <conversation_id>

One-off Queries

Send a single query and get a response:

claude query "What is the capital of France?"

With attachment:

claude query "Summarize this document" --attachment path/to/file.pdf

Managing Conversations

List all conversations:

claude list

Delete a conversation:

claude delete <conversation_id>

Rename a conversation:

claude rename <conversation_id> "New Title"

Commands Reference

  • claude chat: Start an interactive chat session
  • claude query: Send a one-off query
  • claude list: List all conversations
  • claude delete: Delete a conversation
  • claude rename: Rename a conversation
  • claude config: Configure settings

Dependencies

  • claude-api: Unofficial Claude API
  • click: Command-line interface creation
  • rich: Terminal text formatting and display
  • pyyaml: Configuration file handling

License

MIT

Disclaimer

This project provides an unofficial client for Claude AI and is not affiliated with or endorsed by Anthropic. Use it at your own risk.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

claudeshell-0.1.0.tar.gz (8.9 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

claudeshell-0.1.0-py3-none-any.whl (9.5 kB view details)

Uploaded Python 3

File details

Details for the file claudeshell-0.1.0.tar.gz.

File metadata

  • Download URL: claudeshell-0.1.0.tar.gz
  • Upload date:
  • Size: 8.9 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.13.2

File hashes

Hashes for claudeshell-0.1.0.tar.gz
Algorithm Hash digest
SHA256 8bc76033efc9a125b18853c0ff0e113464702ae6cbde9c3bc6ac8c3436194f34
MD5 9b3f4a6e4fa63f57f1b25cfce5f99856
BLAKE2b-256 d1146951afaf5651231a57f05242f1705b59931bc37f385f52e992946705abf0

See more details on using hashes here.

File details

Details for the file claudeshell-0.1.0-py3-none-any.whl.

File metadata

  • Download URL: claudeshell-0.1.0-py3-none-any.whl
  • Upload date:
  • Size: 9.5 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.13.2

File hashes

Hashes for claudeshell-0.1.0-py3-none-any.whl
Algorithm Hash digest
SHA256 fb061a61f159efe285baf96cc2c564324844e0b9181573cfc59a7bf126c7fe58
MD5 e3ba84288ff69983ee0fa95ffbe819e4
BLAKE2b-256 f311b3da849d3f676524a63887a57e25a6f92f1cc9b88488dd3f849e14bd48a4

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page