Adding and Updating a User

This RESTful web service request can be used to add or update a user to WebFOCUS.

HTTP Method: POST

REST URL Format:

http://host:port/ibi_apps/rs/ibfs/SSYS/USERS/Userid

where:

host

Is the name of the system where WebFOCUS is installed.

port

Is the port number used by WebFOCUS.

Userid

Is the name of the user ID to be added.

Body Format:

IBIRS_action=put&IBIRS_object=Object&IBIRS_replace=ReplaceUseridProperties

where:

Object

Is the XML object defining the attributes for the user, using the following format:

<object _jt="IBFSUserObject" description="UseridTitle" email="EmailAddress"
  password="Password" type="User"><status _jt="IBSSUserStatus" name="Status"/></object>

where:

UseridTitle

Is the title for the user. If the title contains an ampersand character (&), this character should be encoded as &amp;.

EmailAddress

Is the email address for the user.

Password

Is the password assigned to the user ID.

Status

Is the status as to whether the user ID is to be added as an active or inactive user. The user ID can also be added or updated so that the password must be changed when signing on. Once the user signs on, the status is changed to Active. Choose from one of the following valid values:

  • ACTIVE
  • INACTIVE
  • MUSTCHANGE
ReplaceUseridProperties

Is an optional property that allows you to decide whether or not the properties for user ID can be updated. The following are examples of properties:

You can choose true (default) or false.

Example:

In the following example, a user ID called restid is added. The title for the user is Rest Userid. The email address for the user is restid@informationbuilders.com. The password for the user is rest. The status for the user is ACTIVE.

Request:

http://localhost:8080/ibi_apps/rs/ibfs/SSYS/USERS/restid

Body:

IBIRS_action=put&IBIRS_object=<object _jt="IBFSUserObject" description="Rest Userid" email="restid@informationbuilders.com"
  password="rest" type="User"><status _jt="IBSSUserStatus" name="ACTIVE"/></object>

Response:

<?xml version="1.0" encoding="UTF-8" standalone="no"?>
<ibfsrpc _jt="IBFSResponseObject" language="EN" name="IBIRS_action" returncode="10000" returndesc="SUCCESS" subreturncode="0"
         subsystem="SSYS" type="simple">
   <ibfsparams size="0"/>
   <rootObject _jt="IBFSUserObject" description="Rest Userid" dummy="false" email="restid@informationbuilders.com"
              fullPath="/SSYS/USERS/restid" name="restid" password="rest" policy="///+f///////9/////////////+AAAAA" type="User">
      <status _jt="IBSSUserStatus" name="ACTIVE"/>
      <groups _jt="ArrayList" size="0"/>
   </rootObject>
</ibfsrpc>

If the value for the returncode attribute in the XML response is 10000, then the user was added successfully.


WebFOCUS