尝试使用category_id添加项目时出现Square-Connect 422错误

时间:2014-05-17 03:33:54

标签: square-connect

当我加入" category_id"时,我收到422响应在项目正文中(当我不包括category_id时,它可以正常工作)。

这是失败的json对象

{
 "name":"9001 Donald Duck",
 "category_id":"284958c8-c837-41b3-8984-6faf2589bcf5",
  "abbreviation":"9001",
  "visibility":"PRIVATE",
  "variations":[
    {"name":"credit card payment",
     "pricing_type":"FIXED_PRICING",
     "price_money":{"currency_code":"USD","amount":"100"}
     }]
 }

我成功添加了没有category_id的项目,然后使用信息中心将其链接到类别,然后执行了项目列表以确保我使用了正确的类别。

以下是商家信息的回复(具有相同类别):

{
 "visibility":"PRIVATE",
 "available_online":false,
 "available_for_pickup":false,
 "id":"4a4c2d1d-ddb7-4b45-b432-f511c5a92117",
 "name":"9001 Donald Duck",
 "taxable":false,"abbreviation":"9001",
 "category_id":"284958c8-c837-41b3-8984-6faf2589bcf5",
 "category":{
      "id":"284958c8-c837-41b3-8984-6faf2589bcf5",
      "name":"Annual Auction & Party Bidders (7fa314q7)"},
 "variations":[
      {"pricing_type":"FIXED_PRICING","track_inventory":false,
       "id":"010fecb9-bd21-406b-bf13-ec42eff07e64",
       "name":"credit card payment",
        "price_money":{"currency_code":"USD","amount":100},
       "ordinal":0,
       "item_id":"4a4c2d1d-ddb7-4b45-b432-f511c5a92117"
      }]
  },

这是一个错误,还是我做错了什么?

0 个答案:

没有答案