Metadata-Version: 2.4
Name: keel-python
Version: 0.1.0
Summary: Keel Python SDK — AI 服务器运维自动化平台客户端 (REST API)
License-Expression: MIT
Project-URL: Homepage, https://keel.codes
Project-URL: Documentation, https://docs.keel.codes
Project-URL: Source, https://github.com/sftgroup/keel
Keywords: keel,server-ops,devops,ai-ops,monitoring
Classifier: Programming Language :: Python :: 3
Classifier: Operating System :: OS Independent
Requires-Python: >=3.9
Description-Content-Type: text/markdown
Requires-Dist: httpx>=0.27.0

# Keel Python SDK

```python
from keel import Keel

ops = Keel("https://keel.codes", token="<your-bearer-token>")

print(ops.health())

# 登录获取 token（自托管模式）
result = ops.login("admin", "password")
print(result["access_token"])

# Agents / 告警 / 指标
agents = ops.list_agents()
alerts = ops.list_alerts(limit=10)
metrics = ops.get_metrics(project="my-project")

# Docker
status = ops.docker_status()
containers = ops.docker_containers()

# AI 运维对话
reply = ops.chat("磁盘快满了怎么办？")
```

## 安装

```bash
pip install keel-python
```

## 认证

- 平台管理员：`Keel(base, token=...)` 直接传平台 API Key
- 用户模式：`login(username, password)` 后自动携带 Bearer token
