# langgraph-cli

> CLI for interacting with LangGraph API

- **URL**: https://www.freshcrate.ai/projects/langgraph-cli
- **Author**: pypi
- **Category**: Prompt Engineering
- **Latest version**: `1.2.4` (2026-06-02)
- **License**: Unknown
- **Source**: https://github.com/langchain-ai/langgraph/tree/main/libs/cli
- **Homepage**: https://pypi.org/project/langgraph-cli/
- **Language**: Python
- **GitHub**: 29,893 stars, 5,113 forks
- **Registry**: pypi (`langgraph-cli`)
- **Tags**: `pypi`

## Description

# LangGraph CLI

The official command-line interface for LangGraph, providing tools to create, develop, and deploy LangGraph applications.

## Installation

Install via pip:
```bash
pip install langgraph-cli
```

For development mode with hot reloading:
```bash
pip install "langgraph-cli[inmem]"
```

## Commands

### `langgraph new` 🌱
Create a new LangGraph project from a template
```bash
langgraph new [PATH] --template TEMPLATE_NAME
```

### `langgraph dev` 🏃‍♀️
Run LangGraph API server in development mode with hot reloading
```bash
langgraph dev [OPTIONS]
  --host TEXT                 Host to bind to (default: 127.0.0.1)
  --port INTEGER             Port to bind to (default: 2024)
  --no-reload               Disable auto-reload
  --debug-port INTEGER      Enable remote debugging
  --no-browser             Skip opening browser window
  -c, --config FILE        Config file path (default: langgraph.json)
```

### `langgraph up` 🚀
Launch LangGraph API server in Docker
```bash
langgraph up [OPTIONS]
  -p, --port INTEGER        Port to expose (default: 8123)
  --wait                   Wait for services to start
  --watch                  Restart on file changes
  --verbose               Show detailed logs
  -c, --config FILE       Config file path
  -d, --docker-compose    Additional services file
```

### `langgraph build`
Build a Docker image for your LangGraph application
```bash
langgraph build -t IMAGE_TAG [OPTIONS]
  --platform TEXT          Target platforms (e.g., linux/amd64,linux/arm64)
  --pull / --no-pull      Use latest/local base image
  -c, --config FILE       Config file path
```

### `langgraph dockerfile`
Generate a Dockerfile for custom deployments
```bash
langgraph dockerfile SAVE_PATH [OPTIONS]
  -c, --config FILE       Config file path
```

## Configuration

The CLI uses a `langgraph.json` configuration file with these key settings:

```json
{
  "dependencies": ["langchain_openai", "./your_package"],  // Required: Package dependencies
  "graphs": {
    "my_graph": "./your_package/file.py:graph"            // Required: Graph definitions
  },
  "env": "./.env",                                        // Optional: Environment variables
  "python_version": "3.11",                               // Optional: Python version (3.11/3.12)
  "pip_config_file": "./pip.conf",                        // Optional: pip configuration
  "dockerfile_lines": []                                  // Optional: Additional Dockerfile commands
}
```

See the [full documentation](https://langchain-ai.github.io/langgraph/cloud/reference/cli/) for detailed configuration options.

## Development

To develop the CLI itself:

1. Clone the repository
2. Navigate to the CLI directory: `cd libs/cli`
3. Install development dependencies: `uv pip install`
4. Make your changes to the CLI code
5. Test your changes:
   ```bash
   # Run CLI commands directly
   uv run langgraph --help
   
   # Or use the examples
   cd examples
   uv pip install
   uv run langgraph dev  # or other commands
   ```

## License

This project is licensed under the terms specified in the repository's LICENSE file.

## Recent releases

| Version | Date | Urgency | Changes |
| --- | --- | --- | --- |
| `1.2.4` | 2026-06-02 | High | Changes since 1.2.3  * release(langgraph): 1.2.4 (#7991) * test(sdk-py): add factory-graph integration test exercising the server factory path (#7978) * fix(langgraph): keep _on_started backward-compatible with overrides predating cause (#7987) |
| `sdk==0.4.0` | 2026-05-28 | High | Changes since sdk==0.3.15  * release(sdk-py): 0.4.0 (#7923) * feat(sdk-py): add thread stream helpers (#7833) * feat(sdk-py): wire websocket stream selection (#7832) * feat(sdk-py): add websocket stream transports (#7830) * feat(sdk-py): harden streaming reconnects (#7829) * feat(sdk-py): add sync scoped subgraphs (#7828) * feat(sdk-py): add sync messages and tool calls (#7827) * feat(sdk-py): add sync thread stream core (#7826) * feat(sdk-py): add async stream reconnect support (#7825) * feat(s |
| `1.2.1` | 2026-05-21 | High | Changes since 1.2.0  * release(langgraph): 1.2.1 (#7883) * feat(langgraph): add `before_builtins` opt-in for stream transformers (#7882) * chore(deps): bump idna from 3.11 to 3.15 in /libs/langgraph (#7866) * fix(langgraph): keep tool results out of v3 messages (#7838) * chore(deps): bump langsmith from 0.7.31 to 0.8.0 in /libs/langgraph (#7788) |
| `1.2.0` | 2026-05-12 | High | Changes since 1.2.0a7  * release: bump alpha packages to official versions (#7775) * feat(langgraph): durable error-handler resume across host crashes (#7773) * feat(langgraph): add set_node_defaults() to StateGraph (#7747) * chore(deps): bump urllib3 from 2.6.3 to 2.7.0 in /libs/langgraph (#7766) * chore(deps): bump mistune from 3.2.0 to 3.2.1 in /libs/langgraph (#7733) * chore(langgraph): bump langchain-core to 1.4.0 (#7767) * feat(checkpoint): force delta channel snapshot after max supersteps |
| `sdk==0.3.14` | 2026-05-05 | High | Changes since sdk==0.3.13  * release(sdk-py): 0.3.14 (#7712) * feat(sdk-py): add return_minimal to threads update (#7704) * release: alpha bump (a4) for langgraph, checkpoint, checkpoint-postgres (#7701) * release: alpha bump langgraph 1.2.0a6 (#7697) * release: alpha bump prebuilt 1.1.0a2, langgraph 1.2.0a5 (#7682) * release: alpha bump prebuilt 1.1.0a1, langgraph 1.2.0a4 (#7679) * feat(langgraph): dispatch stream_events(version='v3') on Pregel (#7677) * release: alpha bump (a3) for langgraph, |
| `prebuilt==1.0.13` | 2026-04-30 | High | Changes since prebuilt==1.0.12  * fix(prebuilt): default ToolRuntime tools to empty list (#7650) * release: alpha for timers (#7647) * chore: update x links to langchain_oss (#7645) * refactor(langgraph,prebuilt): merge EventLog into StreamChannel with optional name (#7637) * feat(langgraph): add streaming transformer infrastructure and tests  (#7519) * chore(deps): bump the minor-and-patch group across 1 directory with 4 updates (ty held back) (#7635) |
| `prebuilt==1.0.11` | 2026-04-24 | High | Changes since prebuilt==1.0.10  * release(prebuilt): 1.0.11 (#7610) * feat(prebuilt): allow ToolNode tools to return list[Command \| ToolMessage] (#7596) * chore(langgraph): bump version 1.1.8 -> 1.1.9 (#7563) * feat(prebuilt): expose available tools on ToolRuntime (#7512) * release(langgraph): 1.1.8 (#7545) |
| `0.4.23` | 2026-04-21 | Low | Imported from PyPI (0.4.23) |
| `1.1.9` | 2026-04-21 | High | Changes since 1.1.8  * chore(langgraph): bump version 1.1.8 -> 1.1.9 (#7563) * fix(langgraph): don't propagate ReplayState to subgraphs on plain resume (#7561) * chore(langgraph): undo unnecessary changes in stream handler (#7536) |
| `1.1.8` | 2026-04-17 | High | Changes since 1.1.7  * release(langgraph): 1.1.8 (#7545) * fix(langgraph): remove strict add_handler type check that breaks OTel instrumentation (#7544) * release(prebuilt): 1.0.10 (#7541) * release(cli): 0.4.23 (#7542) |

## Citation

- HTML: https://www.freshcrate.ai/projects/langgraph-cli
- Markdown: https://www.freshcrate.ai/projects/langgraph-cli.md
- Dependencies JSON: https://www.freshcrate.ai/api/projects/langgraph-cli/deps

_Generated by freshcrate.ai. Indexes pypi releases for AI-agent ecosystem packages._
