================================================================
RepopackPy Output File
================================================================
This file was generated by RepopackPy on: 2025-04-19T14:56:22.156218
Purpose:
--------
This file contains a packed representation of the entire repository's contents.
It is designed to be easily consumable by AI systems for analysis, code review,
or other automated processes.
File Format:
------------
The content is organized as follows:
1. This header section
2. Repository structure
3. Multiple file entries, each consisting of:
a. A separator line (================)
b. The file path (File: path/to/file)
c. Another separator line
d. The full contents of the file
e. A blank line
Usage Guidelines:
-----------------
1. This file should be treated as read-only. Any changes should be made to the
original repository files, not this packed version.
2. When processing this file, use the separators and "File:" markers to
distinguish between different files in the repository.
3. Be aware that this file may contain sensitive information. Handle it with
the same level of security as you would the original repository.
Notes:
------
- Some files may have been excluded based on .gitignore rules and RepopackPy's
configuration.
- Binary files are not included in this packed representation. Please refer to
the Repository Structure section for a complete list of file paths, including
binary files.
For more information about RepopackPy, visit: https://github.com/abinthomasonline/repopack-py
================================================================
Repository Structure
================================================================
src/
mcp_reddit/
__init__.py
auth_helper.py
main.py
reddit_fetcher.py
.python-version
Dockerfile
LICENSE
README.es.md
README.md
pyproject.toml
start_mcp_reddit.sh
uv.lock
================================================================
Repository Files
================================================================
================
File: README.es.md
================
# Reddit Content API - Configuración y Uso
[](https://github.com/jlcases/mcp-reddit/stargazers)
[](https://github.com/jlcases/mcp-reddit/network/members)
Este proyecto proporciona herramientas MCP (Model Context Protocol) para interactuar con Reddit a través de Claude y Cursor.
## Características
- Lectura de posts populares de subreddits
- An√°lisis de discusiones de Reddit con sus comentarios
- Creación de posts en Reddit
- Adición de comentarios a posts o respuestas a comentarios
- Votación en posts y comentarios
## Requisitos
- Python 3.10+
- Una cuenta de Reddit
- Una aplicación de Reddit registrada (para obtener client_id y client_secret)
- Entorno virtual (venv o similar)
- Claude Desktop y/o Cursor (opcional pero recomendado)
## Instalación desde cero
Siga estos pasos cuidadosamente para evitar problemas de importación y configuración:
```bash
# 1. Clonar el repositorio
git clone https://github.com/tu-usuario/mcp-reddit.git
cd mcp-reddit
# 2. Crear y activar entorno virtual
python -m venv .venv
source .venv/bin/activate # En Windows: .venv\Scripts\activate
# 3. Instalar las dependencias (SIN instalar el paquete en modo editable)
pip install -r requirements.txt
# 4. Configurar las variables de entorno (ver m√°s abajo)
# Crear y editar el archivo .env
```
> ⚠️ **IMPORTANTE**: NO instalar el paquete en modo editable (`pip install -e .`)
> ya que puede causar problemas con la importación de módulos.
## Configuración del entorno
1. Crear un archivo `.env` en la raíz del proyecto con las siguientes variables:
```
REDDIT_CLIENT_ID=tu_client_id
REDDIT_CLIENT_SECRET=tu_client_secret
REDDIT_REFRESH_TOKEN=tu_refresh_token
```
2. Para obtener un refresh token, ejecutar:
```bash
python -m mcp_reddit.auth_helper
```
Sigue las instrucciones para autorizar la aplicación. El token obtenido se guardará automáticamente en el archivo `.env`.
## Estructura del proyecto
```
mcp-reddit/
│
├── src/
│ └── mcp_reddit/
│ ├── __init__.py
│ ├── main.py # Punto de entrada para el servidor MCP
│ ├── reddit_fetcher.py # Implementación de herramientas de Reddit
│ └── auth_helper.py # Ayudante para generar tokens de autenticación
│
├── .env # Variables de entorno (crear manualmente)
├── requirements.txt
├── setup.py
└── README.md
```
## Ejecución del servidor directamente
Para ejecutar manualmente (√∫til para desarrollo y pruebas):
```bash
cd /ruta/a/mcp-reddit
.venv/bin/python src/mcp_reddit/main.py
```
Deberías ver logs indicando:
- La inicialización del servidor
- Verificación de autenticación de Reddit
- Registro de las 10 herramientas (5 originales + 5 con prefijo)
- "Running MCP server..."
## Configuración de Claude Desktop
1. Localiza el archivo de configuración:
- En macOS: `/Users/tu-usuario/Library/Application Support/Claude/claude_desktop_config.json`
- En Windows: `%APPDATA%\Claude\claude_desktop_config.json`
2. Añade la configuración para reddit-content-api:
```json
"reddit-content-api": {
"command": "/ruta/completa/a/mcp-reddit/.venv/bin/python",
"args": [
"-m",
"mcp_reddit.main",
"--stdio"
],
"cwd": "/ruta/completa/a/mcp-reddit",
"env": {
"PYTHONPATH": "/ruta/completa/a/mcp-reddit/src:/ruta/completa/a/mcp-reddit",
"DEBUG": "true"
}
}
```
> ⚠️ **EXTREMADAMENTE IMPORTANTE**: `PYTHONPATH` debe incluir tanto el directorio `src` como la raíz del proyecto, en ese orden y separados por `:` (en Unix/macOS) o `;` (en Windows)
## Configuración de Cursor
1. Localiza el archivo de configuración:
- En macOS: `/Users/tu-usuario/.cursor/mcp.json`
- En Windows: `%USERPROFILE%\.cursor\mcp.json`
2. Añade la misma configuración que en Claude, ajustando las rutas según sea necesario.
## Solución de Problemas Comunes
### Problema: Solo aparecen 2 herramientas de las 10 esperadas
**Síntomas**: Al ejecutar el servidor aparecen solo 2 herramientas en lugar de las 10 esperadas.
**Causas posibles y soluciones**:
1. **Problema de importación**: Python está importando una versión instalada desde `site-packages` en lugar del código local en `src/`.
**Solución**:
- Aseg√∫rate de NO instalar el paquete en modo editable (`pip install -e .`)
- Añade explícitamente `src` al inicio de `PYTHONPATH` en las configuraciones
- Si ya lo instalaste, usa `pip uninstall reddit-content-api` para eliminarlo
2. **Caché de Python**: Los archivos `.pyc` antiguos pueden causar problemas.
**Solución**:
- Elimina todos los directorios `__pycache__` del proyecto
3. **Conflictos de versiones**: Diferentes versiones de una misma biblioteca.
**Solución**:
- Reinstala las dependencias con `pip install -r requirements.txt`
### Problema: "Cannot create post: Reddit authentication is not configured properly"
**Causa**: El token de actualización no es válido o ha expirado.
**Solución**: Regenera el token ejecutando `python -m mcp_reddit.auth_helper` y asegúrate de que se guarde en `.env`.
### Problema: Herramientas no aparecen en Claude/Cursor
**Causa**: Configuración incorrecta en los archivos de configuración.
**Solución**:
- Revisa las rutas y especialmente `PYTHONPATH` en los archivos de configuración
- Reinicia Claude/Cursor completamente después de modificar la configuración
## Uso de las herramientas en Claude/Cursor
Una vez configurado, puedes usar las siguientes herramientas:
1. `mcp_reddit_content_api_fetch_reddit_hot_threads` - Obtener posts populares
2. `mcp_reddit_content_api_fetch_reddit_post_content` - Analizar un post y sus comentarios
3. `mcp_reddit_content_api_create_reddit_post` - Crear un post nuevo
4. `mcp_reddit_content_api_add_reddit_comment` - Añadir un comentario
5. `mcp_reddit_content_api_vote_on_reddit_content` - Votar contenido
### Ejemplos
**Obtener posts populares**:
```
Subreddit: python
N√∫mero de posts: 5
```
**Crear un post**:
```
Subreddit: test
Título: Test desde MCP
Tipo de contenido: text
Contenido: Este es un test desde la API de contenido de Reddit usando MCP.
```
## Contribuciones
Si encuentras problemas o tienes mejoras, por favor crea un issue o envía un pull request.
## Licencia
[MIT](LICENSE)
## Apoya Este Proyecto
Si encuentras útil este proyecto en tu trabajo o investigación, por favor considera:
- ⭐ Darle una estrella al repositorio para mostrar tu apoyo
- üîÑ Seguir el repositorio para recibir actualizaciones sobre nuevas funcionalidades y mejoras
- üêõ Abrir issues para reportar errores o solicitar nuevas caracter√≠sticas
- üõ†Ô∏è Contribuir con pull requests si tienes mejoras para compartir
¬°Tu apoyo ayuda a hacer este proyecto mejor para todos!
================
File: LICENSE
================
MIT License
Copyright (c) 2024 Adhika Setya Pramudita
Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
in the Software without restriction, including without limitation the rights
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
copies of the Software, and to permit persons to whom the Software is
furnished to do so, subject to the following conditions:
The above copyright notice and this permission notice shall be included in all
copies or substantial portions of the Software.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
SOFTWARE.
================
File: uv.lock
================
version = 1
revision = 1
requires-python = ">=3.11"
[[package]]
name = "annotated-types"
version = "0.7.0"
source = { registry = "https://pypi.org/simple" }
sdist = { url = "https://files.pythonhosted.org/packages/ee/67/531ea369ba64dcff5ec9c3402f9f51bf748cec26dde048a2f973a4eea7f5/annotated_types-0.7.0.tar.gz", hash = "sha256:aff07c09a53a08bc8cfccb9c85b05f1aa9a2a6f23728d790723543408344ce89", size = 16081 }
wheels = [
{ url = "https://files.pythonhosted.org/packages/78/b6/6307fbef88d9b5ee7421e68d78a9f162e0da4900bc5f5793f6d3d0e34fb8/annotated_types-0.7.0-py3-none-any.whl", hash = "sha256:1f02e8b43a8fbbc3f3e0d4f0f4bfc8131bcb4eebe8849b8e5c773f3a1c582a53", size = 13643 },
]
[[package]]
name = "anyio"
version = "4.9.0"
source = { registry = "https://pypi.org/simple" }
dependencies = [
{ name = "idna" },
{ name = "sniffio" },
{ name = "typing-extensions", marker = "python_full_version < '3.13'" },
]
sdist = { url = "https://files.pythonhosted.org/packages/95/7d/4c1bd541d4dffa1b52bd83fb8527089e097a106fc90b467a7313b105f840/anyio-4.9.0.tar.gz", hash = "sha256:673c0c244e15788651a4ff38710fea9675823028a6f08a5eda409e0c9840a028", size = 190949 }
wheels = [
{ url = "https://files.pythonhosted.org/packages/a1/ee/48ca1a7c89ffec8b6a0c5d02b89c305671d5ffd8d3c94acf8b8c408575bb/anyio-4.9.0-py3-none-any.whl", hash = "sha256:9f76d541cad6e36af7beb62e978876f3b41e3e04f2c1fbf0884604c0a9c4d93c", size = 100916 },
]
[[package]]
name = "certifi"
version = "2024.8.30"
source = { registry = "https://pypi.org/simple" }
sdist = { url = "https://files.pythonhosted.org/packages/b0/ee/9b19140fe824b367c04c5e1b369942dd754c4c5462d5674002f75c4dedc1/certifi-2024.8.30.tar.gz", hash = "sha256:bec941d2aa8195e248a60b31ff9f0558284cf01a52591ceda73ea9afffd69fd9", size = 168507 }
wheels = [
{ url = "https://files.pythonhosted.org/packages/12/90/3c9ff0512038035f59d279fddeb79f5f1eccd8859f06d6163c58798b9487/certifi-2024.8.30-py3-none-any.whl", hash = "sha256:922820b53db7a7257ffbda3f597266d435245903d80737e34f8a45ff3e3230d8", size = 167321 },
]
[[package]]
name = "charset-normalizer"
version = "3.4.0"
source = { registry = "https://pypi.org/simple" }
sdist = { url = "https://files.pythonhosted.org/packages/f2/4f/e1808dc01273379acc506d18f1504eb2d299bd4131743b9fc54d7be4df1e/charset_normalizer-3.4.0.tar.gz", hash = "sha256:223217c3d4f82c3ac5e29032b3f1c2eb0fb591b72161f86d93f5719079dae93e", size = 106620 }
wheels = [
{ url = "https://files.pythonhosted.org/packages/9c/61/73589dcc7a719582bf56aae309b6103d2762b526bffe189d635a7fcfd998/charset_normalizer-3.4.0-cp311-cp311-macosx_10_9_universal2.whl", hash = "sha256:0d99dd8ff461990f12d6e42c7347fd9ab2532fb70e9621ba520f9e8637161d7c", size = 193339 },
{ url = "https://files.pythonhosted.org/packages/77/d5/8c982d58144de49f59571f940e329ad6e8615e1e82ef84584c5eeb5e1d72/charset_normalizer-3.4.0-cp311-cp311-macosx_10_9_x86_64.whl", hash = "sha256:c57516e58fd17d03ebe67e181a4e4e2ccab1168f8c2976c6a334d4f819fe5944", size = 124366 },
{ url = "https://files.pythonhosted.org/packages/bf/19/411a64f01ee971bed3231111b69eb56f9331a769072de479eae7de52296d/charset_normalizer-3.4.0-cp311-cp311-macosx_11_0_arm64.whl", hash = "sha256:6dba5d19c4dfab08e58d5b36304b3f92f3bd5d42c1a3fa37b5ba5cdf6dfcbcee", size = 118874 },
{ url = "https://files.pythonhosted.org/packages/4c/92/97509850f0d00e9f14a46bc751daabd0ad7765cff29cdfb66c68b6dad57f/charset_normalizer-3.4.0-cp311-cp311-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:bf4475b82be41b07cc5e5ff94810e6a01f276e37c2d55571e3fe175e467a1a1c", size = 138243 },
{ url = "https://files.pythonhosted.org/packages/e2/29/d227805bff72ed6d6cb1ce08eec707f7cfbd9868044893617eb331f16295/charset_normalizer-3.4.0-cp311-cp311-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl", hash = "sha256:ce031db0408e487fd2775d745ce30a7cd2923667cf3b69d48d219f1d8f5ddeb6", size = 148676 },
{ url = "https://files.pythonhosted.org/packages/13/bc/87c2c9f2c144bedfa62f894c3007cd4530ba4b5351acb10dc786428a50f0/charset_normalizer-3.4.0-cp311-cp311-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:8ff4e7cdfdb1ab5698e675ca622e72d58a6fa2a8aa58195de0c0061288e6e3ea", size = 141289 },
{ url = "https://files.pythonhosted.org/packages/eb/5b/6f10bad0f6461fa272bfbbdf5d0023b5fb9bc6217c92bf068fa5a99820f5/charset_normalizer-3.4.0-cp311-cp311-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:3710a9751938947e6327ea9f3ea6332a09bf0ba0c09cae9cb1f250bd1f1549bc", size = 142585 },
{ url = "https://files.pythonhosted.org/packages/3b/a0/a68980ab8a1f45a36d9745d35049c1af57d27255eff8c907e3add84cf68f/charset_normalizer-3.4.0-cp311-cp311-manylinux_2_5_i686.manylinux1_i686.manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:82357d85de703176b5587dbe6ade8ff67f9f69a41c0733cf2425378b49954de5", size = 144408 },
{ url = "https://files.pythonhosted.org/packages/d7/a1/493919799446464ed0299c8eef3c3fad0daf1c3cd48bff9263c731b0d9e2/charset_normalizer-3.4.0-cp311-cp311-musllinux_1_2_aarch64.whl", hash = "sha256:47334db71978b23ebcf3c0f9f5ee98b8d65992b65c9c4f2d34c2eaf5bcaf0594", size = 139076 },
{ url = "https://files.pythonhosted.org/packages/fb/9d/9c13753a5a6e0db4a0a6edb1cef7aee39859177b64e1a1e748a6e3ba62c2/charset_normalizer-3.4.0-cp311-cp311-musllinux_1_2_i686.whl", hash = "sha256:8ce7fd6767a1cc5a92a639b391891bf1c268b03ec7e021c7d6d902285259685c", size = 146874 },
{ url = "https://files.pythonhosted.org/packages/75/d2/0ab54463d3410709c09266dfb416d032a08f97fd7d60e94b8c6ef54ae14b/charset_normalizer-3.4.0-cp311-cp311-musllinux_1_2_ppc64le.whl", hash = "sha256:f1a2f519ae173b5b6a2c9d5fa3116ce16e48b3462c8b96dfdded11055e3d6365", size = 150871 },
{ url = "https://files.pythonhosted.org/packages/8d/c9/27e41d481557be53d51e60750b85aa40eaf52b841946b3cdeff363105737/charset_normalizer-3.4.0-cp311-cp311-musllinux_1_2_s390x.whl", hash = "sha256:63bc5c4ae26e4bc6be6469943b8253c0fd4e4186c43ad46e713ea61a0ba49129", size = 148546 },
{ url = "https://files.pythonhosted.org/packages/ee/44/4f62042ca8cdc0cabf87c0fc00ae27cd8b53ab68be3605ba6d071f742ad3/charset_normalizer-3.4.0-cp311-cp311-musllinux_1_2_x86_64.whl", hash = "sha256:bcb4f8ea87d03bc51ad04add8ceaf9b0f085ac045ab4d74e73bbc2dc033f0236", size = 143048 },
{ url = "https://files.pythonhosted.org/packages/01/f8/38842422988b795220eb8038745d27a675ce066e2ada79516c118f291f07/charset_normalizer-3.4.0-cp311-cp311-win32.whl", hash = "sha256:9ae4ef0b3f6b41bad6366fb0ea4fc1d7ed051528e113a60fa2a65a9abb5b1d99", size = 94389 },
{ url = "https://files.pythonhosted.org/packages/0b/6e/b13bd47fa9023b3699e94abf565b5a2f0b0be6e9ddac9812182596ee62e4/charset_normalizer-3.4.0-cp311-cp311-win_amd64.whl", hash = "sha256:cee4373f4d3ad28f1ab6290684d8e2ebdb9e7a1b74fdc39e4c211995f77bec27", size = 101752 },
{ url = "https://files.pythonhosted.org/packages/d3/0b/4b7a70987abf9b8196845806198975b6aab4ce016632f817ad758a5aa056/charset_normalizer-3.4.0-cp312-cp312-macosx_10_13_universal2.whl", hash = "sha256:0713f3adb9d03d49d365b70b84775d0a0d18e4ab08d12bc46baa6132ba78aaf6", size = 194445 },
{ url = "https://files.pythonhosted.org/packages/50/89/354cc56cf4dd2449715bc9a0f54f3aef3dc700d2d62d1fa5bbea53b13426/charset_normalizer-3.4.0-cp312-cp312-macosx_10_13_x86_64.whl", hash = "sha256:de7376c29d95d6719048c194a9cf1a1b0393fbe8488a22008610b0361d834ecf", size = 125275 },
{ url = "https://files.pythonhosted.org/packages/fa/44/b730e2a2580110ced837ac083d8ad222343c96bb6b66e9e4e706e4d0b6df/charset_normalizer-3.4.0-cp312-cp312-macosx_11_0_arm64.whl", hash = "sha256:4a51b48f42d9358460b78725283f04bddaf44a9358197b889657deba38f329db", size = 119020 },
{ url = "https://files.pythonhosted.org/packages/9d/e4/9263b8240ed9472a2ae7ddc3e516e71ef46617fe40eaa51221ccd4ad9a27/charset_normalizer-3.4.0-cp312-cp312-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:b295729485b06c1a0683af02a9e42d2caa9db04a373dc38a6a58cdd1e8abddf1", size = 139128 },
{ url = "https://files.pythonhosted.org/packages/6b/e3/9f73e779315a54334240353eaea75854a9a690f3f580e4bd85d977cb2204/charset_normalizer-3.4.0-cp312-cp312-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl", hash = "sha256:ee803480535c44e7f5ad00788526da7d85525cfefaf8acf8ab9a310000be4b03", size = 149277 },
{ url = "https://files.pythonhosted.org/packages/1a/cf/f1f50c2f295312edb8a548d3fa56a5c923b146cd3f24114d5adb7e7be558/charset_normalizer-3.4.0-cp312-cp312-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:3d59d125ffbd6d552765510e3f31ed75ebac2c7470c7274195b9161a32350284", size = 142174 },
{ url = "https://files.pythonhosted.org/packages/16/92/92a76dc2ff3a12e69ba94e7e05168d37d0345fa08c87e1fe24d0c2a42223/charset_normalizer-3.4.0-cp312-cp312-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:8cda06946eac330cbe6598f77bb54e690b4ca93f593dee1568ad22b04f347c15", size = 143838 },
{ url = "https://files.pythonhosted.org/packages/a4/01/2117ff2b1dfc61695daf2babe4a874bca328489afa85952440b59819e9d7/charset_normalizer-3.4.0-cp312-cp312-manylinux_2_5_i686.manylinux1_i686.manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:07afec21bbbbf8a5cc3651aa96b980afe2526e7f048fdfb7f1014d84acc8b6d8", size = 146149 },
{ url = "https://files.pythonhosted.org/packages/f6/9b/93a332b8d25b347f6839ca0a61b7f0287b0930216994e8bf67a75d050255/charset_normalizer-3.4.0-cp312-cp312-musllinux_1_2_aarch64.whl", hash = "sha256:6b40e8d38afe634559e398cc32b1472f376a4099c75fe6299ae607e404c033b2", size = 140043 },
{ url = "https://files.pythonhosted.org/packages/ab/f6/7ac4a01adcdecbc7a7587767c776d53d369b8b971382b91211489535acf0/charset_normalizer-3.4.0-cp312-cp312-musllinux_1_2_i686.whl", hash = "sha256:b8dcd239c743aa2f9c22ce674a145e0a25cb1566c495928440a181ca1ccf6719", size = 148229 },
{ url = "https://files.pythonhosted.org/packages/9d/be/5708ad18161dee7dc6a0f7e6cf3a88ea6279c3e8484844c0590e50e803ef/charset_normalizer-3.4.0-cp312-cp312-musllinux_1_2_ppc64le.whl", hash = "sha256:84450ba661fb96e9fd67629b93d2941c871ca86fc38d835d19d4225ff946a631", size = 151556 },
{ url = "https://files.pythonhosted.org/packages/5a/bb/3d8bc22bacb9eb89785e83e6723f9888265f3a0de3b9ce724d66bd49884e/charset_normalizer-3.4.0-cp312-cp312-musllinux_1_2_s390x.whl", hash = "sha256:44aeb140295a2f0659e113b31cfe92c9061622cadbc9e2a2f7b8ef6b1e29ef4b", size = 149772 },
{ url = "https://files.pythonhosted.org/packages/f7/fa/d3fc622de05a86f30beea5fc4e9ac46aead4731e73fd9055496732bcc0a4/charset_normalizer-3.4.0-cp312-cp312-musllinux_1_2_x86_64.whl", hash = "sha256:1db4e7fefefd0f548d73e2e2e041f9df5c59e178b4c72fbac4cc6f535cfb1565", size = 144800 },
{ url = "https://files.pythonhosted.org/packages/9a/65/bdb9bc496d7d190d725e96816e20e2ae3a6fa42a5cac99c3c3d6ff884118/charset_normalizer-3.4.0-cp312-cp312-win32.whl", hash = "sha256:5726cf76c982532c1863fb64d8c6dd0e4c90b6ece9feb06c9f202417a31f7dd7", size = 94836 },
{ url = "https://files.pythonhosted.org/packages/3e/67/7b72b69d25b89c0b3cea583ee372c43aa24df15f0e0f8d3982c57804984b/charset_normalizer-3.4.0-cp312-cp312-win_amd64.whl", hash = "sha256:b197e7094f232959f8f20541ead1d9862ac5ebea1d58e9849c1bf979255dfac9", size = 102187 },
{ url = "https://files.pythonhosted.org/packages/f3/89/68a4c86f1a0002810a27f12e9a7b22feb198c59b2f05231349fbce5c06f4/charset_normalizer-3.4.0-cp313-cp313-macosx_10_13_universal2.whl", hash = "sha256:dd4eda173a9fcccb5f2e2bd2a9f423d180194b1bf17cf59e3269899235b2a114", size = 194617 },
{ url = "https://files.pythonhosted.org/packages/4f/cd/8947fe425e2ab0aa57aceb7807af13a0e4162cd21eee42ef5b053447edf5/charset_normalizer-3.4.0-cp313-cp313-macosx_10_13_x86_64.whl", hash = "sha256:e9e3c4c9e1ed40ea53acf11e2a386383c3304212c965773704e4603d589343ed", size = 125310 },
{ url = "https://files.pythonhosted.org/packages/5b/f0/b5263e8668a4ee9becc2b451ed909e9c27058337fda5b8c49588183c267a/charset_normalizer-3.4.0-cp313-cp313-macosx_11_0_arm64.whl", hash = "sha256:92a7e36b000bf022ef3dbb9c46bfe2d52c047d5e3f3343f43204263c5addc250", size = 119126 },
{ url = "https://files.pythonhosted.org/packages/ff/6e/e445afe4f7fda27a533f3234b627b3e515a1b9429bc981c9a5e2aa5d97b6/charset_normalizer-3.4.0-cp313-cp313-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:54b6a92d009cbe2fb11054ba694bc9e284dad30a26757b1e372a1fdddaf21920", size = 139342 },
{ url = "https://files.pythonhosted.org/packages/a1/b2/4af9993b532d93270538ad4926c8e37dc29f2111c36f9c629840c57cd9b3/charset_normalizer-3.4.0-cp313-cp313-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl", hash = "sha256:1ffd9493de4c922f2a38c2bf62b831dcec90ac673ed1ca182fe11b4d8e9f2a64", size = 149383 },
{ url = "https://files.pythonhosted.org/packages/fb/6f/4e78c3b97686b871db9be6f31d64e9264e889f8c9d7ab33c771f847f79b7/charset_normalizer-3.4.0-cp313-cp313-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:35c404d74c2926d0287fbd63ed5d27eb911eb9e4a3bb2c6d294f3cfd4a9e0c23", size = 142214 },
{ url = "https://files.pythonhosted.org/packages/2b/c9/1c8fe3ce05d30c87eff498592c89015b19fade13df42850aafae09e94f35/charset_normalizer-3.4.0-cp313-cp313-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:4796efc4faf6b53a18e3d46343535caed491776a22af773f366534056c4e1fbc", size = 144104 },
{ url = "https://files.pythonhosted.org/packages/ee/68/efad5dcb306bf37db7db338338e7bb8ebd8cf38ee5bbd5ceaaaa46f257e6/charset_normalizer-3.4.0-cp313-cp313-manylinux_2_5_i686.manylinux1_i686.manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:e7fdd52961feb4c96507aa649550ec2a0d527c086d284749b2f582f2d40a2e0d", size = 146255 },
{ url = "https://files.pythonhosted.org/packages/0c/75/1ed813c3ffd200b1f3e71121c95da3f79e6d2a96120163443b3ad1057505/charset_normalizer-3.4.0-cp313-cp313-musllinux_1_2_aarch64.whl", hash = "sha256:92db3c28b5b2a273346bebb24857fda45601aef6ae1c011c0a997106581e8a88", size = 140251 },
{ url = "https://files.pythonhosted.org/packages/7d/0d/6f32255c1979653b448d3c709583557a4d24ff97ac4f3a5be156b2e6a210/charset_normalizer-3.4.0-cp313-cp313-musllinux_1_2_i686.whl", hash = "sha256:ab973df98fc99ab39080bfb0eb3a925181454d7c3ac8a1e695fddfae696d9e90", size = 148474 },
{ url = "https://files.pythonhosted.org/packages/ac/a0/c1b5298de4670d997101fef95b97ac440e8c8d8b4efa5a4d1ef44af82f0d/charset_normalizer-3.4.0-cp313-cp313-musllinux_1_2_ppc64le.whl", hash = "sha256:4b67fdab07fdd3c10bb21edab3cbfe8cf5696f453afce75d815d9d7223fbe88b", size = 151849 },
{ url = "https://files.pythonhosted.org/packages/04/4f/b3961ba0c664989ba63e30595a3ed0875d6790ff26671e2aae2fdc28a399/charset_normalizer-3.4.0-cp313-cp313-musllinux_1_2_s390x.whl", hash = "sha256:aa41e526a5d4a9dfcfbab0716c7e8a1b215abd3f3df5a45cf18a12721d31cb5d", size = 149781 },
{ url = "https://files.pythonhosted.org/packages/d8/90/6af4cd042066a4adad58ae25648a12c09c879efa4849c705719ba1b23d8c/charset_normalizer-3.4.0-cp313-cp313-musllinux_1_2_x86_64.whl", hash = "sha256:ffc519621dce0c767e96b9c53f09c5d215578e10b02c285809f76509a3931482", size = 144970 },
{ url = "https://files.pythonhosted.org/packages/cc/67/e5e7e0cbfefc4ca79025238b43cdf8a2037854195b37d6417f3d0895c4c2/charset_normalizer-3.4.0-cp313-cp313-win32.whl", hash = "sha256:f19c1585933c82098c2a520f8ec1227f20e339e33aca8fa6f956f6691b784e67", size = 94973 },
{ url = "https://files.pythonhosted.org/packages/65/97/fc9bbc54ee13d33dc54a7fcf17b26368b18505500fc01e228c27b5222d80/charset_normalizer-3.4.0-cp313-cp313-win_amd64.whl", hash = "sha256:707b82d19e65c9bd28b81dde95249b07bf9f5b90ebe1ef17d9b57473f8a64b7b", size = 102308 },
{ url = "https://files.pythonhosted.org/packages/bf/9b/08c0432272d77b04803958a4598a51e2a4b51c06640af8b8f0f908c18bf2/charset_normalizer-3.4.0-py3-none-any.whl", hash = "sha256:fe9f97feb71aa9896b81973a7bbada8c49501dc73e58a10fcef6663af95e5079", size = 49446 },
]
[[package]]
name = "click"
version = "8.1.8"
source = { registry = "https://pypi.org/simple" }
dependencies = [
{ name = "colorama", marker = "sys_platform == 'win32'" },
]
sdist = { url = "https://files.pythonhosted.org/packages/b9/2e/0090cbf739cee7d23781ad4b89a9894a41538e4fcf4c31dcdd705b78eb8b/click-8.1.8.tar.gz", hash = "sha256:ed53c9d8990d83c2a27deae68e4ee337473f6330c040a31d4225c9574d16096a", size = 226593 }
wheels = [
{ url = "https://files.pythonhosted.org/packages/7e/d4/7ebdbd03970677812aac39c869717059dbb71a4cfc033ca6e5221787892c/click-8.1.8-py3-none-any.whl", hash = "sha256:63c132bbbed01578a06712a2d1f497bb62d9c1c0d329b7903a866228027263b2", size = 98188 },
]
[[package]]
name = "colorama"
version = "0.4.6"
source = { registry = "https://pypi.org/simple" }
sdist = { url = "https://files.pythonhosted.org/packages/d8/53/6f443c9a4a8358a93a6792e2acffb9d9d5cb0a5cfd8802644b7b1c9a02e4/colorama-0.4.6.tar.gz", hash = "sha256:08695f5cb7ed6e0531a20572697297273c47b8cae5a63ffc6d6ed5c201be6e44", size = 27697 }
wheels = [
{ url = "https://files.pythonhosted.org/packages/d1/d6/3965ed04c63042e047cb6a3e6ed1a63a35087b6a609aa3a15ed8ac56c221/colorama-0.4.6-py2.py3-none-any.whl", hash = "sha256:4f1d9991f5acc0ca119f9d443620b77f9d6b33703e51011c16baf57afb285fc6", size = 25335 },
]
[[package]]
name = "dnspython"
version = "2.7.0"
source = { registry = "https://pypi.org/simple" }
sdist = { url = "https://files.pythonhosted.org/packages/b5/4a/263763cb2ba3816dd94b08ad3a33d5fdae34ecb856678773cc40a3605829/dnspython-2.7.0.tar.gz", hash = "sha256:ce9c432eda0dc91cf618a5cedf1a4e142651196bbcd2c80e89ed5a907e5cfaf1", size = 345197 }
wheels = [
{ url = "https://files.pythonhosted.org/packages/68/1b/e0a87d256e40e8c888847551b20a017a6b98139178505dc7ffb96f04e954/dnspython-2.7.0-py3-none-any.whl", hash = "sha256:b4c34b7d10b51bcc3a5071e7b8dee77939f1e878477eeecc965e9835f63c6c86", size = 313632 },
]
[[package]]
name = "fastmcp"
version = "0.4.1"
source = { registry = "https://pypi.org/simple" }
dependencies = [
{ name = "httpx" },
{ name = "mcp" },
{ name = "pydantic" },
{ name = "pydantic-settings" },
{ name = "python-dotenv" },
{ name = "typer" },
]
sdist = { url = "https://files.pythonhosted.org/packages/6f/84/17b549133263d7ee77141970769bbc401525526bf1af043ea6842bce1a55/fastmcp-0.4.1.tar.gz", hash = "sha256:713ad3b8e4e04841c9e2f3ca022b053adb89a286ceffad0d69ae7b56f31cbe64", size = 785575 }
wheels = [
{ url = "https://files.pythonhosted.org/packages/79/0b/008a340435fe8f0879e9d608f48af2737ad48440e09bd33b83b3fd03798b/fastmcp-0.4.1-py3-none-any.whl", hash = "sha256:664b42c376fb89ec90a50c9433f5a1f4d24f36696d6c41b024b427ae545f9619", size = 35282 },
]
[[package]]
name = "h11"
version = "0.14.0"
source = { registry = "https://pypi.org/simple" }
sdist = { url = "https://files.pythonhosted.org/packages/f5/38/3af3d3633a34a3316095b39c8e8fb4853a28a536e55d347bd8d8e9a14b03/h11-0.14.0.tar.gz", hash = "sha256:8f19fbbe99e72420ff35c00b27a34cb9937e902a8b810e2c88300c6f0a3b699d", size = 100418 }
wheels = [
{ url = "https://files.pythonhosted.org/packages/95/04/ff642e65ad6b90db43e668d70ffb6736436c7ce41fcc549f4e9472234127/h11-0.14.0-py3-none-any.whl", hash = "sha256:e3fe4ac4b851c468cc8363d500db52c2ead036020723024a109d37346efaa761", size = 58259 },
]
[[package]]
name = "httpcore"
version = "1.0.7"
source = { registry = "https://pypi.org/simple" }
dependencies = [
{ name = "certifi" },
{ name = "h11" },
]
sdist = { url = "https://files.pythonhosted.org/packages/6a/41/d7d0a89eb493922c37d343b607bc1b5da7f5be7e383740b4753ad8943e90/httpcore-1.0.7.tar.gz", hash = "sha256:8551cb62a169ec7162ac7be8d4817d561f60e08eaa485234898414bb5a8a0b4c", size = 85196 }
wheels = [
{ url = "https://files.pythonhosted.org/packages/87/f5/72347bc88306acb359581ac4d52f23c0ef445b57157adedb9aee0cd689d2/httpcore-1.0.7-py3-none-any.whl", hash = "sha256:a3fff8f43dc260d5bd363d9f9cf1830fa3a458b332856f34282de498ed420edd", size = 78551 },
]
[[package]]
name = "httpx"
version = "0.28.1"
source = { registry = "https://pypi.org/simple" }
dependencies = [
{ name = "anyio" },
{ name = "certifi" },
{ name = "httpcore" },
{ name = "idna" },
]
sdist = { url = "https://files.pythonhosted.org/packages/b1/df/48c586a5fe32a0f01324ee087459e112ebb7224f646c0b5023f5e79e9956/httpx-0.28.1.tar.gz", hash = "sha256:75e98c5f16b0f35b567856f597f06ff2270a374470a5c2392242528e3e3e42fc", size = 141406 }
wheels = [
{ url = "https://files.pythonhosted.org/packages/2a/39/e50c7c3a983047577ee07d2a9e53faf5a69493943ec3f6a384bdc792deb2/httpx-0.28.1-py3-none-any.whl", hash = "sha256:d909fcccc110f8c7faf814ca82a9a4d816bc5a6dbfea25d6591d6985b8ba59ad", size = 73517 },
]
[[package]]
name = "httpx-sse"
version = "0.4.0"
source = { registry = "https://pypi.org/simple" }
sdist = { url = "https://files.pythonhosted.org/packages/4c/60/8f4281fa9bbf3c8034fd54c0e7412e66edbab6bc74c4996bd616f8d0406e/httpx-sse-0.4.0.tar.gz", hash = "sha256:1e81a3a3070ce322add1d3529ed42eb5f70817f45ed6ec915ab753f961139721", size = 12624 }
wheels = [
{ url = "https://files.pythonhosted.org/packages/e1/9b/a181f281f65d776426002f330c31849b86b31fc9d848db62e16f03ff739f/httpx_sse-0.4.0-py3-none-any.whl", hash = "sha256:f329af6eae57eaa2bdfd962b42524764af68075ea87370a2de920af5341e318f", size = 7819 },
]
[[package]]
name = "idna"
version = "3.10"
source = { registry = "https://pypi.org/simple" }
sdist = { url = "https://files.pythonhosted.org/packages/f1/70/7703c29685631f5a7590aa73f1f1d3fa9a380e654b86af429e0934a32f7d/idna-3.10.tar.gz", hash = "sha256:12f65c9b470abda6dc35cf8e63cc574b1c52b11df2c86030af0ac09b01b13ea9", size = 190490 }
wheels = [
{ url = "https://files.pythonhosted.org/packages/76/c6/c88e154df9c4e1a2a66ccf0005a88dfb2650c1dffb6f5ce603dfbd452ce3/idna-3.10-py3-none-any.whl", hash = "sha256:946d195a0d259cbba61165e88e65941f16e9b36ea6ddb97f00452bae8b1287d3", size = 70442 },
]
[[package]]
name = "markdown-it-py"
version = "3.0.0"
source = { registry = "https://pypi.org/simple" }
dependencies = [
{ name = "mdurl" },
]
sdist = { url = "https://files.pythonhosted.org/packages/38/71/3b932df36c1a044d397a1f92d1cf91ee0a503d91e470cbd670aa66b07ed0/markdown-it-py-3.0.0.tar.gz", hash = "sha256:e3f60a94fa066dc52ec76661e37c851cb232d92f9886b15cb560aaada2df8feb", size = 74596 }
wheels = [
{ url = "https://files.pythonhosted.org/packages/42/d7/1ec15b46af6af88f19b8e5ffea08fa375d433c998b8a7639e76935c14f1f/markdown_it_py-3.0.0-py3-none-any.whl", hash = "sha256:355216845c60bd96232cd8d8c40e8f9765cc86f46880e43a8fd22dc1a1a8cab1", size = 87528 },
]
[[package]]
name = "mcp"
version = "1.6.0"
source = { registry = "https://pypi.org/simple" }
dependencies = [
{ name = "anyio" },
{ name = "httpx" },
{ name = "httpx-sse" },
{ name = "pydantic" },
{ name = "pydantic-settings" },
{ name = "sse-starlette" },
{ name = "starlette" },
{ name = "uvicorn" },
]
sdist = { url = "https://files.pythonhosted.org/packages/95/d2/f587cb965a56e992634bebc8611c5b579af912b74e04eb9164bd49527d21/mcp-1.6.0.tar.gz", hash = "sha256:d9324876de2c5637369f43161cd71eebfd803df5a95e46225cab8d280e366723", size = 200031 }
wheels = [
{ url = "https://files.pythonhosted.org/packages/10/30/20a7f33b0b884a9d14dd3aa94ff1ac9da1479fe2ad66dd9e2736075d2506/mcp-1.6.0-py3-none-any.whl", hash = "sha256:7bd24c6ea042dbec44c754f100984d186620d8b841ec30f1b19eda9b93a634d0", size = 76077 },
]
[[package]]
name = "mcp-reddit-server"
version = "0.1.0"
source = { editable = "." }
dependencies = [
{ name = "dnspython" },
{ name = "fastmcp" },
{ name = "praw" },
{ name = "redditwarp" },
{ name = "uvicorn" },
]
[package.metadata]
requires-dist = [
{ name = "dnspython", specifier = ">=2.7.0" },
{ name = "fastmcp", specifier = ">=0.1.0" },
{ name = "praw", specifier = ">=7.8.1" },
{ name = "redditwarp", specifier = ">=1.3.0" },
{ name = "uvicorn" },
]
[[package]]
name = "mdurl"
version = "0.1.2"
source = { registry = "https://pypi.org/simple" }
sdist = { url = "https://files.pythonhosted.org/packages/d6/54/cfe61301667036ec958cb99bd3efefba235e65cdeb9c84d24a8293ba1d90/mdurl-0.1.2.tar.gz", hash = "sha256:bb413d29f5eea38f31dd4754dd7377d4465116fb207585f97bf925588687c1ba", size = 8729 }
wheels = [
{ url = "https://files.pythonhosted.org/packages/b3/38/89ba8ad64ae25be8de66a6d463314cf1eb366222074cfda9ee839c56a4b4/mdurl-0.1.2-py3-none-any.whl", hash = "sha256:84008a41e51615a49fc9966191ff91509e3c40b939176e643fd50a5c2196b8f8", size = 9979 },
]
[[package]]
name = "praw"
version = "7.8.1"
source = { registry = "https://pypi.org/simple" }
dependencies = [
{ name = "prawcore" },
{ name = "update-checker" },
{ name = "websocket-client" },
]
sdist = { url = "https://files.pythonhosted.org/packages/4c/52/7dd0b3d9ccb78e90236420ef6c51b6d9b2400a7229442f0cfcf2258cce21/praw-7.8.1.tar.gz", hash = "sha256:3c5767909f71e48853eb6335fef7b50a43cbe3da728cdfb16d3be92904b0a4d8", size = 154106 }
wheels = [
{ url = "https://files.pythonhosted.org/packages/73/ca/60ec131c3b43bff58261167045778b2509b83922ce8f935ac89d871bd3ea/praw-7.8.1-py3-none-any.whl", hash = "sha256:15917a81a06e20ff0aaaf1358481f4588449fa2421233040cb25e5c8202a3e2f", size = 189338 },
]
[[package]]
name = "prawcore"
version = "2.4.0"
source = { registry = "https://pypi.org/simple" }
dependencies = [
{ name = "requests" },
]
sdist = { url = "https://files.pythonhosted.org/packages/8a/62/d4c99cf472205f1e5da846b058435a6a7c988abf8eb6f7d632a7f32f4a77/prawcore-2.4.0.tar.gz", hash = "sha256:b7b2b5a1d04406e086ab4e79988dc794df16059862f329f4c6a43ed09986c335", size = 15862 }
wheels = [
{ url = "https://files.pythonhosted.org/packages/96/5c/8af904314e42d5401afcfaff69940dc448e974f80f7aa39b241a4fbf0cf1/prawcore-2.4.0-py3-none-any.whl", hash = "sha256:29af5da58d85704b439ad3c820873ad541f4535e00bb98c66f0fbcc8c603065a", size = 17203 },
]
[[package]]
name = "pydantic"
version = "2.11.1"
source = { registry = "https://pypi.org/simple" }
dependencies = [
{ name = "annotated-types" },
{ name = "pydantic-core" },
{ name = "typing-extensions" },
{ name = "typing-inspection" },
]
sdist = { url = "https://files.pythonhosted.org/packages/93/a3/698b87a4d4d303d7c5f62ea5fbf7a79cab236ccfbd0a17847b7f77f8163e/pydantic-2.11.1.tar.gz", hash = "sha256:442557d2910e75c991c39f4b4ab18963d57b9b55122c8b2a9cd176d8c29ce968", size = 782817 }
wheels = [
{ url = "https://files.pythonhosted.org/packages/cc/12/f9221a949f2419e2e23847303c002476c26fbcfd62dc7f3d25d0bec5ca99/pydantic-2.11.1-py3-none-any.whl", hash = "sha256:5b6c415eee9f8123a14d859be0c84363fec6b1feb6b688d6435801230b56e0b8", size = 442648 },
]
[[package]]
name = "pydantic-core"
version = "2.33.0"
source = { registry = "https://pypi.org/simple" }
dependencies = [
{ name = "typing-extensions" },
]
sdist = { url = "https://files.pythonhosted.org/packages/b9/05/91ce14dfd5a3a99555fce436318cc0fd1f08c4daa32b3248ad63669ea8b4/pydantic_core-2.33.0.tar.gz", hash = "sha256:40eb8af662ba409c3cbf4a8150ad32ae73514cd7cb1f1a2113af39763dd616b3", size = 434080 }
wheels = [
{ url = "https://files.pythonhosted.org/packages/f0/93/9e97af2619b4026596487a79133e425c7d3c374f0a7f100f3d76bcdf9c83/pydantic_core-2.33.0-cp311-cp311-macosx_10_12_x86_64.whl", hash = "sha256:a608a75846804271cf9c83e40bbb4dab2ac614d33c6fd5b0c6187f53f5c593ef", size = 2042784 },
{ url = "https://files.pythonhosted.org/packages/42/b4/0bba8412fd242729feeb80e7152e24f0e1a1c19f4121ca3d4a307f4e6222/pydantic_core-2.33.0-cp311-cp311-macosx_11_0_arm64.whl", hash = "sha256:e1c69aa459f5609dec2fa0652d495353accf3eda5bdb18782bc5a2ae45c9273a", size = 1858179 },
{ url = "https://files.pythonhosted.org/packages/69/1f/c1c40305d929bd08af863df64b0a26203b70b352a1962d86f3bcd52950fe/pydantic_core-2.33.0-cp311-cp311-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:b9ec80eb5a5f45a2211793f1c4aeddff0c3761d1c70d684965c1807e923a588b", size = 1909396 },
{ url = "https://files.pythonhosted.org/packages/0f/99/d2e727375c329c1e652b5d450fbb9d56e8c3933a397e4bd46e67c68c2cd5/pydantic_core-2.33.0-cp311-cp311-manylinux_2_17_armv7l.manylinux2014_armv7l.whl", hash = "sha256:e925819a98318d17251776bd3d6aa9f3ff77b965762155bdad15d1a9265c4cfd", size = 1998264 },
{ url = "https://files.pythonhosted.org/packages/9c/2e/3119a33931278d96ecc2e9e1b9d50c240636cfeb0c49951746ae34e4de74/pydantic_core-2.33.0-cp311-cp311-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl", hash = "sha256:5bf68bb859799e9cec3d9dd8323c40c00a254aabb56fe08f907e437005932f2b", size = 2140588 },
{ url = "https://files.pythonhosted.org/packages/35/bd/9267bd1ba55f17c80ef6cb7e07b3890b4acbe8eb6014f3102092d53d9300/pydantic_core-2.33.0-cp311-cp311-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:1b2ea72dea0825949a045fa4071f6d5b3d7620d2a208335207793cf29c5a182d", size = 2746296 },
{ url = "https://files.pythonhosted.org/packages/6f/ed/ef37de6478a412ee627cbebd73e7b72a680f45bfacce9ff1199de6e17e88/pydantic_core-2.33.0-cp311-cp311-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:1583539533160186ac546b49f5cde9ffc928062c96920f58bd95de32ffd7bffd", size = 2005555 },
{ url = "https://files.pythonhosted.org/packages/dd/84/72c8d1439585d8ee7bc35eb8f88a04a4d302ee4018871f1f85ae1b0c6625/pydantic_core-2.33.0-cp311-cp311-manylinux_2_5_i686.manylinux1_i686.whl", hash = "sha256:23c3e77bf8a7317612e5c26a3b084c7edeb9552d645742a54a5867635b4f2453", size = 2124452 },
{ url = "https://files.pythonhosted.org/packages/a7/8f/cb13de30c6a3e303423751a529a3d1271c2effee4b98cf3e397a66ae8498/pydantic_core-2.33.0-cp311-cp311-musllinux_1_1_aarch64.whl", hash = "sha256:a7a7f2a3f628d2f7ef11cb6188bcf0b9e1558151d511b974dfea10a49afe192b", size = 2087001 },
{ url = "https://files.pythonhosted.org/packages/83/d0/e93dc8884bf288a63fedeb8040ac8f29cb71ca52e755f48e5170bb63e55b/pydantic_core-2.33.0-cp311-cp311-musllinux_1_1_armv7l.whl", hash = "sha256:f1fb026c575e16f673c61c7b86144517705865173f3d0907040ac30c4f9f5915", size = 2261663 },
{ url = "https://files.pythonhosted.org/packages/4c/ba/4b7739c95efa0b542ee45fd872c8f6b1884ab808cf04ce7ac6621b6df76e/pydantic_core-2.33.0-cp311-cp311-musllinux_1_1_x86_64.whl", hash = "sha256:635702b2fed997e0ac256b2cfbdb4dd0bf7c56b5d8fba8ef03489c03b3eb40e2", size = 2257786 },
{ url = "https://files.pythonhosted.org/packages/cc/98/73cbca1d2360c27752cfa2fcdcf14d96230e92d7d48ecd50499865c56bf7/pydantic_core-2.33.0-cp311-cp311-win32.whl", hash = "sha256:07b4ced28fccae3f00626eaa0c4001aa9ec140a29501770a88dbbb0966019a86", size = 1925697 },
{ url = "https://files.pythonhosted.org/packages/9a/26/d85a40edeca5d8830ffc33667d6fef329fd0f4bc0c5181b8b0e206cfe488/pydantic_core-2.33.0-cp311-cp311-win_amd64.whl", hash = "sha256:4927564be53239a87770a5f86bdc272b8d1fbb87ab7783ad70255b4ab01aa25b", size = 1949859 },
{ url = "https://files.pythonhosted.org/packages/7e/0b/5a381605f0b9870465b805f2c86c06b0a7c191668ebe4117777306c2c1e5/pydantic_core-2.33.0-cp311-cp311-win_arm64.whl", hash = "sha256:69297418ad644d521ea3e1aa2e14a2a422726167e9ad22b89e8f1130d68e1e9a", size = 1907978 },
{ url = "https://files.pythonhosted.org/packages/a9/c4/c9381323cbdc1bb26d352bc184422ce77c4bc2f2312b782761093a59fafc/pydantic_core-2.33.0-cp312-cp312-macosx_10_12_x86_64.whl", hash = "sha256:6c32a40712e3662bebe524abe8abb757f2fa2000028d64cc5a1006016c06af43", size = 2025127 },
{ url = "https://files.pythonhosted.org/packages/6f/bd/af35278080716ecab8f57e84515c7dc535ed95d1c7f52c1c6f7b313a9dab/pydantic_core-2.33.0-cp312-cp312-macosx_11_0_arm64.whl", hash = "sha256:8ec86b5baa36f0a0bfb37db86c7d52652f8e8aa076ab745ef7725784183c3fdd", size = 1851687 },
{ url = "https://files.pythonhosted.org/packages/12/e4/a01461225809c3533c23bd1916b1e8c2e21727f0fea60ab1acbffc4e2fca/pydantic_core-2.33.0-cp312-cp312-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:4deac83a8cc1d09e40683be0bc6d1fa4cde8df0a9bf0cda5693f9b0569ac01b6", size = 1892232 },
{ url = "https://files.pythonhosted.org/packages/51/17/3d53d62a328fb0a49911c2962036b9e7a4f781b7d15e9093c26299e5f76d/pydantic_core-2.33.0-cp312-cp312-manylinux_2_17_armv7l.manylinux2014_armv7l.whl", hash = "sha256:175ab598fb457a9aee63206a1993874badf3ed9a456e0654273e56f00747bbd6", size = 1977896 },
{ url = "https://files.pythonhosted.org/packages/30/98/01f9d86e02ec4a38f4b02086acf067f2c776b845d43f901bd1ee1c21bc4b/pydantic_core-2.33.0-cp312-cp312-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl", hash = "sha256:5f36afd0d56a6c42cf4e8465b6441cf546ed69d3a4ec92724cc9c8c61bd6ecf4", size = 2127717 },
{ url = "https://files.pythonhosted.org/packages/3c/43/6f381575c61b7c58b0fd0b92134c5a1897deea4cdfc3d47567b3ff460a4e/pydantic_core-2.33.0-cp312-cp312-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:0a98257451164666afafc7cbf5fb00d613e33f7e7ebb322fbcd99345695a9a61", size = 2680287 },
{ url = "https://files.pythonhosted.org/packages/01/42/c0d10d1451d161a9a0da9bbef023b8005aa26e9993a8cc24dc9e3aa96c93/pydantic_core-2.33.0-cp312-cp312-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:ecc6d02d69b54a2eb83ebcc6f29df04957f734bcf309d346b4f83354d8376862", size = 2008276 },
{ url = "https://files.pythonhosted.org/packages/20/ca/e08df9dba546905c70bae44ced9f3bea25432e34448d95618d41968f40b7/pydantic_core-2.33.0-cp312-cp312-manylinux_2_5_i686.manylinux1_i686.whl", hash = "sha256:1a69b7596c6603afd049ce7f3835bcf57dd3892fc7279f0ddf987bebed8caa5a", size = 2115305 },
{ url = "https://files.pythonhosted.org/packages/03/1f/9b01d990730a98833113581a78e595fd40ed4c20f9693f5a658fb5f91eff/pydantic_core-2.33.0-cp312-cp312-musllinux_1_1_aarch64.whl", hash = "sha256:ea30239c148b6ef41364c6f51d103c2988965b643d62e10b233b5efdca8c0099", size = 2068999 },
{ url = "https://files.pythonhosted.org/packages/20/18/fe752476a709191148e8b1e1139147841ea5d2b22adcde6ee6abb6c8e7cf/pydantic_core-2.33.0-cp312-cp312-musllinux_1_1_armv7l.whl", hash = "sha256:abfa44cf2f7f7d7a199be6c6ec141c9024063205545aa09304349781b9a125e6", size = 2241488 },
{ url = "https://files.pythonhosted.org/packages/81/22/14738ad0a0bf484b928c9e52004f5e0b81dd8dabbdf23b843717b37a71d1/pydantic_core-2.33.0-cp312-cp312-musllinux_1_1_x86_64.whl", hash = "sha256:20d4275f3c4659d92048c70797e5fdc396c6e4446caf517ba5cad2db60cd39d3", size = 2248430 },
{ url = "https://files.pythonhosted.org/packages/e8/27/be7571e215ac8d321712f2433c445b03dbcd645366a18f67b334df8912bc/pydantic_core-2.33.0-cp312-cp312-win32.whl", hash = "sha256:918f2013d7eadea1d88d1a35fd4a1e16aaf90343eb446f91cb091ce7f9b431a2", size = 1908353 },
{ url = "https://files.pythonhosted.org/packages/be/3a/be78f28732f93128bd0e3944bdd4b3970b389a1fbd44907c97291c8dcdec/pydantic_core-2.33.0-cp312-cp312-win_amd64.whl", hash = "sha256:aec79acc183865bad120b0190afac467c20b15289050648b876b07777e67ea48", size = 1955956 },
{ url = "https://files.pythonhosted.org/packages/21/26/b8911ac74faa994694b76ee6a22875cc7a4abea3c381fdba4edc6c6bef84/pydantic_core-2.33.0-cp312-cp312-win_arm64.whl", hash = "sha256:5461934e895968655225dfa8b3be79e7e927e95d4bd6c2d40edd2fa7052e71b6", size = 1903259 },
{ url = "https://files.pythonhosted.org/packages/79/20/de2ad03ce8f5b3accf2196ea9b44f31b0cd16ac6e8cfc6b21976ed45ec35/pydantic_core-2.33.0-cp313-cp313-macosx_10_12_x86_64.whl", hash = "sha256:f00e8b59e1fc8f09d05594aa7d2b726f1b277ca6155fc84c0396db1b373c4555", size = 2032214 },
{ url = "https://files.pythonhosted.org/packages/f9/af/6817dfda9aac4958d8b516cbb94af507eb171c997ea66453d4d162ae8948/pydantic_core-2.33.0-cp313-cp313-macosx_11_0_arm64.whl", hash = "sha256:1a73be93ecef45786d7d95b0c5e9b294faf35629d03d5b145b09b81258c7cd6d", size = 1852338 },
{ url = "https://files.pythonhosted.org/packages/44/f3/49193a312d9c49314f2b953fb55740b7c530710977cabe7183b8ef111b7f/pydantic_core-2.33.0-cp313-cp313-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:ff48a55be9da6930254565ff5238d71d5e9cd8c5487a191cb85df3bdb8c77365", size = 1896913 },
{ url = "https://files.pythonhosted.org/packages/06/e0/c746677825b2e29a2fa02122a8991c83cdd5b4c5f638f0664d4e35edd4b2/pydantic_core-2.33.0-cp313-cp313-manylinux_2_17_armv7l.manylinux2014_armv7l.whl", hash = "sha256:26a4ea04195638dcd8c53dadb545d70badba51735b1594810e9768c2c0b4a5da", size = 1986046 },
{ url = "https://files.pythonhosted.org/packages/11/ec/44914e7ff78cef16afb5e5273d480c136725acd73d894affdbe2a1bbaad5/pydantic_core-2.33.0-cp313-cp313-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl", hash = "sha256:41d698dcbe12b60661f0632b543dbb119e6ba088103b364ff65e951610cb7ce0", size = 2128097 },
{ url = "https://files.pythonhosted.org/packages/fe/f5/c6247d424d01f605ed2e3802f338691cae17137cee6484dce9f1ac0b872b/pydantic_core-2.33.0-cp313-cp313-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:ae62032ef513fe6281ef0009e30838a01057b832dc265da32c10469622613885", size = 2681062 },
{ url = "https://files.pythonhosted.org/packages/f0/85/114a2113b126fdd7cf9a9443b1b1fe1b572e5bd259d50ba9d5d3e1927fa9/pydantic_core-2.33.0-cp313-cp313-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:f225f3a3995dbbc26affc191d0443c6c4aa71b83358fd4c2b7d63e2f6f0336f9", size = 2007487 },
{ url = "https://files.pythonhosted.org/packages/e6/40/3c05ed28d225c7a9acd2b34c5c8010c279683a870219b97e9f164a5a8af0/pydantic_core-2.33.0-cp313-cp313-manylinux_2_5_i686.manylinux1_i686.whl", hash = "sha256:5bdd36b362f419c78d09630cbaebc64913f66f62bda6d42d5fbb08da8cc4f181", size = 2121382 },
{ url = "https://files.pythonhosted.org/packages/8a/22/e70c086f41eebd323e6baa92cc906c3f38ddce7486007eb2bdb3b11c8f64/pydantic_core-2.33.0-cp313-cp313-musllinux_1_1_aarch64.whl", hash = "sha256:2a0147c0bef783fd9abc9f016d66edb6cac466dc54a17ec5f5ada08ff65caf5d", size = 2072473 },
{ url = "https://files.pythonhosted.org/packages/3e/84/d1614dedd8fe5114f6a0e348bcd1535f97d76c038d6102f271433cd1361d/pydantic_core-2.33.0-cp313-cp313-musllinux_1_1_armv7l.whl", hash = "sha256:c860773a0f205926172c6644c394e02c25421dc9a456deff16f64c0e299487d3", size = 2249468 },
{ url = "https://files.pythonhosted.org/packages/b0/c0/787061eef44135e00fddb4b56b387a06c303bfd3884a6df9bea5cb730230/pydantic_core-2.33.0-cp313-cp313-musllinux_1_1_x86_64.whl", hash = "sha256:138d31e3f90087f42aa6286fb640f3c7a8eb7bdae829418265e7e7474bd2574b", size = 2254716 },
{ url = "https://files.pythonhosted.org/packages/ae/e2/27262eb04963201e89f9c280f1e10c493a7a37bc877e023f31aa72d2f911/pydantic_core-2.33.0-cp313-cp313-win32.whl", hash = "sha256:d20cbb9d3e95114325780f3cfe990f3ecae24de7a2d75f978783878cce2ad585", size = 1916450 },
{ url = "https://files.pythonhosted.org/packages/13/8d/25ff96f1e89b19e0b70b3cd607c9ea7ca27e1dcb810a9cd4255ed6abf869/pydantic_core-2.33.0-cp313-cp313-win_amd64.whl", hash = "sha256:ca1103d70306489e3d006b0f79db8ca5dd3c977f6f13b2c59ff745249431a606", size = 1956092 },
{ url = "https://files.pythonhosted.org/packages/1b/64/66a2efeff657b04323ffcd7b898cb0354d36dae3a561049e092134a83e9c/pydantic_core-2.33.0-cp313-cp313-win_arm64.whl", hash = "sha256:6291797cad239285275558e0a27872da735b05c75d5237bbade8736f80e4c225", size = 1908367 },
{ url = "https://files.pythonhosted.org/packages/52/54/295e38769133363d7ec4a5863a4d579f331728c71a6644ff1024ee529315/pydantic_core-2.33.0-cp313-cp313t-macosx_11_0_arm64.whl", hash = "sha256:7b79af799630af263eca9ec87db519426d8c9b3be35016eddad1832bac812d87", size = 1813331 },
{ url = "https://files.pythonhosted.org/packages/4c/9c/0c8ea02db8d682aa1ef48938abae833c1d69bdfa6e5ec13b21734b01ae70/pydantic_core-2.33.0-cp313-cp313t-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:eabf946a4739b5237f4f56d77fa6668263bc466d06a8036c055587c130a46f7b", size = 1986653 },
{ url = "https://files.pythonhosted.org/packages/8e/4f/3fb47d6cbc08c7e00f92300e64ba655428c05c56b8ab6723bd290bae6458/pydantic_core-2.33.0-cp313-cp313t-win_amd64.whl", hash = "sha256:8a1d581e8cdbb857b0e0e81df98603376c1a5c34dc5e54039dcc00f043df81e7", size = 1931234 },
{ url = "https://files.pythonhosted.org/packages/2b/b2/553e42762e7b08771fca41c0230c1ac276f9e79e78f57628e1b7d328551d/pydantic_core-2.33.0-pp311-pypy311_pp73-macosx_10_12_x86_64.whl", hash = "sha256:5d8dc9f63a26f7259b57f46a7aab5af86b2ad6fbe48487500bb1f4b27e051e4c", size = 2041207 },
{ url = "https://files.pythonhosted.org/packages/85/81/a91a57bbf3efe53525ab75f65944b8950e6ef84fe3b9a26c1ec173363263/pydantic_core-2.33.0-pp311-pypy311_pp73-macosx_11_0_arm64.whl", hash = "sha256:30369e54d6d0113d2aa5aee7a90d17f225c13d87902ace8fcd7bbf99b19124db", size = 1873736 },
{ url = "https://files.pythonhosted.org/packages/9c/d2/5ab52e9f551cdcbc1ee99a0b3ef595f56d031f66f88e5ca6726c49f9ce65/pydantic_core-2.33.0-pp311-pypy311_pp73-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:f3eb479354c62067afa62f53bb387827bee2f75c9c79ef25eef6ab84d4b1ae3b", size = 1903794 },
{ url = "https://files.pythonhosted.org/packages/2f/5f/a81742d3f3821b16f1265f057d6e0b68a3ab13a814fe4bffac536a1f26fd/pydantic_core-2.33.0-pp311-pypy311_pp73-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:0310524c833d91403c960b8a3cf9f46c282eadd6afd276c8c5edc617bd705dc9", size = 2083457 },
{ url = "https://files.pythonhosted.org/packages/b5/2f/e872005bc0fc47f9c036b67b12349a8522d32e3bda928e82d676e2a594d1/pydantic_core-2.33.0-pp311-pypy311_pp73-manylinux_2_5_i686.manylinux1_i686.whl", hash = "sha256:eddb18a00bbb855325db27b4c2a89a4ba491cd6a0bd6d852b225172a1f54b36c", size = 2119537 },
{ url = "https://files.pythonhosted.org/packages/d3/13/183f13ce647202eaf3dada9e42cdfc59cbb95faedd44d25f22b931115c7f/pydantic_core-2.33.0-pp311-pypy311_pp73-musllinux_1_1_aarch64.whl", hash = "sha256:ade5dbcf8d9ef8f4b28e682d0b29f3008df9842bb5ac48ac2c17bc55771cc976", size = 2080069 },
{ url = "https://files.pythonhosted.org/packages/23/8b/b6be91243da44a26558d9c3a9007043b3750334136c6550551e8092d6d96/pydantic_core-2.33.0-pp311-pypy311_pp73-musllinux_1_1_armv7l.whl", hash = "sha256:2c0afd34f928383e3fd25740f2050dbac9d077e7ba5adbaa2227f4d4f3c8da5c", size = 2251618 },
{ url = "https://files.pythonhosted.org/packages/aa/c5/fbcf1977035b834f63eb542e74cd6c807177f383386175b468f0865bcac4/pydantic_core-2.33.0-pp311-pypy311_pp73-musllinux_1_1_x86_64.whl", hash = "sha256:7da333f21cd9df51d5731513a6d39319892947604924ddf2e24a4612975fb936", size = 2255374 },
{ url = "https://files.pythonhosted.org/packages/2f/f8/66f328e411f1c9574b13c2c28ab01f308b53688bbbe6ca8fb981e6cabc42/pydantic_core-2.33.0-pp311-pypy311_pp73-win_amd64.whl", hash = "sha256:4b6d77c75a57f041c5ee915ff0b0bb58eabb78728b69ed967bc5b780e8f701b8", size = 2082099 },
]
[[package]]
name = "pydantic-settings"
version = "2.8.1"
source = { registry = "https://pypi.org/simple" }
dependencies = [
{ name = "pydantic" },
{ name = "python-dotenv" },
]
sdist = { url = "https://files.pythonhosted.org/packages/88/82/c79424d7d8c29b994fb01d277da57b0a9b09cc03c3ff875f9bd8a86b2145/pydantic_settings-2.8.1.tar.gz", hash = "sha256:d5c663dfbe9db9d5e1c646b2e161da12f0d734d422ee56f567d0ea2cee4e8585", size = 83550 }
wheels = [
{ url = "https://files.pythonhosted.org/packages/0b/53/a64f03044927dc47aafe029c42a5b7aabc38dfb813475e0e1bf71c4a59d0/pydantic_settings-2.8.1-py3-none-any.whl", hash = "sha256:81942d5ac3d905f7f3ee1a70df5dfb62d5569c12f51a5a647defc1c3d9ee2e9c", size = 30839 },
]
[[package]]
name = "pygments"
version = "2.19.1"
source = { registry = "https://pypi.org/simple" }
sdist = { url = "https://files.pythonhosted.org/packages/7c/2d/c3338d48ea6cc0feb8446d8e6937e1408088a72a39937982cc6111d17f84/pygments-2.19.1.tar.gz", hash = "sha256:61c16d2a8576dc0649d9f39e089b5f02bcd27fba10d8fb4dcc28173f7a45151f", size = 4968581 }
wheels = [
{ url = "https://files.pythonhosted.org/packages/8a/0b/9fcc47d19c48b59121088dd6da2488a49d5f72dacf8262e2790a1d2c7d15/pygments-2.19.1-py3-none-any.whl", hash = "sha256:9ea1544ad55cecf4b8242fab6dd35a93bbce657034b0611ee383099054ab6d8c", size = 1225293 },
]
[[package]]
name = "python-dotenv"
version = "1.1.0"
source = { registry = "https://pypi.org/simple" }
sdist = { url = "https://files.pythonhosted.org/packages/88/2c/7bb1416c5620485aa793f2de31d3df393d3686aa8a8506d11e10e13c5baf/python_dotenv-1.1.0.tar.gz", hash = "sha256:41f90bc6f5f177fb41f53e87666db362025010eb28f60a01c9143bfa33a2b2d5", size = 39920 }
wheels = [
{ url = "https://files.pythonhosted.org/packages/1e/18/98a99ad95133c6a6e2005fe89faedf294a748bd5dc803008059409ac9b1e/python_dotenv-1.1.0-py3-none-any.whl", hash = "sha256:d7c01d9e2293916c18baf562d95698754b0dbbb5e74d457c45d4f6561fb9d55d", size = 20256 },
]
[[package]]
name = "redditwarp"
version = "1.3.0"
source = { registry = "https://pypi.org/simple" }
sdist = { url = "https://files.pythonhosted.org/packages/03/f8/48d632fa5d21f805d0298dbdf70e6c802c9f5df048b5fe10074dd279ac47/redditwarp-1.3.0.tar.gz", hash = "sha256:962a092ae0e8e40f703af40996a6b7d896b718893e4c619d16740aa2426c7901", size = 207632 }
wheels = [
{ url = "https://files.pythonhosted.org/packages/0b/c4/a62b72c184e2d98bd0a16a4fa7d693e82cb40ae2342c74d8e7acb66eebc5/redditwarp-1.3.0-py3-none-any.whl", hash = "sha256:752139e961965524e534295ddef363316ffcfafc9abb6e8a1cb08cc90645db97", size = 483990 },
]
[[package]]
name = "requests"
version = "2.32.3"
source = { registry = "https://pypi.org/simple" }
dependencies = [
{ name = "certifi" },
{ name = "charset-normalizer" },
{ name = "idna" },
{ name = "urllib3" },
]
sdist = { url = "https://files.pythonhosted.org/packages/63/70/2bf7780ad2d390a8d301ad0b550f1581eadbd9a20f896afe06353c2a2913/requests-2.32.3.tar.gz", hash = "sha256:55365417734eb18255590a9ff9eb97e9e1da868d4ccd6402399eaf68af20a760", size = 131218 }
wheels = [
{ url = "https://files.pythonhosted.org/packages/f9/9b/335f9764261e915ed497fcdeb11df5dfd6f7bf257d4a6a2a686d80da4d54/requests-2.32.3-py3-none-any.whl", hash = "sha256:70761cfe03c773ceb22aa2f671b4757976145175cdfca038c02654d061d6dcc6", size = 64928 },
]
[[package]]
name = "rich"
version = "13.9.4"
source = { registry = "https://pypi.org/simple" }
dependencies = [
{ name = "markdown-it-py" },
{ name = "pygments" },
]
sdist = { url = "https://files.pythonhosted.org/packages/ab/3a/0316b28d0761c6734d6bc14e770d85506c986c85ffb239e688eeaab2c2bc/rich-13.9.4.tar.gz", hash = "sha256:439594978a49a09530cff7ebc4b5c7103ef57baf48d5ea3184f21d9a2befa098", size = 223149 }
wheels = [
{ url = "https://files.pythonhosted.org/packages/19/71/39c7c0d87f8d4e6c020a393182060eaefeeae6c01dab6a84ec346f2567df/rich-13.9.4-py3-none-any.whl", hash = "sha256:6049d5e6ec054bf2779ab3358186963bac2ea89175919d699e378b99738c2a90", size = 242424 },
]
[[package]]
name = "shellingham"
version = "1.5.4"
source = { registry = "https://pypi.org/simple" }
sdist = { url = "https://files.pythonhosted.org/packages/58/15/8b3609fd3830ef7b27b655beb4b4e9c62313a4e8da8c676e142cc210d58e/shellingham-1.5.4.tar.gz", hash = "sha256:8dbca0739d487e5bd35ab3ca4b36e11c4078f3a234bfce294b0a0291363404de", size = 10310 }
wheels = [
{ url = "https://files.pythonhosted.org/packages/e0/f9/0595336914c5619e5f28a1fb793285925a8cd4b432c9da0a987836c7f822/shellingham-1.5.4-py2.py3-none-any.whl", hash = "sha256:7ecfff8f2fd72616f7481040475a65b2bf8af90a56c89140852d1120324e8686", size = 9755 },
]
[[package]]
name = "sniffio"
version = "1.3.1"
source = { registry = "https://pypi.org/simple" }
sdist = { url = "https://files.pythonhosted.org/packages/a2/87/a6771e1546d97e7e041b6ae58d80074f81b7d5121207425c964ddf5cfdbd/sniffio-1.3.1.tar.gz", hash = "sha256:f4324edc670a0f49750a81b895f35c3adb843cca46f0530f79fc1babb23789dc", size = 20372 }
wheels = [
{ url = "https://files.pythonhosted.org/packages/e9/44/75a9c9421471a6c4805dbf2356f7c181a29c1879239abab1ea2cc8f38b40/sniffio-1.3.1-py3-none-any.whl", hash = "sha256:2f6da418d1f1e0fddd844478f41680e794e6051915791a034ff65e5f100525a2", size = 10235 },
]
[[package]]
name = "sse-starlette"
version = "2.2.1"
source = { registry = "https://pypi.org/simple" }
dependencies = [
{ name = "anyio" },
{ name = "starlette" },
]
sdist = { url = "https://files.pythonhosted.org/packages/71/a4/80d2a11af59fe75b48230846989e93979c892d3a20016b42bb44edb9e398/sse_starlette-2.2.1.tar.gz", hash = "sha256:54470d5f19274aeed6b2d473430b08b4b379ea851d953b11d7f1c4a2c118b419", size = 17376 }
wheels = [
{ url = "https://files.pythonhosted.org/packages/d9/e0/5b8bd393f27f4a62461c5cf2479c75a2cc2ffa330976f9f00f5f6e4f50eb/sse_starlette-2.2.1-py3-none-any.whl", hash = "sha256:6410a3d3ba0c89e7675d4c273a301d64649c03a5ef1ca101f10b47f895fd0e99", size = 10120 },
]
[[package]]
name = "starlette"
version = "0.46.1"
source = { registry = "https://pypi.org/simple" }
dependencies = [
{ name = "anyio" },
]
sdist = { url = "https://files.pythonhosted.org/packages/04/1b/52b27f2e13ceedc79a908e29eac426a63465a1a01248e5f24aa36a62aeb3/starlette-0.46.1.tar.gz", hash = "sha256:3c88d58ee4bd1bb807c0d1acb381838afc7752f9ddaec81bbe4383611d833230", size = 2580102 }
wheels = [
{ url = "https://files.pythonhosted.org/packages/a0/4b/528ccf7a982216885a1ff4908e886b8fb5f19862d1962f56a3fce2435a70/starlette-0.46.1-py3-none-any.whl", hash = "sha256:77c74ed9d2720138b25875133f3a2dae6d854af2ec37dceb56aef370c1d8a227", size = 71995 },
]
[[package]]
name = "typer"
version = "0.15.2"
source = { registry = "https://pypi.org/simple" }
dependencies = [
{ name = "click" },
{ name = "rich" },
{ name = "shellingham" },
{ name = "typing-extensions" },
]
sdist = { url = "https://files.pythonhosted.org/packages/8b/6f/3991f0f1c7fcb2df31aef28e0594d8d54b05393a0e4e34c65e475c2a5d41/typer-0.15.2.tar.gz", hash = "sha256:ab2fab47533a813c49fe1f16b1a370fd5819099c00b119e0633df65f22144ba5", size = 100711 }
wheels = [
{ url = "https://files.pythonhosted.org/packages/7f/fc/5b29fea8cee020515ca82cc68e3b8e1e34bb19a3535ad854cac9257b414c/typer-0.15.2-py3-none-any.whl", hash = "sha256:46a499c6107d645a9c13f7ee46c5d5096cae6f5fc57dd11eccbbb9ae3e44ddfc", size = 45061 },
]
[[package]]
name = "typing-extensions"
version = "4.13.0"
source = { registry = "https://pypi.org/simple" }
sdist = { url = "https://files.pythonhosted.org/packages/0e/3e/b00a62db91a83fff600de219b6ea9908e6918664899a2d85db222f4fbf19/typing_extensions-4.13.0.tar.gz", hash = "sha256:0a4ac55a5820789d87e297727d229866c9650f6521b64206413c4fbada24d95b", size = 106520 }
wheels = [
{ url = "https://files.pythonhosted.org/packages/e0/86/39b65d676ec5732de17b7e3c476e45bb80ec64eb50737a8dce1a4178aba1/typing_extensions-4.13.0-py3-none-any.whl", hash = "sha256:c8dd92cc0d6425a97c18fbb9d1954e5ff92c1ca881a309c45f06ebc0b79058e5", size = 45683 },
]
[[package]]
name = "typing-inspection"
version = "0.4.0"
source = { registry = "https://pypi.org/simple" }
dependencies = [
{ name = "typing-extensions" },
]
sdist = { url = "https://files.pythonhosted.org/packages/82/5c/e6082df02e215b846b4b8c0b887a64d7d08ffaba30605502639d44c06b82/typing_inspection-0.4.0.tar.gz", hash = "sha256:9765c87de36671694a67904bf2c96e395be9c6439bb6c87b5142569dcdd65122", size = 76222 }
wheels = [
{ url = "https://files.pythonhosted.org/packages/31/08/aa4fdfb71f7de5176385bd9e90852eaf6b5d622735020ad600f2bab54385/typing_inspection-0.4.0-py3-none-any.whl", hash = "sha256:50e72559fcd2a6367a19f7a7e610e6afcb9fac940c650290eed893d61386832f", size = 14125 },
]
[[package]]
name = "update-checker"
version = "0.18.0"
source = { registry = "https://pypi.org/simple" }
dependencies = [
{ name = "requests" },
]
sdist = { url = "https://files.pythonhosted.org/packages/5c/0b/1bec4a6cc60d33ce93d11a7bcf1aeffc7ad0aa114986073411be31395c6f/update_checker-0.18.0.tar.gz", hash = "sha256:6a2d45bb4ac585884a6b03f9eade9161cedd9e8111545141e9aa9058932acb13", size = 6699 }
wheels = [
{ url = "https://files.pythonhosted.org/packages/0c/ba/8dd7fa5f0b1c6a8ac62f8f57f7e794160c1f86f31c6d0fb00f582372a3e4/update_checker-0.18.0-py3-none-any.whl", hash = "sha256:cbba64760a36fe2640d80d85306e8fe82b6816659190993b7bdabadee4d4bbfd", size = 7008 },
]
[[package]]
name = "urllib3"
version = "2.2.3"
source = { registry = "https://pypi.org/simple" }
sdist = { url = "https://files.pythonhosted.org/packages/ed/63/22ba4ebfe7430b76388e7cd448d5478814d3032121827c12a2cc287e2260/urllib3-2.2.3.tar.gz", hash = "sha256:e7d814a81dad81e6caf2ec9fdedb284ecc9c73076b62654547cc64ccdcae26e9", size = 300677 }
wheels = [
{ url = "https://files.pythonhosted.org/packages/ce/d9/5f4c13cecde62396b0d3fe530a50ccea91e7dfc1ccf0e09c228841bb5ba8/urllib3-2.2.3-py3-none-any.whl", hash = "sha256:ca899ca043dcb1bafa3e262d73aa25c465bfb49e0bd9dd5d59f1d0acba2f8fac", size = 126338 },
]
[[package]]
name = "uvicorn"
version = "0.34.0"
source = { registry = "https://pypi.org/simple" }
dependencies = [
{ name = "click" },
{ name = "h11" },
]
sdist = { url = "https://files.pythonhosted.org/packages/4b/4d/938bd85e5bf2edeec766267a5015ad969730bb91e31b44021dfe8b22df6c/uvicorn-0.34.0.tar.gz", hash = "sha256:404051050cd7e905de2c9a7e61790943440b3416f49cb409f965d9dcd0fa73e9", size = 76568 }
wheels = [
{ url = "https://files.pythonhosted.org/packages/61/14/33a3a1352cfa71812a3a21e8c9bfb83f60b0011f5e36f2b1399d51928209/uvicorn-0.34.0-py3-none-any.whl", hash = "sha256:023dc038422502fa28a09c7a30bf2b6991512da7dcdb8fd35fe57cfc154126f4", size = 62315 },
]
[[package]]
name = "websocket-client"
version = "1.8.0"
source = { registry = "https://pypi.org/simple" }
sdist = { url = "https://files.pythonhosted.org/packages/e6/30/fba0d96b4b5fbf5948ed3f4681f7da2f9f64512e1d303f94b4cc174c24a5/websocket_client-1.8.0.tar.gz", hash = "sha256:3239df9f44da632f96012472805d40a23281a991027ce11d2f45a6f24ac4c3da", size = 54648 }
wheels = [
{ url = "https://files.pythonhosted.org/packages/5a/84/44687a29792a70e111c5c477230a72c4b957d88d16141199bf9acb7537a3/websocket_client-1.8.0-py3-none-any.whl", hash = "sha256:17b44cc997f5c498e809b22cdf2d9c7a9e71c02c8cc2b6c56e7c2d1239bfa526", size = 58826 },
]
================
File: Dockerfile
================
# Generated by https://smithery.ai. See: https://smithery.ai/docs/config#dockerfile
# Use a Python image with uv pre-installed
FROM ghcr.io/astral-sh/uv:python3.13-bookworm-slim AS uv
# Set the working directory in the container
WORKDIR /app
# Copy the project descriptor files for dependency installation
COPY pyproject.toml uv.lock /app/
# Enable bytecode compilation
ENV UV_COMPILE_BYTECODE=1
# Copy from the cache instead of linking since it's a mounted volume
ENV UV_LINK_MODE=copy
# Install the project's dependencies using the lockfile and settings
RUN --mount=type=cache,target=/root/.cache/uv \
uv sync --frozen --no-install-project --no-dev --no-editable
# Then, add the rest of the project source code and install it
# Installing separately from its dependencies allows optimal layer caching
COPY src /app/src
RUN --mount=type=cache,target=/root/.cache/uv \
uv sync --frozen --no-dev --no-editable
# Create a minimal runtime image
FROM python:3.13-slim-bookworm
WORKDIR /app
COPY --from=uv /root/.local /root/.local
COPY --from=uv --chown=app:app /app/.venv /app/.venv
# Place executables in the environment at the front of the path
ENV PATH="/app/.venv/bin:$PATH"
# Set the entry point for the container
ENTRYPOINT ["mcp-reddit"]
================
File: pyproject.toml
================
[project]
name = "reddit-content-api"
version = "0.1.0"
description = "Reddit Content API - An MCP server for analyzing Reddit content"
readme = "README.md"
requires-python = ">=3.11"
dependencies = [
"dnspython>=2.7.0",
"praw>=7.8.1",
"redditwarp>=1.3.0",
"fastmcp>=0.1.0",
"uvicorn",
]
[project.scripts]
reddit-content = "mcp_reddit.reddit_fetcher:mcp.run"
[build-system]
requires = ["hatchling"]
build-backend = "hatchling.build"
[tool.hatch.build.targets.wheel]
packages = ["src/mcp_reddit"]
================
File: README.md
================
# Reddit Content API - Setup and Usage Guide
[](https://github.com/jlcases/mcp-reddit/stargazers)
[](https://github.com/jlcases/mcp-reddit/network/members)
This project provides MCP (Model Context Protocol) tools for interacting with Reddit through Claude and Cursor.
## Features
- Reading trending posts from subreddits
- Analyzing Reddit discussions with comments
- Creating posts on Reddit
- Adding comments to posts or replies to existing comments
- Voting on posts and comments
## Requirements
- Python 3.10+
- A Reddit account
- A registered Reddit application (to obtain client_id and client_secret)
- Virtual environment (venv or similar)
- Claude Desktop and/or Cursor (optional but recommended)
## Installation from Scratch
Follow these steps carefully to avoid import and configuration issues:
```bash
# 1. Clone the repository
git clone https://github.com/your-username/mcp-reddit.git
cd mcp-reddit
# 2. Create and activate virtual environment
python -m venv .venv
source .venv/bin/activate # On Windows: .venv\Scripts\activate
# 3. Install dependencies (WITHOUT installing the package in editable mode)
pip install -r requirements.txt
# 4. Configure environment variables (see below)
# Create and edit the .env file
```
> ⚠️ **IMPORTANT**: DO NOT install the package in editable mode (`pip install -e .`)
> as it can cause module import problems.
## Environment Configuration
1. Create a `.env` file in the project root with the following variables:
```
REDDIT_CLIENT_ID=your_client_id
REDDIT_CLIENT_SECRET=your_client_secret
REDDIT_REFRESH_TOKEN=your_refresh_token
```
2. To obtain a refresh token, run:
```bash
python -m mcp_reddit.auth_helper
```
Follow the instructions to authorize the application. The token will be automatically saved to the `.env` file.
## Project Structure
```
mcp-reddit/
│
├── src/
│ └── mcp_reddit/
│ ├── __init__.py
│ ├── main.py # Entry point for the MCP server
│ ├── reddit_fetcher.py # Implementation of Reddit tools
│ └── auth_helper.py # Helper for generating authentication tokens
│
├── .env # Environment variables (create manually)
├── requirements.txt
├── setup.py
└── README.md
```
## Running the Server Directly
To run manually (useful for development and testing):
```bash
cd /path/to/mcp-reddit
.venv/bin/python src/mcp_reddit/main.py
```
You should see logs indicating:
- Server initialization
- Reddit authentication verification
- Registration of 10 tools (5 original + 5 with prefix)
- "Running MCP server..."
## Claude Desktop Configuration
1. Locate the configuration file:
- On macOS: `/Users/your-username/Library/Application Support/Claude/claude_desktop_config.json`
- On Windows: `%APPDATA%\Claude\claude_desktop_config.json`
2. Add the configuration for reddit-content-api:
```json
"reddit-content-api": {
"command": "/full/path/to/mcp-reddit/.venv/bin/python",
"args": [
"-m",
"mcp_reddit.main",
"--stdio"
],
"cwd": "/full/path/to/mcp-reddit",
"env": {
"PYTHONPATH": "/full/path/to/mcp-reddit/src:/full/path/to/mcp-reddit",
"DEBUG": "true"
}
}
```
> ⚠️ **EXTREMELY IMPORTANT**: `PYTHONPATH` must include both the `src` directory and the project root, in that order, separated by `:` (on Unix/macOS) or `;` (on Windows)
## Cursor Configuration
1. Locate the configuration file:
- On macOS: `/Users/your-username/.cursor/mcp.json`
- On Windows: `%USERPROFILE%\.cursor\mcp.json`
2. Add the same configuration as in Claude, adjusting paths as necessary.
## Troubleshooting Common Issues
### Issue: Only 2 tools appear instead of the expected 10
**Symptoms**: When running the server, only 2 tools appear instead of the expected 10.
**Possible causes and solutions**:
1. **Import problem**: Python is importing an installed version from `site-packages` instead of the local code in `src/`.
**Solution**:
- Make sure NOT to install the package in editable mode (`pip install -e .`)
- Explicitly add `src` to the beginning of `PYTHONPATH` in the configurations
- If you've already installed it, use `pip uninstall reddit-content-api` to remove it
2. **Python cache**: Old `.pyc` files can cause problems.
**Solution**:
- Remove all `__pycache__` directories from the project
3. **Version conflicts**: Different versions of the same library.
**Solution**:
- Reinstall dependencies with `pip install -r requirements.txt`
### Issue: "Cannot create post: Reddit authentication is not configured properly"
**Cause**: The refresh token is invalid or has expired.
**Solution**: Regenerate the token by running `python -m mcp_reddit.auth_helper` and make sure it's saved in `.env`.
### Issue: Tools don't appear in Claude/Cursor
**Cause**: Incorrect configuration in the configuration files.
**Solution**:
- Check paths and especially `PYTHONPATH` in the configuration files
- Completely restart Claude/Cursor after modifying the configuration
## Using the Tools in Claude/Cursor
Once configured, you can use the following tools:
1. `mcp_reddit_content_api_fetch_reddit_hot_threads` - Get trending posts
2. `mcp_reddit_content_api_fetch_reddit_post_content` - Analyze a post and its comments
3. `mcp_reddit_content_api_create_reddit_post` - Create a new post
4. `mcp_reddit_content_api_add_reddit_comment` - Add a comment
5. `mcp_reddit_content_api_vote_on_reddit_content` - Vote on content
### Examples
**Getting trending posts**:
```
Subreddit: python
Number of posts: 5
```
**Creating a post**:
```
Subreddit: test
Title: Test from MCP
Content type: text
Content: This is a test from the Reddit Content API using MCP.
```
## Contributions
If you find issues or have improvements, please create an issue or submit a pull request.
## License
[MIT](LICENSE)
## Support This Project
If you find this project useful in your work or research, please consider:
- ⭐ Starring the repository to show your support
- üîÑ Following the repository for updates on new features and improvements
- üêõ Opening issues for bugs or feature requests
- üõ†Ô∏è Contributing with pull requests if you have improvements to share
Your support helps make this project better for everyone!
================
File: .python-version
================
3.13
================
File: start_mcp_reddit.sh
================
#!/bin/bash
# Script para iniciar el servidor MCP-Reddit
cd "$(dirname "$0")"
export PYTHONPATH="$(pwd)/src:$(pwd)"
.venv/bin/python src/mcp_reddit/main.py
================
File: src/mcp_reddit/reddit_fetcher.py
================
"""
Reddit Content API - Provides MCP tools for accessing and analyzing Reddit content
"""
import sys
import logging
import os
import importlib
from typing import Any, Dict, List, Optional, Union
import praw # type: ignore
from dotenv import load_dotenv
from fastmcp import FastMCP, Context
from redditwarp.ASYNC import Client
from redditwarp.models.submission_ASYNC import GalleryPost, LinkPost, TextPost
# Load environment variables
load_dotenv()
# Configure logging
logging.basicConfig(
level=logging.INFO,
format="%(asctime)s - %(name)s - %(levelname)s - %(message)s",
stream=sys.stderr
)
logger = logging.getLogger(__name__)
# Initialize MCP and Reddit clients (lectura)
mcp = FastMCP("Reddit Content API")
reddit_client = Client()
# Initialize authenticated Reddit client for posting (escritura)
authenticated_reddit = None
try:
client_id = os.getenv("REDDIT_CLIENT_ID")
client_secret = os.getenv("REDDIT_CLIENT_SECRET")
refresh_token = os.getenv("REDDIT_REFRESH_TOKEN")
if not client_id or not client_secret:
logger.error("REDDIT_CLIENT_ID o REDDIT_CLIENT_SECRET no están configurados. Las funciones de escritura no estarán disponibles.")
elif not refresh_token:
logger.warning("REDDIT_REFRESH_TOKEN no configurado. Funciones de escritura no disponibles.")
logger.warning("Ejecuta 'python -m mcp_reddit.auth_helper' para obtener un token de actualización.")
else:
logger.info("Attempting to initialize authenticated PRAW client...")
authenticated_reddit = praw.Reddit(
client_id=client_id,
client_secret=client_secret,
refresh_token=refresh_token,
user_agent="Reddit Content API:v0.1.0 (by u/jlcases-dev)",
)
try:
logger.info("Verifying PRAW authentication...")
user = authenticated_reddit.user.me()
if user:
logger.info(f"Successfully authenticated Reddit client as user: {user.name}")
else:
logger.error("Authenticated Reddit client, but could not retrieve user information.")
authenticated_reddit = None
except Exception as auth_exc:
logger.error(f"Failed to verify Reddit authentication after initialization: {auth_exc}", exc_info=True)
authenticated_reddit = None
except Exception as e:
logger.error(f"Critical error during authenticated Reddit client PRAW initialization: {e}", exc_info=True)
authenticated_reddit = None
logger.info(f"Authenticated PRAW client initialized: {authenticated_reddit is not None}")
class ContentFormatters:
"""Helper class for formatting Reddit content"""
@staticmethod
def determine_content_type(submission: Any) -> str:
if isinstance(submission, LinkPost):
return 'external_link'
elif isinstance(submission, TextPost):
return 'text_post'
elif isinstance(submission, GalleryPost):
return 'image_gallery'
return 'other'
@staticmethod
def extract_content_body(submission: Any) -> Optional[str]:
if isinstance(submission, LinkPost):
return f"External link: {submission.permalink}"
elif isinstance(submission, TextPost):
return submission.body or "No text content available"
elif isinstance(submission, GalleryPost):
return f"Gallery with multiple images: {submission.gallery_link}"
return None
@staticmethod
def format_nested_comments(comment_tree_node: Any, level: int = 0) -> str:
comment = comment_tree_node.value
indent = " " * level + "└─ " if level > 0 else ""
formatted = (
f"{indent}Comment by {comment.author_display_name or '[anonymous]'} "
f"(votes: {comment.score})\n"
f"{indent}{' ' if level > 0 else ''}{comment.body}\n"
)
if comment_tree_node.children:
for child in comment_tree_node.children:
formatted += ContentFormatters.format_nested_comments(child, level + 1)
return formatted
# Herramienta 1 - Hot Threads
@mcp.tool(name="fetch_reddit_hot_threads")
async def get_trending_posts(community: str, count: int = 10) -> str:
"""
Retrieve trending posts from a specific Reddit community
Args:
community: The Reddit community/subreddit name
count: Maximum number of posts to retrieve (default: 10)
Returns:
Formatted string with trending posts information
"""
logger.info(f"Fetching {count} hot threads from r/{community}")
try:
results = []
async for post in reddit_client.p.subreddit.pull.hot(community, count):
post_type = ContentFormatters.determine_content_type(post)
post_content = ContentFormatters.extract_content_body(post)
post_details = [
f"## {post.title}",
f"* Upvotes: {post.score}",
f"* Comments: {post.comment_count}",
f"* Author: u/{post.author_display_name or '[deleted]'}",
f"* Type: {post_type}",
f"* Content: {post_content}",
f"* Link: https://reddit.com{post.permalink}",
"---"
]
results.append("\n".join(post_details))
if not results:
return f"No trending posts found in r/{community}"
return "\n\n".join(results)
except Exception as e:
error_msg = f"Failed to retrieve trending posts: {str(e)}"
logger.error(error_msg, exc_info=True)
return error_msg
mcp.tool(name="mcp_reddit_content_api_fetch_reddit_hot_threads")(get_trending_posts)
# Herramienta 2 - Post Content
@mcp.tool(name="fetch_reddit_post_content")
async def analyze_reddit_discussion(thread_id: str, max_comments: int = 20,
comment_tree_depth: int = 3) -> str:
"""
Analyze a specific Reddit discussion thread with comments
Args:
thread_id: The Reddit post identifier
max_comments: Maximum number of top-level comments to include (default: 20)
comment_tree_depth: How deep to traverse the comment tree (default: 3)
Returns:
Detailed analysis of the post and its discussion
"""
logger.info(f"Fetching content for post {thread_id} (comments: {max_comments}, depth: {comment_tree_depth})")
try:
post = await reddit_client.p.submission.fetch(thread_id)
post_type = ContentFormatters.determine_content_type(post)
post_content = ContentFormatters.extract_content_body(post)
post_analysis = [
f"# Discussion Analysis: {post.title}",
f"* Upvotes: {post.score}",
f"* Author: u/{post.author_display_name or '[deleted]'}",
f"* Content type: {post_type}",
f"* Content: {post_content}",
"\n## Discussion Overview"
]
discussion = await reddit_client.p.comment_tree.fetch(
thread_id,
sort='top',
limit=max_comments,
depth=comment_tree_depth
)
if discussion.children:
post_analysis.append("### Top Comments:")
for comment_node in discussion.children:
post_analysis.append(ContentFormatters.format_nested_comments(comment_node))
else:
post_analysis.append("No comments found in this discussion.")
return "\n".join(post_analysis)
except Exception as e:
error_msg = f"Failed to analyze discussion: {str(e)}"
logger.error(error_msg, exc_info=True)
return error_msg
mcp.tool(name="mcp_reddit_content_api_fetch_reddit_post_content")(analyze_reddit_discussion)
# Herramienta 3 - Create Post
@mcp.tool(name="create_reddit_post")
def create_reddit_post(subreddit: str, title: str, content_type: str = "text",
content: str = "", url: Optional[str] = None, ctx: Optional[Context] = None) -> str:
"""
Create a new post on a subreddit
Args:
subreddit: Name of the subreddit to post to
title: Title of the post
content_type: Type of post to create ("text", "link")
content: Text content for text posts
url: URL for link posts
ctx: MCP context object (automatically provided)
Returns:
URL of the created post or error message
"""
if ctx:
ctx.info(f"Attempting to create a {content_type} post in r/{subreddit}")
if not authenticated_reddit:
return "Cannot create post: Reddit authentication is not configured properly or failed to initialize."
try:
if not authenticated_reddit.user or not authenticated_reddit.user.me():
return "Cannot create post: Reddit client is not authenticated. Please check credentials or run auth_helper."
target_subreddit = authenticated_reddit.subreddit(subreddit)
if content_type.lower() == "text":
submission = target_subreddit.submit(title=title, selftext=content)
elif content_type.lower() == "link":
if not url:
return "Cannot create link post: URL is required"
submission = target_subreddit.submit(title=title, url=url)
else:
return f"Unsupported content type: {content_type}. Supported types are 'text' and 'link'"
post_url = f"https://reddit.com{submission.permalink}"
if ctx:
ctx.info(f"Successfully created post: {post_url}")
return f"Post created successfully: {post_url}"
except Exception as e:
logger.error(f"Error during post creation: {e}", exc_info=True)
return f"Failed to create Reddit post: {str(e)}"
mcp.tool(name="mcp_reddit_content_api_create_reddit_post")(create_reddit_post)
# Herramienta 4 - Add Comment
@mcp.tool(name="add_reddit_comment")
def add_reddit_comment(post_id: str = "", comment_text: str = "",
reply_to_comment_id: Optional[str] = None, ctx: Optional[Context] = None) -> str:
"""
Add a comment to a Reddit post or reply to an existing comment
Args:
post_id: ID of the Reddit post to comment on (required unless replying to a comment)
comment_text: Content of the comment
reply_to_comment_id: ID of the comment to reply to (optional)
ctx: MCP context object (automatically provided)
Returns:
URL of the created comment or error message
"""
if ctx:
action = f"reply to comment {reply_to_comment_id}" if reply_to_comment_id else f"comment on post {post_id}"
ctx.info(f"Attempting to {action}")
if not authenticated_reddit:
return "Cannot add comment: Reddit authentication is not configured properly or failed to initialize."
try:
if not authenticated_reddit.user or not authenticated_reddit.user.me():
return "Cannot add comment: Reddit client is not authenticated. Please check credentials or run auth_helper."
if reply_to_comment_id:
target_comment = authenticated_reddit.comment(reply_to_comment_id)
new_comment = target_comment.reply(comment_text)
comment_url = f"https://reddit.com{new_comment.permalink}"
if ctx:
ctx.info(f"Successfully replied to comment: {comment_url}")
return f"Comment reply created successfully: {comment_url}"
elif post_id:
submission = authenticated_reddit.submission(id=post_id)
new_comment = submission.reply(comment_text)
comment_url = f"https://reddit.com{new_comment.permalink}"
if ctx:
ctx.info(f"Successfully commented on post: {comment_url}")
return f"Comment created successfully: {comment_url}"
else:
return "Error: Must provide either post_id or reply_to_comment_id"
except Exception as e:
logger.error(f"Error during comment creation: {e}", exc_info=True)
return f"Failed to create Reddit comment: {str(e)}"
mcp.tool(name="mcp_reddit_content_api_add_reddit_comment")(add_reddit_comment)
# Herramienta 5 - Vote
@mcp.tool(name="vote_on_reddit_content")
def vote_on_reddit_content(content_id: str = "", vote_direction: str = "", content_type: str = "post", ctx: Optional[Context] = None) -> str:
"""
Vote on a Reddit post or comment
Args:
content_id: ID of the Reddit post or comment to vote on
vote_direction: Direction of vote ("up", "down", or "neutral")
content_type: Type of content to vote on ("post" or "comment")
ctx: MCP context object (automatically provided)
Returns:
Status message confirming vote action
"""
if ctx:
ctx.info(f"Attempting to {vote_direction}vote on {content_type} {content_id}")
if not authenticated_reddit:
return "Cannot vote: Reddit authentication is not configured properly or failed to initialize."
try:
if not authenticated_reddit.user or not authenticated_reddit.user.me():
return "Cannot vote: Reddit client is not authenticated. Please check credentials or run auth_helper."
if content_type.lower() == "post":
target = authenticated_reddit.submission(id=content_id)
elif content_type.lower() == "comment":
target = authenticated_reddit.comment(id=content_id)
else:
return f"Unsupported content type: {content_type}. Supported types are 'post' and 'comment'"
if vote_direction.lower() == "up":
target.upvote()
status = "upvoted"
elif vote_direction.lower() == "down":
target.downvote()
status = "downvoted"
elif vote_direction.lower() == "neutral":
target.clear_vote()
status = "vote cleared"
else:
return f"Unsupported vote direction: {vote_direction}. Supported directions are 'up', 'down', and 'neutral'"
if ctx:
ctx.info(f"Successfully {status} {content_type}: {content_id}")
return f"Successfully {status} the {content_type}"
except Exception as e:
logger.error(f"Error during voting: {e}", exc_info=True)
return f"Failed to vote on Reddit content: {str(e)}"
mcp.tool(name="mcp_reddit_content_api_vote_on_reddit_content")(vote_on_reddit_content)
logger.info("Finished loading reddit_fetcher.py")
================
File: src/mcp_reddit/__init__.py
================
"""
MCP Reddit package for fetching Reddit content
"""
================
File: src/mcp_reddit/auth_helper.py
================
#!/usr/bin/env python
"""
Script para obtener un token de autenticación de Reddit.
Este script implementa el flujo OAuth2 para obtener un token de acceso y un refresh token
que permita a la aplicación realizar acciones en nombre del usuario.
Para usar este script:
1. Configura tu aplicación en https://www.reddit.com/prefs/apps/
2. Crea una aplicación de tipo "web app" con redirect_uri = http://localhost:8080
3. Toma nota del client_id y client_secret
4. Ejecuta este script y sigue las instrucciones
El token obtenido se guardará automáticamente en el archivo .env
"""
import os
import random
import socket
import sys
from pathlib import Path
from urllib.parse import urlparse, parse_qs
import praw
from dotenv import load_dotenv, set_key
# Cargar variables de entorno
load_dotenv()
def receive_connection():
"""Espera y devuelve un socket conectado.
Abre una conexión TCP en el puerto 8080 y espera a un cliente.
"""
server = socket.socket(socket.AF_INET, socket.SOCK_STREAM)
server.setsockopt(socket.SOL_SOCKET, socket.SO_REUSEADDR, 1)
server.bind(("localhost", 8080))
server.listen(1)
client = server.accept()[0]
server.close()
return client
def send_message(client, message):
"""Envía un mensaje al cliente y cierra la conexión."""
print(message)
client.send(f"HTTP/1.1 200 OK\r\n\r\n{message}".encode("utf-8"))
client.close()
def update_env_file(token):
"""Actualiza el archivo .env con el refresh token."""
# Buscar el archivo .env
env_path = Path(os.getcwd()) / '.env'
if not env_path.exists():
print(f"Archivo .env no encontrado, creando en {env_path}")
# Actualizar o añadir el token
set_key(env_path, "REDDIT_REFRESH_TOKEN", token)
print(f"Token guardado exitosamente en {env_path}")
return env_path
def get_auth_token(callback=None):
"""Obtiene un token de autenticación de Reddit.
Args:
callback: Función opcional a llamar con el token obtenido
Returns:
El refresh token o None si hubo un error
"""
client_id = os.getenv("REDDIT_CLIENT_ID")
client_secret = os.getenv("REDDIT_CLIENT_SECRET")
if not client_id or not client_secret:
print("Error: REDDIT_CLIENT_ID o REDDIT_CLIENT_SECRET no están configurados.")
print("Configura estas variables en tu archivo .env")
return None
print("Este script obtendrá un refresh token para tu aplicación de Reddit.")
print("Necesitarás este token para las acciones de escritura.")
# Solicitar los scopes
print("\nScopes necesarios para la aplicación:")
print(" - identity: para verificar la identidad")
print(" - submit: para crear posts")
print(" - edit: para editar posts/comentarios")
print(" - vote: para votar")
scopes_list = ["identity", "submit", "edit", "vote"]
print(f"\nUsando scopes: {', '.join(scopes_list)}")
# Inicializar Reddit
reddit = praw.Reddit(
client_id=client_id,
client_secret=client_secret,
redirect_uri="http://localhost:8080",
user_agent="MCP-Reddit-Content-API/v0.1.0",
)
# Generar URL de autorización
state = str(random.randint(0, 65000))
auth_url = reddit.auth.url(scopes=scopes_list, state=state, duration="permanent")
print(f"\nPor favor, abre esta URL en tu navegador:\n{auth_url}\n")
print("Una vez que autorices la aplicación, serás redirigido a localhost.")
# Esperar la redirección
print("Esperando redirección...")
client = receive_connection()
data = client.recv(1024).decode("utf-8")
# Extraer los parámetros de la URL
url_path = data.split(" ", 2)[1]
parsed_url = urlparse(url_path)
query_params = parse_qs(parsed_url.query)
# Convertir a diccionario simple
params = {k: v[0] for k, v in query_params.items()}
# Verificar state para prevenir CSRF
if state != params.get("state"):
error_msg = f"State mismatch. Expected: {state} Received: {params.get('state')}"
send_message(client, error_msg)
print(f"Error: {error_msg}")
return None
# Verificar si hay error
if "error" in params:
error_msg = f"Error en la autenticación: {params['error']}"
send_message(client, error_msg)
print(f"Error: {error_msg}")
return None
# Obtener refresh token
refresh_token = reddit.auth.authorize(params["code"])
# Actualizar el .env
env_path = update_env_file(refresh_token)
success_msg = f"¡Autenticación exitosa!\n\nRefresh token: {refresh_token}\n\n"
success_msg += f"El token ha sido guardado automáticamente en {env_path}"
send_message(client, success_msg)
print("\n=== AUTENTICACIÓN COMPLETADA ===")
print(f"Token guardado en {env_path}")
print("No es necesario reiniciar manualmente el servidor.")
# Llamar al callback si existe
if callback and callable(callback):
callback(refresh_token)
return refresh_token
def main():
"""Punto de entrada del programa."""
token = get_auth_token()
return 0 if token else 1
if __name__ == "__main__":
sys.exit(main())
================
File: src/mcp_reddit/main.py
================
"""
Main entry point for the Reddit Content API
"""
import logging
import sys
import traceback
import os
# Añadir la raíz del proyecto a sys.path para priorizar los módulos locales
project_root = os.path.dirname(os.path.dirname(os.path.dirname(os.path.abspath(__file__))))
src_root = os.path.join(project_root, 'src')
if project_root not in sys.path:
sys.path.insert(0, project_root)
if src_root not in sys.path:
sys.path.insert(0, src_root)
# Importar reddit_fetcher de forma más robusta - SOLO importamos mcp
try:
import mcp_reddit.reddit_fetcher
mcp = mcp_reddit.reddit_fetcher.mcp
except ImportError as e:
print(f"FATAL: No se pudo importar mcp_reddit.reddit_fetcher: {e}", file=sys.stderr)
sys.exit(1)
# Configure logging to stdout
logging.basicConfig(
level=logging.INFO,
format="%(asctime)s - %(name)s - %(levelname)s - %(message)s",
stream=sys.stdout
)
logger = logging.getLogger(__name__)
if __name__ == "__main__":
logger.info("Starting Reddit Content API server...")
# Función para listar las herramientas registradas
def list_all_registered_tools():
logger.info("Listing registered tools...")
tool_manager = getattr(mcp, "_tool_manager", None)
if tool_manager:
all_tools = tool_manager.list_tools()
logger.info(f"Total registered tools: {len(all_tools)}")
for i, tool in enumerate(all_tools):
logger.info(f"Tool {i+1}: NAME='{tool.name}', DESC='{tool.description}'")
else:
logger.error("Tool manager not found in MCP instance")
# Listar herramientas
list_all_registered_tools()
try:
# Start the server
logger.info("Running MCP server...")
mcp.run()
logger.info("Server running. Press Ctrl+C to stop.")
except Exception as e:
logger.error(f"Error starting server: {str(e)}")
sys.exit(1)