Invoice issuance lifecycle
Peru has an synchronic invoicing system, which means that documents will be checked immediately as you issue them.
The steps are as follow, you can identify them by using GET /documents and reading the fields.
GET /documents/{document_id}
1) Draft
2) Issued, pending validation
The document has all required fields and was issued by our system, it will be sent to the tax authority in a few minutes. No action is required on your side.
3) Approved by tax authority (SUNAT)
The document has completed its cycle succesfully, no further action is required.
3B) Rejected by tax authority (SUNAT)
The document was rejected, you will find further information on the comments field. The document must be issued and sent again in this case.