Documentación Mercado Libre
Descubre toda la información que debes conocer sobre las APIs de Mercado Libre.Documentación
Shipping capacity management
Shipment Capacity Management is a tool that allows sellers to set the maximum number of shipments they can ship in a day without delays. This gives them the flexibility to organize themselves and avoid delays, either in the face of planned changes in their sales volume or unexpected situations.
Learn more about:
- What is my shipping capacity and what is it for.
- What happens when I exceed my capacity.
- Until when I can modify it.
- How do I modify it if I have more than one picking in a day.
- What is my minimum capacity.
- How to end collections with my code.
Also, learn how Mercado Envíos Colecta (cross_docking) works, Mercado Envíos Places (xd_drop_off) and what is Mercado Envíos 2.
Get current capacity
This endpoint allows you to GET the current configuration of a user's sending capacity:
Request:
curl -X GET -H 'Authorization: Bearer $ACCESS_TOKEN' https://api.mercadolibre.com/users/$USER_ID/capacity_middleend/$LOGISTIC_TYPE
Example:
curl -X GET -H 'Authorization: Bearer $ACCESS_TOKEN' https://api.mercadolibre.com/users/419059119/capacity_middleend/cross_docking
Response with intervention delay:
{
"capacities":[
{
"day": "monday",
"capacity_min":20,
"capacity_max": 140,
"capacity": {
"value": 120,
"maximum": false
},
"next_capacity": {
"value": 110,
"maximum": false
},
"can_add_capacity": false,
"can_subtract_capacity": true,
"intervention" : "delay",
},
{
"day": "tuesday",
"capacity_min":20,
"capacity_max": 140,
"capacity": {
"value": 120,
"maximum": false
},
"next_capacity": null,
"can_add_capacity": true,
"can_subtract_capacity": false,
"intervention" : "delay",
},
{
"day": "wednesday",
"capacity_min":20,
"capacity_max": 140,
"capacity": {
"value": 140,
"maximum": false
},
"next_capacity": null,
"can_add_capacity": true,
"can_subtract_capacity": false,
"intervention" : "delay",
},
{
"day": "thursday",
"capacity_min":20,
"capacity_max": 140,
"capacity": {
"value": 120,
"maximum": false
},
"next_capacity": null,
"can_add_capacity": true,
"can_subtract_capacity": false,
"intervention" : "delay",
},
{
"day": "friday",
"capacity_min":20,
"capacity_max": 140,
"capacity": {
"value": 110,
"maximum": false
},
"next_capacity": null,
"can_add_capacity": true,
"can_subtract_capacity": false,
"intervention" : "delay",
},
{
"day": "saturday",
"capacity_min":20,
"capacity_max": 140,
"capacity": {
"value": 120,
"maximum": true
},
"next_capacity": null,
"can_add_capacity": true,
"can_subtract_capacity": false,
"intervention" : "delay",
},
]
}
Response with intervention early:
{
"capacities":[
{
"day": "monday",
"capacity_min":20,
"capacity_max": null,
"capacity": {
"value": 120,
"maximum": false
},
"next_capacity": {
"value": 110,
"maximum": false
},
"can_add_capacity": false,
"can_subtract_capacity": true,
"intervention" : "early",
},
{
"day": "tuesday",
"capacity_min":20,
"capacity_max": null,
"capacity": {
"value": 120,
"maximum": false
},
"next_capacity": null,
"can_add_capacity": true,
"can_subtract_capacity": false,
"intervention" : "early",
},
{
"day": "wednesday",
"capacity_min":20,
"capacity_max": null,
"capacity": {
"value": 140,
"maximum": false
},
"next_capacity": null,
"can_add_capacity": true,
"can_subtract_capacity": false,
"intervention" : "early",
},
{
"day": "thursday",
"capacity_min":20,
"capacity_max": null,
"capacity": {
"value": 120,
"maximum": false
},
"next_capacity": null,
"can_add_capacity": true,
"can_subtract_capacity": false,
"intervention" : "early",
},
{
"day": "friday",
"capacity_min":20,
"capacity_max": null,
"capacity": {
"value": 110,
"maximum": false
},
"next_capacity": null,
"can_add_capacity": true,
"can_subtract_capacity": false,
"intervention" : "early",
},
{
"day": "saturday",
"capacity_min":20,
"capacity_max": null,
"capacity": {
"value": 120,
"maximum": true
},
"next_capacity": null,
"can_add_capacity": true,
"can_subtract_capacity": false,
"intervention" : "early",
},
]
}
Response parameters:
- day: Represents the day of the week to which the capability refers. Possible values are monday, tuesday, wednesday, thursday, friday, and saturday.
- capacity_min: Is the minimum capacity value allowed for that day.
- capacity_max: Is the maximum capacity value allowed for that day.
- capacity.value: It is the current capacity value for the day and week in which the user is.
- capacity.maximum: Indicates if the user has selected the infinite(false) / maximum(true) capacity. In case of not having next_capacity a null is returned for this field.
- next_capacity.value: It is the value of the configured capacity applicable for the following week.
- next_capacity.maximum: Indicates if the user has selected the infinite(false) / maximum(true) capacity for the following week.
- can_add_capacity: Indicates if it is possible to add additional capacity for that day. Possible values are true or false.
- can_subtract_capacity: Indicates if it is possible to subtract capacity for that day. Possible values are true or false.
- intervention: Describes the type of intervention the user may incur:
- delay: delay intervention
- early: early delivery intervention.
- null: no intervention.
Response Status Codes
Codes | Mesage | Description | Recommendation |
---|---|---|---|
200 - OK | - | The current configuration was obtained correctly. | - |
404 - Not Found | not valid logistic type | The user does not exist or does not have cross_docking logistics. | Validate the user's user_id and logistic types. |
Update shipping capacity
This endpoint allows you to modify or update the configuration of a user's sending capacity.
Request:
curl -X PUT -H 'Authorization: Bearer $ACCESS_TOKEN' https://api.mercadolibre.com/users/$USER_ID/capacity_middleend/$LOGISTIC_TYPE
Example:
curl -X PUT -H 'Authorization: Bearer $ACCESS_TOKEN' https://api.mercadolibre.com/users/419059119/capacity_middleend/cross_docking
{
"capacities": [
{
"day": "monday",
"capacity": {
"value": 120,
"maximum": false
},
},
{
"day": "tuesday",
"capacity": {
"value": 120,
"maximum": false
},
},
{
"day": "wednesday",
"capacity": {
"value": 120,
"maximum": false
},
},
{
"day": "tuesday",
"capacity": {
"value": 120,
"maximum": false
},
},
{
"day": "friday",
"capacity": {
"value": 120,
"maximum": true
},
},
{
"day": "saturday",
"capacity": {
"value": 120,
"maximum": false
},
},
]
}'
Response status codes
Codes | Mesage | Description | Recommendation |
---|---|---|---|
200 - OK | - | The current configuration was obtained correctly. | - |
400 - Bad Request | there was an error parsing the request body | Error in the parameters of the request body. | Validate the request body. |
404 - Not Found | not valid logistic type | The user does not exist or does not have cross_docking logistics. | Validate the user's user_id and logistic types. |