As you found, setting .setProfile("EN16931") or .setProfile("EXTENDED") is mandatory for French Factur-X compliance. Here's a quick reference for choosing the right profile:
Factur-X Profiles:
For the French mandatory e-invoicing (starting Sept 2026), you must use EN16931 profile minimum to pass validation with Plateformes Agréées (PA/PDP).
Common pitfall: Don't forget to validate both PDF/A-3 conformance AND XML Schematron rules (250+ business rules). VeraPDF only checks PDF structure, not invoice semantics.
Alternative approach: If maintaining Mustang integration becomes complex (especially for Schematron validation, auto-completion from SIRET, or multi-PA/PDP compatibility), you can externalize this via REST API. For example, FactPulse API accepts PDF + invoice metadata and returns compliant Factur-X (disclaimer: I'm the founder, but it's open for integration regardless of your stack).
Documentation: