piilot-pack-fr-opendata
Plugin Piilot qui agrège 6 APIs gouvernementales françaises pour enrichir vos fiches clients, normaliser les adresses, et surveiller les annonces juridiques de votre portefeuille.
| Package | Registry | Version |
|---|---|---|
piilot-pack-fropendata |
PyPI | 0.1.0 |
piilot-pack-fropendata-ui |
npm | 0.1.0 |
APIs couvertes
| API | Auth | Quota | Use case |
|---|---|---|---|
| Recherche entreprises (DINUM) | ❌ | 7 req/s | Lookup rapide nom / SIREN / SIRET / dirigeant |
| SIRENE V3 (INSEE) | 🔑 OAuth2 BYOK | 30 req/min | Source de vérité légale, NAF, état admin |
| BAN (Base Adresse Nationale) | ❌ | 50 req/s | Géocodage + normalisation adresses |
| geo.api.gouv.fr | ❌ | ~10 req/s | Communes, départements, régions par code INSEE |
| Bodacc | ❌ | OK | Annonces juridiques (procédures, ventes, modifs) |
| INPI DNE | 🔑 Basic BYOK | OK | Comptes annuels, mandataires sociaux |
Surface v0.1
- 2 connectors BYOK —
fropendata.sirene(consumer_key + consumer_secret INSEE),fropendata.inpi(username + password) - 18 agent tools tous wrappés
bind_session— 10 no-auth + 5 BYOK + 3 composés (enrich_company,validate_address,record_bodacc_alert) - 3 agent templates prêts à l'emploi :
fropendata-enricheur— single-SIRET → fiche enrichie via send_tablefropendata-veille-portefeuille— surveillance Bodacc du portefeuille SIREN, écrit alertes dans la KB pluginfropendata-onboarding-cabinet— enrichissement batch depuis liste SIRETs
- 1 module Settings + ModuleView React 4 onglets (APIs / Auth / Cache / Métriques)
- 3 routes HTTP sous
/plugins/fropendata/*(settings/health, connections/test, connections/{id} PATCH) - 1 KB plugin-owned "Veille juridique — Annonces Bodacc" lazy-seedée à la 1re alerte
- Stateless DB-side — pas de schéma plugin, pas de migration plugin
Installation
Sur une instance Piilot existante (admin)
Le plugin est intégré au core depuis AICockpit PR #180. Pour activer pour une company :
curl -X PUT "https://<your-piilot>/admin/plugins/fropendata/activations/<company_id>" \
-H "Authorization: Bearer $TOKEN"
Puis dans l'UI :
- Ouvrir Settings → Open Data France (le ModuleView 4 onglets)
- Onglet Auth → cliquer le lien d'aide pour créer vos comptes développeur :
- SIRENE : https://api.insee.fr/catalogue/ → créer une application → récupérer
consumer_key+consumer_secret - INPI : https://www.inpi.fr/services-en-ligne → créer un compte développeur → récupérer
username+password
- SIRENE : https://api.insee.fr/catalogue/ → créer une application → récupérer
- Saisir les credentials via la page Settings → Connecteurs du host (la Save passe par là, pas par ce ModuleView)
- Revenir dans le ModuleView, cliquer Tester la connexion par connecteur
Les 4 APIs sans auth (recherche, BAN, geo, Bodacc) marchent dès l'activation, sans aucune config.
Standalone (dev / test isolé)
pip install piilot-pack-fropendata==0.1.0
npm install piilot-pack-fropendata-ui@0.1.0
Le plugin se déclare via le [project.entry-points."piilot.plugins"] du pyproject.toml ; le loader Piilot le découvre au boot.
Décisions architecturales (cf. CHANGELOG)
- BYOK full — chaque cabinet crée ses propres comptes INSEE + INPI (pas de pool centralisé Piilot)
- 2 connectors distincts — pattern aligné sur
piilot-pack-supabase - Stateless DB-side — la seule KB plugin-owned (Veille Bodacc) vit dans
kbs.*natif PG, lazy-seedée façonpiilot-pack-compta - Pas de scheduler v0.1 — SDK scheduler bloqué côté core, veille = invocation manuelle d'agent ou trigger N8N externe
- Pas de write KB générique — le core n'expose pas
kb_insert_rowaux agents.enricheuretonboarding-cabinetrestituent viasend_table(l'utilisateur recopie dans son CRM/KB cible). Seule la veille a son proprerecord_bodacc_alertcustom.
Stack technique
- Backend : Python 3.12+ ·
piilot-sdk>=0.7.0,<1.0.0·httpx/async · LangChainStructuredTool+bind_session - Frontend : React 19 · TypeScript strict ·
react-i18next· Tailwind classes brutes (pas d'imports@plugin-host/*hors le type API) - Tests : pytest 78 unit tests à 71% coverage (clients HTTP 85-96%, helpers 84%, routes 89%, infra 100%)
- CI : ruff + black + pytest sur Python 3.12 / SDK 0.7.0
Roadmap potentielle v0.2+
- Tool plugin
fropendata.upsert_company_row(kb_name, ...)générique pour permettre aux agentsenricheur+onboarding-cabinetd'écrire directement dans une KB cible (déclenche dogfood-driven) - TTL overrides cache par company depuis
connection.config["cache_ttl_overrides"] - KB référentielle staff
kbs_reference.fropendata_naf_rev2(~750 codes NAF) — bloqué tant que le SDK n'expose pas formellementkbs_reference.*aux plugins - Scheduled veille Bodacc native (bloqué par SDK scheduler)
- KB plugin-owned
dirigeant_societeenfant viakb_ref(multi-mandataires INPI) - DECP marchés publics (synergie verticale ESN)
- KALI conventions collectives
Contribuer
Forks, issues et PRs bienvenus. Suivre les conventions du CLAUDE.md du repo.
License : Apache-2.0.
Release files for piilot-pack-fropendata 0.1.3
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | |
|---|---|---|---|
| piilot_pack_fropendata-0.1.3.tar.gz | 60.7 kB | Details |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Reset |
|---|---|---|---|---|
| piilot_pack_fropendata-0.1.3-py3-none-any.whl | Python 3 | none | any | Details |
Total release size: 122.3 kB
Release files / piilot_pack_fropendata-0.1.3.tar.gz
| Download URL | piilot_pack_fropendata-0.1.3.tar.gz |
|---|---|
| Size | 60.7 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
2cf525096b9e43c92a70428a2a29706e25cb0ebf571174ae52aefee59bdb3fa7
|
|
BLAKE2b-256 checksum How to use checksums |
d57402f5b8e11838ecfaf1cc4d5a613207b7fc44dc458b141729af6d914898bc
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
Yes |
| Uploaded via |
twine/6.1.0 CPython/3.13.12
|
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
PyPI Publish Attestation
PyPI verified that this artifact, at this checksum, originated from the publisher listed below.
Signed by GitHub Actions, verified by PyPI on May 19, 2026.
Transparency logRelease files / piilot_pack_fropendata-0.1.3-py3-none-any.whl
| Download URL | piilot_pack_fropendata-0.1.3-py3-none-any.whl |
|---|---|
| Size | 61.6 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
24294e1173ba7aca8b25c8d75ed94f1ee08f6050d8a421fc211cb33c1ca1a497
|
|
BLAKE2b-256 checksum How to use checksums |
a41693349f0cce929537b63d54e3b5ab64355b780ad6730ce5d1ba0e8f56d423
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
Yes |
| Uploaded via |
twine/6.1.0 CPython/3.13.12
|
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
PyPI Publish Attestation
PyPI verified that this artifact, at this checksum, originated from the publisher listed below.
Signed by GitHub Actions, verified by PyPI on May 19, 2026.
Transparency log