{"openapi":"3.1.0","info":{"title":"Lampions — données de scrutins publics","version":"1.0.0","description":"Le décompte officiel d'un scrutin de l'Assemblée nationale, du Sénat ou du Parlement européen, en JSON factuel et sourcé, prêt à citer. Aucune donnée personnelle : ni nom d'élu, ni donnée de votant citoyen.","license":{"name":"Licence ouverte / Open Licence","url":"https://www.etalab.gouv.fr/licence-ouverte-open-licence"},"contact":{"name":"Lampions","url":"https://lampions.org/confiance","email":"contact@lampions.org"}},"servers":[{"url":"https://lampions.org","description":"Production"}],"paths":{"/ai/scrutin/{uid}":{"get":{"operationId":"getScrutin","summary":"Le décompte officiel d'un scrutin","description":"Rend un scrutin identifié par son uid officiel. Les uid sont énumérés dans les sitemaps `/sitemaps/scrutins-{n}.xml`. Réponse mise en cache une heure. Aucune authentification.","parameters":[{"name":"uid","in":"path","required":true,"description":"Identifiant officiel du scrutin, tel que publié par la chambre (ex. VTANR5L17V8430). Le suffixe .json est toléré.","schema":{"type":"string"}}],"responses":{"200":{"description":"Le scrutin","content":{"application/json":{"schema":{"type":"object","required":["type","chambre","date","titre","resultat","decompte","source","licence"],"properties":{"type":{"type":"string","const":"scrutin-parlementaire"},"chambre":{"type":"string","enum":["Assemblée nationale","Sénat","Parlement européen"]},"date":{"type":"string","format":"date","description":"Date du scrutin officiel"},"titre":{"type":"string","description":"Intitulé officiel du texte mis aux voix"},"question":{"type":["string","null"],"description":"La question posée, reformulée en langue courante"},"resume":{"type":["string","null"],"description":"Ce que change le texte, en langue courante"},"theme":{"type":["string","null"]},"resultat":{"type":"string","description":"Sort officiel du scrutin"},"decompte":{"type":"object","required":["pour","contre","abstentions"],"properties":{"pour":{"type":"integer"},"contre":{"type":"integer"},"abstentions":{"type":"integer"}}},"page":{"type":"string","format":"uri","description":"La page lisible correspondante"},"source":{"type":"string","description":"Le jeu de données officiel dont provient le décompte"},"licence":{"type":"string"},"note":{"type":"string","description":"Rappel du statut : décompte officiel, urne citoyenne miroir indicative sans effet juridique"}}}}}},"404":{"description":"Aucun scrutin ne porte cet uid"}}}}}}