Documentación Mercado Libre
Descubre toda la información que debes conocer sobre las APIs de Mercado Libre.Documentación
Credits pre-approved
Notifications of new credit leads
With the leads credits topic you will be able to subscribe and start receiving notifications about new credit leads generated in your publications, it will allow you to recognize a new credit created in Meli at the moment of its creation.
Consult available credits for the seller's items
Now, the seller can consult all the credits available for his negotiations, with the possibility of paginating them with the offset parameter and with a maximum limit of 100 items per page. The data will be available within a maximum consultation period of 3 months.
To obtain test data, use the header 'x-sandbox: true'
Request:
curl -X GET -H 'Authorization: Bearer $ACCESS_TOKEN' https://api.mercadolibre.com/vis/loans/search?seller_id=$SELLER_ID&date_from=AAAA-MM-DDTHH:MM:SS&date_to=AAAA-MM-DDTHH:MM:SS
Example:
curl -X GET -H 'Authorization: Bearer $ACCESS_TOKEN' https://api.mercadolibre.com/vis/loans/search?seller_id=707775316&date_from=2020-12-10T00:00:00&date_to=2021-01-01T00:00:00
Response:
{
"results": [{
"id": "14b556e2-85dc-11eb-8436-2753cb1f9665",
"item_id": "MLB5903538649",
"down_payment_amount": 9012.0,
"installments_number": 9,
"installments_amount": 1001.0,
"seller_id": 707775316,
"buyer_id": 65979,
"proposal_id": "40962",
"date_created": "2020-12-19T14:00:59",
"financial_entity_id": "VOTORANTIM",
"expired": false
}],
"paging": {
"offset": 0,
"limit": 10,
"total": 1
},
"date_from": "2020-12-10T00:00:00",
"date_to": "2021-01-01T00:00:00"
}
Parámetros disponibles:
item_id
status: approved, rejected, in_analysis, all. If it is not added we will bring it approved by default.
financial_entity_id: MERCADO_CREDITO, VOTORANTIM, SANTANDER or SCOTIA.
Response fields:
- ID :credit id.
- item_id: id Item.
- down_payment_amount: credit entry amount.
- installments_number: number of installments.
- installments_amount: amount of the installment.
- seller_id: seller id.
- buyer_id: buyer id.
- proposal_id: only returns information when the financing entity makes it available.
- date_created: date of credit creation.
- financial_entity_id: id bank.
- expired: true or false.
Details of the available credi
With the credit ID, you can access the details including the buyer's contact details.
Para obtener los datos de pruebas, utilice el header 'x-sandbox: true'.
Request:
curl -X GET -H 'Authorization: Bearer $ACCESS_TOKEN' https://api.mercadolibre.com/vis/loans/$CREDIT_ID?seller_id=$SELLER_ID
Example:
curl -X GET -H 'Authorization: Bearer $ACCESS_TOKEN' https://api.mercadolibre.com/vis/loans/14b52fd8-85dc-11eb-8436-2753cb1f9665?seller_id=707775316
Response:
{
"id": "14b52fd8-85dc-11eb-8436-2753cb1f9665",
"item_id": "MLB3450596169",
"down_payment_amount": 3575.0,
"installments_number": 21,
"installments_amount": 170.0,
"seller_id": 707775316,
"date_created": "2021-03-08T04:41:39",
"financial_entity_id": "VOTORANTIM",
"buyer": {
"id": 7165,
"full_name": "Natália Costa",
"email": "Bernardo.Silva@example.com",
"phone": "(46) 6501-4768"
}
}
Response fields
- buyer.id: buyer's id.
- buyer.full_name: buyer's name.
- buyer.email: buyer's e-mail.
- buyer.phone: buyer's contact phone number.
- status: credit status.
- proposal_id: only returns information when the financing entity makes it available.
Possible errors
Errors in the search for credits:
Error_code | Tipe | Error message | Solution |
---|---|---|---|
401 | Unauthorized | Unauthorized | No access token |
400 | Bad Request | "Value of seller_id parameter must match value obtained from auth token" | Access token does not belong to the seller |
400 | Bad Request | Invalid date_from format. It must follow ISO format | Invalid date format |
400 | Bad Request | Date range cannot exceed 3 months | Search period longer than 3 months |
400 | Bad Request | Invalid financial entity | Bank does not exist |
400 | Bad Request | item_id value must match M[A-Z]{2}[0-9]+$ | item invalid |
Errors in obtaining credit details:
Error_code | Tipe | Error message | Solution |
---|---|---|---|
401 | Unauthorized | Unauthorized | No access token |
400 | Bad Request | Value of seller_id parameter must match value obtained from auth token | Access token does not belong to the seller |
400 | Bad Request | id value must match [a-fA-F0-9]{8}-[a-fA-F0-9]{4}-[a-fA-F0-9]{4}-[a-fA-F0-9]{4}-[a-fA-F0-9]{12} like an uuid" | Invalid identifier |
404 | Not Found | Detail not found for credit with id | Credit does not exist |
410 | The resource is expired | Gone | Credit expired |