Get product collection relationships
GET https://{handle}.myshopline.com/admin/openapi/v20261201/products/collects.json
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 .Get a list of relationships between products and collections.
Query Parameters
- limit stringThe quantity limit of relationships to be queried.
Value range: 1-250
Default Value: 50 - page_info stringThe unique identifier for pagination queries, used to locate a specific page.This parameter value is obtained from the
linkvalue in the response header of this API after you have queried the pagination information.For example, if thelinkvalue you obtained is<https://{handle}.myshopline.com/admin/openapi/{version}/products/collects.json?limit=1&page_info=eyJzaW5jZUlkIjoiMTYwNTc1OTAxNTM4OTA4Mjk1MjExMTI3ODgiLCJkaXJlY3Rpb24iOiJuZXh0IiwibGltaXQiOjF9>; rel="next", the value ofpage_infoiseyJzaW5jZUlkIjoiMTYwNTc1OTAxNTM4OTA4Mjk1MjExMTI3ODgiLCJkaXJlY3Rpb24iOiJuZXh0IiwibGltaXQiOjF9.For more information on how to use pagination, refer to Paging Mechanism. - product_id stringThe unique identifier for the product.
Maximum length:64Example:16057039432335097907370282 - since_id stringThe ID of a specific product collection relationship. Start querying product collection relationships from this specified ID.Example:
6063851731392959569,6239973670640427881 - collection_id stringThe unique identifier for the collection.
Maximum length: 64Example:12249026592161154694000282 - fields stringSpecify the fields to be returned, with multiple fields separated by commas. For available fields, refer to the top-level child parameters under the
collectsobject in the response.Example:created_at,id
Request Headers
- Content-Type string requiredThe field must be set to the fixed value
application/json; charset=utf-8. - Authorization string requiredThe access token for the API resource. Refer to App authorization to obtain the access token, and then pass the obtained token in the Bearer format.Example:
Bearer eyJhbGciOiJIUzUxMiIsInR5cCI6IkpXVCJ9.eyJhcHBJZCI6MCwiYXBwS2V5IjoiNzU2ZjI1NWE2NjdlZTcwNTk1MzM0ZjVjYzk4NzU5MzBmN2E3NGZjMSIsImV4cCI6MTg3OTQ4MjA3NiwiaXNzIjoieXNvdWwiLCJzZWxsZXJJZCI6IjIwMDAyMzQ4ODAiLCJzdG9yZUlkIjoiMTY3MjM2OTcyOTYwNiIsInRpbWVzdGFtcCI6MTc4NDc4NzY3NjY2MSwidmVyc2lvbiI6IlYyIn0.3ZzbGAH4cLU1QR2VPEvMOQInUDvus-C4amkINSQIPuNVlXsFKj0sAt1c0KnUy9MWUOFV9cHlkf7J90r2y1FzpA
Status Codes
- 200
- 401
- 429
For the complete list of codes and messages, see Http status code.
Response Headers
link
The URL link that provides the pagination data. You can obtainpage_infofrom 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.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
collectsobject[]
A list of relationships.product_id stringThe unique identifier for the product.Example:16057039432335097907370282product_priority longThe priority of a product within a collection. A smaller value indicates a higher priority. The priority values are non-continuous and are not arranged in sequential integers.Example:10000000000000sort_value stringProduct sorting value within a collection. Constructed by left-padding theproduct_priorityvalue with zeros to reach a total length of 20 characters.Example:00000010000000000000updated_at stringThe date and time when the product collection relationship was last updated. Format: ISO 8601.Example:2025-03-06T02:20:26+08:00collection_id stringThe unique identifier for the collection.Example:12249026592161154694000282created_at stringThe date and time when the product collection relationship was created. Format: ISO 8601.Example:2025-03-06T02:20:26+08:00id longThe unique identifier for the product collection relationship.Example:5392284410644534000
API Explorer
Debugger
Examples
Was this article helpful to you?