From 3.3 version and above, the ability to create custom API endpoints has been added. This allows you to specify which fields you want to share with external parties. 


The first part of the configuration is described in the article Creating Custom Nodes: http://support.clickhome.com.au/solution/articles/3000031218-creating-custom-nodes-technical-


The rest of the setting  is described here, the token substitution and the xslt setting.


In case the inCustomisationType is 1 (Link) you might need to set a token substitution. The scalar valued function fnTokenSubstitution gives information on the different values it can passes in.

The Following Tokens can be imported in the Custom Nodes: 


--#CONTRACTID# - Contract ID

--

--#CONTRACTNO# - Contract No

--

--#CLIENTID# - Client ID

--

--#CLIENTNAME# - Clients full name

--

--#CLIENTEXTREF# - Clients External Reference

--

--#WORKITEMID# - Work Item ID

--

--#WORKITEMWBS# - Work Item Work Breakdown Structure Code

--

--#SUPPLIERID# - Supplier ID

--

--#SUPPLIEREXTREF# - Supplier External Reference

--

--#QUOTENUM# - Quotation Number

--

--#USERID# - User ID

--

--#USERNAME# - User Name


The structure of the token substitution is as follows, the variables need to be comma separated:
1. Userid
2. XSLT Type (1=Contract, 2= Task)
3. Primary Key (Contract id or Task id)
4. XSLT to be used (the name of the file only)
5. Expiry days (days until xml is active, minimum is 1 day)


Ex: #SEKTOK1# #USERID#,1,#CONTRACTID#,ExternalParty,7 #SEKTOK2#


This value has to be entered in tblAppCustomisations in the column sgParameters:


Finally, the xslt: in the tblValidationEntries the default string xlstPath is C:\ClickHome\XsltQuery, you can edit the mLargeText if you prefer to save it in another folder. 


You can customise or use the standard xslt attached, and save it in the folder set in the tblValidationEntries.

 


The xslt file name has to match with the the value 4 of the token substitution, ExternalParty in our example.