[英]Postman - How to Import Users to a BIM 360 Project Using the V2 Endpoint
I am working on a small .NET Console App that uses the BIM 360 API to manage both Project and Account members using the two-legged authentication method. 我正在使用小型.NET控制台应用程序,该应用程序使用BIM 360 API使用两足身份验证方法来管理项目和帐户成员。 I am having trouble trying to import users to a BIM 360 Project using the hq/v2/accounts/:account_id/projects/:project_id/users/import endpoint.
我在尝试使用hq / v2 / accounts /:account_id / projects /:project_id / users / import端点将用户导入BIM 360 Project时遇到麻烦。
In both a .NET Console App and Postman, I receive a 404 status code with the following body response: 在.NET Console应用程序和Postman中,我都收到带有以下正文响应的404状态代码:
{
"code": 1004,
"message": "this user doesn't exist."
}
Request Header : 请求标头 :
Content-Type: "application/json";
x-user-id: "********-****-****-****-************";
Authorization: Bearer ****<two-legged token string>*****;
( x-user-id is the guid assigned to the account admin) ( x-user-id是分配给帐户admin的guid)
Request Body : 请求正文 :
{
"user_id": "********-****-****-****-************",
"services": {
"project_administration": {
"access_level": "admin"
},
"document_management": {
"access_level": "admin"
}
},
"company_id": "********-****-****-****-************",
"industry_roles": []
}
In the request body, I have used both the user_id
fetched from the hq/v1/accounts/:account_id/users/:user_id id
property, and the email
. 在请求主体,我用两个
user_id
来自取出HQ / V1 /帐号/:ACCOUNT_ID /用户/:USER_ID id
属性和email
。 I have used a user who is already a member of the project, a user who is in the Admin directory but not a member of the project, and a completely new user who is neither. 我使用了一个已经是该项目成员的用户,一个在Admin目录中但不是该项目成员的用户以及一个都不是的全新用户。 All three still return the same error.
所有这三个仍然返回相同的错误。
I've came across similar questions here and here but still can't get it to work. 我在这里和这里都遇到过类似的问题,但仍然无法解决。 Is there something else I am overlooking?
我还有其他事要注意吗? Thanks in advance for the help.
先谢谢您的帮助。
有效负载和x-user-id
标头的user_id
属性需要是用户的uid
而不是用户的id
。
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.