Used to link a user to project, activity and subactivity.

bportalUserLink(p_companyID, p_userId, p_codeProject, p_codeActivity, p_codeSubactivity)

 

You can use this endpoint to link a user to a project, activity and subactivity from our software.

Parameters

Name Type Required Description
p_companyID string Yes The security code you have been provided with, string (32)
p_userId string Yes The user's internal id in our db
p_codeProject string Yes Mandatory only in case we want to add a Task, during update it will not be taken in consideration.
p_codeActivity string No The Activity's code, mandatory in case a p_codeSubactivity was supplied, can be left empty if the user needs to be linked only to a Project.
p_codeSubactivity string No The Subactivity's code.

Return values

LINKED – user was successfully linked to the Tasks.

ERROR_NO_SECURITY_HASH - user did not supply p_companyId security code.

ERROR_UNKNOWN_SECURITY_HASH - supplied security code p_companyId is invalid.

USER_NOT_FOUND – no user was identified in our db with the given p_userId value.

PROJECT_NOT_SUPPLIED – no p_codeProject value was supplied by the user.

ACTIVITY_NOT_SUPPLIED_FOR_SUBACTIVITY – there was a p_codeSubactivity value sent, but no p_codeActivity which is mandatory in this case.

CODE_PROJECT_NOT_FOUND – no Project found with the supplied p_codeProject.

CODE_ACTIVITY_NOT_FOUND – no Activity found with the supplied p_codeActivity.

CODE_SUBACTIVITY_NOT_FOUND – no Subactivity found with the supplied p_codeSubactivity.

ACTIVITY_NOT_LINKED_TO_PROJECT – the given p_codeActivity task is not linked to the p_codeProject task.

SUBACTIVITY_NOT_LINKED_TO_ACTIVITY – the given p_codeSubactivity task is not linked to the p_codeActivity task.

CAN_NOT_SAVE_USERSTASKTREES – unknown error happened during linking user to Task(s).

Sample

<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">
<soapenv:Header/>
<soapenv:Body>
<uen:Esws.bportalUserLink soapenv:encodingStyle="http://schemas.xmlsoap.org/soap/encoding/">
<p_companyId xsi:type="xsd:string">^4p;tU0Q+#dEIhTWkuj5FnLD^aKWqVu0</p_companyId>
<p_userId xsi:type="xsd:string">1</p_userId>
<p_codeProject xsi:type="xsd:string">1111</p_codeProject>
<p_codeActivity xsi:type="xsd:string">2222</p_codeActivity>
<p_codeSubactivity xsi:type="xsd:string">3333</p_codeSubactivity>
</uen:Esws.bportalUserLink>
</soapenv:Body>
</soapenv:Envelope>

Response

<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/">
<SOAP-ENV:Body>
<ns1:Esws.bportalUserLinkResponse xmlns:ns1="uen:esws">
<return xsi:type="xsd:string">USER_NOT_FOUND</return>
</ns1:Esws.bportalUserLinkResponse>
</SOAP-ENV:Body>
</SOAP-ENV:Envelope>