Metadata-Version: 2.4
Name: mcarchive-api
Version: 0.1.1
Summary: Unofficial library to help you consume the MCArchive API
Keywords: minecraft,http,api,json
Author: 红温的鼠鼠7891
Author-email: 红温的鼠鼠7891 <pystart@qq.com>
License-Expression: MIT
Classifier: Programming Language :: Python :: 3
Classifier: License :: OSI Approved :: MIT License
Classifier: Operating System :: OS Independent
Requires-Dist: httpx>=0.28.1
Requires-Dist: urllib3>=2.8.0
Requires-Python: >=3.14
Project-URL: Homepage, https://angrymouse7891.github.io/mcarchive-api-python/
Project-URL: Documentation, https://angrymouse7891.github.io/mcarchive-api-python/en/changelog/
Project-URL: Repository, https://github.com/AngryMouse7891/mcarchive-api-python.git
Project-URL: Issues, https://github.com/AngryMouse7891/mcarchive-api-python/issues
Project-URL: Changelog, https://angrymouse7891.github.io/mcarchive-api-python/en/changelog/
Description-Content-Type: text/markdown

# MCArchive API for Python

## 简介

这是一个允许开发者与MCArchive API交互的Python库，使用[`httpx`](https://pypi.org/project/httpx/)进行API交互，[`urllib`](https://pypi.org/project/urllib/)库作为变量转URL参数。

## 安装

通过`pip`包管理器安装：

```bash
pip install mcarchive-api
poetry install mcarchive-api #或者使用Poetry
uv pip install mcarchive-api #或者使用uv
```

你也可以下载轮子并安装：

```bash
pip install ./mcarchive_api-x.x.x-py3-none-any.whl
```

或者克隆Git仓库并构建轮子：

```bash
git clone https://github.com/AngryMouse7891/mcarchive-api-python.git
cd mcarchive-api-python
uv build
```

## 使用方法

以下是该库所有模块的描述：

- `mcarchive_api.default`：获取Minecraft游戏版本和作者

- `mcarchive_api.mods`：获取所有模组以及通过特定slug获取

- `mcarchive_api.files`：通过文件名/SHA256哈希值获取文件

比如获取所有Minecraft游戏版本：

```python
from mcarchive_api.default import get_game_versions

print(f'Game Versions: {get_game_versions()}')
```

## 使用的依赖

| 包名                                          | 最新版本                                       | 描述                        |
| ------------------------------------------- | ------------------------------------------ | ------------------------- |
| [`httpx`](https://pypi.org/project/httpx)   | ![latest](https://img.shields.io/pypi/v/httpx)   | HTTP客户端                   |
| [`urllib3`](https://pypi.org/project/httpx) | ![latest](https://img.shields.io/pypi/v/urllib3) | 带有线程安全连接池、文件上传等功能的 HTTP 库 |

## 开源许可

使用[MIT许可证](https://choosealicense.com/zh/licenses/mit/)。
