---
title: "Get the list of published products in the market"
description: "Get a list of published product details for a specified market."
doc_type: openapi
doc_category: openapi
doc_version: v20270301
source_url:
  html: 'https://developer.shopline.com/docs/admin-rest-api/market/get-markets-published-products'
  md: 'https://developer.shopline.com/docs/admin-rest-api/market/get-markets-published-products.md'
---
# Get the list of published products in the market

Get a list of published product details for a specified market.

- **Base URL:** `https://{handle}.myshopline.com/admin/openapi`
- **Required Scopes:** `read_products`
- **API Version:** v20270301
- **API Type:** Admin
- **API Protocol:** RESTful

## Endpoint

```http
GET /markets/:markets_id/products.json
```

## Base URL

* `https://{handle}.myshopline.com/admin/openapi`

  * `{handle}`: `handle` : The store's unique identifier, which is the prefix of the store's domain name. For example, if a store's domain name is `open001.myshopline.com` , the store handle is `open001` .

## Required Permissions

* `read_products`

## Request

### Path Parameters

* `markets_id`

  string (required)

  The unique identifier for a market.<br/>
  Maximum length：64 

### Query Parameters

* `limit`

  string (optional)

  The maximum number of product IDs to be returned in the query.  <br/>
  Value range: 1-250  <br/>
  Default value: `50`

* `page_info`

  string (optional)

  The unique identifier for pagination queries, used to locate a specific page. 
  
  This parameter value is obtained from the `link` value in the response header of this API after you have queried the pagination information. 
  
  For example, if the `link` value you obtained is `<https://{handle}.myshopline.com/admin/openapi/{version}/markets/:markets_id/products.json?limit=1&page_info=eyJzaW5jZUlkIjoiMTYwNTc1OTAxNTM4OTA4Mjk1MjExMTI3ODgiLCJkaXJlY3Rpb24iOiJuZXh0IiwibGltaXQiOjF9>; rel="next"` , the value of `page_info` is `eyJzaW5jZUlkIjoiMTYwNTc1OTAxNTM4OTA4Mjk1MjExMTI3ODgiLCJkaXJlY3Rpb24iOiJuZXh0IiwibGltaXQiOjF9` . 
  
  For more information on how to use pagination, refer to [Paging Mechanism](https://developer.shopline.com/docs/apps/api-instructions-for-use/paging-mechanism.md).

### Request Headers

* `Content-Type`

  string (required)

  The field must be set to the fixed value `application/json; charset=utf-8`.

* `Authorization`

  string (required)

   The access token for the API resource. Refer to [App authorization](https://developer.shopline.com/docs/apps/api-instructions-for-use/app-authorization.md?lang=en) to obtain the access token, and then pass the obtained token in the Bearer format. 

## Response

### Status Codes

* `200`

  For the complete list of codes and messages, see [Http status code](https://developer.shopline.com/docs/apps/api-instructions-for-use/http-status-code.md?lang=en).

* `401`

  

* `429`

  

### Response Headers

* `link`

  The URL link that provides the pagination data. You can obtain `page_info` from this parameter for subsequent pagination requests. 
  
  This parameter is returned when the requested page has a previous or next page. 
  
  For more information on how to use pagination, refer to [Paging Mechanism](https://developer.shopline.com/docs/apps/api-instructions-for-use/paging-mechanism.md).

* `traceId`

  A globally unique identifier for the request. It is used to track the request flow throughout the system, allowing for easy location and debugging when issues arise.

### Response Body

#### 200

* `product_ids`

  array<string>

  A list of product IDs published in the market.

* `products_count`

  integer

  The number of products published in the market.


#### 401

* `errors`

  string

  Error message. 


#### 429

* `errors`

  string

  Error message. 


## OpenAPI Definition

```json
{
  "tags": [
    "Get the list of published products in the market"
  ],
  "description": "Get a list of published product details for a specified market.",
  "externalDocs": {
    "description": "Permission point used by the interface is `read_products` , For more information about the use of permission points, see",
    "url": "ec20/3cv5d7wpfgr6a8z5/xabczf5442284vkq?lang=en",
    "errorTableDescription": ""
  },
  "operationId": "UeBInMTT",
  "parameters": [
    {
      "name": "limit",
      "in": "query",
      "description": "The maximum number of product IDs to be returned in the query.  <br/>\nValue range: 1-250  <br/>\nDefault value: `50`",
      "style": "form",
      "explode": true,
      "schema": {
        "name": "limit",
        "description": "The maximum number of product IDs to be returned in the query.  <br/>\nValue range: 1-250  <br/>\nDefault value: `50`",
        "type": "string"
      },
      "examples": {
        "Get the list of published products in the market": {
          "value": "50"
        }
      }
    },
    {
      "name": "page_info",
      "in": "query",
      "description": "The unique identifier for pagination queries, used to locate a specific page. \n\nThis parameter value is obtained from the `link` value in the response header of this API after you have queried the pagination information. \n\nFor example, if the `link` value you obtained is `<https://{handle}.myshopline.com/admin/openapi/{version}/markets/:markets_id/products.json?limit=1&page_info=eyJzaW5jZUlkIjoiMTYwNTc1OTAxNTM4OTA4Mjk1MjExMTI3ODgiLCJkaXJlY3Rpb24iOiJuZXh0IiwibGltaXQiOjF9>; rel=\"next\"` , the value of `page_info` is `eyJzaW5jZUlkIjoiMTYwNTc1OTAxNTM4OTA4Mjk1MjExMTI3ODgiLCJkaXJlY3Rpb24iOiJuZXh0IiwibGltaXQiOjF9` . \n\nFor more information on how to use pagination, refer to [Paging Mechanism](https://developer.shopline.com/docs/apps/api-instructions-for-use/paging-mechanism.md).",
      "style": "form",
      "explode": true,
      "schema": {
        "name": "page_info",
        "description": "The unique identifier for pagination queries, used to locate a specific page. This parameter value is obtained from the `link` value in the response header of this API after you have queried the pagination information. For example, if the `link` value you obtained is `<https://\\{handle\\}.myshopline.com/admin/openapi/\\{version\\}/products/products.json? limit=1&page_info=eyJzaW5jZUlkIjoiMTYwNTc1OTAxNTM4OTA4Mjk1MjExMTI3ODgiLCJkaXJlY3Rpb24iOiJuZXh0IiwibGltaXQiOjF9>; rel=\"next\"`, the value of `page_info` is `eyJzaW5jZUlkIjoiMTYwNTc1OTAxNTM4OTA4Mjk1MjExMTI3ODgiLCJkaXJlY3Rpb24iOiJuZXh0IiwibGltaXQiOjF9`.\n\nFor more information on how to use pagination, refer to [Paging Mechanism](https://developer.shopline.com/docs/apps/api-instructions-for-use/paging-mechanism.md).",
        "type": "string"
      },
      "examples": {
        "Get the list of published products in the market": {
          "value": "eyJzaW5jZUlkIjoiMTYwNjYyMTQ5NDMwNDQ1NTUzMjI0MTI2MDAiLCJkaXJlY3Rpb24iOiJuZXh0In0"
        }
      }
    },
    {
      "name": "markets_id",
      "in": "path",
      "description": "The unique identifier for a market.<br/>\nMaximum length：64 ",
      "required": true,
      "style": "simple",
      "schema": {
        "name": "markets_id",
        "description": "The unique identifier for a market.<br/>\nMaximum length：64 ",
        "type": "string",
        "example": "2805879435494983497000"
      },
      "example": "2805879435494983497000",
      "examples": {
        "Get the list of published products in the market": {
          "value": "6608773158211162343"
        }
      }
    },
    {
      "name": "Content-Type",
      "in": "header",
      "description": "The field must be set to the fixed value `application/json; charset=utf-8`.",
      "required": true,
      "schema": {
        "name": "Content-Type",
        "type": "string",
        "example": "application/json; charset=utf-8"
      }
    },
    {
      "name": "Authorization",
      "in": "header",
      "description": " The access token for the API resource. Refer to [App authorization](https://developer.shopline.com/docs/apps/api-instructions-for-use/app-authorization.md?lang=en) to obtain the access token, and then pass the obtained token in the Bearer format. ",
      "required": true,
      "style": "string",
      "schema": {
        "name": "Authorization",
        "description": " The access token for the API resource. Refer to [App authorization](https://developer.shopline.com/docs/apps/api-instructions-for-use/app-authorization.md?lang=en) to obtain the access token, and then pass the obtained token in the Bearer format. ",
        "type": "string",
        "example": "Bearer eyJhbGciOiJIUzUxMiIsInR5cCI6IkpXVCJ9.eyJhcHBJZCI6MCwiYXBwS2V5IjoiNzU2ZjI1NWE2NjdlZTcwNTk1MzM0ZjVjYzk4NzU5MzBmN2E3NGZjMSIsImV4cCI6MTg3OTQ4MjA3NiwiaXNzIjoieXNvdWwiLCJzZWxsZXJJZCI6IjIwMDAyMzQ4ODAiLCJzdG9yZUlkIjoiMTY3MjM2OTcyOTYwNiIsInRpbWVzdGFtcCI6MTc4NDc4NzY3NjY2MSwidmVyc2lvbiI6IlYyIn0.3ZzbGAH4cLU1QR2VPEvMOQInUDvus-C4amkINSQIPuNVlXsFKj0sAt1c0KnUy9MWUOFV9cHlkf7J90r2y1FzpA"
      },
      "example": "Bearer eyJhbGciOiJIUzUxMiIsInR5cCI6IkpXVCJ9.eyJhcHBJZCI6MCwiYXBwS2V5IjoiNzU2ZjI1NWE2NjdlZTcwNTk1MzM0ZjVjYzk4NzU5MzBmN2E3NGZjMSIsImV4cCI6MTg3OTQ4MjA3NiwiaXNzIjoieXNvdWwiLCJzZWxsZXJJZCI6IjIwMDAyMzQ4ODAiLCJzdG9yZUlkIjoiMTY3MjM2OTcyOTYwNiIsInRpbWVzdGFtcCI6MTc4NDc4NzY3NjY2MSwidmVyc2lvbiI6IlYyIn0.3ZzbGAH4cLU1QR2VPEvMOQInUDvus-C4amkINSQIPuNVlXsFKj0sAt1c0KnUy9MWUOFV9cHlkf7J90r2y1FzpA"
    }
  ],
  "responses": {
    "200": {
      "description": "For the complete list of codes and messages, see [Http status code](https://developer.shopline.com/docs/apps/api-instructions-for-use/http-status-code.md?lang=en).",
      "headers": {
        "link": {
          "description": "The URL link that provides the pagination data. You can obtain `page_info` from this parameter for subsequent pagination requests. \n\nThis parameter is returned when the requested page has a previous or next page. \n\nFor more information on how to use pagination, refer to [Paging Mechanism](https://developer.shopline.com/docs/apps/api-instructions-for-use/paging-mechanism.md).",
          "example": "\\<https://{handle}.myshopline.com/admin/openapi/{version}/markets/:markets_id/products.json?limit=20&page_info=eyJzaW5jZUlkIjoiMTYwNTc1OTAxNTM4OTA4Mjk1MjExMTI3ODgiLCJkaXJlY3Rpb24iOiJuZXh0IiwibGltaXQiOjF9>; rel='previous',<https://{handle}.myshopline.com/admin/openapi/{version}/markets/:markets_id/products.json?limit=20&page_info=eyJzaW5jZUlkIjoiMTYwNTc1OTAxNTM4OTA4Mjk1MjExMTI3ODgiLCJkaXJlY3Rpb24iOiJwcmUiLCJsaW1pdCI6MX0=\\>; rel='next'"
        },
        "traceId": {
          "description": "A globally unique identifier for the request. It is used to track the request flow throughout the system, allowing for easy location and debugging when issues arise."
        }
      },
      "content": {
        "application/json": {
          "schema": {
            "name": "body",
            "type": "object",
            "properties": {
              "product_ids": {
                "name": "product_ids",
                "description": "A list of product IDs published in the market.",
                "type": "array",
                "items": {
                  "type": "string"
                },
                "example": [
                  "16057850264845250791280282",
                  "16057850264845250333280282"
                ]
              },
              "products_count": {
                "name": "products_count",
                "description": "The number of products published in the market.",
                "type": "integer",
                "example": 50
              }
            },
            "example": {
              "product_ids": [
                "16057850264845250791280282",
                "16057850264845250333280282"
              ],
              "products_count": 50
            }
          },
          "examples": {
            "Get the list of published products in the market": {
              "description": "Get the list of published products in the market.",
              "value": {
                "product_ids": [
                  "16065793365869904616712340",
                  "16065793323425393631512340",
                  "16065690901535908341382340",
                  "16065690895797261611862340",
                  "16064130513208279099762340",
                  "16064130513114830006072340",
                  "16063827081911638501372340",
                  "16063827068327294480742340",
                  "16063826695322974362142340",
                  "16063826691183699652712340",
                  "16063824173154264755072340",
                  "16063434376948322207362340",
                  "16063434197904221869752340",
                  "16061634995776701135972340",
                  "16061246306308668863802340",
                  "16060405504526209790962788",
                  "16060405487448010311972788",
                  "16060405479426320035142788",
                  "16060405465922339097612788",
                  "16060389009008390587282788",
                  "16060388517788618662442788",
                  "16060388466424500983352788",
                  "16060168249162080005412788",
                  "16060138163779023693422788",
                  "16060128949221969178472788",
                  "16060128836758418310932788",
                  "16060128823883918292452788",
                  "16060128351674074473402788",
                  "16060128291745020059602788",
                  "16060128252554617897002788",
                  "16059678845260925524882788",
                  "16059678778391472401032788",
                  "16059677572514140705172788",
                  "16059625605167943573222788",
                  "16059625605010405484432788",
                  "16059358474019188528132788",
                  "16059211472066521570672788",
                  "16057660312387633863902788",
                  "16057660305330297953112788",
                  "16057660223136032411232788",
                  "16057660172527392801092788",
                  "16057590153890829521112788"
                ],
                "products_count": 42
              }
            }
          }
        }
      }
    },
    "401": {
      "headers": {
        "traceId": {
          "description": "A globally unique identifier for the request. It is used to track the request flow throughout the system, allowing for easy location and debugging when issues arise."
        }
      },
      "content": {
        "application/json": {
          "schema": {
            "type": "object",
            "properties": {
              "errors": {
                "description": "Error message. ",
                "type": "string"
              }
            },
            "required": [
              "errors"
            ]
          }
        }
      }
    },
    "429": {
      "headers": {
        "traceId": {
          "description": "A globally unique identifier for the request. It is used to track the request flow throughout the system, allowing for easy location and debugging when issues arise."
        }
      },
      "content": {
        "application/json": {
          "schema": {
            "type": "object",
            "properties": {
              "errors": {
                "description": "Error message. ",
                "type": "string"
              }
            },
            "required": [
              "errors"
            ]
          }
        }
      }
    }
  },
  "security": [
    {
      "oauth2": []
    }
  ],
  "method": "get",
  "path": "/markets/:markets_id/products.json",
  "servers": [
    {
      "url": "https://{handle}.myshopline.com/admin/openapi",
      "variables": {
        "handle": {
          "default": "openapiceshidianpu",
          "description": "`handle` : The store's unique identifier, which is the prefix of the store's domain name. For example, if a store's domain name is `open001.myshopline.com` , the store handle is `open001` ."
        }
      }
    }
  ],
  "info": {
    "title": "Get the list of published products in the market",
    "version": "v20270301"
  },
  "authIndexes": [
    "read_products"
  ]
}
```