# 查询商品列表

## OpenAPI Specification

```yaml
openapi: 3.0.1
info:
  title: ''
  description: ''
  version: 1.0.0
paths:
  /api/open/product/list:
    post:
      summary: 查询商品列表
      deprecated: false
      description: |-
        注意事项：
        1：该接口只能查询最近六个月内修改过的商品
        2：该接口只返回基础信息，更多信息请调用查询商品详情接口
        3：商品状态为空时，默认不返回`-1:已删除`的商品
      tags:
        - 商品
      parameters:
        - name: appid
          in: query
          description: ''
          required: true
          example: '{{appid}}'
          schema:
            type: string
        - name: timestamp
          in: query
          description: 当前时间戳（单位秒，5分钟内有效）
          required: false
          example: '{{timestamp}}'
          schema:
            type: integer
            default: '{{timestamp}}'
        - name: seller_id
          in: query
          description: 商家ID（仅商务对接传入，自研/第三方ERP对接忽略即可）
          example: '{{seller_id}}'
          schema:
            type: integer
        - name: sign
          in: query
          description: 签名MD5值（参考签名说明）
          required: true
          example: '{{sign}}'
          schema:
            type: string
      requestBody:
        content:
          application/json:
            schema:
              type: object
              properties:
                product_status: &ref_1
                  title: 管家商品状态
                  $ref: '#/components/schemas/product_status'
                  description: '`product_status`和`sale_status`均传入时，优先使用`product_status`'
                page_no:
                  type: integer
                  title: 页码
                  description: '注意：description: 传入值为1代表第一页，传入值为2代表第二页，依此类推'
                  minimum: 1
                  maximum: 100
                  default: 1
                  format: int32
                page_size:
                  type: integer
                  title: 每页行数
                  description: >-
                    注意：当翻页获取的条数（page_no*page_size）超过1万，接口将报错，所以请大家尽可能的细化自己的搜索条件，例如缩短修改时间分段获取商品
                  minimum: 1
                  maximum: 100
                  default: 50
                  format: int32
                online_time: &ref_0
                  title: 商品上架时间
                  $ref: '#/components/schemas/time_range'
                  deprecated: true
                offline_time: *ref_0
                sold_time: *ref_0
                update_time: *ref_0
                create_time: *ref_0
                sale_status:
                  type: integer
                  title: 销售状态
                  description: '枚举值：1 : 待发布2 : 销售中3 : 已下架'
                  format: int32
                  enum:
                    - 1
                    - 2
                    - 3
                  default: 0
                  examples:
                    - 1
                  x-apifox-enum:
                    - value: 1
                      name: ''
                      description: 待发布
                    - value: 2
                      name: ''
                      description: 销售中
                    - value: 3
                      name: ''
                      description: 已下架
              x-apifox-orders:
                - online_time
                - offline_time
                - sold_time
                - update_time
                - create_time
                - product_status
                - sale_status
                - page_no
                - page_size
              x--orders:
                - product_status
                - page_no
                - page_size
                - online_time
                - offline_time
                - sold_time
                - update_time
                - create_time
                - sale_status
              x--ignore-properties: []
            example:
              update_time:
                - 1690300800
                - 1690366883
              product_status: 21
              page_no: 1
              page_size: 50
      responses:
        '200':
          description: ''
          content:
            application/json:
              schema:
                type: object
                x-apifox-refs:
                  01H5SAMZN8TK74ARSB0XBMNX4D:
                    $ref: '#/components/schemas/response_ok'
                    x-apifox-overrides:
                      data:
                        type: object
                        properties:
                          list:
                            type: array
                            items:
                              type: object
                              properties:
                                product_id:
                                  type: integer
                                  title: 闲鱼管家商品ID
                                  format: int64
                                item_biz_type:
                                  title: 商品类型ID
                                  $ref: '#/components/schemas/item_biz_type'
                                sp_biz_type:
                                  title: 商品行业ID
                                  $ref: '#/components/schemas/sp_biz_type'
                                channel_cat_id:
                                  type: string
                                  title: 商品类目ID
                                  examples:
                                    - e11455b218c06e7ae10cfa39bf43dc0f
                                original_price:
                                  title: 商品原价（分）
                                  $ref: '#/components/schemas/original_price'
                                price:
                                  title: 商品售价（分）
                                  $ref: '#/components/schemas/price'
                                stock:
                                  type: integer
                                  title: 商品库存
                                  minimum: 1
                                  maximum: 399960
                                  format: int32
                                  examples:
                                    - 1
                                title:
                                  type: string
                                  title: 商品标题
                                  minLength: 1
                                  maxLength: 30
                                  examples:
                                    - iPhone 12 128G 黑色
                                district_id:
                                  type: integer
                                  title: 发货地区ID
                                  examples:
                                    - 440305
                                outer_id:
                                  type: string
                                  title: 商家编码
                                  examples:
                                    - '2021110112345'
                                spec_type:
                                  title: 商品规格类型
                                  $ref: '#/components/schemas/spec_type'
                                source:
                                  type: integer
                                  enum:
                                    - 11
                                    - 12
                                    - 21
                                    - 91
                                  x-apifox:
                                    enumDescriptions:
                                      '11': 新建商品
                                      '12': 闲鱼APP
                                      '21': 淘宝搬家
                                      '91': ERP
                                  title: 商品来源
                                  examples:
                                    - 91
                                stuff_status:
                                  title: 商品成色
                                  $ref: '#/components/schemas/stuff_status'
                                express_fee:
                                  title: 运费（分）
                                  $ref: '#/components/schemas/express_fee'
                                product_status: *ref_1
                                online_time:
                                  type: integer
                                  title: 商品上架时间
                                  examples:
                                    - 1636019388
                                offline_time:
                                  type: integer
                                  title: 商品下架时间
                                  examples:
                                    - 1636019388
                                sold_time:
                                  type: integer
                                  title: 商品售罄时间
                                  examples:
                                    - 1636019388
                                create_time:
                                  type: integer
                                  title: 商品创建时间
                                  examples:
                                    - 1636019388
                                update_time:
                                  type: integer
                                  title: 商品更新时间
                                  examples:
                                    - 1636019388
                                specify_publish_time:
                                  type: integer
                                  title: 定时上架时间
                                  examples:
                                    - 1692281858
                                sold:
                                  type: integer
                                  title: 商品销量
                                  format: int32
                              required:
                                - product_id
                                - item_biz_type
                                - sp_biz_type
                                - channel_cat_id
                                - original_price
                                - price
                                - stock
                                - title
                                - district_id
                                - outer_id
                                - stuff_status
                                - express_fee
                                - product_status
                                - online_time
                                - offline_time
                                - sold_time
                                - update_time
                                - create_time
                                - spec_type
                                - source
                                - specify_publish_time
                                - sold
                              x-apifox-orders:
                                - product_id
                                - product_status
                                - item_biz_type
                                - sp_biz_type
                                - channel_cat_id
                                - original_price
                                - price
                                - stock
                                - sold
                                - title
                                - district_id
                                - outer_id
                                - stuff_status
                                - express_fee
                                - spec_type
                                - source
                                - specify_publish_time
                                - online_time
                                - offline_time
                                - sold_time
                                - update_time
                                - create_time
                            title: 列表数据
                          count:
                            type: integer
                            format: int32
                            title: 查询总数
                          page_no:
                            type: integer
                            format: int32
                            title: 页码
                          page_size:
                            type: integer
                            format: int32
                            title: 每页行数
                        x-apifox-orders:
                          - list
                          - count
                          - page_no
                          - page_size
                        title: 数据
                        required:
                          - list
                          - count
                          - page_no
                          - page_size
                    required:
                      - data
                x-apifox-orders:
                  - 01H5SAMZN8TK74ARSB0XBMNX4D
                properties: {}
                x--orders: []
                x--ignore-properties: []
              examples:
                '1':
                  summary: 成功示例
                  value:
                    code: 0
                    msg: OK
                    data:
                      list:
                        - product_id: 448592974859525
                          product_status: 31
                          item_biz_type: 2
                          sp_biz_type: 27
                          channel_cat_id: 48b41f39bc7cb246267e0a01017d9f44
                          original_price: 400000
                          price: 400000
                          stock: 2
                          title: 测试0717食品-海外
                          district_id: 130100
                          outer_id: CS-230717
                          stuff_status: 60
                          express_fee: 1
                          spec_type: 1
                          source: 14
                          specify_publish_time: 0
                          online_time: 1691656170
                          offline_time: 1691657197
                          sold_time: 0
                          update_time: 1691657199
                          create_time: 1691656171
                      count: 100
                      page_no: 1
                      page_size: 5
                '2':
                  summary: 异常示例
                  value:
                    code: 500
                    msg: Internal Server Error
          headers: {}
          x-apifox-name: 成功
        x-200:失败:
          description: ''
          content:
            application/json:
              schema:
                type: object
                properties:
                  msg:
                    type: string
                    examples:
                      - Internal Server Error
                    additionalProperties: false
                  code:
                    type: integer
                    format: int32
                    examples:
                      - 500
                    additionalProperties: false
                required:
                  - msg
                  - code
                x-apifox-orders:
                  - code
                  - msg
                x--orders:
                  - msg
                  - code
                x--ignore-properties: []
          headers: {}
          x-apifox-name: 失败
      security: []
      x-apifox-folder: 商品
      x-apifox-status: released
      x-run-in-apifox: https://app.apifox.com/web/project/2973339/apis/api-93586381-run
components:
  schemas:
    time_range:
      type: array
      items:
        type: integer
        format: int64
        x--mock: '@timestamp'
      title: 时间范围
      description: 第一个元素值为开始时间戳,第二个元素值为结束时间戳
      minItems: 2
      maxItems: 2
      x-apifox-folder: ''
    product_status:
      type: integer
      title: 商品状态
      description: '枚举值：-1 : 已删除21 : 待发布22 : 销售中23 : 已售罄31 : 手动下架33 : 售出下架36 : 自动下架'
      format: int32
      enum:
        - -1
        - 21
        - 22
        - 23
        - 31
        - 33
        - 36
      x-apifox:
        enumDescriptions:
          '21': 待发布
          '22': 销售中
          '23': 已售罄
          '31': 手动下架
          '33': 售出下架
          '36': 自动下架
          '-1': 删除
      default: 0
      examples:
        - 21
      x-apifox-folder: ''
    response_ok:
      type: object
      properties:
        code:
          type: integer
          format: int32
          additionalProperties: false
          default: 0
        data:
          type: object
          properties: {}
          x-apifox-orders: []
          additionalProperties: false
          x--orders: []
          x--ignore-properties: []
        msg:
          type: string
          additionalProperties: false
          default: OK
      x-apifox-orders:
        - code
        - msg
        - data
      required:
        - code
        - data
        - msg
      title: 成功报文
      x--orders:
        - code
        - data
        - msg
      x--ignore-properties: []
      x-apifox-folder: ''
    express_fee:
      type: integer
      title: 运费
      format: int64
      x-apifox-folder: ''
    stuff_status:
      type: integer
      title: 商品成色
      description: |-
        枚举值：
        0 : 无成色（普通商品可用）
        100 : 全新
         -1 : 准新 
        99 : 99新 
        95 : 95新 
        90 : 9新 
        80 : 8新 
        70 : 7新 
        60 : 6新 
        50 : 5新 

        -仅品牌捡漏类型可用-
        40 : 未使用·中度瑕疵
        30 : 未使用·轻微瑕疵
        20 : 未使用·仅拆封
        10 : 未使用·准新
        100 : 全新未使用
        -仅品牌捡漏类型可用-

        及以下注意：非普通商品类型时必填~~
      format: int32
      enum:
        - 100
        - -1
        - 99
        - 95
        - 90
        - 80
        - 70
        - 60
        - 50
        - 40
        - 30
        - 20
        - 10
        - 0
      x-apifox:
        enumDescriptions:
          '0': 无
          '10': 未使用·准新
          '20': 未使用·仅拆封
          '30': 未使用·轻微瑕疵
          '40': 未使用·中度瑕疵
          '50': 5新及以下
          '60': 6新
          '70': 7新
          '80': 8新
          '90': 9新
          '95': 95新
          '99': 99新
          '100': 全新
          '-1': 准新
      default: 0
      examples:
        - 100
      x-apifox-folder: ''
    spec_type:
      type: integer
      title: 规格类型
      description: |
        枚举值：
        1 : 单规格
        2 : 多规格
      enum:
        - 1
        - 2
      x-apifox:
        enumDescriptions:
          '1': 单规格
          '2': 多规格
      format: int32
      examples:
        - 1
      x-apifox-folder: ''
    price:
      type: integer
      title: 商品售价
      minimum: 1
      maximum: 9999999900
      format: int64
      examples:
        - 199900
      x-apifox-folder: ''
    original_price:
      type: integer
      title: 商品原价
      minimum: 0
      maximum: 9999999900
      format: int64
      examples:
        - 199900
      x-apifox-folder: ''
    sp_biz_type:
      type: integer
      title: 行业类型
      format: int32
      enum:
        - 1
        - 2
        - 3
        - 8
        - 9
        - 16
        - 17
        - 18
        - 19
        - 20
        - 21
        - 22
        - 23
        - 24
        - 25
        - 27
        - 28
        - 29
        - 30
        - 31
        - 33
        - 99
      examples:
        - 2
      x-apifox-enum:
        - name: ''
          value: 1
          description: 手机
        - name: ''
          value: 2
          description: 潮品
        - name: ''
          value: 3
          description: 家电
        - name: ''
          value: 8
          description: 乐器
        - name: ''
          value: 9
          description: 3C数码
        - name: ''
          value: 16
          description: 奢品
        - name: ''
          value: 17
          description: 母婴
        - name: ''
          value: 18
          description: 美妆个护
        - name: ''
          value: 19
          description: 文玩/珠宝
        - name: ''
          value: 20
          description: 游戏电玩
        - name: ''
          value: 21
          description: 家居
        - name: ''
          value: 22
          description: 虚拟游戏
        - name: ''
          value: 23
          description: 租号
        - name: ''
          value: 24
          description: 图书
        - name: ''
          value: 25
          description: 卡券
        - name: ''
          value: 27
          description: 食品
        - name: ''
          value: 28
          description: 潮玩
        - name: ''
          value: 29
          description: 二手车
        - name: ''
          value: 30
          description: 宠植
        - name: ''
          value: 31
          description: 工艺礼品
        - name: ''
          value: 33
          description: 汽车服务
        - name: ''
          value: 99
          description: 其他
      x-apifox-folder: ''
    item_biz_type:
      type: integer
      title: 商品类型
      format: int32
      enum:
        - 2
        - 0
        - 10
        - 16
        - 19
        - 24
        - 26
        - 35
      examples:
        - 2
      x-apifox-enum:
        - name: ''
          value: 2
          description: 普通商品
        - name: ''
          value: 0
          description: 已验货
        - name: ''
          value: 10
          description: 验货宝
        - name: ''
          value: 16
          description: 品牌授权
        - name: ''
          value: 19
          description: 闲鱼严选
        - name: ''
          value: 24
          description: 闲鱼特卖
        - name: ''
          value: 26
          description: 品牌捡漏
        - value: 35
          name: ''
          description: 跨境商品
      x-apifox-folder: ''
  securitySchemes:
    apiKey:
      type: apikey
      description: Enter JWT Bearer token **_only_**
      name: Authorization
      in: header
servers:
  - url: https://open.goofish.pro
    description: 新版正式环境
security: []

```
