Invoicing & Waybills
Create and manage invoices, receipts, credit notes, debit notes, and transport documents (waybills) through the MagniFinance API.
REST vs SOAP: Which Should I Use?
Choose REST for new integrations. It's simpler, uses JSON, and has better tooling support.
| Criteria | REST API | SOAP API |
|---|---|---|
| Data Format | JSON | XML |
| Best For | New integrations, modern apps | Legacy systems, enterprise environments |
| Learning Curve | Easier | Steeper |
| Tooling | Excellent (Postman, curl, etc.) | Requires SOAP clients |
| Feature Parity | Full support | Full support |
| Recommendation | Recommended | Maintained for compatibility |
Choose REST if:
- You're building a new integration
- Your tech stack is modern (Node.js, Python, React, etc.)
- You prefer working with JSON
- You want simpler debugging with standard HTTP tools
Choose SOAP if:
- You have existing SOAP infrastructure
- Your enterprise requires SOAP/XML protocols
- You're integrating with legacy systems that only support SOAP
Available Operations
Both APIs support the same document operations:
| Operation | Description |
|---|---|
| Create Document | Create invoices, receipts, credit/debit notes |
| Get Document | Retrieve document details and download PDF |
| Cancel Document | Cancel a closed document |
| Create Waybill | Create transport documents |
| Get Document Property | Retrieve specific document properties |
| Get a Client | Get a company registered in your subscription |
Get Started
- REST API Documentation - JSON-based, recommended for new integrations
- SOAP API Documentation - XML-based, for legacy system integration
Try it in Postman
The quickest way to try the operations is a ready-made Postman collection with every operation on this page and a sample body already filled in. There is one for each API:
- REST: download the collection, or paste this URL in Postman's Import:
https://developer.magnifinance.com/finance/postman/invoicing-waybills-rest.json - SOAP: download the collection, or paste this URL in Postman's Import:
https://developer.magnifinance.com/finance/postman/invoicing-waybills-soap.json
- Import the collection.
- Open its Variables tab and fill in
emailandtoken(see Authentication). - Send Create Document. It stores the new
DocumentIdin the collection, so Get Document, Get Document Property and Cancel Document work right after it.
Dates are filled in when you press Send, so the sample documents are always dated today.
Document Types
| Code | Type | Portuguese Name | Created with |
|---|---|---|---|
T | Invoice/Receipt | Fatura-Recibo | Create Document |
I | Invoice | Fatura | Create Document |
S | Simplified Invoice | Fatura Simplificada | Create Document |
C | Credit Note | Nota de Crédito | Create Document |
D | Debit Note | Nota de Débito | Create Document |
B | Quote | Orçamento | Create Document |
P | Pro-forma Invoice | Pro-forma | Create Document |
Z | Purchase Order | Nota de Encomenda | Create Document |
W | Waybill | Guia de Transporte | Create Waybill |
Y | Delivery Note | Guia de Remessa | Create Waybill |
Your account needs an active series for a type before it can issue it. Number prefixes, SAF-T codes, which documents can reference which, and the limits per type are in the Appendix.
Authentication
Both APIs require authentication credentials. See Authentication for setup instructions.