正在加载页面,请稍候…

公开文档

织机领毛明细

根据wcid获取对应的明细数据

瑞盈毛织ERP公开接口限流 不限

接口地址

按环境选择对应 Base URL,请求方法见下方标识。

请求基础路径https://api.maoyimall.com/wewin/
GET
Request Method织机领毛明细
生产环境
/open/erp/woolconsumedetail
测试环境
/open/erp/woolconsumedetail

调用说明

鉴权方式、调用限制与参数概览。

鉴权方式

请求需携带应用密钥相关 Header(见下方请求头参数),请先在控制台创建应用并获取 AppId / AppSecret。

调用限制

当前接口日限额为 不限 。超出限额将返回限流错误,请合理控制调用频率。

参数概览

Header 7 项 · Body 1 项 · 其中必填 8 项

字段名类型是否必填说明示例
wcidstring必填——
字段名类型是否必返说明示例
errcodenumber必返错误码0
errmsgstring必返错误码的英文消息ok
dataobject[]可选请求成功时返回的业务数据—
idnumber可选id1041
widnumber可选—1
wcidnumber可选—334
ctidnumber可选—210
woolTypestring可选品种3/68 100%羊绒
houseNamestring可选仓库—
colorTypestring可选—色纱
clidstring可选——
colorstring可选颜色深灰
rgbValuestring可选——
vatNostring可选缸号J2407736-5
packTypestring可选包装—
stripQtynumber可选件数0
planWeightnumber可选—-0.2699999999999996
grossWeightnumber可选虚重0
wetRatenumber可选—0
wasteRatenumber可选损耗%0
netWeightnumber可选配货重1.01
unitPricenumber可选单价0
remarksstring可选备注—
storePosstring可选仓位—
colorIdstring可选色号XC21044M
dyeColorIdstring可选染色号—
plidnumber可选—0
costPricenumber可选—0
priceTagstring可选——
timestampnumber必返请求时的毫秒级时间戳1790040200712

请求示例

1

可直接复制到本地调试的多语言示例。

JavaScript
const crypto = require('crypto');
const axios = require('axios');

// 请替换为真实的appid,appsecret,access token
const APP_ID = 'your_app_id';
const APP_SECRET = 'your_app_secret';
const ACCESS_TOKEN = 'your_access_token';

const BASE_URL = 'https://your-domain.com';

// 请求参数
const params = {
  // 请根据接口实际参数填写
};

// 生成签名
const timestamp = Math.floor(Date.now() / 1000);

const signStr = `${APP_ID}${timestamp}${APP_SECRET}`;
const sign = crypto
  .createHash('md5')
  .update(signStr)
  .digest('hex');

axios({
  method: 'POST',
  url: `${BASE_URL}/open/erp/woolconsumedetail`,
  headers: {
    'Content-Type': 'application/json',
    'appid': APP_ID,
    'access-token': ACCESS_TOKEN,
    timestamp: timestamp,
    sign: sign
  },
  data: params
})
  .then(res => {
    console.log('请求成功:');
    console.log(res.data);
  })
  .catch(err => {
    console.error('请求失败:');
    console.error(err.response ? err.response.data : err.message);
  });
成功响应
{
  "errcode": 0,
  "errmsg": "ok",
  "data": [
    {
      "id": 1041,
      "wid": 1,
      "wcid": 334,
      "ctid": 210,
      "woolType": "3/68 100%羊绒",
      "houseName": null,
      "colorType": "色纱",
      "clid": null,
      "color": "深灰",
      "rgbValue": null,
      "vatNo": "J2407736-5",
      "packType": null,
      "stripQty": 0,
      "planWeight": -0.2699999999999996,
      "grossWeight": 0,
      "wetRate": 0,
      "wasteRate": 0,
      "netWeight": 1.01,
      "unitPrice": 0,
      "remarks": null,
      "storePos": "",
      "colorId": "XC21044M",
      "dyeColorId": "",
      "plid": 0,
      "costPrice": 0,
      "priceTag": null
    }
  ],
  "timestamp": 1790040200712
}
失败响应
{
  "code": 500,
  "message": "操作失败",
  "result": null
}
错误码英文说明中文说明
-1system error系统繁忙,请稍候再试
40001appid invalidAPPID无效或不存在
40002appsecret invalidAppSecret错误,请检查密钥
41001access_token missing请求中未携带access_token
41002access_token expiredacess_token已过期,请重新获取