insertUser

This action inserts a new user in the ExtraView database. The user must not exist in the database, else an error results.

Input

Class

Name

Type

Required

Details

InsertUserRequest

userId

String

Yes

The callers user name

InsertUserRequest

password

String

Yes

The callers password

InsertUserRequest

newUserId

String

Yes

The desired new user id (must be unique)

InsertUserRequest

newUserPassword

String

Yes

The desired new password

InsertUserRequest

firstName

String

Yes

The new users first name

InsertUserRequest

lastName

String

Yes

The new users last name

InsertUserRequest

email

String

Yes

The new users email address

InsertUserRequest

jobTitle

String

No

The new users job title

InsertUserRequest

companyName

String

No

The new users Company name

InsertUserRequest

addressLine1

String

No

The new users address (line 1)

InsertUserRequest

addressLine2

String

No

The new users address (line 2)

InsertUserRequest

city

String

No

The new users city

InsertUserRequest

state

String

No

The new users state

InsertUserRequest

postalCode

String

No

The new users postal code

InsertUserRequest

country

String

No

The new users country

InsertUserRequest

workPhoneNumber

String

No

The new users work phone number

InsertUserRequest

homePhoneNumber

String

No

The new users home phone number

InsertUserRequest

cellPhoneNumber

String

No

The new users cell phone number

InsertUserRequest

faxNumber

String

No

The new users fax phone number

InsertUserRequest

pagerNumber

String

No

The new users pager phone number

Output

Class

Name

Type

Required

Details

InsertUserResponse

success

boolean

Yes

True is succeeded False if failed

InsertUserResponse

returnCode

String

No

See Appendix for details

InsertUserResponse

returnMessage

String

No

Human readable message

Example

public static void testInsertUser(EVUserServiceStub stub) {
    try {
        // first we build the request...
        InsertUserDocument reqEnvelope = InsertUserDocument.Factory.newInstance();
        InsertUserRequest request = reqEnvelope.addNewInsertUser().addNewParam0();
        request.setNewUserPassword(ServiceClientHelper.generatedPassword);
        request.setNewUserId(ServiceClientHelper.generatedUserId);
        request.setUserId(ServiceClientHelper.ADMIN_USER_ID);
        request.setPassword(ServiceClientHelper.ADMIN_PASSWORD);
        request.setEmail(ServiceClientHelper.generatedEmail);
        request.setFirstName(ServiceClientHelper.generatedFirstName);
        request.setLastName(ServiceClientHelper.generatedLastName);
        InsertUserResponseDocument resEnvelope = stub.insertUser(reqEnvelope);
        InsertUserResponse response = resEnvelope.getInsertUserResponse().getReturn();
        if (response.getSuccess()) {
            System.out.println("success: [" + response.getReturnCode() + "] : " +
                response.getReturnMessage());
            System.out.println(
              "user [" + ServiceClientHelper.generatedUserId + "] user has been inserted.");
        } else {
            System.out.println("failure: [" + response.getReturnCode() + "] : " +
                                              response.getReturnMessage());
        }
    } catch (Exception e) {
        e.printStackTrace();
        System.err.println("nnn");
    }
}