更新时间:2024-05-28 GMT+08:00
添加用户
功能介绍
通过访问Manager接口完成添加用户。
代码样例
以下代码片段是添加用户的示例,在rest.UserManager类的main方法中。
![](https://support.huaweicloud.com/intl/zh-cn/devg3-mrs/public_sys-resources/note_3.0-zh-cn.png)
密码明文存储存在安全风险,建议在配置文件或者环境变量中密文存放,使用时解密,确保安全。
//访问Manager接口完成添加用户 operationName = "AddUser"; operationUrl = webUrl + ADD_USER_URL; jsonFilePath = "./conf/addUser.json"; httpManager.sendHttpPostRequest(httpClient, operationUrl, jsonFilePath, operationName)
父主题: 样例代码说明