Skip to content

创建一个用户​

POST
/v2/ship/products/{product_id}/users
  • 用于在产品中创建用户。

授权

企业令牌
企业令牌获取流程
令牌 URLhttps://{rest_api_root}/v1/auth/token
作用域
  • pcp:write:ship:product
或
用户令牌
用户令牌获取流程
授权 URLhttps://{oauth2_root}/authorize
令牌 URLhttps://{rest_api_root}/v1/auth/token
作用域
  • pcp:write:ship:product

参数​

路径参数

product_id*

产品的 id。

类型
string
必填

请求体​

application/json

用户类型。internal 为内部用户,external 为外部用户。

有效值"internal""external"
默认"external"

type 为 internal 时必填,企业成员的用户 id。

用户的名称。type 为 external 时必填。

外部用户的邮箱地址,type 为 external 时邮箱与手机号其中一个必填。

外部用户的手机号,type 为 external 时邮箱与手机号其中一个必填,若同时存在以手机号为准。

用户所属客户的 id。

响应​

响应示例:

application/json

用户的 id。

用户的资源地址。

用户的名称。

用户的显示名称。

用户的头像。

用户的邮箱地址。

用户的手机号。

用户类型。

用户关联产品的引用结构数据。

用户所属客户的引用结构数据。

示例​

举报邮箱:abuse@worktile.com