Search products by seller

By using our public resource /sites/{site_id}/search? you can get the results of active items directly from Mercado Libre listings. By using our private resource /users/{cust_id}/items/search?access_token= you can get a list of items posted by a certain user from his/her account.

Contents:

Get items of Listings by seller

This search adjusts to the site's listing rules. Results will always be active items. Notes:

  • Get Mercado Libre listing URL directly by replacing /search? for /searchUrl?
  • Offset searches above 50,000 are limited

By nickname

When you don’t know what’s the seller_id of an user by you know the nickname, you can try doing the following search:

curl https://api.mercadolibre.com/sites/MLA/search?nickname=

By seller_id

If you already know the seller_id just do as it follows:

curl https://api.mercadolibre.com/sites/MLA/search?seller_id=

Note: While the API sites/(site_id) will show item description, it will not display all the seller's listings. To see the full list without the descriptions, you should make the following call:

https://api.mercadolibre.com/users/{seller_id}/items/search?access_token=$ACCESS_TOKEN

By seller id for an specific category

Note that the previous searches don’t retrieve the seller’s classified listings, only their products. You can use the following example to search within a specific category and this call accepts classified categories to also query those listings.

curl https://api.mercadolibre.com/sites/MLB/search?seller_id=36060987&category=MLB1743

Filter and sort search results in the listings

In /sites/{site_id}/search? you will find the fields ”available_sorts" and “available_filters”. How to filter? For example, to filter items with free shipping, you will find the "shipping” ID among the ”available_filters" with “free” ID value.

https://api.mercadolibre.com/sites/MLA/search?seller_id={cust_id}&shipping=free

How to sort? In this case, you should add “sort” to the available sort ID that you wish to apply, for example: “price_asc”

https://api.mercadolibre.com/sites/MLA/search?seller_id={cust_id}&sort=price_asc

Note: Listing search includes an order of relevance defined by default.

Get items from a seller’s account

This search is performed directly in the seller’s account; this is a private resource and you will need an access_token.

By seller_id

If you already know the seller_id, just do the following:

curl https://api.mercadolibre.com/users/{seller_id}/items/search?access_token=$ACCESS_TOKEN

If the request return more than 1000 result, please refer to the following documentation.

By SKU

Por SKU

  • Seller_custom_field: if the ítem include a SKU in the field “seller_custom_field”, you can test with:

    curl https://api.mercadolibre.com/users/{Cust_id}/items/search?sku={seller_custom_field}&access_token=$ACCESS_TOKEN
  • Seller_sku: if the item include a SKU in the field /atributo “SELLER_SKU”, you can test with:
    curl https://api.mercadolibre.com/users/$CUST_ID/items/search?seller_sku=$SELLER_SKU&access_token=$ACCESS_TOKEN

By status

curl https://api.mercadolibre.com/users/{Cust_id}/items/search?status=active&access_token=$ACCESS_TOKEN

Filter and Sort results of items by seller

In /users/{cust_id}/items/search? you will find the fields ”available_orders" and “available_filters” How to sort? In this case, you should add “orders” to the available sort ID that you wish to apply, for example: “start_time_desc”

https://api.mercadolibre.com/users/226384143/items/search?orders=start_time_desc&access_token=$ACCESS_TOKEN

Note: It includes a stop_time_asc by default. How to filter? For example, to filter items with listing_type “gold_pro” you will find the "listing_type_id" among the "available_filters" with the "gold_pro" ID value.

https://api.mercadolibre.com/users/{Cust_id}/items/search?isting_type_id=gold_pro&access_token=$ACCESS_TOKEN

For more search examples, go to: Items and searches.

Multiget

We encourage you to use multiget to improve your interaction with the item resource /items and /users and thus to access a maximum of 20 publications with a single call.
Note that using multiget you will get a response in verbose format, which means, that in addition to the information json we will be answering with a code to show if the request was successful or not for each item.
Call to /items:

https://api.mercadolibre.com/items?ids={Item_id1},{Item_id2}&access_token=YOUR_ACCESS_TOKEN

Example:

https://api.mercadolibre.com/items?ids=MLA599260060,MLA594239600&access_token=YOUR_ACCESS_TOKEN

Response:

[
     {
          "code": 200,
           "body": {
    "id": "MLA599260060",
    "site_id": "MLA",
    "title": "Item De Test - Por Favor No Ofertar",
    "subtitle": null,
    "seller_id": 303888594,
    "category_id": "MLA401685",
    "official_store_id": null,
    "price": 130,
    "base_price": 130,
    "original_price": null,
    "currency_id": "ARS",
    "initial_quantity": 1,
    "available_quantity": 1,
    "sold_quantity": 0,
    "sale_terms": [],
    [...]
    "automatic_relist": false,
    "date_created": "2018-02-26T18:15:05.000Z",
    "last_updated": "2018-03-29T04:14:39.000Z",
    "health": null
              }
        }

 {
          "code": 200,
           "body": {
    "id": "MLA594239600",
    "site_id": "MLA",
    "title": "Item De Test - Por Favor No Ofertar",
    "subtitle": null,
    "seller_id": 303888594,
    "category_id": "MLA401685",
    "official_store_id": null,
    "price": 120,
    "base_price": 120,
    "original_price": null,
    "currency_id": "ARS",
    "initial_quantity": 1,
    "available_quantity": 1,
    "sold_quantity": 0,
    "sale_terms": [],
    [...]
    "automatic_relist": false,
    "date_created": "2018-02-26T18:15:05.000Z",
    "last_updated": "2018-03-29T04:14:39.000Z",
    "health": null
              }
        }

]

Call to /users:

https://api.mercadolibre.com/users?ids={user_id1},{user_id2}&access_token=YOUR_ACCESS_TOKEN

Example:

https://api.mercadolibre.com/users?ids=401114259,287440999&access_token=YOUR_ACCESS_TOKEN

Response:

[
  {
    "code": 200,
    "body": {
      "id": 401114259,
      "nickname": "user_test234",
      "registration_date": "2019-02-05T10:38:03.000-04:00",
      "country_id": "BR",
      "address": {
        "city": null,
        "state": null
      },
      "user_type": "normal",
      "tags": [
        "normal"
      ],
      "logo": null,
      "points": 0,
      "site_id": "MLB",
      "permalink": "http://perfil.mercadolivre.com.br/user_test234",
      "seller_reputation": {
        "level_id": null,
        "power_seller_status": null,
        "transactions": {
          "canceled": 0,
          "completed": 0,
          "period": "historic",
          "ratings": {
            "negative": 0,
            "neutral": 0,
            "positive": 0
          },
          "total": 0
        }
      },
      "buyer_reputation": {
        "tags": [
        ]
      },
      "status": {
        "site_status": "guest"
      }
    }
  },
  {
    "code": 200,
    "body": {
      "id": 287440999,
      "nickname": "user_test111",
      "registration_date": "2019-03-06T00:16:08.000-04:00",
      "country_id": "MX",
      "address": {
        "city": null,
        "state": null
      },
      "user_type": "normal",
      "tags": [
        "normal"
      ],
      "logo": null,
      "points": 0,
      "site_id": "MLM",
      "permalink": "http://perfil.mercadolibre.com.mx/user_test111",
      "seller_reputation": {
        "level_id": null,
        "power_seller_status": null,
        "transactions": {
          "canceled": 0,
          "completed": 0,
          "period": "historic",
          "ratings": {
            "negative": 0,
            "neutral": 0,
            "positive": 0
          },
          "total": 0
        }
      },
      "buyer_reputation": {
        "tags": [
        ]
      },
      "status": {
        "site_status": "active"
      }
    }
  }
]

Field selection

Another alternative for the GET to item implementation is to select fields to receive those required only.
To define the fields you want to receive, add the attribute parameter like this: Call:

https://api.mercadolibre.com/items?ids={Item_id1},{Item_id2}&attributes={attribute1,attribute2,attribute3}&access_token=YOUR_ACCESS_TOKEN

Example:

https://api.mercadolibre.com/items?ids=MLA599260060,MLA594239600&attributes={id,price,category_id,title}&access_token=YOUR_ACCESS_TOKEN

Response:

[
     {
          "code": 200,
           "body": {
    "id": "MLA599260060",
    "title": "Item De Test - Por Favor No Ofertar",
    "category_id": "MLA401685",
    "price": 130
              }
        }

 {
          "code": 200,
           "body": {
    "id": "MLA594239600",
    "title": "Item De Test - Por Favor No Ofertar",
    "category_id": "MLA401685",
    "official_store_id": null,
    "price": 120,
              }
        }

]

Be part of our community