需要 read_products 权限点。
更多权限点使用信息,请参考:
GET https://{handle}.myshopline.com/admin/openapi/v20220901/products/products.json
handle :店铺的唯一标识符,值为店铺域名的前缀。例如,域名为 open001.myshopline.com 的店铺,其 handleopen001
批量查询商品基本信息
查询参数
  • brand string
    商品品牌
    Example: Shopline
  • collection_id string
    商品分类ID
    Example: 12248721639068681442230282
  • created_at_max string
    创建时间在XXX前(格式见IOS8601)
    Example: 2021-09-02T14:11:54+00:00
  • created_at_min string
    创建时间从XXX起(格式见IOS8601)
    Example: 2021-09-02T14:11:54+00:00
  • fields string
    一级属性,逗号分隔
    Example: title,id,created_at
  • handle string
    全局唯一的商品handle, 在使用批量查询商品接口时,准确传入此参数等同于查询单个商品
    Example: product-handle
  • ids string
    指定的Id对象,多个用","分隔
    Example: 16057850264845250791280282,16057850264845250333280282
  • limit integer
    查询数量限制,默认50,不能超过250
    Example: 100
  • order_by string
    排序方式,created_at_asc:创建时间从远到近,created_at_desc:创建时间从近到远
    Example: created_at_desc
  • page_info string
    分页信息
    Example: eyJzaW5jZUlkIjoiMTYwNTc4NTY3NjcxMTc3MDcyNTEwNjAyODIiLCJkaXJlY3Rpb24iOiJuZXh0Iiwic29ydFR5cGUiOiJjcmVh
  • product_category string
    产品类型
    Example: 电子产品
  • since_id string
    返回某个ID“之后”的对象
    Example: 16057850264845250791280282
  • status string
    商品状态;active-上架,draft-下架,archived-归档
    Example: active
  • title string
    商品标题,不分词、不模糊查询
    Example: 这是商品标题
  • updated_at_max string
    更新时间在XXX前(格式见IOS8601)
    Example: 2021-09-02T14:11:54+00:00
  • updated_at_min string
    更新时间从XXX起(格式见IOS8601)
    Example: 2021-09-02T14:11:54+00:00
请求头
  • Content-Type required
    字段值固定为application/json; charset=utf-8
  • Authorization string required
    资源的访问令牌。请参考 应用授权 获取访问令牌,然后将获取到的访问令牌以 Bearer 格式传入
    Example:
    Bearer eyJhbGciOiJIUzUxMiJ9.eyJhcHBLZXkiOiJmMjM3OWQyMTYyOGMzM2QxMWRiMWZkYjY5N2EzZjdjMjZlNGMwYTA5Iiwic2VsbGVySWQiOiIyMDAwMjM0ODgwIiwic3RvcmVJZCI6IjE2NzIzNjk3Mjk2MDYiLCJ2ZXJzaW9uIjoiVjIiLCJkb21haW4iOiJodHRwczovL3NsLW9wZW4tc2cubXlzaG9wbGluZS5jb20iLCJ0aW1lc3RhbXAiOjE2NzUzMTk0OTI0MzksImlzcyI6Inlzb3VsIiwiZXhwIjoxNzY5OTI3NDkyfQ.UwQzomM2veGCUaOZ0paUxq5dpc7DXuhHYFvsQ_uIAKduzWcb_j2E4q_36El83sp145D4cKbpcE5KCeeIz-JNQw
响应
更多状态码信息请参考 HTTP 状态码

响应头
  • link
    查询跳转页
  • traceId
    traceId
响应体
  • productsobject[]
    商品
  • body_html string
    商品描述
    Example: 这是商品描述
  • brand string
    品牌
    Example: Shopline
  • created_at string
    创建时间(格式见IOS8601)
    Example: 2021-09-03T14:11:54+00:00
  • handle string
    商品handle
    Example: product-handle
  • id string
    商品id
    Example: 16057850264845250791280282
  • imageobject
    第一张主图
  • alt string
    alt
    Example: 这是图片ALT
  • src string
    src
    Example: https://img.myshopline.com/image/official/e46e6189dd5641a3b179444cacdcdd2a.png
  • imagesobject[]
    主图列表
  • alt string
    alt
    Example: 这是图片ALT
  • src string
    src
    Example: https://img.myshopline.com/image/official/e46e6189dd5641a3b179444cacdcdd2a.png
  • optionsobject[]
    属性列表
  • id string
    商品属性的ID
    Example: 16158068291703878544960282
  • name string
    属性名称
    Example: Color
  • product_id string
    对应的商品ID
    Example: 16057850264845250791280282
  • values array
    属性值列表
    Example: [Red]
  • values_images map
    属性值图
    Example: [object Object]
  • product_behavior string
    商品的行为
    Example: RISK,HIDDEN
  • product_category string
    产品类型
    Example: 电子产品
  • product_type string
    商品类型:NORMAL-正常商品,POD_TEMPORARY-POD临时商品,TEMPORARY-临时商品
    Example: NORMAL
  • published_at string
    发布时间
    Example: 2021-09-02T14:11:54+00:00
  • published_scope string
    设置发布范围,值为「web」时表示在线商店
    Example: web
  • status string
    商品状态;active-上架,draft-下架,archived-归档
    Example: active
  • subtitle string
    摘要
    Example: 这是商品副标题
  • tags string
    标签,逗号分隔
    Example: tag1,tag2
  • template_path string
    主题模板
    Example: templates/products/detail.json
  • title string
    标题
    Example: 这是商品标题
  • updated_at string
    更新时间(格式见IOS8601)
    Example: 2021-09-02T14:11:54+00:00
  • variantsobject[]
    款式列表
  • barcode string
    条形码
    Example: T0000001
  • compare_at_price string
    原价
    Example: 99
  • id string
    款式ID
    Example: 18057850264851626133510282
  • imageobject
    图片
  • alt string
    alt
    Example: 这是图片ALT
  • src string
    src
    Example: https://img.myshopline.com/image/official/e46e6189dd5641a3b179444cacdcdd2a.png
  • inventory_item_id string
    库存对象ID
    Example: 5785060242375689228
  • inventory_policy string
    超卖策略,continue:允许,deny:不允许
    Example: deny
  • inventory_quantity integer
    库存数
    Example: 99
  • inventory_tracker boolean
    是否追踪库存
    Example: true
  • option1 string
    属性值1
    Example: Red
  • option2 string
    属性值2
    Example: L
  • option3 string
    属性值3
  • option4 string
    属性值4
  • option5 string
    属性值5
  • position integer
    款式的位置权重
    Example: 1
  • price string
    销售价
    Example: 90
  • product_id string
    对应的商品ID
    Example: 16057850264845250791280282
  • required_shipping boolean
    是否需要发货
    Example: true
  • sku string
    SKU码
    Example: S000000001
  • taxable boolean
    是否需要收税
    Example: true
  • title string
    款式标题
    Example: Red/L
  • weight string
    重量
    Example: 0.2
  • weight_unit string
    重量单位, g:克,kg:千克,lb:磅,oz:盎司,zh_kg:公斤
    Example: kg
API Explorer
https://openapiceshidianpu.myshopline.com/admin/openapi/v20220901

ParamOptions

— header required
— query
— query
— query
— query
— query
— query
— query
— query
— query
— query
— query
— query
— query
— query
— query
— query

Language

curl --request GET \
--url https://openapiceshidianpu.myshopline.com/admin/openapi/v20220901/products/products.json \
--header 'Authorization: Bearer eyJhbGciOiJIUzUxMiJ9.eyJhcHBLZXkiOiJmMjM3OWQyMTYyOGMzM2QxMWRiMWZkYjY5N2EzZjdjMjZlNGMwYTA5Iiwic2VsbGVySWQiOiIyMDAwMjM0ODgwIiwic3RvcmVJZCI6IjE2NzIzNjk3Mjk2MDYiLCJ2ZXJzaW9uIjoiVjIiLCJkb21haW4iOiJodHRwczovL3NsLW9wZW4tc2cubXlzaG9wbGluZS5jb20iLCJ0aW1lc3RhbXAiOjE2NzUzMTk0OTI0MzksImlzcyI6Inlzb3VsIiwiZXhwIjoxNzY5OTI3NDkyfQ.UwQzomM2veGCUaOZ0paUxq5dpc7DXuhHYFvsQ_uIAKduzWcb_j2E4q_36El83sp145D4cKbpcE5KCeeIz-JNQw' \
--header 'Content-Type: application/json; charset=utf-8' \
--header 'accept: application/json'
这篇文章对你有帮助吗?

Error loading component.

Error loading component.