CLI¶
The CLI wraps the Rust core for common workflows like CSR generation, invoice signing, validation, QR extraction, and hashing.
Examples¶
fatoora-rs-cli csr --csr-config csr.properties --generated-csr csr.pem --private-key key.pem --pem
fatoora-rs-cli sign --invoice invoice.xml --cert cert.pem --key key.pem --signed-invoice signed.xml
fatoora-rs-cli validate --invoice invoice.xml --xsd-path assets/schemas/UBL2.1/xsd/maindoc/UBL-Invoice-2.1.xsd
fatoora-rs-cli qr --invoice signed.xml
fatoora-rs-cli generate-hash --invoice invoice.xml
Notes¶
csrwrites CSR and key to stdout unless--generated-csr/--private-keyare provided. Use--pemto output PEM; otherwise output is base64 DER.signrequires matching cert/key formats (--cert-formatand--key-formatmust both be PEM or DER).validateuses the bundled UBL schema by default and accepts--xsd-pathto override it.generate-hashprints a signed hash if the XML is signed, otherwise falls back to finalized XML.
See also: Invoice Reference and Signing Reference