A loan (TPROD — transaction product) is the core lending record in Marbes. It captures the borrower, loan amount, commission structure, bank costs, and repayment term. Before disbursing, you can pre-allocate funds using Control de Fondos to ensure the lending capacity exists. Once created, a TPROD goes through a status workflow — fromDocumentation Index
Fetch the complete documentation index at: https://mintlify.com/scoria02/marbes2021_backend/llms.txt
Use this file to discover all available pages before exploring further.
pendiente to aceptado — before funds are released. This guide covers each step.
All requests require a valid JWT token in the Authorization header.
Create a credit client
A credit client is a borrower. You must register them before creating a loan.Save the returned client
Client’s first name.
Client’s last name.
National ID (
V-########) or company tax ID (J-########).Contact email address.
Client type:
natural (individual) or juridico (company).Approved credit limit for this client.
Referral code for the person or channel that introduced this client.
Contact phone number.
Registration date in
YYYY-MM-DD format. Defaults to now if omitted.id — you’ll use it when creating the TPROD.Pre-allocate funds with Control de Fondos
Control de Fondos lets an operator reserve a portion of available TCOL funds for a specific lending window before any loans are issued. This step is optional but recommended when multiple executives share a common pool of funds.
UUID of the operator who owns this fund allocation.
Array of executive UUIDs authorized to lend from this allocation.
UUID of the company the funds belong to.
UUID of the bank where funds are held.
Start date of the allocation window in
YYYY-MM-DD format.End date of the allocation window in
YYYY-MM-DD format.Currency of the allocation:
VES, USD, or EUR. Defaults to USD.BCV exchange rate at the time of allocation.
Total amount reserved for lending in this window.
Optional notes about this allocation.
Each time a TPROD is created from this allocation, the system decrements
monto_disponible and increments monto_usado. You can check the current balance at any time with GET /api/negocios/control-fondos.Create a TPROD loan
A TPROD records a loan disbursement to a client. The The
monto field is the base loan amount; the final amount collected from the client includes the commission.UUID of the bank from which funds are disbursed.
UUID of the credit client receiving the loan.
Base loan amount in the specified currency. This is the principal disbursed to the client.
Commission as a percentage of
monto (e.g., 15 for 15%). The system calculates the total amount the client must repay as monto + (monto × monto_comision / 100).Bank processing cost as a percentage (e.g.,
0.5 for 0.5%). Optional — defaults to 0.00.Loan currency:
VES, USD, or EUR.BCV exchange rate at the time of disbursement.
Numeric repayment term (e.g.,
30 for thirty days).Term unit:
dias (days), mes (months), or ano (years).Bank transfer reference for the disbursement. Can be updated later.
Disbursement date in
YYYY-MM-DD format.Initial status. Defaults to
pendiente.Description of the guarantee backing the loan.
UUID of the employee responsible for this loan. Defaults to the authenticated user if omitted.
Fee structure
The total repayment amount a client owes is computed as:costo_banco is a separate operating cost charged by the bank for processing the transfer and does not affect the client’s repayment amount. Both are stored on the TPROD record for reporting purposes.Accept TPROD records in bulk
Once guarantee documents are in order, an operator can accept one or more TPROD records in a single call. This transitions them from
pendiente to aceptado and releases the funds from the bank’s available balance.The request is multipart/form-data because guarantee files can be attached alongside the JSON payload.The
ids field is a JSON array of TPROD UUIDs. Guarantee files uploaded here are attached to each TPROD in the batch. Existing guarantee metadata is preserved.Update a single TPROD record
To update the status or add a reference/observation to a single TPROD — for example when a repayment arrives or when moving a loan to
mora (delinquency) — use:TPROD statuses
| Status | Meaning |
|---|---|
pendiente | Loan created but not yet approved or disbursed. |
aceptado | Loan approved and funds released to the client. |
devuelto | Funds returned before disbursement was finalized. |
rechazado | Loan rejected — funds were never disbursed. |
mora | Client is delinquent — repayment is overdue. |
Check available funds before lending
Before creating a TPROD, verify that the target bank has enough available balance. UseGET /api/negocios/bancos/{idBanco}/disponible to retrieve the current available funds: