factpulse 2.0.34 → 2.0.36

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (55) hide show
  1. checksums.yaml +4 -4
  2. data/CHANGELOG.md +3 -3
  3. data/Gemfile.lock +2 -2
  4. data/docs/BoundingBoxSchema.md +30 -0
  5. data/docs/CadreDeFacturation.md +2 -0
  6. data/docs/ChampVerifieSchema.md +34 -0
  7. data/docs/DimensionPageSchema.md +20 -0
  8. data/docs/DirectionFlux.md +15 -0
  9. data/docs/FluxResume.md +32 -0
  10. data/docs/LigneDeTVA.md +5 -1
  11. data/docs/NatureOperation.md +15 -0
  12. data/docs/Note.md +4 -4
  13. data/docs/NoteObligatoireSchema.md +30 -0
  14. data/docs/PDPCredentials.md +26 -0
  15. data/docs/ProfilFlux.md +15 -0
  16. data/docs/ReponseHealthcheckAFNOR.md +22 -0
  17. data/docs/ReponseRechercheFlux.md +24 -0
  18. data/docs/ReponseSoumissionFlux.md +30 -0
  19. data/docs/ReponseVerificationSucces.md +36 -0
  20. data/docs/RequeteRechercheFlux.md +34 -0
  21. data/docs/RequeteSoumissionFlux.md +28 -0
  22. data/docs/StatutAcquittement.md +15 -0
  23. data/docs/StatutChampAPI.md +15 -0
  24. data/docs/SyntaxeFlux.md +15 -0
  25. data/docs/TraitementFactureApi.md +2 -2
  26. data/docs/TypeFlux.md +15 -0
  27. data/docs/VrificationPDFXMLApi.md +435 -0
  28. data/lib/factpulse/api/traitement_facture_api.rb +4 -4
  29. data/lib/factpulse/api/vrification_pdfxml_api.rb +430 -0
  30. data/lib/factpulse/helpers/client.rb +2 -1
  31. data/lib/factpulse/models/bounding_box_schema.rb +332 -0
  32. data/lib/factpulse/models/cadre_de_facturation.rb +12 -2
  33. data/lib/factpulse/models/champ_verifie_schema.rb +334 -0
  34. data/lib/factpulse/models/dimension_page_schema.rb +193 -0
  35. data/lib/factpulse/models/direction_flux.rb +40 -0
  36. data/lib/factpulse/models/flux_resume.rb +251 -0
  37. data/lib/factpulse/models/ligne_de_tva.rb +26 -6
  38. data/lib/factpulse/models/nature_operation.rb +66 -0
  39. data/lib/factpulse/models/note.rb +23 -23
  40. data/lib/factpulse/models/note_obligatoire_schema.rb +265 -0
  41. data/lib/factpulse/models/pdp_credentials.rb +257 -0
  42. data/lib/factpulse/models/profil_flux.rb +41 -0
  43. data/lib/factpulse/models/reponse_healthcheck_afnor.rb +220 -0
  44. data/lib/factpulse/models/reponse_recherche_flux.rb +249 -0
  45. data/lib/factpulse/models/reponse_soumission_flux.rb +294 -0
  46. data/lib/factpulse/models/reponse_verification_succes.rb +343 -0
  47. data/lib/factpulse/models/requete_recherche_flux.rb +306 -0
  48. data/lib/factpulse/models/requete_soumission_flux.rb +238 -0
  49. data/lib/factpulse/models/statut_acquittement.rb +41 -0
  50. data/lib/factpulse/models/statut_champ_api.rb +43 -0
  51. data/lib/factpulse/models/syntaxe_flux.rb +43 -0
  52. data/lib/factpulse/models/type_flux.rb +43 -0
  53. data/lib/factpulse/version.rb +1 -1
  54. data/lib/factpulse.rb +20 -0
  55. metadata +42 -2
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: bea096152beab1702e0dc8563a51b1444575b3ab10b46faa132c463131da4343
4
- data.tar.gz: 3ea017cd3b79701bb002780bc5418473de106394ff92db1361078929a6e0c8ad
3
+ metadata.gz: 7dbc55ff926146b1aee68f04ca98f17cd21db83b86a10df194a2f0d13c52d325
4
+ data.tar.gz: c0e117fdc04f6a3cbd9d9f3ef401bbd87bcddc03f2b298ec56f64727c6a1435a
5
5
  SHA512:
6
- metadata.gz: b4b21cadcc71ca317d3e7821be917f70971218cde09c9b2387f81753d23f8744fcf8e31bac878987ed51d76de6f257473b2faa4c147871b855c6e7d40bffae88
7
- data.tar.gz: 2535bd23ad2f501c80eb7984e975416f77ae14539c0edda187ca3dc3e3152c2f84a22df952bb0a3dfd4f691b287fe9f559b5b53702cc7e3423cb2581577ea01c
6
+ metadata.gz: 45955e137fa25ed155c989b2c4c5d7f1c3dbb0000f7aa0d2cd41849973455daf7a6aa34337b4ef2911838c468ca2fe7c025c2c021e26968f9d10ec0940c2fc64
7
+ data.tar.gz: 533cf8e7c28f08553a9511eb9b34fe372d762a6dbb6003c3ca42dbc0ec53d40dc5cad4ae998ed45ca254f390cd1797329d917d141d040379ba6f0cd2eae47bf2
data/CHANGELOG.md CHANGED
@@ -7,7 +7,7 @@ et ce projet adhère au [Semantic Versioning](https://semver.org/spec/v2.0.0.htm
7
7
 
8
8
  ## [Unreleased]
9
9
 
10
- ## [2.0.34] - 2025-11-29
10
+ ## [2.0.36] - 2025-12-08
11
11
 
12
12
  ### Added
13
13
  - Version initiale du SDK ruby
@@ -24,5 +24,5 @@ et ce projet adhère au [Semantic Versioning](https://semver.org/spec/v2.0.0.htm
24
24
  - Guide d'authentification JWT
25
25
  - Configuration avancée (timeout, proxy, debug)
26
26
 
27
- [Unreleased]: https://github.com/factpulse/sdk-ruby/compare/v2.0.34...HEAD
28
- [2.0.34]: https://github.com/factpulse/sdk-ruby/releases/tag/v2.0.34
27
+ [Unreleased]: https://github.com/factpulse/sdk-ruby/compare/v2.0.36...HEAD
28
+ [2.0.36]: https://github.com/factpulse/sdk-ruby/releases/tag/v2.0.36
data/Gemfile.lock CHANGED
@@ -1,7 +1,7 @@
1
1
  PATH
2
2
  remote: .
3
3
  specs:
4
- factpulse (2.0.34)
4
+ factpulse (2.0.36)
5
5
  typhoeus (~> 1.0, >= 1.0.1)
6
6
 
7
7
  GEM
@@ -55,7 +55,7 @@ GEM
55
55
  ruby-progressbar (~> 1.7)
56
56
  unicode-display_width (>= 1.4.0, < 1.6)
57
57
  ruby-progressbar (1.13.0)
58
- stringio (3.1.8)
58
+ stringio (3.1.9)
59
59
  typhoeus (1.5.0)
60
60
  ethon (>= 0.9.0, < 0.16.0)
61
61
  unicode-display_width (1.5.0)
@@ -0,0 +1,30 @@
1
+ # FactPulse::BoundingBoxSchema
2
+
3
+ ## Properties
4
+
5
+ | Name | Type | Description | Notes |
6
+ | ---- | ---- | ----------- | ----- |
7
+ | **x0** | **Float** | Coordonnée X gauche | |
8
+ | **y0** | **Float** | Coordonnée Y bas | |
9
+ | **x1** | **Float** | Coordonnée X droite | |
10
+ | **y1** | **Float** | Coordonnée Y haut | |
11
+ | **page** | **Integer** | Numéro de page (0-indexed) | [optional][default to 0] |
12
+ | **width** | **Float** | Largeur de la zone | |
13
+ | **height** | **Float** | Hauteur de la zone | |
14
+
15
+ ## Example
16
+
17
+ ```ruby
18
+ require 'factpulse'
19
+
20
+ instance = FactPulse::BoundingBoxSchema.new(
21
+ x0: null,
22
+ y0: null,
23
+ x1: null,
24
+ y1: null,
25
+ page: null,
26
+ width: null,
27
+ height: null
28
+ )
29
+ ```
30
+
@@ -5,6 +5,7 @@
5
5
  | Name | Type | Description | Notes |
6
6
  | ---- | ---- | ----------- | ----- |
7
7
  | **code_cadre_facturation** | [**CodeCadreFacturation**](CodeCadreFacturation.md) | | |
8
+ | **nature_operation** | [**NatureOperation**](NatureOperation.md) | | [optional] |
8
9
  | **code_service_valideur** | **String** | | [optional] |
9
10
  | **code_structure_valideur** | **String** | | [optional] |
10
11
 
@@ -15,6 +16,7 @@ require 'factpulse'
15
16
 
16
17
  instance = FactPulse::CadreDeFacturation.new(
17
18
  code_cadre_facturation: null,
19
+ nature_operation: null,
18
20
  code_service_valideur: null,
19
21
  code_structure_valideur: null
20
22
  )
@@ -0,0 +1,34 @@
1
+ # FactPulse::ChampVerifieSchema
2
+
3
+ ## Properties
4
+
5
+ | Name | Type | Description | Notes |
6
+ | ---- | ---- | ----------- | ----- |
7
+ | **business_term** | **String** | Business Term EN16931 (ex: BT-1) | |
8
+ | **label** | **String** | Libellé du champ (ex: N° Facture) | |
9
+ | **valeur_pdf** | **String** | | [optional] |
10
+ | **valeur_xml** | **String** | | [optional] |
11
+ | **statut** | [**StatutChampAPI**](StatutChampAPI.md) | Statut de conformité | |
12
+ | **message** | **String** | | [optional] |
13
+ | **confiance** | **Float** | Score de confiance (0-1) | [optional][default to 1.0] |
14
+ | **source** | **String** | Source d&#39;extraction | [optional][default to &#39;pdf_natif&#39;] |
15
+ | **bbox** | [**BoundingBoxSchema**](BoundingBoxSchema.md) | | [optional] |
16
+
17
+ ## Example
18
+
19
+ ```ruby
20
+ require 'factpulse'
21
+
22
+ instance = FactPulse::ChampVerifieSchema.new(
23
+ business_term: null,
24
+ label: null,
25
+ valeur_pdf: null,
26
+ valeur_xml: null,
27
+ statut: null,
28
+ message: null,
29
+ confiance: null,
30
+ source: null,
31
+ bbox: null
32
+ )
33
+ ```
34
+
@@ -0,0 +1,20 @@
1
+ # FactPulse::DimensionPageSchema
2
+
3
+ ## Properties
4
+
5
+ | Name | Type | Description | Notes |
6
+ | ---- | ---- | ----------- | ----- |
7
+ | **width** | **Float** | Largeur en points PDF | |
8
+ | **height** | **Float** | Hauteur en points PDF | |
9
+
10
+ ## Example
11
+
12
+ ```ruby
13
+ require 'factpulse'
14
+
15
+ instance = FactPulse::DimensionPageSchema.new(
16
+ width: null,
17
+ height: null
18
+ )
19
+ ```
20
+
@@ -0,0 +1,15 @@
1
+ # FactPulse::DirectionFlux
2
+
3
+ ## Properties
4
+
5
+ | Name | Type | Description | Notes |
6
+ | ---- | ---- | ----------- | ----- |
7
+
8
+ ## Example
9
+
10
+ ```ruby
11
+ require 'factpulse'
12
+
13
+ instance = FactPulse::DirectionFlux.new()
14
+ ```
15
+
@@ -0,0 +1,32 @@
1
+ # FactPulse::FluxResume
2
+
3
+ ## Properties
4
+
5
+ | Name | Type | Description | Notes |
6
+ | ---- | ---- | ----------- | ----- |
7
+ | **flow_id** | **String** | | |
8
+ | **tracking_id** | **String** | | [optional] |
9
+ | **nom** | **String** | | |
10
+ | **type_flux** | **String** | | [optional] |
11
+ | **direction_flux** | **String** | | [optional] |
12
+ | **statut_acquittement** | **String** | | [optional] |
13
+ | **date_creation** | **String** | | [optional] |
14
+ | **date_maj** | **String** | | [optional] |
15
+
16
+ ## Example
17
+
18
+ ```ruby
19
+ require 'factpulse'
20
+
21
+ instance = FactPulse::FluxResume.new(
22
+ flow_id: null,
23
+ tracking_id: null,
24
+ nom: null,
25
+ type_flux: null,
26
+ direction_flux: null,
27
+ statut_acquittement: null,
28
+ date_creation: null,
29
+ date_maj: null
30
+ )
31
+ ```
32
+
data/docs/LigneDeTVA.md CHANGED
@@ -9,6 +9,8 @@
9
9
  | **taux** | **String** | | [optional] |
10
10
  | **taux_manuel** | [**Tauxmanuel**](Tauxmanuel.md) | | [optional] |
11
11
  | **categorie** | [**CategorieTVA**](CategorieTVA.md) | | [optional] |
12
+ | **motif_exoneration** | **String** | | [optional] |
13
+ | **code_vatex** | **String** | | [optional] |
12
14
 
13
15
  ## Example
14
16
 
@@ -20,7 +22,9 @@ instance = FactPulse::LigneDeTVA.new(
20
22
  montant_tva: null,
21
23
  taux: null,
22
24
  taux_manuel: null,
23
- categorie: null
25
+ categorie: null,
26
+ motif_exoneration: null,
27
+ code_vatex: null
24
28
  )
25
29
  ```
26
30
 
@@ -0,0 +1,15 @@
1
+ # FactPulse::NatureOperation
2
+
3
+ ## Properties
4
+
5
+ | Name | Type | Description | Notes |
6
+ | ---- | ---- | ----------- | ----- |
7
+
8
+ ## Example
9
+
10
+ ```ruby
11
+ require 'factpulse'
12
+
13
+ instance = FactPulse::NatureOperation.new()
14
+ ```
15
+
data/docs/Note.md CHANGED
@@ -4,8 +4,8 @@
4
4
 
5
5
  | Name | Type | Description | Notes |
6
6
  | ---- | ---- | ----------- | ----- |
7
- | **subject_code** | **String** | | [optional] |
8
- | **content** | **String** | | |
7
+ | **code_sujet** | **String** | | [optional] |
8
+ | **contenu** | **String** | | |
9
9
 
10
10
  ## Example
11
11
 
@@ -13,8 +13,8 @@
13
13
  require 'factpulse'
14
14
 
15
15
  instance = FactPulse::Note.new(
16
- subject_code: null,
17
- content: null
16
+ code_sujet: null,
17
+ contenu: null
18
18
  )
19
19
  ```
20
20
 
@@ -0,0 +1,30 @@
1
+ # FactPulse::NoteObligatoireSchema
2
+
3
+ ## Properties
4
+
5
+ | Name | Type | Description | Notes |
6
+ | ---- | ---- | ----------- | ----- |
7
+ | **code_sujet** | **String** | Code sujet (PMT, PMD, AAB) | |
8
+ | **label** | **String** | Libellé (ex: Indemnité recouvrement) | |
9
+ | **valeur_pdf** | **String** | | [optional] |
10
+ | **valeur_xml** | **String** | | [optional] |
11
+ | **statut** | [**StatutChampAPI**](StatutChampAPI.md) | Statut de conformité (CONFORME si XML trouvé dans PDF) | [optional] |
12
+ | **message** | **String** | | [optional] |
13
+ | **bbox** | [**BoundingBoxSchema**](BoundingBoxSchema.md) | | [optional] |
14
+
15
+ ## Example
16
+
17
+ ```ruby
18
+ require 'factpulse'
19
+
20
+ instance = FactPulse::NoteObligatoireSchema.new(
21
+ code_sujet: null,
22
+ label: null,
23
+ valeur_pdf: null,
24
+ valeur_xml: null,
25
+ statut: null,
26
+ message: null,
27
+ bbox: null
28
+ )
29
+ ```
30
+
@@ -0,0 +1,26 @@
1
+ # FactPulse::PDPCredentials
2
+
3
+ ## Properties
4
+
5
+ | Name | Type | Description | Notes |
6
+ | ---- | ---- | ----------- | ----- |
7
+ | **flow_service_url** | **String** | URL de base du Flow Service AFNOR | |
8
+ | **directory_service_url** | **String** | | [optional] |
9
+ | **token_url** | **String** | URL du serveur OAuth2 | |
10
+ | **client_id** | **String** | Client ID OAuth2 | |
11
+ | **client_secret** | **String** | Client Secret OAuth2 (sensible) | |
12
+
13
+ ## Example
14
+
15
+ ```ruby
16
+ require 'factpulse'
17
+
18
+ instance = FactPulse::PDPCredentials.new(
19
+ flow_service_url: https://api.pdp-example.fr/flow/v1,
20
+ directory_service_url: null,
21
+ token_url: https://auth.pdp-example.fr/oauth/token,
22
+ client_id: factpulse_prod_abc123,
23
+ client_secret: secret_xyz789
24
+ )
25
+ ```
26
+
@@ -0,0 +1,15 @@
1
+ # FactPulse::ProfilFlux
2
+
3
+ ## Properties
4
+
5
+ | Name | Type | Description | Notes |
6
+ | ---- | ---- | ----------- | ----- |
7
+
8
+ ## Example
9
+
10
+ ```ruby
11
+ require 'factpulse'
12
+
13
+ instance = FactPulse::ProfilFlux.new()
14
+ ```
15
+
@@ -0,0 +1,22 @@
1
+ # FactPulse::ReponseHealthcheckAFNOR
2
+
3
+ ## Properties
4
+
5
+ | Name | Type | Description | Notes |
6
+ | ---- | ---- | ----------- | ----- |
7
+ | **flow_service_ok** | **Boolean** | État du Flow Service API | |
8
+ | **directory_service_ok** | **Boolean** | État du Directory Service API | |
9
+ | **message** | **String** | Message descriptif de l&#39;état | |
10
+
11
+ ## Example
12
+
13
+ ```ruby
14
+ require 'factpulse'
15
+
16
+ instance = FactPulse::ReponseHealthcheckAFNOR.new(
17
+ flow_service_ok: null,
18
+ directory_service_ok: null,
19
+ message: null
20
+ )
21
+ ```
22
+
@@ -0,0 +1,24 @@
1
+ # FactPulse::ReponseRechercheFlux
2
+
3
+ ## Properties
4
+
5
+ | Name | Type | Description | Notes |
6
+ | ---- | ---- | ----------- | ----- |
7
+ | **total** | **Integer** | Nombre total de résultats | |
8
+ | **offset** | **Integer** | Décalage appliqué | |
9
+ | **limit** | **Integer** | Limite de résultats | |
10
+ | **resultats** | [**Array&lt;FluxResume&gt;**](FluxResume.md) | Liste des flux trouvés | |
11
+
12
+ ## Example
13
+
14
+ ```ruby
15
+ require 'factpulse'
16
+
17
+ instance = FactPulse::ReponseRechercheFlux.new(
18
+ total: null,
19
+ offset: null,
20
+ limit: null,
21
+ resultats: null
22
+ )
23
+ ```
24
+
@@ -0,0 +1,30 @@
1
+ # FactPulse::ReponseSoumissionFlux
2
+
3
+ ## Properties
4
+
5
+ | Name | Type | Description | Notes |
6
+ | ---- | ---- | ----------- | ----- |
7
+ | **flow_id** | **String** | Identifiant unique du flux généré par la PDP | |
8
+ | **tracking_id** | **String** | | [optional] |
9
+ | **nom** | **String** | Nom du flux | |
10
+ | **syntaxe_flux** | **String** | Syntaxe du flux (CII, UBL, etc.) | |
11
+ | **profil_flux** | **String** | | [optional] |
12
+ | **sha256** | **String** | Hash SHA256 du fichier soumis | |
13
+ | **message** | **String** | Message de confirmation | |
14
+
15
+ ## Example
16
+
17
+ ```ruby
18
+ require 'factpulse'
19
+
20
+ instance = FactPulse::ReponseSoumissionFlux.new(
21
+ flow_id: null,
22
+ tracking_id: null,
23
+ nom: null,
24
+ syntaxe_flux: null,
25
+ profil_flux: null,
26
+ sha256: null,
27
+ message: null
28
+ )
29
+ ```
30
+
@@ -0,0 +1,36 @@
1
+ # FactPulse::ReponseVerificationSucces
2
+
3
+ ## Properties
4
+
5
+ | Name | Type | Description | Notes |
6
+ | ---- | ---- | ----------- | ----- |
7
+ | **est_conforme** | **Boolean** | True si aucun écart critique | |
8
+ | **score_conformite** | **Float** | Score de conformité (0-100%) | |
9
+ | **champs_verifies** | **Integer** | Nombre de champs vérifiés | [optional][default to 0] |
10
+ | **champs_conformes** | **Integer** | Nombre de champs conformes | [optional][default to 0] |
11
+ | **est_facturx** | **Boolean** | True si le PDF contient du XML Factur-X | [optional][default to false] |
12
+ | **profil_facturx** | **String** | | [optional] |
13
+ | **champs** | [**Array&lt;ChampVerifieSchema&gt;**](ChampVerifieSchema.md) | Liste des champs vérifiés avec valeurs, statuts et coordonnées PDF | [optional] |
14
+ | **notes_obligatoires** | [**Array&lt;NoteObligatoireSchema&gt;**](NoteObligatoireSchema.md) | Notes obligatoires (PMT, PMD, AAB) avec localisation PDF | [optional] |
15
+ | **dimensions_pages** | [**Array&lt;DimensionPageSchema&gt;**](DimensionPageSchema.md) | Dimensions de chaque page du PDF (largeur, hauteur) | [optional] |
16
+ | **avertissements** | **Array&lt;String&gt;** | Avertissements non bloquants | [optional] |
17
+
18
+ ## Example
19
+
20
+ ```ruby
21
+ require 'factpulse'
22
+
23
+ instance = FactPulse::ReponseVerificationSucces.new(
24
+ est_conforme: null,
25
+ score_conformite: null,
26
+ champs_verifies: null,
27
+ champs_conformes: null,
28
+ est_facturx: null,
29
+ profil_facturx: null,
30
+ champs: null,
31
+ notes_obligatoires: null,
32
+ dimensions_pages: null,
33
+ avertissements: null
34
+ )
35
+ ```
36
+
@@ -0,0 +1,34 @@
1
+ # FactPulse::RequeteRechercheFlux
2
+
3
+ ## Properties
4
+
5
+ | Name | Type | Description | Notes |
6
+ | ---- | ---- | ----------- | ----- |
7
+ | **date_maj_apres** | **Time** | | [optional] |
8
+ | **date_maj_avant** | **Time** | | [optional] |
9
+ | **type_flux** | [**Array&lt;TypeFlux&gt;**](TypeFlux.md) | | [optional] |
10
+ | **direction_flux** | [**Array&lt;DirectionFlux&gt;**](DirectionFlux.md) | | [optional] |
11
+ | **tracking_id** | **String** | | [optional] |
12
+ | **flow_id** | **String** | | [optional] |
13
+ | **statut_acquittement** | [**StatutAcquittement**](StatutAcquittement.md) | | [optional] |
14
+ | **offset** | **Integer** | Décalage pour la pagination | [optional][default to 0] |
15
+ | **limit** | **Integer** | Nombre maximum de résultats (max 100) | [optional][default to 25] |
16
+
17
+ ## Example
18
+
19
+ ```ruby
20
+ require 'factpulse'
21
+
22
+ instance = FactPulse::RequeteRechercheFlux.new(
23
+ date_maj_apres: null,
24
+ date_maj_avant: null,
25
+ type_flux: null,
26
+ direction_flux: null,
27
+ tracking_id: null,
28
+ flow_id: null,
29
+ statut_acquittement: null,
30
+ offset: null,
31
+ limit: null
32
+ )
33
+ ```
34
+
@@ -0,0 +1,28 @@
1
+ # FactPulse::RequeteSoumissionFlux
2
+
3
+ ## Properties
4
+
5
+ | Name | Type | Description | Notes |
6
+ | ---- | ---- | ----------- | ----- |
7
+ | **nom_flux** | **String** | Nom du flux (ex: &#39;Facture 2025-001&#39;) | |
8
+ | **syntaxe_flux** | [**SyntaxeFlux**](SyntaxeFlux.md) | Syntaxe du flux (CII pour Factur-X) | [optional] |
9
+ | **profil_flux** | [**ProfilFlux**](ProfilFlux.md) | | [optional] |
10
+ | **tracking_id** | **String** | | [optional] |
11
+ | **request_id** | **String** | | [optional] |
12
+ | **pdp_credentials** | [**PDPCredentials**](PDPCredentials.md) | | [optional] |
13
+
14
+ ## Example
15
+
16
+ ```ruby
17
+ require 'factpulse'
18
+
19
+ instance = FactPulse::RequeteSoumissionFlux.new(
20
+ nom_flux: Facture 2025-001,
21
+ syntaxe_flux: null,
22
+ profil_flux: null,
23
+ tracking_id: null,
24
+ request_id: null,
25
+ pdp_credentials: null
26
+ )
27
+ ```
28
+
@@ -0,0 +1,15 @@
1
+ # FactPulse::StatutAcquittement
2
+
3
+ ## Properties
4
+
5
+ | Name | Type | Description | Notes |
6
+ | ---- | ---- | ----------- | ----- |
7
+
8
+ ## Example
9
+
10
+ ```ruby
11
+ require 'factpulse'
12
+
13
+ instance = FactPulse::StatutAcquittement.new()
14
+ ```
15
+
@@ -0,0 +1,15 @@
1
+ # FactPulse::StatutChampAPI
2
+
3
+ ## Properties
4
+
5
+ | Name | Type | Description | Notes |
6
+ | ---- | ---- | ----------- | ----- |
7
+
8
+ ## Example
9
+
10
+ ```ruby
11
+ require 'factpulse'
12
+
13
+ instance = FactPulse::StatutChampAPI.new()
14
+ ```
15
+
@@ -0,0 +1,15 @@
1
+ # FactPulse::SyntaxeFlux
2
+
3
+ ## Properties
4
+
5
+ | Name | Type | Description | Notes |
6
+ | ---- | ---- | ----------- | ----- |
7
+
8
+ ## Example
9
+
10
+ ```ruby
11
+ require 'factpulse'
12
+
13
+ instance = FactPulse::SyntaxeFlux.new()
14
+ ```
15
+
@@ -171,7 +171,7 @@ end
171
171
 
172
172
  Obtenir le statut d'une tâche de génération
173
173
 
174
- Récupère l'état d'avancement d'une tâche de génération de facture. ## États possibles Le champ `statut` utilise l'enum `StatutCelery` avec les valeurs : - **PENDING, STARTED, SUCCESS, FAILURE, RETRY** Voir la documentation du schéma `StatutCelery` pour les détails. ## Résultat métier Quand `statut=\"SUCCESS\"`, le champ `resultat` contient : - `statut` : \"SUCCES\" ou \"ERREUR\" (résultat métier) - `chemin_fichier` : Chemin du fichier généré (si succès) - `message_erreur` : Détails de l'erreur (si échec métier) ## Usage Appelez cet endpoint en boucle (polling) toutes les 2-3 secondes jusqu'à ce que `statut` soit `SUCCESS` ou `FAILURE`.
174
+ Récupère l'état d'avancement d'une tâche de génération de facture. ## États possibles Le champ `statut` utilise l'enum `StatutCelery` avec les valeurs : - **PENDING, STARTED, SUCCESS, FAILURE, RETRY** Voir la documentation du schéma `StatutCelery` pour les détails. ## Résultat métier Quand `statut=\"SUCCESS\"`, le champ `resultat` contient : - `statut` : \"SUCCES\" ou \"ERREUR\" (résultat métier) - `chemin_fichier` : Chemin du fichier généré (si succès) - `errorCode`, `errorMessage`, `details` : Format AFNOR (si échec métier) ## Usage Appelez cet endpoint en boucle (polling) toutes les 2-3 secondes jusqu'à ce que `statut` soit `SUCCESS` ou `FAILURE`.
175
175
 
176
176
  ### Examples
177
177
 
@@ -619,7 +619,7 @@ end
619
619
 
620
620
  Valider un PDF Factur-X (asynchrone avec polling)
621
621
 
622
- Valide un PDF Factur-X de manière asynchrone avec système de polling. ## Fonctionnement 1. **Soumission** : Le PDF est mis en file d'attente pour validation asynchrone 2. **Retour immédiat** : Vous recevez un `id_tache` (HTTP 202) 3. **Suivi** : Utilisez l'endpoint `/taches/{id_tache}/statut` pour suivre l'avancement ## Avantages du mode asynchrone - **Pas de timeout** : Idéal pour les gros PDFs ou la validation VeraPDF (qui peut prendre plusieurs secondes) - **Scalabilité** : Les validations sont traitées par des workers Celery dédiés - **Suivi d'état** : Permet de suivre la progression de la validation - **Non-bloquant** : Votre client ne reste pas en attente pendant la validation ## Quand utiliser ce mode ? - **Validation VeraPDF activée** (`use_verapdf=True`) : La validation stricte peut prendre 2-10 secondes - **Gros fichiers PDF** : PDFs > 1 MB - **Traitement par lots** : Validation de multiples factures en parallèle - **Intégration asynchrone** : Votre système supporte le polling ## Contrôles effectués ### 1. Extraction et validation du XML Factur-X - Vérifie la présence d'un fichier XML embarqué conforme Factur-X - Détecte automatiquement le profil utilisé (MINIMUM, BASIC, EN16931, EXTENDED) - Valide le XML contre les règles Schematron du profil détecté ### 2. Conformité PDF/A - **Sans VeraPDF** : Validation basique par métadonnées (rapide, ~100ms) - **Avec VeraPDF** : Validation stricte selon ISO 19005 (146+ règles, 2-10s) - Détecte la version PDF/A (PDF/A-1, PDF/A-3, etc.) - Rapports détaillés des non-conformités ### 3. Métadonnées XMP - Vérifie la présence de métadonnées XMP dans le PDF - Valide la conformité des métadonnées Factur-X (profil, version) - Extrait toutes les métadonnées XMP disponibles ### 4. Signatures électroniques - Détecte la présence de signatures ou cachets électroniques - Extrait les informations sur chaque signature (signataire, date, raison) - Compte le nombre de signatures présentes ## Paramètres - **fichier_pdf** : Le fichier PDF Factur-X à valider - **profil** : Le profil Factur-X attendu (optionnel). Si non spécifié, le profil sera automatiquement détecté depuis le fichier XML embarqué. - **use_verapdf** : Active la validation stricte PDF/A avec VeraPDF. ⚠️ **Attention** : VeraPDF peut prendre 2-10 secondes selon la taille du PDF. Recommandé uniquement en mode asynchrone pour éviter les timeouts. ## Récupération du résultat Après soumission, utilisez l'endpoint `GET /taches/{id_tache}/statut` pour récupérer le résultat. **Exemple de polling** : ```python import requests import time # 1. Soumettre la tâche response = requests.post(\"/valider-facturx-async\", files={\"fichier_pdf\": pdf_file}) task_id = response.json()[\"id_tache\"] # 2. Polling toutes les 2 secondes while True: status_response = requests.get(f\"/taches/{task_id}/statut\") status = status_response.json() if status[\"statut\"] == \"SUCCESS\": resultat = status[\"resultat\"][\"resultat_validation\"] print(f\"Conforme: {resultat['est_conforme']}\") break elif status[\"statut\"] == \"FAILURE\": print(f\"Erreur: {status['resultat']['message_erreur']}\") break time.sleep(2) # Attendre 2 secondes avant le prochain check ``` ## Cas d'usage - Valider des factures avant envoi avec VeraPDF (validation stricte) - Traiter des lots de factures en parallèle - Intégrer la validation dans un pipeline asynchrone - Valider des PDFs volumineux sans risque de timeout
622
+ Valide un PDF Factur-X de manière asynchrone avec système de polling. ## Fonctionnement 1. **Soumission** : Le PDF est mis en file d'attente pour validation asynchrone 2. **Retour immédiat** : Vous recevez un `id_tache` (HTTP 202) 3. **Suivi** : Utilisez l'endpoint `/taches/{id_tache}/statut` pour suivre l'avancement ## Avantages du mode asynchrone - **Pas de timeout** : Idéal pour les gros PDFs ou la validation VeraPDF (qui peut prendre plusieurs secondes) - **Scalabilité** : Les validations sont traitées par des workers Celery dédiés - **Suivi d'état** : Permet de suivre la progression de la validation - **Non-bloquant** : Votre client ne reste pas en attente pendant la validation ## Quand utiliser ce mode ? - **Validation VeraPDF activée** (`use_verapdf=True`) : La validation stricte peut prendre 2-10 secondes - **Gros fichiers PDF** : PDFs > 1 MB - **Traitement par lots** : Validation de multiples factures en parallèle - **Intégration asynchrone** : Votre système supporte le polling ## Contrôles effectués ### 1. Extraction et validation du XML Factur-X - Vérifie la présence d'un fichier XML embarqué conforme Factur-X - Détecte automatiquement le profil utilisé (MINIMUM, BASIC, EN16931, EXTENDED) - Valide le XML contre les règles Schematron du profil détecté ### 2. Conformité PDF/A - **Sans VeraPDF** : Validation basique par métadonnées (rapide, ~100ms) - **Avec VeraPDF** : Validation stricte selon ISO 19005 (146+ règles, 2-10s) - Détecte la version PDF/A (PDF/A-1, PDF/A-3, etc.) - Rapports détaillés des non-conformités ### 3. Métadonnées XMP - Vérifie la présence de métadonnées XMP dans le PDF - Valide la conformité des métadonnées Factur-X (profil, version) - Extrait toutes les métadonnées XMP disponibles ### 4. Signatures électroniques - Détecte la présence de signatures ou cachets électroniques - Extrait les informations sur chaque signature (signataire, date, raison) - Compte le nombre de signatures présentes ## Paramètres - **fichier_pdf** : Le fichier PDF Factur-X à valider - **profil** : Le profil Factur-X attendu (optionnel). Si non spécifié, le profil sera automatiquement détecté depuis le fichier XML embarqué. - **use_verapdf** : Active la validation stricte PDF/A avec VeraPDF. ⚠️ **Attention** : VeraPDF peut prendre 2-10 secondes selon la taille du PDF. Recommandé uniquement en mode asynchrone pour éviter les timeouts. ## Récupération du résultat Après soumission, utilisez l'endpoint `GET /taches/{id_tache}/statut` pour récupérer le résultat. **Exemple de polling** : ```python import requests import time # 1. Soumettre la tâche response = requests.post(\"/valider-facturx-async\", files={\"fichier_pdf\": pdf_file}) task_id = response.json()[\"id_tache\"] # 2. Polling toutes les 2 secondes while True: status_response = requests.get(f\"/taches/{task_id}/statut\") status = status_response.json() if status[\"statut\"] == \"SUCCESS\": resultat = status[\"resultat\"][\"resultat_validation\"] print(f\"Conforme: {resultat['est_conforme']}\") break elif status[\"statut\"] == \"FAILURE\": print(f\"Erreur: {status['resultat']['errorMessage']}\") break time.sleep(2) # Attendre 2 secondes avant le prochain check ``` ## Cas d'usage - Valider des factures avant envoi avec VeraPDF (validation stricte) - Traiter des lots de factures en parallèle - Intégrer la validation dans un pipeline asynchrone - Valider des PDFs volumineux sans risque de timeout
623
623
 
624
624
  ### Examples
625
625
 
data/docs/TypeFlux.md ADDED
@@ -0,0 +1,15 @@
1
+ # FactPulse::TypeFlux
2
+
3
+ ## Properties
4
+
5
+ | Name | Type | Description | Notes |
6
+ | ---- | ---- | ----------- | ----- |
7
+
8
+ ## Example
9
+
10
+ ```ruby
11
+ require 'factpulse'
12
+
13
+ instance = FactPulse::TypeFlux.new()
14
+ ```
15
+