factpulse 3.0.7__py3-none-any.whl → 3.0.23__py3-none-any.whl

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.

Potentially problematic release.


This version of factpulse might be problematic. Click here for more details.

Files changed (305) hide show
  1. factpulse/__init__.py +289 -12
  2. factpulse/api/__init__.py +2 -0
  3. factpulse/api/afnorpdppa_api.py +16 -14
  4. factpulse/api/afnorpdppa_directory_service_api.py +1224 -309
  5. factpulse/api/afnorpdppa_flow_service_api.py +199 -68
  6. factpulse/api/chorus_pro_api.py +61 -8
  7. factpulse/api/document_conversion_api.py +54 -338
  8. factpulse/api/downloads_api.py +1171 -0
  9. factpulse/api/e_reporting_api.py +3254 -0
  10. factpulse/api/health_api.py +8 -1
  11. factpulse/api/invoice_processing_api.py +234 -37
  12. factpulse/api/pdfxml_verification_api.py +98 -19
  13. factpulse/api/user_api.py +5 -1
  14. factpulse/api_client.py +3 -2
  15. factpulse/configuration.py +10 -5
  16. factpulse/exceptions.py +2 -1
  17. factpulse/models/__init__.py +143 -6
  18. factpulse/models/accept_language.py +38 -0
  19. factpulse/models/acknowledgment_status.py +2 -1
  20. factpulse/models/additional_document.py +2 -1
  21. factpulse/models/afnor_acknowledgement.py +100 -0
  22. factpulse/models/afnor_acknowledgement_detail.py +105 -0
  23. factpulse/models/afnor_address_edit.py +111 -0
  24. factpulse/models/afnor_address_patch.py +141 -0
  25. factpulse/models/afnor_address_put.py +129 -0
  26. factpulse/models/afnor_address_read.py +113 -0
  27. factpulse/models/afnor_algorithm.py +41 -0
  28. factpulse/models/afnor_contains_operator.py +37 -0
  29. factpulse/models/afnor_create_directory_line_body.py +98 -0
  30. factpulse/models/afnor_create_directory_line_body_addressing_information.py +122 -0
  31. factpulse/models/afnor_create_directory_line_body_period.py +91 -0
  32. factpulse/models/afnor_create_routing_code_body.py +153 -0
  33. factpulse/models/afnor_credentials.py +2 -1
  34. factpulse/models/afnor_destination.py +15 -15
  35. factpulse/models/afnor_diffusion_status.py +38 -0
  36. factpulse/models/afnor_directory_line_field.py +42 -0
  37. factpulse/models/afnor_directory_line_payload_history_legal_unit_facility_routing_code.py +139 -0
  38. factpulse/models/afnor_directory_line_payload_history_legal_unit_facility_routing_code_platform.py +92 -0
  39. factpulse/models/afnor_directory_line_payload_history_legal_unit_facility_routing_code_routing_code.py +134 -0
  40. factpulse/models/afnor_directory_line_post201_response.py +94 -0
  41. factpulse/models/afnor_directory_line_search_post200_response.py +104 -0
  42. factpulse/models/afnor_entity_type.py +38 -0
  43. factpulse/models/afnor_error.py +97 -0
  44. factpulse/models/afnor_facility_administrative_status.py +38 -0
  45. factpulse/models/afnor_facility_nature.py +38 -0
  46. factpulse/models/afnor_facility_payload_history.py +140 -0
  47. factpulse/models/afnor_facility_payload_history_ule_b2g_additional_data.py +98 -0
  48. factpulse/models/afnor_facility_payload_included.py +134 -0
  49. factpulse/models/afnor_facility_type.py +38 -0
  50. factpulse/models/afnor_flow.py +129 -0
  51. factpulse/models/afnor_flow_ack_status.py +39 -0
  52. factpulse/models/afnor_flow_direction.py +38 -0
  53. factpulse/models/afnor_flow_info.py +112 -0
  54. factpulse/models/afnor_flow_profile.py +39 -0
  55. factpulse/models/afnor_flow_syntax.py +41 -0
  56. factpulse/models/afnor_flow_type.py +49 -0
  57. factpulse/models/afnor_full_flow_info.py +117 -0
  58. factpulse/models/afnor_health_check_response.py +2 -1
  59. factpulse/models/afnor_legal_unit_administrative_status.py +38 -0
  60. factpulse/models/afnor_legal_unit_payload_history.py +107 -0
  61. factpulse/models/afnor_legal_unit_payload_included.py +107 -0
  62. factpulse/models/afnor_legal_unit_payload_included_no_siren.py +95 -0
  63. factpulse/models/afnor_platform_status.py +38 -0
  64. factpulse/models/afnor_processing_rule.py +42 -0
  65. factpulse/models/afnor_reason_code.py +141 -0
  66. factpulse/models/afnor_reason_code_enum.py +51 -0
  67. factpulse/models/afnor_recipient_platform_type.py +38 -0
  68. factpulse/models/afnor_result.py +25 -3
  69. factpulse/models/afnor_routing_code_administrative_status.py +38 -0
  70. factpulse/models/afnor_routing_code_field.py +44 -0
  71. factpulse/models/afnor_routing_code_payload_history_legal_unit_facility.py +158 -0
  72. factpulse/models/afnor_routing_code_post201_response.py +113 -0
  73. factpulse/models/afnor_routing_code_search.py +122 -0
  74. factpulse/models/afnor_routing_code_search_filters.py +128 -0
  75. factpulse/models/afnor_routing_code_search_filters_administrative_status.py +92 -0
  76. factpulse/models/afnor_routing_code_search_filters_routing_code_name.py +102 -0
  77. factpulse/models/afnor_routing_code_search_filters_routing_identifier.py +102 -0
  78. factpulse/models/afnor_routing_code_search_post200_response.py +104 -0
  79. factpulse/models/afnor_routing_code_search_sorting_inner.py +92 -0
  80. factpulse/models/afnor_search_directory_line.py +109 -0
  81. factpulse/models/afnor_search_directory_line_filters.py +116 -0
  82. factpulse/models/afnor_search_directory_line_filters_addressing_identifier.py +92 -0
  83. factpulse/models/afnor_search_directory_line_filters_addressing_suffix.py +92 -0
  84. factpulse/models/afnor_search_directory_line_sorting_inner.py +92 -0
  85. factpulse/models/afnor_search_flow_content.py +104 -0
  86. factpulse/models/afnor_search_flow_filters.py +106 -0
  87. factpulse/models/afnor_search_flow_params.py +95 -0
  88. factpulse/models/afnor_search_siren.py +109 -0
  89. factpulse/models/afnor_search_siren_filters.py +110 -0
  90. factpulse/models/afnor_search_siren_filters_administrative_status.py +92 -0
  91. factpulse/models/afnor_search_siren_filters_business_name.py +92 -0
  92. factpulse/models/afnor_search_siren_filters_entity_type.py +92 -0
  93. factpulse/models/afnor_search_siren_filters_siren.py +102 -0
  94. factpulse/models/afnor_search_siren_sorting_inner.py +92 -0
  95. factpulse/models/afnor_search_siret.py +122 -0
  96. factpulse/models/afnor_search_siret_filters.py +140 -0
  97. factpulse/models/afnor_search_siret_filters_address_lines.py +92 -0
  98. factpulse/models/afnor_search_siret_filters_administrative_status.py +92 -0
  99. factpulse/models/afnor_search_siret_filters_country_subdivision.py +92 -0
  100. factpulse/models/afnor_search_siret_filters_facility_type.py +92 -0
  101. factpulse/models/afnor_search_siret_filters_locality.py +92 -0
  102. factpulse/models/afnor_search_siret_filters_name.py +92 -0
  103. factpulse/models/afnor_search_siret_filters_postal_code.py +102 -0
  104. factpulse/models/afnor_search_siret_filters_siret.py +102 -0
  105. factpulse/models/afnor_search_siret_sorting_inner.py +92 -0
  106. factpulse/models/afnor_siren_field.py +41 -0
  107. factpulse/models/afnor_siren_search_post200_response.py +104 -0
  108. factpulse/models/afnor_siret_field.py +50 -0
  109. factpulse/models/afnor_siret_search_post200_response.py +104 -0
  110. factpulse/models/afnor_sorting_order.py +38 -0
  111. factpulse/models/afnor_strict_operator.py +37 -0
  112. factpulse/models/afnor_update_patch_directory_line_body.py +89 -0
  113. factpulse/models/afnor_update_patch_routing_code_body.py +120 -0
  114. factpulse/models/afnor_update_put_routing_code_body.py +114 -0
  115. factpulse/models/afnor_webhook_callback_content.py +92 -0
  116. factpulse/models/aggregated_payment_input.py +106 -0
  117. factpulse/models/aggregated_transaction_input.py +136 -0
  118. factpulse/models/allowance_charge.py +9 -6
  119. factpulse/models/allowance_charge_reason_code.py +74 -0
  120. factpulse/models/allowance_reason_code.py +2 -1
  121. factpulse/models/allowance_total_amount.py +2 -1
  122. factpulse/models/amount.py +3 -2
  123. factpulse/models/amount1.py +140 -0
  124. factpulse/models/amount_due.py +2 -1
  125. factpulse/models/api_error.py +2 -1
  126. factpulse/models/api_profile.py +41 -0
  127. factpulse/models/async_task_status.py +2 -1
  128. factpulse/models/base_amount.py +2 -1
  129. factpulse/models/bounding_box_schema.py +2 -1
  130. factpulse/models/buyercountry.py +137 -0
  131. factpulse/models/celery_status.py +2 -1
  132. factpulse/models/certificate_info_response.py +2 -1
  133. factpulse/models/charge_total_amount.py +2 -1
  134. factpulse/models/{facture_electronique_rest_api_schemas_chorus_pro_chorus_pro_credentials.py → chorus_pro_credentials.py} +5 -4
  135. factpulse/models/chorus_pro_destination.py +2 -1
  136. factpulse/models/chorus_pro_result.py +2 -1
  137. factpulse/models/contact.py +2 -1
  138. factpulse/models/convert_resume_request.py +2 -1
  139. factpulse/models/convert_success_response.py +2 -1
  140. factpulse/models/convert_validation_failed_response.py +7 -6
  141. factpulse/models/country_code.py +206 -0
  142. factpulse/models/create_aggregated_report_request.py +170 -0
  143. factpulse/models/create_e_reporting_request.py +173 -0
  144. factpulse/models/currency.py +137 -0
  145. factpulse/models/currency_code.py +89 -0
  146. factpulse/models/delivery_party.py +2 -1
  147. factpulse/models/destination.py +2 -1
  148. factpulse/models/directory_line_include.py +40 -0
  149. factpulse/models/doc_type.py +40 -0
  150. factpulse/models/document_type_info.py +2 -1
  151. factpulse/models/e_reporting_flow_type.py +40 -0
  152. factpulse/models/{convert_error_response.py → e_reporting_validation_error.py} +15 -23
  153. factpulse/models/electronic_address.py +4 -3
  154. factpulse/models/enriched_invoice_info.py +8 -7
  155. factpulse/models/error_level.py +2 -1
  156. factpulse/models/error_source.py +2 -1
  157. factpulse/models/extraction_info.py +2 -1
  158. factpulse/models/factur_x_invoice.py +2 -1
  159. factpulse/models/factur_xpdf_info.py +2 -1
  160. factpulse/models/facture_electronique_rest_api_schemas_ereporting_invoice_type_code.py +41 -0
  161. factpulse/models/facture_electronique_rest_api_schemas_processing_chorus_pro_credentials.py +2 -1
  162. factpulse/models/field_status.py +2 -1
  163. factpulse/models/file_info.py +2 -1
  164. factpulse/models/files_info.py +2 -1
  165. factpulse/models/flow_direction.py +2 -1
  166. factpulse/models/flow_profile.py +2 -1
  167. factpulse/models/flow_summary.py +5 -4
  168. factpulse/models/flow_syntax.py +2 -1
  169. factpulse/models/flow_type.py +12 -3
  170. factpulse/models/generate_aggregated_report_response.py +100 -0
  171. factpulse/models/generate_certificate_request.py +2 -1
  172. factpulse/models/generate_certificate_response.py +2 -1
  173. factpulse/models/generate_e_reporting_response.py +96 -0
  174. factpulse/models/get_chorus_pro_id_request.py +5 -4
  175. factpulse/models/get_chorus_pro_id_response.py +2 -1
  176. factpulse/models/get_invoice_request.py +5 -4
  177. factpulse/models/get_invoice_response.py +4 -3
  178. factpulse/models/get_structure_request.py +5 -4
  179. factpulse/models/get_structure_response.py +4 -3
  180. factpulse/models/global_allowance_amount.py +2 -1
  181. factpulse/models/gross_unit_price.py +2 -1
  182. factpulse/models/http_validation_error.py +2 -1
  183. factpulse/models/incoming_invoice.py +8 -29
  184. factpulse/models/incoming_supplier.py +2 -1
  185. factpulse/models/invoice_format.py +2 -1
  186. factpulse/models/invoice_input.py +179 -0
  187. factpulse/models/invoice_line.py +18 -2
  188. factpulse/models/invoice_line_allowance_amount.py +2 -1
  189. factpulse/models/invoice_note.py +4 -3
  190. factpulse/models/invoice_payment_input.py +110 -0
  191. factpulse/models/invoice_references.py +2 -1
  192. factpulse/models/invoice_status.py +2 -1
  193. factpulse/models/invoice_totals.py +2 -1
  194. factpulse/models/invoice_totals_prepayment.py +2 -1
  195. factpulse/models/invoice_type_code.py +2 -1
  196. factpulse/models/invoice_type_code_output.py +52 -0
  197. factpulse/models/invoicing_framework.py +4 -3
  198. factpulse/models/invoicing_framework_code.py +2 -1
  199. factpulse/models/line_net_amount.py +2 -1
  200. factpulse/models/line_sub_type.py +39 -0
  201. factpulse/models/line_total_amount.py +2 -1
  202. factpulse/models/{validation_error_loc_inner.py → location_inner.py} +8 -7
  203. factpulse/models/mandatory_note_schema.py +2 -1
  204. factpulse/models/manual_rate.py +2 -1
  205. factpulse/models/manual_vat_rate.py +2 -1
  206. factpulse/models/missing_field.py +2 -1
  207. factpulse/models/operation_nature.py +2 -1
  208. factpulse/models/output_format.py +2 -1
  209. factpulse/models/page_dimensions_schema.py +2 -1
  210. factpulse/models/payee.py +2 -1
  211. factpulse/models/payment_amount_by_rate.py +98 -0
  212. factpulse/models/payment_card.py +2 -1
  213. factpulse/models/payment_means.py +2 -1
  214. factpulse/models/pdf_validation_result_api.py +2 -1
  215. factpulse/models/pdp_credentials.py +2 -1
  216. factpulse/models/percentage.py +2 -1
  217. factpulse/models/postal_address.py +2 -1
  218. factpulse/models/price_allowance_amount.py +2 -1
  219. factpulse/models/price_basis_quantity.py +2 -1
  220. factpulse/models/processing_options.py +4 -3
  221. factpulse/models/processing_rule.py +42 -0
  222. factpulse/models/product_characteristic.py +2 -1
  223. factpulse/models/product_classification.py +2 -1
  224. factpulse/models/quantity.py +2 -1
  225. factpulse/models/rate.py +140 -0
  226. factpulse/models/rate1.py +140 -0
  227. factpulse/models/recipient.py +2 -1
  228. factpulse/models/report_period.py +91 -0
  229. factpulse/models/report_sender.py +98 -0
  230. factpulse/models/rounding_amount.py +2 -1
  231. factpulse/models/routing_code_include.py +38 -0
  232. factpulse/models/schematron_validation_error.py +128 -0
  233. factpulse/models/scheme_id.py +9 -1
  234. factpulse/models/search_flow_request.py +2 -1
  235. factpulse/models/search_flow_response.py +2 -1
  236. factpulse/models/search_services_response.py +5 -4
  237. factpulse/models/search_structure_request.py +5 -4
  238. factpulse/models/search_structure_response.py +2 -1
  239. factpulse/models/sellercountry.py +137 -0
  240. factpulse/models/signature_info.py +2 -1
  241. factpulse/models/signature_info_api.py +2 -1
  242. factpulse/models/signature_parameters.py +2 -1
  243. factpulse/models/simplified_invoice_data.py +30 -3
  244. factpulse/models/siret_include.py +37 -0
  245. factpulse/models/structure_info.py +2 -1
  246. factpulse/models/structure_parameters.py +2 -1
  247. factpulse/models/structure_service.py +2 -1
  248. factpulse/models/submission_mode.py +2 -1
  249. factpulse/models/submit_aggregated_report_request.py +127 -0
  250. factpulse/models/submit_complete_invoice_request.py +2 -1
  251. factpulse/models/submit_complete_invoice_response.py +2 -1
  252. factpulse/models/submit_e_reporting_request.py +127 -0
  253. factpulse/models/submit_e_reporting_response.py +117 -0
  254. factpulse/models/submit_flow_request.py +2 -1
  255. factpulse/models/submit_flow_response.py +2 -1
  256. factpulse/models/submit_gross_amount.py +2 -1
  257. factpulse/models/submit_invoice_request.py +5 -4
  258. factpulse/models/submit_invoice_response.py +2 -1
  259. factpulse/models/submit_net_amount.py +2 -1
  260. factpulse/models/submit_vat_amount.py +2 -1
  261. factpulse/models/supplementary_attachment.py +7 -6
  262. factpulse/models/supplier.py +2 -1
  263. factpulse/models/task_response.py +2 -1
  264. factpulse/models/tax_breakdown_input.py +104 -0
  265. factpulse/models/tax_due_date_type.py +42 -0
  266. factpulse/models/tax_representative.py +2 -1
  267. factpulse/models/taxable_amount.py +2 -1
  268. factpulse/models/taxableamount.py +140 -0
  269. factpulse/models/taxamount.py +140 -0
  270. factpulse/models/taxamount1.py +140 -0
  271. factpulse/models/taxamount2.py +140 -0
  272. factpulse/models/taxexclusiveamount.py +140 -0
  273. factpulse/models/taxexclusiveamount1.py +140 -0
  274. factpulse/models/total_gross_amount.py +2 -1
  275. factpulse/models/total_net_amount.py +2 -1
  276. factpulse/models/total_vat_amount.py +2 -1
  277. factpulse/models/transaction_category.py +40 -0
  278. factpulse/models/transmission_type_code.py +38 -0
  279. factpulse/models/unit_net_price.py +2 -1
  280. factpulse/models/unit_of_measure.py +2 -1
  281. factpulse/models/validate_e_reporting_request.py +92 -0
  282. factpulse/models/validate_e_reporting_response.py +113 -0
  283. factpulse/models/validation_error.py +5 -4
  284. factpulse/models/validation_error_detail.py +2 -1
  285. factpulse/models/validation_error_response.py +2 -1
  286. factpulse/models/validation_info.py +5 -4
  287. factpulse/models/validation_success_response.py +2 -1
  288. factpulse/models/vat_accounting_code.py +2 -1
  289. factpulse/models/vat_amount.py +2 -1
  290. factpulse/models/vat_category.py +2 -1
  291. factpulse/models/vat_line.py +2 -1
  292. factpulse/models/vat_point_date_code.py +2 -1
  293. factpulse/models/vat_rate.py +2 -1
  294. factpulse/models/verification_success_response.py +2 -1
  295. factpulse/models/verified_field_schema.py +2 -1
  296. factpulse/rest.py +2 -1
  297. {factpulse-3.0.7.dist-info → factpulse-3.0.23.dist-info}/METADATA +42 -40
  298. factpulse-3.0.23.dist-info/RECORD +306 -0
  299. {factpulse-3.0.7.dist-info → factpulse-3.0.23.dist-info}/licenses/LICENSE +1 -1
  300. factpulse_helpers/client.py +2 -1
  301. factpulse/models/convert_pending_input_response.py +0 -114
  302. factpulse/models/factur_x_profile.py +0 -39
  303. factpulse-3.0.7.dist-info/RECORD +0 -168
  304. {factpulse-3.0.7.dist-info → factpulse-3.0.23.dist-info}/WHEEL +0 -0
  305. {factpulse-3.0.7.dist-info → factpulse-3.0.23.dist-info}/top_level.txt +0 -0
@@ -3,9 +3,10 @@
3
3
  """
4
4
  FactPulse REST API
5
5
 
6
- REST API for electronic invoicing in France: Factur-X, AFNOR PDP/PA, electronic signatures. ## 🎯 Main Features ### 📄 Factur-X Invoice Generation - **Formats**: XML only or PDF/A-3 with embedded XML - **Profiles**: MINIMUM, BASIC, EN16931, EXTENDED - **Standards**: EN 16931 (EU directive 2014/55), ISO 19005-3 (PDF/A-3), CII (UN/CEFACT) - **🆕 Simplified Format**: Generation from SIRET + auto-enrichment (Chorus Pro API + Business Search) ### ✅ Validation and Compliance - **XML Validation**: Schematron (45 to 210+ rules depending on profile) - **PDF Validation**: PDF/A-3, Factur-X XMP metadata, electronic signatures - **VeraPDF**: Strict PDF/A validation (146+ ISO 19005-3 rules) - **Asynchronous Processing**: Celery support for heavy validations (VeraPDF) ### 📡 AFNOR PDP/PA Integration (XP Z12-013) - **Flow Submission**: Send invoices to Partner Dematerialization Platforms - **Flow Search**: View submitted invoices - **Download**: Retrieve PDF/A-3 with XML - **Directory Service**: Company search (SIREN/SIRET) - **Multi-client**: Support for multiple PDP configs per user (stored credentials or zero-storage) ### ✍️ PDF Electronic Signature - **Standards**: PAdES-B-B, PAdES-B-T (RFC 3161 timestamping), PAdES-B-LT (long-term archival) - **eIDAS Levels**: SES (self-signed), AdES (commercial CA), QES (QTSP) - **Validation**: Cryptographic integrity and certificate verification - **Certificate Generation**: Self-signed X.509 certificates for testing ### 🔄 Asynchronous Processing - **Celery**: Asynchronous generation, validation and signing - **Polling**: Status tracking via `/tasks/{task_id}/status` - **No timeout**: Ideal for large files or heavy validations ## 🔒 Authentication All requests require a **JWT token** in the Authorization header: ``` Authorization: Bearer YOUR_JWT_TOKEN ``` ### How to obtain a JWT token? #### 🔑 Method 1: `/api/token/` API (Recommended) **URL:** `https://www.factpulse.fr/api/token/` This method is **recommended** for integration in your applications and CI/CD workflows. **Prerequisites:** Having set a password on your account **For users registered via email/password:** - You already have a password, use it directly **For users registered via OAuth (Google/GitHub):** - You must first set a password at: https://www.factpulse.fr/accounts/password/set/ - Once the password is created, you can use the API **Request example:** ```bash curl -X POST https://www.factpulse.fr/api/token/ \\ -H \"Content-Type: application/json\" \\ -d '{ \"username\": \"your_email@example.com\", \"password\": \"your_password\" }' ``` **Optional `client_uid` parameter:** To select credentials for a specific client (PA/PDP, Chorus Pro, signing certificates), add `client_uid`: ```bash curl -X POST https://www.factpulse.fr/api/token/ \\ -H \"Content-Type: application/json\" \\ -d '{ \"username\": \"your_email@example.com\", \"password\": \"your_password\", \"client_uid\": \"550e8400-e29b-41d4-a716-446655440000\" }' ``` The `client_uid` will be included in the JWT and allow the API to automatically use: - AFNOR/PDP credentials configured for this client - Chorus Pro credentials configured for this client - Electronic signature certificates configured for this client **Response:** ```json { \"access\": \"eyJ0eXAiOiJKV1QiLCJhbGc...\", // Access token (validity: 30 min) \"refresh\": \"eyJ0eXAiOiJKV1QiLCJhbGc...\" // Refresh token (validity: 7 days) } ``` **Advantages:** - ✅ Full automation (CI/CD, scripts) - ✅ Programmatic token management - ✅ Refresh token support for automatic access renewal - ✅ Easy integration in any language/tool #### 🖥️ Method 2: Dashboard Generation (Alternative) **URL:** https://www.factpulse.fr/dashboard/ This method is suitable for quick tests or occasional use via the graphical interface. **How it works:** - Log in to the dashboard - Use the \"Generate Test Token\" or \"Generate Production Token\" buttons - Works for **all** users (OAuth and email/password), without requiring a password **Token types:** - **Test Token**: 24h validity, 1000 calls/day quota (free) - **Production Token**: 7 days validity, quota based on your plan **Advantages:** - ✅ Quick for API testing - ✅ No password required - ✅ Simple visual interface **Disadvantages:** - ❌ Requires manual action - ❌ No refresh token - ❌ Less suited for automation ### 📚 Full Documentation For more information on authentication and API usage: https://www.factpulse.fr/documentation-api/
6
+ REST API for electronic invoicing in France: Factur-X, AFNOR PDP/PA, electronic signatures. ## 🎯 Main Features ### 📄 Factur-X Invoice Generation - **Formats**: XML only or PDF/A-3 with embedded XML - **Profiles**: MINIMUM, BASIC, EN16931, EXTENDED - **Standards**: EN 16931 (EU directive 2014/55), ISO 19005-3 (PDF/A-3), CII (UN/CEFACT) - **🆕 Simplified Format**: Generation from SIRET + auto-enrichment (Chorus Pro API + Business Search) ### ✅ Validation and Compliance - **XML Validation**: Schematron (45 to 210+ rules depending on profile) - **PDF Validation**: PDF/A-3, Factur-X XMP metadata, electronic signatures - **VeraPDF**: Strict PDF/A validation (146+ ISO 19005-3 rules) - **Asynchronous Processing**: Celery support for heavy validations (VeraPDF) ### 📡 AFNOR PDP/PA Integration (XP Z12-013) - **Flow Submission**: Send invoices to Partner Dematerialization Platforms - **Flow Search**: View submitted invoices - **Download**: Retrieve PDF/A-3 with XML - **Directory Service**: Company search (SIREN/SIRET) - **Multi-client**: Support for multiple PDP configs per user (stored credentials or zero-storage) ### ✍️ PDF Electronic Signature - **Standards**: PAdES-B-B, PAdES-B-T (RFC 3161 timestamping), PAdES-B-LT (long-term archival) - **eIDAS Levels**: SES (self-signed), AdES (commercial CA), QES (QTSP) - **Validation**: Cryptographic integrity and certificate verification - **Certificate Generation**: Self-signed X.509 certificates for testing ### 🔄 Asynchronous Processing - **Celery**: Asynchronous generation, validation and signing - **Polling**: Status tracking via `/tasks/{task_id}/status` - **No timeout**: Ideal for large files or heavy validations ## 🔒 Authentication All requests require a **JWT token** in the Authorization header: ``` Authorization: Bearer YOUR_JWT_TOKEN ``` ### How to obtain a JWT token? #### 🔑 Method 1: `/api/token/` API (Recommended) **URL:** `https://factpulse.fr/api/token/` This method is **recommended** for integration in your applications and CI/CD workflows. **Prerequisites:** Having set a password on your account **For users registered via email/password:** - You already have a password, use it directly **For users registered via OAuth (Google/GitHub):** - You must first set a password at: https://factpulse.fr/accounts/password/set/ - Once the password is created, you can use the API **Request example:** ```bash curl -X POST https://factpulse.fr/api/token/ \\ -H \"Content-Type: application/json\" \\ -d '{ \"username\": \"your_email@example.com\", \"password\": \"your_password\" }' ``` **Optional `client_uid` parameter:** To select credentials for a specific client (PA/PDP, Chorus Pro, signing certificates), add `client_uid`: ```bash curl -X POST https://factpulse.fr/api/token/ \\ -H \"Content-Type: application/json\" \\ -d '{ \"username\": \"your_email@example.com\", \"password\": \"your_password\", \"client_uid\": \"550e8400-e29b-41d4-a716-446655440000\" }' ``` The `client_uid` will be included in the JWT and allow the API to automatically use: - AFNOR/PDP credentials configured for this client - Chorus Pro credentials configured for this client - Electronic signature certificates configured for this client **Response:** ```json { \"access\": \"eyJ0eXAiOiJKV1QiLCJhbGc...\", // Access token (validity: 30 min) \"refresh\": \"eyJ0eXAiOiJKV1QiLCJhbGc...\" // Refresh token (validity: 7 days) } ``` **Advantages:** - ✅ Full automation (CI/CD, scripts) - ✅ Programmatic token management - ✅ Refresh token support for automatic access renewal - ✅ Easy integration in any language/tool #### 🖥️ Method 2: Dashboard Generation (Alternative) **URL:** https://factpulse.fr/api/dashboard/ This method is suitable for quick tests or occasional use via the graphical interface. **How it works:** - Log in to the dashboard - Use the \"Generate Test Token\" or \"Generate Production Token\" buttons - Works for **all** users (OAuth and email/password), without requiring a password **Token types:** - **Test Token**: 24h validity, 1000 calls/day quota (free) - **Production Token**: 7 days validity, quota based on your plan **Advantages:** - ✅ Quick for API testing - ✅ No password required - ✅ Simple visual interface **Disadvantages:** - ❌ Requires manual action - ❌ No refresh token - ❌ Less suited for automation ### 📚 Full Documentation For more information on authentication and API usage: https://factpulse.fr/documentation-api/
7
7
 
8
8
  The version of the OpenAPI document: 1.0.0
9
+ Contact: contact@factpulse.fr
9
10
  Generated by OpenAPI Generator (https://openapi-generator.tech)
10
11
 
11
12
  Do not edit the class manually.
@@ -20,6 +21,7 @@ from pydantic import Field, StrictBytes, StrictStr
20
21
  from typing import Any, Dict, Optional, Tuple, Union
21
22
  from typing_extensions import Annotated
22
23
  from factpulse.models.convert_resume_request import ConvertResumeRequest
24
+ from factpulse.models.convert_success_response import ConvertSuccessResponse
23
25
 
24
26
  from factpulse.api_client import ApiClient, RequestSerialized
25
27
  from factpulse.api_response import ApiResponse
@@ -39,325 +41,13 @@ class DocumentConversionApi:
39
41
  self.api_client = api_client
40
42
 
41
43
 
42
- @validate_call
43
- def convert_document_api_v1_convert_post(
44
- self,
45
- file: Annotated[Union[StrictBytes, StrictStr, Tuple[StrictStr, StrictBytes]], Field(description="Document à convertir (PDF, DOCX, XLSX, JPG, PNG)")],
46
- output: Annotated[Optional[StrictStr], Field(description="Format de sortie: pdf, xml, both")] = None,
47
- callback_url: Optional[StrictStr] = None,
48
- _request_timeout: Union[
49
- None,
50
- Annotated[StrictFloat, Field(gt=0)],
51
- Tuple[
52
- Annotated[StrictFloat, Field(gt=0)],
53
- Annotated[StrictFloat, Field(gt=0)]
54
- ]
55
- ] = None,
56
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
57
- _content_type: Optional[StrictStr] = None,
58
- _headers: Optional[Dict[StrictStr, Any]] = None,
59
- _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
60
- ) -> ConvertSuccessResponse:
61
- """Convertir un document en Factur-X
62
-
63
- Convertit un document (PDF, DOCX, XLSX, image) en Factur-X conforme. ## Workflow 1. **Upload** : Le document est envoyé en multipart/form-data 2. **Extraction OCR + Classification** : Mistral OCR extrait les données et classifie le document en un seul appel 3. **Enrichissement** : Les données sont enrichies via SIRENE (SIRET → raison sociale) 4. **Validation** : Les règles Schematron sont appliquées 5. **Génération** : Le Factur-X PDF/A-3 est généré ## Réponses possibles - **200** : Conversion réussie, fichiers disponibles - **202** : Données manquantes, complétion requise - **422** : Validation échouée, corrections nécessaires - **400** : Fichier invalide - **429** : Quota dépassé
64
-
65
- :param file: Document à convertir (PDF, DOCX, XLSX, JPG, PNG) (required)
66
- :type file: bytearray
67
- :param output: Format de sortie: pdf, xml, both
68
- :type output: str
69
- :param callback_url:
70
- :type callback_url: str
71
- :param _request_timeout: timeout setting for this request. If one
72
- number provided, it will be total request
73
- timeout. It can also be a pair (tuple) of
74
- (connection, read) timeouts.
75
- :type _request_timeout: int, tuple(int, int), optional
76
- :param _request_auth: set to override the auth_settings for an a single
77
- request; this effectively ignores the
78
- authentication in the spec for a single request.
79
- :type _request_auth: dict, optional
80
- :param _content_type: force content-type for the request.
81
- :type _content_type: str, Optional
82
- :param _headers: set to override the headers for a single
83
- request; this effectively ignores the headers
84
- in the spec for a single request.
85
- :type _headers: dict, optional
86
- :param _host_index: set to override the host_index for a single
87
- request; this effectively ignores the host_index
88
- in the spec for a single request.
89
- :type _host_index: int, optional
90
- :return: Returns the result object.
91
- """ # noqa: E501
92
-
93
- _param = self._convert_document_api_v1_convert_post_serialize(
94
- file=file,
95
- output=output,
96
- callback_url=callback_url,
97
- _request_auth=_request_auth,
98
- _content_type=_content_type,
99
- _headers=_headers,
100
- _host_index=_host_index
101
- )
102
-
103
- _response_types_map: Dict[str, Optional[str]] = {
104
- '200': "ConvertSuccessResponse",
105
- '202': "ConvertPendingInputResponse",
106
- '422': "ConvertValidationFailedResponse",
107
- '400': "ConvertErrorResponse",
108
- }
109
- response_data = self.api_client.call_api(
110
- *_param,
111
- _request_timeout=_request_timeout
112
- )
113
- response_data.read()
114
- return self.api_client.response_deserialize(
115
- response_data=response_data,
116
- response_types_map=_response_types_map,
117
- ).data
118
-
119
-
120
- @validate_call
121
- def convert_document_api_v1_convert_post_with_http_info(
122
- self,
123
- file: Annotated[Union[StrictBytes, StrictStr, Tuple[StrictStr, StrictBytes]], Field(description="Document à convertir (PDF, DOCX, XLSX, JPG, PNG)")],
124
- output: Annotated[Optional[StrictStr], Field(description="Format de sortie: pdf, xml, both")] = None,
125
- callback_url: Optional[StrictStr] = None,
126
- _request_timeout: Union[
127
- None,
128
- Annotated[StrictFloat, Field(gt=0)],
129
- Tuple[
130
- Annotated[StrictFloat, Field(gt=0)],
131
- Annotated[StrictFloat, Field(gt=0)]
132
- ]
133
- ] = None,
134
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
135
- _content_type: Optional[StrictStr] = None,
136
- _headers: Optional[Dict[StrictStr, Any]] = None,
137
- _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
138
- ) -> ApiResponse[ConvertSuccessResponse]:
139
- """Convertir un document en Factur-X
140
-
141
- Convertit un document (PDF, DOCX, XLSX, image) en Factur-X conforme. ## Workflow 1. **Upload** : Le document est envoyé en multipart/form-data 2. **Extraction OCR + Classification** : Mistral OCR extrait les données et classifie le document en un seul appel 3. **Enrichissement** : Les données sont enrichies via SIRENE (SIRET → raison sociale) 4. **Validation** : Les règles Schematron sont appliquées 5. **Génération** : Le Factur-X PDF/A-3 est généré ## Réponses possibles - **200** : Conversion réussie, fichiers disponibles - **202** : Données manquantes, complétion requise - **422** : Validation échouée, corrections nécessaires - **400** : Fichier invalide - **429** : Quota dépassé
142
-
143
- :param file: Document à convertir (PDF, DOCX, XLSX, JPG, PNG) (required)
144
- :type file: bytearray
145
- :param output: Format de sortie: pdf, xml, both
146
- :type output: str
147
- :param callback_url:
148
- :type callback_url: str
149
- :param _request_timeout: timeout setting for this request. If one
150
- number provided, it will be total request
151
- timeout. It can also be a pair (tuple) of
152
- (connection, read) timeouts.
153
- :type _request_timeout: int, tuple(int, int), optional
154
- :param _request_auth: set to override the auth_settings for an a single
155
- request; this effectively ignores the
156
- authentication in the spec for a single request.
157
- :type _request_auth: dict, optional
158
- :param _content_type: force content-type for the request.
159
- :type _content_type: str, Optional
160
- :param _headers: set to override the headers for a single
161
- request; this effectively ignores the headers
162
- in the spec for a single request.
163
- :type _headers: dict, optional
164
- :param _host_index: set to override the host_index for a single
165
- request; this effectively ignores the host_index
166
- in the spec for a single request.
167
- :type _host_index: int, optional
168
- :return: Returns the result object.
169
- """ # noqa: E501
170
-
171
- _param = self._convert_document_api_v1_convert_post_serialize(
172
- file=file,
173
- output=output,
174
- callback_url=callback_url,
175
- _request_auth=_request_auth,
176
- _content_type=_content_type,
177
- _headers=_headers,
178
- _host_index=_host_index
179
- )
180
-
181
- _response_types_map: Dict[str, Optional[str]] = {
182
- '200': "ConvertSuccessResponse",
183
- '202': "ConvertPendingInputResponse",
184
- '422': "ConvertValidationFailedResponse",
185
- '400': "ConvertErrorResponse",
186
- }
187
- response_data = self.api_client.call_api(
188
- *_param,
189
- _request_timeout=_request_timeout
190
- )
191
- response_data.read()
192
- return self.api_client.response_deserialize(
193
- response_data=response_data,
194
- response_types_map=_response_types_map,
195
- )
196
-
197
-
198
- @validate_call
199
- def convert_document_api_v1_convert_post_without_preload_content(
200
- self,
201
- file: Annotated[Union[StrictBytes, StrictStr, Tuple[StrictStr, StrictBytes]], Field(description="Document à convertir (PDF, DOCX, XLSX, JPG, PNG)")],
202
- output: Annotated[Optional[StrictStr], Field(description="Format de sortie: pdf, xml, both")] = None,
203
- callback_url: Optional[StrictStr] = None,
204
- _request_timeout: Union[
205
- None,
206
- Annotated[StrictFloat, Field(gt=0)],
207
- Tuple[
208
- Annotated[StrictFloat, Field(gt=0)],
209
- Annotated[StrictFloat, Field(gt=0)]
210
- ]
211
- ] = None,
212
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
213
- _content_type: Optional[StrictStr] = None,
214
- _headers: Optional[Dict[StrictStr, Any]] = None,
215
- _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
216
- ) -> RESTResponseType:
217
- """Convertir un document en Factur-X
218
-
219
- Convertit un document (PDF, DOCX, XLSX, image) en Factur-X conforme. ## Workflow 1. **Upload** : Le document est envoyé en multipart/form-data 2. **Extraction OCR + Classification** : Mistral OCR extrait les données et classifie le document en un seul appel 3. **Enrichissement** : Les données sont enrichies via SIRENE (SIRET → raison sociale) 4. **Validation** : Les règles Schematron sont appliquées 5. **Génération** : Le Factur-X PDF/A-3 est généré ## Réponses possibles - **200** : Conversion réussie, fichiers disponibles - **202** : Données manquantes, complétion requise - **422** : Validation échouée, corrections nécessaires - **400** : Fichier invalide - **429** : Quota dépassé
220
-
221
- :param file: Document à convertir (PDF, DOCX, XLSX, JPG, PNG) (required)
222
- :type file: bytearray
223
- :param output: Format de sortie: pdf, xml, both
224
- :type output: str
225
- :param callback_url:
226
- :type callback_url: str
227
- :param _request_timeout: timeout setting for this request. If one
228
- number provided, it will be total request
229
- timeout. It can also be a pair (tuple) of
230
- (connection, read) timeouts.
231
- :type _request_timeout: int, tuple(int, int), optional
232
- :param _request_auth: set to override the auth_settings for an a single
233
- request; this effectively ignores the
234
- authentication in the spec for a single request.
235
- :type _request_auth: dict, optional
236
- :param _content_type: force content-type for the request.
237
- :type _content_type: str, Optional
238
- :param _headers: set to override the headers for a single
239
- request; this effectively ignores the headers
240
- in the spec for a single request.
241
- :type _headers: dict, optional
242
- :param _host_index: set to override the host_index for a single
243
- request; this effectively ignores the host_index
244
- in the spec for a single request.
245
- :type _host_index: int, optional
246
- :return: Returns the result object.
247
- """ # noqa: E501
248
-
249
- _param = self._convert_document_api_v1_convert_post_serialize(
250
- file=file,
251
- output=output,
252
- callback_url=callback_url,
253
- _request_auth=_request_auth,
254
- _content_type=_content_type,
255
- _headers=_headers,
256
- _host_index=_host_index
257
- )
258
-
259
- _response_types_map: Dict[str, Optional[str]] = {
260
- '200': "ConvertSuccessResponse",
261
- '202': "ConvertPendingInputResponse",
262
- '422': "ConvertValidationFailedResponse",
263
- '400': "ConvertErrorResponse",
264
- }
265
- response_data = self.api_client.call_api(
266
- *_param,
267
- _request_timeout=_request_timeout
268
- )
269
- return response_data.response
270
-
271
-
272
- def _convert_document_api_v1_convert_post_serialize(
273
- self,
274
- file,
275
- output,
276
- callback_url,
277
- _request_auth,
278
- _content_type,
279
- _headers,
280
- _host_index,
281
- ) -> RequestSerialized:
282
-
283
- _host = None
284
-
285
- _collection_formats: Dict[str, str] = {
286
- }
287
-
288
- _path_params: Dict[str, str] = {}
289
- _query_params: List[Tuple[str, str]] = []
290
- _header_params: Dict[str, Optional[str]] = _headers or {}
291
- _form_params: List[Tuple[str, str]] = []
292
- _files: Dict[
293
- str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
294
- ] = {}
295
- _body_params: Optional[bytes] = None
296
-
297
- # process the path parameters
298
- # process the query parameters
299
- # process the header parameters
300
- # process the form parameters
301
- if file is not None:
302
- _files['file'] = file
303
- if output is not None:
304
- _form_params.append(('output', output))
305
- if callback_url is not None:
306
- _form_params.append(('callback_url', callback_url))
307
- # process the body parameter
308
-
309
-
310
- # set the HTTP header `Accept`
311
- if 'Accept' not in _header_params:
312
- _header_params['Accept'] = self.api_client.select_header_accept(
313
- [
314
- 'application/json'
315
- ]
316
- )
317
-
318
- # set the HTTP header `Content-Type`
319
- if _content_type:
320
- _header_params['Content-Type'] = _content_type
321
- else:
322
- _default_content_type = (
323
- self.api_client.select_header_content_type(
324
- [
325
- 'multipart/form-data'
326
- ]
327
- )
328
- )
329
- if _default_content_type is not None:
330
- _header_params['Content-Type'] = _default_content_type
331
-
332
- # authentication setting
333
- _auth_settings: List[str] = [
334
- 'HTTPBearer'
335
- ]
336
-
337
- return self.api_client.param_serialize(
338
- method='POST',
339
- resource_path='/api/v1/convert',
340
- path_params=_path_params,
341
- query_params=_query_params,
342
- header_params=_header_params,
343
- body=_body_params,
344
- post_params=_form_params,
345
- files=_files,
346
- auth_settings=_auth_settings,
347
- collection_formats=_collection_formats,
348
- _host=_host,
349
- _request_auth=_request_auth
350
- )
351
-
352
-
353
-
354
-
355
44
  @validate_call
356
45
  def convert_document_async_api_v1_convert_async_post(
357
46
  self,
358
47
  file: Annotated[Union[StrictBytes, StrictStr, Tuple[StrictStr, StrictBytes]], Field(description="Document à convertir (PDF, DOCX, XLSX, JPG, PNG)")],
359
48
  output: Annotated[Optional[StrictStr], Field(description="Format de sortie: pdf, xml, both")] = None,
360
49
  callback_url: Optional[StrictStr] = None,
50
+ webhook_mode: Annotated[Optional[StrictStr], Field(description="Mode de livraison du contenu: 'inline' (base64 dans webhook) ou 'download_url' (URL temporaire 1h)")] = None,
361
51
  _request_timeout: Union[
362
52
  None,
363
53
  Annotated[StrictFloat, Field(gt=0)],
@@ -381,6 +71,8 @@ class DocumentConversionApi:
381
71
  :type output: str
382
72
  :param callback_url:
383
73
  :type callback_url: str
74
+ :param webhook_mode: Mode de livraison du contenu: 'inline' (base64 dans webhook) ou 'download_url' (URL temporaire 1h)
75
+ :type webhook_mode: str
384
76
  :param _request_timeout: timeout setting for this request. If one
385
77
  number provided, it will be total request
386
78
  timeout. It can also be a pair (tuple) of
@@ -407,6 +99,7 @@ class DocumentConversionApi:
407
99
  file=file,
408
100
  output=output,
409
101
  callback_url=callback_url,
102
+ webhook_mode=webhook_mode,
410
103
  _request_auth=_request_auth,
411
104
  _content_type=_content_type,
412
105
  _headers=_headers,
@@ -418,6 +111,7 @@ class DocumentConversionApi:
418
111
  '202': None,
419
112
  '400': None,
420
113
  '422': "HTTPValidationError",
114
+ '401': "APIError",
421
115
  }
422
116
  response_data = self.api_client.call_api(
423
117
  *_param,
@@ -436,6 +130,7 @@ class DocumentConversionApi:
436
130
  file: Annotated[Union[StrictBytes, StrictStr, Tuple[StrictStr, StrictBytes]], Field(description="Document à convertir (PDF, DOCX, XLSX, JPG, PNG)")],
437
131
  output: Annotated[Optional[StrictStr], Field(description="Format de sortie: pdf, xml, both")] = None,
438
132
  callback_url: Optional[StrictStr] = None,
133
+ webhook_mode: Annotated[Optional[StrictStr], Field(description="Mode de livraison du contenu: 'inline' (base64 dans webhook) ou 'download_url' (URL temporaire 1h)")] = None,
439
134
  _request_timeout: Union[
440
135
  None,
441
136
  Annotated[StrictFloat, Field(gt=0)],
@@ -459,6 +154,8 @@ class DocumentConversionApi:
459
154
  :type output: str
460
155
  :param callback_url:
461
156
  :type callback_url: str
157
+ :param webhook_mode: Mode de livraison du contenu: 'inline' (base64 dans webhook) ou 'download_url' (URL temporaire 1h)
158
+ :type webhook_mode: str
462
159
  :param _request_timeout: timeout setting for this request. If one
463
160
  number provided, it will be total request
464
161
  timeout. It can also be a pair (tuple) of
@@ -485,6 +182,7 @@ class DocumentConversionApi:
485
182
  file=file,
486
183
  output=output,
487
184
  callback_url=callback_url,
185
+ webhook_mode=webhook_mode,
488
186
  _request_auth=_request_auth,
489
187
  _content_type=_content_type,
490
188
  _headers=_headers,
@@ -496,6 +194,7 @@ class DocumentConversionApi:
496
194
  '202': None,
497
195
  '400': None,
498
196
  '422': "HTTPValidationError",
197
+ '401': "APIError",
499
198
  }
500
199
  response_data = self.api_client.call_api(
501
200
  *_param,
@@ -514,6 +213,7 @@ class DocumentConversionApi:
514
213
  file: Annotated[Union[StrictBytes, StrictStr, Tuple[StrictStr, StrictBytes]], Field(description="Document à convertir (PDF, DOCX, XLSX, JPG, PNG)")],
515
214
  output: Annotated[Optional[StrictStr], Field(description="Format de sortie: pdf, xml, both")] = None,
516
215
  callback_url: Optional[StrictStr] = None,
216
+ webhook_mode: Annotated[Optional[StrictStr], Field(description="Mode de livraison du contenu: 'inline' (base64 dans webhook) ou 'download_url' (URL temporaire 1h)")] = None,
517
217
  _request_timeout: Union[
518
218
  None,
519
219
  Annotated[StrictFloat, Field(gt=0)],
@@ -537,6 +237,8 @@ class DocumentConversionApi:
537
237
  :type output: str
538
238
  :param callback_url:
539
239
  :type callback_url: str
240
+ :param webhook_mode: Mode de livraison du contenu: 'inline' (base64 dans webhook) ou 'download_url' (URL temporaire 1h)
241
+ :type webhook_mode: str
540
242
  :param _request_timeout: timeout setting for this request. If one
541
243
  number provided, it will be total request
542
244
  timeout. It can also be a pair (tuple) of
@@ -563,6 +265,7 @@ class DocumentConversionApi:
563
265
  file=file,
564
266
  output=output,
565
267
  callback_url=callback_url,
268
+ webhook_mode=webhook_mode,
566
269
  _request_auth=_request_auth,
567
270
  _content_type=_content_type,
568
271
  _headers=_headers,
@@ -574,6 +277,7 @@ class DocumentConversionApi:
574
277
  '202': None,
575
278
  '400': None,
576
279
  '422': "HTTPValidationError",
280
+ '401': "APIError",
577
281
  }
578
282
  response_data = self.api_client.call_api(
579
283
  *_param,
@@ -587,6 +291,7 @@ class DocumentConversionApi:
587
291
  file,
588
292
  output,
589
293
  callback_url,
294
+ webhook_mode,
590
295
  _request_auth,
591
296
  _content_type,
592
297
  _headers,
@@ -617,6 +322,8 @@ class DocumentConversionApi:
617
322
  _form_params.append(('output', output))
618
323
  if callback_url is not None:
619
324
  _form_params.append(('callback_url', callback_url))
325
+ if webhook_mode is not None:
326
+ _form_params.append(('webhook_mode', webhook_mode))
620
327
  # process the body parameter
621
328
 
622
329
 
@@ -668,8 +375,8 @@ class DocumentConversionApi:
668
375
  @validate_call
669
376
  def download_file_api_v1_convert_conversion_id_download_filename_get(
670
377
  self,
671
- conversion_id: StrictStr,
672
- filename: StrictStr,
378
+ conversion_id: Annotated[StrictStr, Field(description="Conversion ID returned by POST /convert (UUID format)")],
379
+ filename: Annotated[StrictStr, Field(description="File to download: 'facturx.pdf' or 'facturx.xml'")],
673
380
  _request_timeout: Union[
674
381
  None,
675
382
  Annotated[StrictFloat, Field(gt=0)],
@@ -687,9 +394,9 @@ class DocumentConversionApi:
687
394
 
688
395
  Télécharge le fichier Factur-X PDF ou XML généré. ## Fichiers disponibles - `facturx.pdf` : PDF/A-3 avec XML embarqué - `facturx.xml` : XML CII seul (Cross Industry Invoice) Les fichiers sont disponibles pendant 24 heures après génération.
689
396
 
690
- :param conversion_id: (required)
397
+ :param conversion_id: Conversion ID returned by POST /convert (UUID format) (required)
691
398
  :type conversion_id: str
692
- :param filename: (required)
399
+ :param filename: File to download: 'facturx.pdf' or 'facturx.xml' (required)
693
400
  :type filename: str
694
401
  :param _request_timeout: timeout setting for this request. If one
695
402
  number provided, it will be total request
@@ -726,6 +433,7 @@ class DocumentConversionApi:
726
433
  '200': "object",
727
434
  '404': None,
728
435
  '422': "HTTPValidationError",
436
+ '401': "APIError",
729
437
  }
730
438
  response_data = self.api_client.call_api(
731
439
  *_param,
@@ -741,8 +449,8 @@ class DocumentConversionApi:
741
449
  @validate_call
742
450
  def download_file_api_v1_convert_conversion_id_download_filename_get_with_http_info(
743
451
  self,
744
- conversion_id: StrictStr,
745
- filename: StrictStr,
452
+ conversion_id: Annotated[StrictStr, Field(description="Conversion ID returned by POST /convert (UUID format)")],
453
+ filename: Annotated[StrictStr, Field(description="File to download: 'facturx.pdf' or 'facturx.xml'")],
746
454
  _request_timeout: Union[
747
455
  None,
748
456
  Annotated[StrictFloat, Field(gt=0)],
@@ -760,9 +468,9 @@ class DocumentConversionApi:
760
468
 
761
469
  Télécharge le fichier Factur-X PDF ou XML généré. ## Fichiers disponibles - `facturx.pdf` : PDF/A-3 avec XML embarqué - `facturx.xml` : XML CII seul (Cross Industry Invoice) Les fichiers sont disponibles pendant 24 heures après génération.
762
470
 
763
- :param conversion_id: (required)
471
+ :param conversion_id: Conversion ID returned by POST /convert (UUID format) (required)
764
472
  :type conversion_id: str
765
- :param filename: (required)
473
+ :param filename: File to download: 'facturx.pdf' or 'facturx.xml' (required)
766
474
  :type filename: str
767
475
  :param _request_timeout: timeout setting for this request. If one
768
476
  number provided, it will be total request
@@ -799,6 +507,7 @@ class DocumentConversionApi:
799
507
  '200': "object",
800
508
  '404': None,
801
509
  '422': "HTTPValidationError",
510
+ '401': "APIError",
802
511
  }
803
512
  response_data = self.api_client.call_api(
804
513
  *_param,
@@ -814,8 +523,8 @@ class DocumentConversionApi:
814
523
  @validate_call
815
524
  def download_file_api_v1_convert_conversion_id_download_filename_get_without_preload_content(
816
525
  self,
817
- conversion_id: StrictStr,
818
- filename: StrictStr,
526
+ conversion_id: Annotated[StrictStr, Field(description="Conversion ID returned by POST /convert (UUID format)")],
527
+ filename: Annotated[StrictStr, Field(description="File to download: 'facturx.pdf' or 'facturx.xml'")],
819
528
  _request_timeout: Union[
820
529
  None,
821
530
  Annotated[StrictFloat, Field(gt=0)],
@@ -833,9 +542,9 @@ class DocumentConversionApi:
833
542
 
834
543
  Télécharge le fichier Factur-X PDF ou XML généré. ## Fichiers disponibles - `facturx.pdf` : PDF/A-3 avec XML embarqué - `facturx.xml` : XML CII seul (Cross Industry Invoice) Les fichiers sont disponibles pendant 24 heures après génération.
835
544
 
836
- :param conversion_id: (required)
545
+ :param conversion_id: Conversion ID returned by POST /convert (UUID format) (required)
837
546
  :type conversion_id: str
838
- :param filename: (required)
547
+ :param filename: File to download: 'facturx.pdf' or 'facturx.xml' (required)
839
548
  :type filename: str
840
549
  :param _request_timeout: timeout setting for this request. If one
841
550
  number provided, it will be total request
@@ -872,6 +581,7 @@ class DocumentConversionApi:
872
581
  '200': "object",
873
582
  '404': None,
874
583
  '422': "HTTPValidationError",
584
+ '401': "APIError",
875
585
  }
876
586
  response_data = self.api_client.call_api(
877
587
  *_param,
@@ -950,7 +660,7 @@ class DocumentConversionApi:
950
660
  @validate_call
951
661
  def get_conversion_status_api_v1_convert_conversion_id_status_get(
952
662
  self,
953
- conversion_id: StrictStr,
663
+ conversion_id: Annotated[StrictStr, Field(description="Conversion ID returned by POST /convert (UUID format)")],
954
664
  _request_timeout: Union[
955
665
  None,
956
666
  Annotated[StrictFloat, Field(gt=0)],
@@ -968,7 +678,7 @@ class DocumentConversionApi:
968
678
 
969
679
  Retourne le statut actuel d'une conversion asynchrone.
970
680
 
971
- :param conversion_id: (required)
681
+ :param conversion_id: Conversion ID returned by POST /convert (UUID format) (required)
972
682
  :type conversion_id: str
973
683
  :param _request_timeout: timeout setting for this request. If one
974
684
  number provided, it will be total request
@@ -1003,6 +713,7 @@ class DocumentConversionApi:
1003
713
  _response_types_map: Dict[str, Optional[str]] = {
1004
714
  '200': "Dict[str, object]",
1005
715
  '422': "HTTPValidationError",
716
+ '401': "APIError",
1006
717
  }
1007
718
  response_data = self.api_client.call_api(
1008
719
  *_param,
@@ -1018,7 +729,7 @@ class DocumentConversionApi:
1018
729
  @validate_call
1019
730
  def get_conversion_status_api_v1_convert_conversion_id_status_get_with_http_info(
1020
731
  self,
1021
- conversion_id: StrictStr,
732
+ conversion_id: Annotated[StrictStr, Field(description="Conversion ID returned by POST /convert (UUID format)")],
1022
733
  _request_timeout: Union[
1023
734
  None,
1024
735
  Annotated[StrictFloat, Field(gt=0)],
@@ -1036,7 +747,7 @@ class DocumentConversionApi:
1036
747
 
1037
748
  Retourne le statut actuel d'une conversion asynchrone.
1038
749
 
1039
- :param conversion_id: (required)
750
+ :param conversion_id: Conversion ID returned by POST /convert (UUID format) (required)
1040
751
  :type conversion_id: str
1041
752
  :param _request_timeout: timeout setting for this request. If one
1042
753
  number provided, it will be total request
@@ -1071,6 +782,7 @@ class DocumentConversionApi:
1071
782
  _response_types_map: Dict[str, Optional[str]] = {
1072
783
  '200': "Dict[str, object]",
1073
784
  '422': "HTTPValidationError",
785
+ '401': "APIError",
1074
786
  }
1075
787
  response_data = self.api_client.call_api(
1076
788
  *_param,
@@ -1086,7 +798,7 @@ class DocumentConversionApi:
1086
798
  @validate_call
1087
799
  def get_conversion_status_api_v1_convert_conversion_id_status_get_without_preload_content(
1088
800
  self,
1089
- conversion_id: StrictStr,
801
+ conversion_id: Annotated[StrictStr, Field(description="Conversion ID returned by POST /convert (UUID format)")],
1090
802
  _request_timeout: Union[
1091
803
  None,
1092
804
  Annotated[StrictFloat, Field(gt=0)],
@@ -1104,7 +816,7 @@ class DocumentConversionApi:
1104
816
 
1105
817
  Retourne le statut actuel d'une conversion asynchrone.
1106
818
 
1107
- :param conversion_id: (required)
819
+ :param conversion_id: Conversion ID returned by POST /convert (UUID format) (required)
1108
820
  :type conversion_id: str
1109
821
  :param _request_timeout: timeout setting for this request. If one
1110
822
  number provided, it will be total request
@@ -1139,6 +851,7 @@ class DocumentConversionApi:
1139
851
  _response_types_map: Dict[str, Optional[str]] = {
1140
852
  '200': "Dict[str, object]",
1141
853
  '422': "HTTPValidationError",
854
+ '401': "APIError",
1142
855
  }
1143
856
  response_data = self.api_client.call_api(
1144
857
  *_param,
@@ -1214,7 +927,7 @@ class DocumentConversionApi:
1214
927
  @validate_call
1215
928
  def resume_conversion_api_v1_convert_conversion_id_resume_post(
1216
929
  self,
1217
- conversion_id: StrictStr,
930
+ conversion_id: Annotated[StrictStr, Field(description="Conversion ID returned by POST /convert (UUID format)")],
1218
931
  convert_resume_request: ConvertResumeRequest,
1219
932
  _request_timeout: Union[
1220
933
  None,
@@ -1233,7 +946,7 @@ class DocumentConversionApi:
1233
946
 
1234
947
  Reprend une conversion après complétion des données manquantes ou correction des erreurs. L'extraction OCR est conservée, les données sont mises à jour avec les corrections, puis une nouvelle validation Schematron est effectuée.
1235
948
 
1236
- :param conversion_id: (required)
949
+ :param conversion_id: Conversion ID returned by POST /convert (UUID format) (required)
1237
950
  :type conversion_id: str
1238
951
  :param convert_resume_request: (required)
1239
952
  :type convert_resume_request: ConvertResumeRequest
@@ -1272,6 +985,7 @@ class DocumentConversionApi:
1272
985
  '200': "ConvertSuccessResponse",
1273
986
  '404': None,
1274
987
  '422': "ConvertValidationFailedResponse",
988
+ '401': "APIError",
1275
989
  }
1276
990
  response_data = self.api_client.call_api(
1277
991
  *_param,
@@ -1287,7 +1001,7 @@ class DocumentConversionApi:
1287
1001
  @validate_call
1288
1002
  def resume_conversion_api_v1_convert_conversion_id_resume_post_with_http_info(
1289
1003
  self,
1290
- conversion_id: StrictStr,
1004
+ conversion_id: Annotated[StrictStr, Field(description="Conversion ID returned by POST /convert (UUID format)")],
1291
1005
  convert_resume_request: ConvertResumeRequest,
1292
1006
  _request_timeout: Union[
1293
1007
  None,
@@ -1306,7 +1020,7 @@ class DocumentConversionApi:
1306
1020
 
1307
1021
  Reprend une conversion après complétion des données manquantes ou correction des erreurs. L'extraction OCR est conservée, les données sont mises à jour avec les corrections, puis une nouvelle validation Schematron est effectuée.
1308
1022
 
1309
- :param conversion_id: (required)
1023
+ :param conversion_id: Conversion ID returned by POST /convert (UUID format) (required)
1310
1024
  :type conversion_id: str
1311
1025
  :param convert_resume_request: (required)
1312
1026
  :type convert_resume_request: ConvertResumeRequest
@@ -1345,6 +1059,7 @@ class DocumentConversionApi:
1345
1059
  '200': "ConvertSuccessResponse",
1346
1060
  '404': None,
1347
1061
  '422': "ConvertValidationFailedResponse",
1062
+ '401': "APIError",
1348
1063
  }
1349
1064
  response_data = self.api_client.call_api(
1350
1065
  *_param,
@@ -1360,7 +1075,7 @@ class DocumentConversionApi:
1360
1075
  @validate_call
1361
1076
  def resume_conversion_api_v1_convert_conversion_id_resume_post_without_preload_content(
1362
1077
  self,
1363
- conversion_id: StrictStr,
1078
+ conversion_id: Annotated[StrictStr, Field(description="Conversion ID returned by POST /convert (UUID format)")],
1364
1079
  convert_resume_request: ConvertResumeRequest,
1365
1080
  _request_timeout: Union[
1366
1081
  None,
@@ -1379,7 +1094,7 @@ class DocumentConversionApi:
1379
1094
 
1380
1095
  Reprend une conversion après complétion des données manquantes ou correction des erreurs. L'extraction OCR est conservée, les données sont mises à jour avec les corrections, puis une nouvelle validation Schematron est effectuée.
1381
1096
 
1382
- :param conversion_id: (required)
1097
+ :param conversion_id: Conversion ID returned by POST /convert (UUID format) (required)
1383
1098
  :type conversion_id: str
1384
1099
  :param convert_resume_request: (required)
1385
1100
  :type convert_resume_request: ConvertResumeRequest
@@ -1418,6 +1133,7 @@ class DocumentConversionApi:
1418
1133
  '200': "ConvertSuccessResponse",
1419
1134
  '404': None,
1420
1135
  '422': "ConvertValidationFailedResponse",
1136
+ '401': "APIError",
1421
1137
  }
1422
1138
  response_data = self.api_client.call_api(
1423
1139
  *_param,