Upload Invoice
Invoices
Upload Invoice
Upload a CFDI XML invoice file
POST
Upload Invoice
Documentation Index
Fetch the complete documentation index at: https://docs.contafy.com.mx/llms.txt
Use this file to discover all available pages before exploring further.
Authentication
This endpoint requires authentication. Include your access token in the Authorization header.Request Body
This endpoint expects a multipart/form-data request with the following fields:XML file containing the CFDI invoice. The file must be a valid Mexican CFDI XML.
Profile ID to associate the invoice with. The system automatically determines if the invoice is an income (factura) or expense (gasto) based on the RFC in the XML.
Response
Success message
The created invoice object
Validation state of the uploaded invoice
Classification of the invoice:
factura (income) or gasto (expense)Example Request
Example Response
Error Responses
401 Unauthorized
400 Bad Request
409 Conflict
422 Unprocessable Entity
500 Internal Server Error