Metadata-Version: 2.4
Name: levraiberet-discord-interactions
Version: 0.2.0
Summary: Toolkit moderne pour discord.py: composants, containers V2 et modales Discord API
Author: levraiberet (Discord/GitHub: levraiberet)
Maintainer: levraiberet (Discord/GitHub: levraiberet)
License: MIT
Project-URL: Homepage, https://github.com/levraiberet/discord-interactions-py
Project-URL: Repository, https://github.com/levraiberet/discord-interactions-py
Project-URL: Author, https://github.com/levraiberet
Keywords: discord,discord.py,interactions,components,modals,containers
Classifier: Development Status :: 3 - Alpha
Classifier: Intended Audience :: Developers
Classifier: Topic :: Software Development :: Libraries :: Python Modules
Classifier: License :: OSI Approved :: MIT License
Classifier: Programming Language :: Python :: 3
Classifier: Programming Language :: Python :: 3.8
Classifier: Programming Language :: Python :: 3.9
Classifier: Programming Language :: Python :: 3.10
Classifier: Programming Language :: Python :: 3.11
Classifier: Programming Language :: Python :: 3.12
Requires-Python: >=3.8
Description-Content-Type: text/markdown
License-File: LICENSE
Requires-Dist: discord.py>=2.0.0
Provides-Extra: dev
Requires-Dist: pytest>=7.0.0; extra == "dev"
Requires-Dist: pytest-asyncio>=0.21.0; extra == "dev"
Requires-Dist: black>=23.0.0; extra == "dev"
Requires-Dist: flake8>=6.0.0; extra == "dev"
Dynamic: license-file

# discord-interactions-py

Toolkit simple pour `discord.py`, inspire de la logique Discord.js, avec controle direct des payloads Discord API.

## Ce que fait le module

- Boutons et selects sans `View`
- Routing par `custom_id` (avec donnees encodees)
- Envoi/edition via HTTP Discord direct
- Containers V2 (`ContainerBuilder`, `SectionBuilder`, ...)
- Modales modernes (`Label`, `TextDisplay`, `RadioGroup`, `CheckboxGroup`, `Checkbox`)

## Installation

```bash
pip install discord-interactions-py
```

## Demarrage rapide

```bash
$env:DISCORD_BOT_TOKEN="votre_token"
python examples/01_minimal.py
```

## Exemples (1 fichier = 1 sujet)

- `examples/01_minimal.py`
- `examples/02_buttons_routing.py`
- `examples/03_selects.py`
- `examples/04_modales_modernes.py`
- `examples/05_containers_v2.py`
- `examples/06_signed_custom_ids.py`

## Validation rapide

Tu peux valider le module en lancant les exemples un par un, selon le sujet a verifier.

```bash
python examples/01_minimal.py
python examples/04_modales_modernes.py
```

## Note sur les modales modernes

Format recommande:

- top-level: `Label (18)` / `TextDisplay (10)`
- `Label.component`: `TextInput (4)`, selects, `FileUpload (19)`, `RadioGroup (21)`, `CheckboxGroup (22)`, `Checkbox (23)`

## Licence

MIT
