Creating Protected Directory User
Use the add-user operation to create a protected directory user.
Request Packet Structure
A request XML packet adding a protected directory user includes the add-user operation node:
The add-user node is presented by type ProtectedDirAddUserlInput (
protected_dir.xsd), and its graphical representation is as follows:
- The pd-id node is required. It specifies the protected directory ID. Data type: integer.
- The login node is required. It specifies the protected directory user login. Data type: string.
- The password node is required. It specifies the protected directory user password. Data type: string.
- The password-type node is optional. It specifies the protected directory user password type. Data type: string. Allowed values: plain | crypt.
Important: When creating request packets, put nodes and elements in the order they follow in the packet structure.
Response Packet Structure
The add-user node of the output XML packet is presented by type ProtectedDirAddUserOutput (
protected_dir.xsd) and structured as follows:
- The result node is required. It wraps the response retrieved from the server. Data type: resultType (
- The status node is required. It specifies the execution status of the operation. Data type: string. Allowed values: ok | error.
- The errcode node is optional. Is returns the error code if the operation fails. Data type: integer.
- The errtext node is optional. It returns the error message if the operation fails. Data type: string.
- The id node is required if the operation succeeds. It returns the ID of the added protected directory user. Data type: integer.
The packet that creates user MyUser for the protected directory with ID 1 looks as follows:
If the user already exists, the response from the server looks as follows: