Update/Insert one user from/to the database

updateUserDotweb(p_companyID, p_ws_StoreId, p_wsAltUserId, p_PIN, p_Achternaam, p_Voornaam, p_Admin, p_Security, p_StartDate, p_ExpireDate, p_infoFields, p_groupName, p_groupUpdate, p_licensePlate, p_locationID)


You can use this endpoint to insert/update one user from/to our database.


Name Type Required Description
p_companyID string Yes A common security code used by all Plus companies to connect to our webservice. Ask EasySecure International to provide it
p_ws_StoreId numeric Yes Each company which is part of group Plus has a DotWeb store_id in order to know to which company we need to connect
p_wsAltUserId string Yes Used to identify a user in our database based on it's wsAltUserId value. If a user is found, we will update that user, otherwise we will insert a new user – this value must be an alphanumeric string
p_PIN string Yes the PIN of the user, numeric.
NOTE* in case user doesn't have PIN, empty string should be sent to ESWS
p_Achternaam string Yes The lastname of the user
p_Voornaam string Yes The firstname of the user
p_Admin integer Yes 0 if not admin, 1 if admin
p_Security integer Yes 0 if not admin, 1 if admin
p_StartDate string Yes Starting with this date the user is active within EasySecure, datetime format string (yyyy-mm-dd hh:ii:ss). If p_StartDate is not provided or the format is not ok we will add the current date as start date
p_ExpireDate string Yes When the user becomes unavailable for EasySecure actions, datetime format string (yyyy-mm-dd hh:ii:ss). If p_ExpireDate is not provided or the format is not ok we will add as end date = 2030-12-31.
p_infoFields array Yes an associative array of type , with the keys info1, info2, ..., info14.
p_groupName string Required in case the company is type Branches The name of the group or the group names splitted by ';' (as example: Group1;Group2) the user belongs to, string.
NOTE* The group name must exist in the database in case of Branch type companies.
p_groupUpdate integer No 0 or 1
p_licensePlate string No the license plate for the user
p_locationId integer No id of the location, If the company is type branch and the location ID is provided we will remove only the groups that are linked to the provided location ID and link the user to the provided Groups

If p_infoFieldName is not one of the info1, ..., info14 values than the search based on user info fields will not take place.

WsAltUserId value accepts only numbers, small letters, capital letters and the '-' character. If the wsAltUserId string contains other character, the value for wsAltUserId will not be saved.

Return values

“INSERTED” - the user was successfully added in our db.

“UPDATED” - the users was successfully updated.

ERROR_UNKNOWN_SECURITY_HASH: $p_CompanyID added was incorrect.

ERROR_UNKNOWN_STORE_ID: the $wsStoreId added was not found in any of our companies.

ERROR_NO_SECURITY_HASH: the $p_CompanyID is empty/not sent.

NO_ID_RECEIVED: the $p_wsAltUserId field is empty/not sent.

PIN must be unique: the $p_PIN value already exists in our database.

PIN data should consist of numeric character: the $p_PIN is not numeric (should contain only numbers).

wsStartDatum (INFO*) and wsEindDatum (INFO*) must have this following format: the $info* which is set to be wsStartDatum or wsEindDatum are not sent in the correct format (dd-mm-yyyy).

NOT_INSERTED_ERROR: The data was not saved.

NO_WS_ALT_USER_ID_LABEL: The company doesn't have infolabel wsAltUserId.

NO_FIRSTNAME_RECEIVED: the $p_Voornaam field is left empty.

NO_LASTNAME_RECEIVED: the $p_Achternaam field is left empty.

START_DATE_CAN_NOT_BE_AFTER_END_DATE: the $p_StartDate is after the $p_EndDate, user can not start after his dates expire

$p_ws_StoreId_VALUE_MUST_MATCH_WITH_infoX: it is mandatory that the set values to match.


<soapenv:Envelope xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/" xmlns:uen="uen:esws">
<uen:Esws.updateUserDotweb soapenv:encodingStyle="http://schemas.xmlsoap.org/soap/encoding/">
<p_companyID xsi:type="xsd:string">^4p;tU0Q+#dEIhTWkuj5FnLD^aKWqVu0</p_companyID>
<p_ws_StoreId xsi:type="xsd:string">2564</p_ws_StoreId>
<p_wsAltUserId xsi:type="xsd:string">1</p_wsAltUserId>
<p_PIN xsi:type="xsd:string">1234</p_PIN>
<p_Achternaam xsi:type="xsd:string">Lastname</p_Achternaam>
<p_Voornaam xsi:type="xsd:string">Firstname</p_Voornaam>
<p_Admin xsi:type="xsd:string">1</p_Admin>
<p_Security xsi:type="xsd:string">1</p_Security>
<p_StartDate xsi:type="xsd:string">2021-01-01</p_StartDate>
<p_ExpireDate xsi:type="xsd:string">2021-12-31</p_ExpireDate>
<p_infoFields xsi:type="uen:updateUserInfosObject">
<info1 xsi:type="xsd:string">info1</info1>
<info2 xsi:type="xsd:string">info2</info2>
<info3 xsi:type="xsd:string">info3</info3>
<info4 xsi:type="xsd:string">info4</info4>
<info5 xsi:type="xsd:string">info5</info5>
<info6 xsi:type="xsd:string">info6</info6>
<info7 xsi:type="xsd:string">info7</info7>
<info8 xsi:type="xsd:string">info8</info8>
<info9 xsi:type="xsd:string">info9</info9>
<info10 xsi:type="xsd:string">info10</info10>
<info11 xsi:type="xsd:string">info11</info11>
<info12 xsi:type="xsd:string">info12</info12>
<info13 xsi:type="xsd:string">info13</info13>
<info14 xsi:type="xsd:string">info14</info14>
<p_groupName xsi:type="xsd:string">Group Name</p_groupName>
<p_groupUpdate xsi:type="xsd:string">1</p_groupUpdate>
<p_licensePlate xsi:type="xsd:string">GH23-89</p_licensePlate>
<p_locationID xsi:type="xsd:string"></p_locationID>


<SOAP-ENV:Envelope SOAP-ENV:encodingStyle="http://schemas.xmlsoap.org/soap/encoding/" xmlns:SOAP-ENV="http://schemas.xmlsoap.org/soap/envelope/" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:SOAP-ENC="http://schemas.xmlsoap.org/soap/encoding/">
<ns1:Esws.updateUserDotwebResponse xmlns:ns1="uen:esws">
<return xsi:type="xsd:string">INSERTED</return>