This endpoint reuses the invoice upload logic. The system automatically determines if the XML represents an expense or income based on the RFC information.
Authentication
Requires a valid JWT token in the Authorization header.Request Body
The UUID of the profile to associate the expense with. The profile must belong to the authenticated user.
The XML content of the CFDI (Comprobante Fiscal Digital por Internet). Should be the raw XML string.
Response
Success message indicating the expense was uploaded successfully.
The created expense object.
UUID of the expense.
UUID of the associated profile.
Origin type, always “XML” for uploaded expenses.
Date of the expense (ISO 8601 format).
Month of the expense (1-12).
Year of the expense.
Total amount of the expense.
Subtotal amount (before taxes).
IVA (VAT) percentage.
IVA amount in currency.
Fiscal folio UUID from the CFDI.
Payment type: “PUE” (Pago en Una Exhibición), “PPD” (Pago en Parcialidades o Diferido), or “COMPLEMENTO_PAGO”.
RFC (tax ID) of the issuer.
Name of the issuer.
RFC of the receiver.
Name of the receiver.
Description or concept of the expense.
Validation status of the expense.
Whether the RFC was verified.
Whether the tax regime was verified.
Whether this UUID already exists.
Overall validation status.
List of warning messages.
List of error messages.
Rate Limiting
This endpoint has a rate limit of 300 requests per 5 minutes per user.Example Request
cURL
Error Responses
Unauthorized - Invalid or missing JWT token.
Profile not found or doesn’t belong to the user.
Bad request - Invalid XML format or missing required fields.
Too many requests - Rate limit exceeded.