Skip to main content
Exclude a contract from your institution after the worker moves it to another institution by portability.
This flow is a suggested interpretation of the Dataprev manuals for Crédito do Trabalhador. The manuals prevail over this page. Your institution validates the flow and implements it on the Lerian APIs. See how to read the diagrams.

Participants


  • Your institution. The origin institution, which holds the contract until the exclusion.
  • Lerian. Lerian Consignado. It exchanges the requests with Dataprev, and exposes the API and the events your institution uses.
  • Dataprev. Runs the Crédito do Trabalhador system: the portability requests and the registry of payroll loans.

Diagram


Release a payroll loan by portability

Steps


Your institution receives the número único and the destination institution outside Lerian. The contract must be a contract that Lerian holds for your institution: registered through Lerian, or imported with POST /v1/consignado/contracts/{numero_contrato}/import. Any other contract answers 404, and Lerian does not call Dataprev. The exclusion and the averbação by the destination institution can happen in either order. After Dataprev accepts the exclusion, Lerian sends a final outstanding balance of 0.00 for the contract. When Dataprev refuses the exclusion with a code that Lerian recognizes, Lerian publishes consignado.portabilidade.rejeitada. If the answer does not arrive, do not send the command again under a new key. The code RAIL_COMMAND_OUTCOME_UNRESOLVED means that Lerian does not know the outcome yet. Read the command with GET /v1/consignado/rail-commands.

How you know it finished


The answer carries competenciaExclusao, and Lerian publishes consignado.portabilidade.efetivada.