Delete user

deleteUser(p_companyID, p_Id, p_locationID)


You can use this endpoint to delete one user from our software.


Name Type Required Description
p_companyID string Yes The security code you have been provided with, string (32)
p_Id integer Yes The Id of the user from the EasySecure database
p_locationID integer No Required only in case the company is Branch.

Return values

NO_ID_RECEIVED - i case no p_ID is provided.

ERROR_UNKNOWN_SECURITY_HASH – no company found based on the security hash used as parameter

ERROR_NO_SECURITY_HASH – no security hash has been provided when the call was made

USER_WAS_NOT_FOUND - user was not found based on the p_Id provided.

Company is Branches but no location has been provided: The location id is required for branch Type companies to be sure we do not delete the user if he is linked to multiple locations.

User has been deleted: The user and his details have been removed from the database.

User does not exist in our db: User with provided id doesn't exist anymore in our database.

User is linked to multiple locations, we will remove the user from this location: User is linked to multiple locations in a Branch type company. We will remove the user only from that location and the groups associated with that location.


When the user is deleted, we also add flags for each of modules the user had access to and during the next syncronization (overwrite or delete sync) the user will also be removed from those modules.


<soapenv:Envelope xmlns:xsi="" xmlns:xsd="" xmlns:soapenv="" xmlns:uen="uen:esws">
<uen:Esws.deleteUser soapenv:encodingStyle="">
<p_companyID xsi:type="xsd:string">^4p;tU0Q+#dEIhTWkuj5FnLD^aKWqVu0</p_companyID>
<p_Id xsi:type="xsd:string">1</p_Id>
<p_locationID xsi:type="xsd:string"></p_locationID>


<SOAP-ENV:Envelope SOAP-ENV:encodingStyle="" xmlns:SOAP-ENV="" xmlns:xsd="" xmlns:xsi="" xmlns:SOAP-ENC="">
<ns1:Esws.deleteUserResponse xmlns:ns1="uen:esws">
<return xsi:type="xsd:string">User has been deleted</return>