首页 > 解决方案 > 对项目用户更新端点的补丁请求失败

问题描述

当我使用属性发出补丁请求https://developer.api.autodesk.com/hq/v2/accounts/:account_id/projects/:project_id/users/:user_id 并传递角色 ID 列表时,industry_roles我得到以下响应:

{'code': 1001, 'message': 'users list about to be imported are empty or in wrong format.'}

有谁知道为什么会这样?

我在请求中传递的正文是:

{
    "company_id": <my company id>,
    "industry_roles": [
      <role id>,
      <role id>
    ]
}

标签: autodesk-forgeautodesk-bim360

解决方案


请确保数据作为带有标头的 JSON 传递content-type:application/json


推荐阅读