Electronic Payment Receipt (CEP)
What is the CEP?
The Electronic Payment Receipt (CEP) is a document issued by the Bank of Mexico (Banxico) that vouches for any transaction going through the Mexican Interbank Electronic Payment System (SPEI).
This receipt contains digital signatures and transaction identifiers within the banking system, so this file can be trusted to determine the veracity of any SPEI transfer.
The explanation without integration details is in the guide what the Banxico CEP is.
What is Banxico?
"Banxico" is the official acronym for the Bank of Mexico, which is the country's central bank.
It is the institution that regulates Mexico's payment and transfer infrastructure, in charge of designing, operating, and supervising the country's financial systems. Among other things, it is responsible for:
- Managing transfers: Of the SPEI type and other types within the national banking system.
- Issuing money: It controls the production and circulation of banknotes and coins.
Parts of the CEP
In the document we can find a lot of useful information:
Transaction information:
- Operation and settlement dates: They describe the date and time when the transaction went through the SPEI system, as well as the date and time when the receiving bank was notified.
- Payment concept: Free text that the originator of the transaction enters when creating it.
- Amount+VAT: Transaction amount with cents, as well as its calculated tax (if any).
- Reference/Tracking key: Unique identifiers of a SPEI transfer.
Originator and Beneficiary information:
- Originator
- Payment-issuing institution: Issuing/requesting bank of the transaction before the SPEI system.
- Account holder: Name of the representative of the ordering bank account of the transaction.
- RFC/CURP: RFC or CURP of the representative of the ordering bank account of the transaction.
- CLABE, Debit card, Mobile number: Account number (in any variant) of the ordering bank account of the transaction.
- Beneficiary
- Payment-receiving institution: Receiving/beneficiary bank of the transaction before the SPEI system.
- Account holder: Name of the representative of the beneficiary bank account of the transaction.
- RFC/CURP: RFC or CURP of the representative of the beneficiary bank account of the transaction.
- CLABE, Debit card, Mobile number: Account number (in any variant) of the beneficiary bank account of the transaction
- Originator
Authorization and authenticity signatures:
- Serial Number of the Security Certificate of the payment-receiving institution:
- Original String (payment information):
- Digital Seal (signature provided by the payment-receiving institution):
Validation verdict
Querying the CEP of a transfer produces one of these outcomes, exposed in the validation's status field:
| verdict | meaning |
|---|---|
valid | Banxico returned a CEP matching the submitted data. It is the verdict of the moment of the query: it can move to returned in a follow-up check |
not_found | Banxico holds no CEP with that data. This may be final or temporary: a CEP takes time to publish |
cep_unavailable | Banxico identified the operation but did not deliver the receipt. The transfer exists and the CEP may be published later |
returned | The payment settled and the beneficiary institution later sent it back, before the query or in a follow-up check. The CEP, if one exists, is still delivered |
invalid | Banxico answered in a way the service does not recognize. It is a problem reading that answer, not with the submitted data |
failed | The validation stopped because the submitted data was rejected, for example an account that cannot be resolved. The reason travels in error_code |
error | Failure of the service or of Banxico during processing, such as a query Banxico did not answer; the reason travels in error_code |
A valid does not prove that the money is still in the beneficiary's account: the CEP proves that the operation settled, and the receiving institution can send it back hours or days later. That is why the official payment status is kept in banxico_result._payment_status, and a follow-up check moves the valid to returned when Banxico reports it as devuelto or en_proceso_devolucion: it keeps the CEP and emits the validation.returned webhook. The check is requested with POST /v1/validations/{id}/recheck — quota-free, one query every 10 minutes per validation — or the service runs it by itself during the first 72 hours. An absent _payment_status means it could not be determined, never that the payment is settled.
The distinction between not_found and cep_unavailable is the one that matters when integrating: with the first, Banxico holds no operation with that data; with the second, it identified the operation but did not deliver the receipt, so the transfer exists. A query that Banxico does not answer is not cep_unavailable: it ends in error. Conflating them leads to treating as non-existent a transfer that did take place.
The three outcomes without a firm verdict — not_found, cep_unavailable and error — are the ones the retry policy accepts.
When a CEP does not exist yet
A transfer executed moments ago may have no published CEP for the first few minutes. A not_found immediately after the operation does not amount to a non-existent transfer: it amounts to a receipt that is not available yet.