We recommend reviewing what is submitted before posting, in case your idea has already been submitted by another community member. If it has been submitted, vote for that existing feature request (by clicking the up arrow) to increase its opportunity of being added to Cireson solutions.
For more information around feature requests in the Cireson Community click here.
Fully Documented JavaScript API for the Cireson Portal
It would be "really" nice to have access to a fully documented JavaScript API from Cireson for the portal.
Otherwise it’s almost impossible to customise without assistance from Cireson :-/.
I think a lot of customers would appreciate this.
As an example, this would include...
All the possible functions, methods and properties available for configuring cusom.js and other customisable .js config files.
For Example... what are all of the sub functions under "formTasks"? What are its related child methods, and parameters..
Also, with formObj, I understand there are a couple of different methods available e.g. "boundReady", and "boundChange"
What other methods of formObj exist, and what are their methods and properties. It goes on an on.
I understand this is a huge piece of work, and it may take away "some" need for third party customisations away from Cireson and other vendors, but in the end it should provide more of an "openSource" approach to the Cireson portal, which would only increase your userbase, provide more publically available extensions and customisations to the product (which improves the product overall) and ultimately results in further profits for Cireson anyway.
Just my 2 cents.
Comments
I'd love to see more documentation as well-- examples in particular. Understanding how/when custom code executes is the first step towards making a customization, and this is initially illustrated through some knowledge articles. Many of these articles are simple and do not require the API, but are an essential starting point:
https://support.cireson.com/KnowledgeBase/View/52#/
https://support.cireson.com/KnowledgeBase/View/1188#/
https://support.cireson.com/KnowledgeBase/View/1195#/
https://support.cireson.com/KnowledgeBase/View/1166#/
As far as the API itself is concerned, there are some resources already available that come built into any Cireson Portal installation. You can find these as an admin by clicking in the top-right, and selecting "API Documentation."
This page has a list of all the public API calls available. Additionally, there is a .docx file on this page that has several API examples.
So how do you pair the API documentation + API examples with some JavaScript to make a complex customization? In my opinion, the best way to learn this stuff is by example, and there are many examples which use the API on the downloads page.
The Convert IR to PR might be a good place to start, as this customization uses 3 different API calls:
- GetTemplates
- CreateProjectionByTemplate
- Commit
All other API calls follow a similar format, and are called via the parameters specified on the API Documentation page. Browse through the other examples on the downloads page, and if you have any questions about a specific call, just throw the question out to the community.Thanks,
Nick
Hey Nick,
I was already aware of the API Link on the portal, but this is more geared towards the REST API, which does not really help much with JS.
Also the examples are great (from the downloads page), and they have definitely helped me, but this only provides a very small subset of what is possible with the portal.
I really feel a comprehensive API would be much more beneficial than a few examples.
Cheers,
Adrian
Currently I've added this to the custom.js file:
Then going to the console tab you can view the objects and expand them to see what's inside.
I figure it's worth mentioning as it's very intimidating looking at the JavaScript code in CiresonPortal\Scripts
This one I only know about due to the Change Calendar script on the commnuity site.. What other API calls are missing from the documentation?
Another one that is missing : /Search/GetObjectHistory?id=
The API calls published in the "Help" section are the only public calls available and intended for customization. Any other calls (such as /Search/GetObjectHistory) are private and unsupported-- in other words, they are not intended for use in customization. Rather, these calls exist because they support some behind-the-scenes part of the product.
Use any private calls at your own risk, as they are much more likely to change unannounced in a new version of the product. Public calls, on the other hand, are supported and tested with each release.
Thanks,
Nick